/* Weddings: the opening ticket, the tally of what needs flowers, the call list. Grouped: layout, type, colour, motion. */

/* ---------- LAYOUT ---------- */

/* Opening ticket: words on the left, the wedding photograph on the right. */
.aisle {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, clamp(16rem, 30vw, 22rem));
  align-items: center;
  gap: clamp(1.5rem, 4vw, 3rem);
  inline-size: 100%;
}
.aisle > div { display: flex; flex-direction: column; gap: 1rem; }
.aisle > div > * { margin: 0; }
.aisle > figure img { aspect-ratio: 4 / 5; object-position: center 35%; }
@media (max-width: 47.99rem) {
  .aisle { grid-template-columns: minmax(0, 1fr); }
  .aisle > figure img { aspect-ratio: 4 / 3; }
}

/* Tickets inside a rack share the row by their own weight, not by the ticket width. */
.rack > .ticket { flex: 1 1 22rem; inline-size: auto; margin-inline: 0; }
.rack > .ticket[data-cut="narrow"] { flex: 0.8 1 18rem; }

/* Tally: the list of what needs flowers. */
.tally > ul { display: grid; gap: 0.5rem; margin: 0; padding: 0; list-style: none; }
.tick {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 1rem;
  inline-size: 100%;
  min-block-size: 3.25rem;
  padding: 0.25rem;
  border: 0;
  background: none;
  text-align: start;
  cursor: pointer;
}
.tick > span:first-child {
  display: grid;
  place-items: center;
  inline-size: 2.75rem;
  block-size: 2.75rem;
  --hem: 0.3125rem;
  --seam: 0.5rem;
}
.tick > span:first-child::after {
  content: "";
  inline-size: 0.55rem;
  block-size: 1.05rem;
  margin-block-end: 0.25rem;
  border: solid;
  border-width: 0 0.25rem 0.25rem 0;
  transform: rotate(45deg) scale(0);
}
.tick[aria-pressed="true"] > span:first-child::after { transform: rotate(45deg) scale(1); }
.tally > footer { display: grid; gap: 0.5rem; padding-block-start: 0.5rem; }
.tally > footer > p { margin: 0; }

/* Call list: five numbered things to bring. */
.ticket > ol { display: grid; gap: 1.1rem; margin: 0; padding: 0; list-style: none; counter-reset: bring; }
.ticket > ol > li {
  display: grid;
  grid-template-columns: 2.5rem minmax(0, 1fr);
  column-gap: 0.75rem;
  counter-increment: bring;
}
.ticket > ol > li::before { content: counter(bring); grid-row: 1 / span 2; }

/* ---------- TYPE ---------- */

.aisle > div > p { font-size: clamp(1.0625rem, 0.95rem + 0.5vw, 1.25rem); }
.tick > span:last-child { font-size: 1.1875rem; line-height: 1.3; }
.tally > footer > p:first-child { font-family: var(--jost); font-weight: 500; font-size: 1.375rem; line-height: 1.2; }
.tally > footer > p:last-child { font-size: 1rem; }
.ticket > ol > li::before { font-family: var(--jost); font-weight: 500; font-size: 1.875rem; line-height: 1; }
.ticket > ol > li > strong { font-family: var(--jost); font-weight: 500; font-size: 1.25rem; line-height: 1.2; }
.ticket > ol > li > span { font-size: 1.0625rem; }
.tick:hover > span:last-child { text-decoration: underline; text-decoration-thickness: 0.08em; text-underline-offset: 0.2em; }

/* ---------- COLOUR ---------- */

/* Check box, open: pale with the double frame in magenta. */
.tick { color: var(--magenta); }
.tick > span:first-child {
  background: var(--blush);
  color: var(--magenta);
  outline: var(--twine) solid var(--magenta);
  outline-offset: calc(-1 * var(--hem));
  box-shadow: inset 0 0 0 var(--seam) var(--blush), inset 0 0 0 calc(var(--seam) + var(--thread)) var(--magenta);
}
/* Check box, ticked: solid magenta with the strokes reversed. */
.tick[aria-pressed="true"] > span:first-child {
  background: var(--magenta);
  color: var(--blush);
  outline-color: var(--blush);
  box-shadow: inset 0 0 0 var(--seam) var(--magenta), inset 0 0 0 calc(var(--seam) + var(--thread)) var(--blush);
}
.tick:hover > span:first-child { box-shadow: inset 0 0 0 var(--seam) var(--blush), inset 0 0 0 calc(var(--seam) + var(--twine)) var(--magenta); }
.tick[aria-pressed="true"]:hover > span:first-child { box-shadow: inset 0 0 0 var(--seam) var(--magenta), inset 0 0 0 calc(var(--seam) + var(--twine)) var(--blush); }
.tick:focus-visible { outline: 0.1875rem solid var(--magenta); outline-offset: 0.15rem; }

/* ---------- MOTION ---------- */

.tick > span:first-child { transition: background-color 200ms ease-out, box-shadow 200ms ease-out; }
.tick > span:first-child::after { transition: transform 200ms cubic-bezier(0.2, 0.7, 0.2, 1); }
