/* s-trip.css: the trip team's screen styles, loaded after app/ui.css.

   The plan, the days, the train, who pays, approving, the ticket, the trip days and the keepsake,
   in Candlelight. Every color comes from design/tokens.css; every rule is scoped to a trip screen
   or a class only these screens emit. The accent (gold at night, cranberry by day) stays the one
   main action and the picked car or fare; stamps are ink in the good tone; gold is a hairline.
   Numbers set in Playfair use lining figures so times, prices and dates stand straight. */

/* Lining figures wherever the display serif carries a time, a date or a price */
.screen.plan .hero-title, .screen.today .hero-title, .screen.day .head .h1, .screen.train .head .h1, .screen.approve-screen .head .h1,
.plan-list .row-title, .zayde-list .row-title, .cars .option-title, .plan-card-title, .now-title, .now-count, .tl-item.is-star .tl-title,
.moments .row-title, .stop-head .h2, .screen.ticket-screen .stat-num, .screen.approve-screen .stat-num {
  font-variant-numeric: lining-nums tabular-nums;
}

/* ============================== The plan ============================== */

.screen.plan > .steps { margin: 2px 0; }

/* A grouped list clips its rows, so a row's keyboard ring is drawn inside it */
.plan-list > .row:focus-visible, .zayde-list > .row:focus-visible, .cost-list > .row:focus-visible, .todo > .row:focus-visible,
.tools > .row:focus-visible, .road-links > .row:focus-visible, .sheet-list > .row:focus-visible { outline-offset: -3px; border-radius: var(--r-l); }
/* A pill under a row's line, while that part is still open */
.plan-list .row-main > .pill, .zayde-list .row-main > .pill, .cost-list .row-main > .pill { align-self: flex-start; margin-top: 7px; }

/* The plan at a glance: 44 px picture tiles, a small label, the outcome in the display serif, one
   line, and a pill while a part is still open. Every row opens a screen or a sheet of its own. */
.plan-list > .row { min-height: 78px; padding: 13px 16px 14px 14px; }
.plan-list > button.row { width: 100%; text-align: left; }
.plan-list > .row:has(> .row-icon) + .row:has(> .row-icon)::before { left: 72px; }
.plan-list .row-icon { width: 44px; height: 44px; border-radius: 13px; }
.plan-list .row-icon > svg { width: 34px; height: 34px; }
.plan-list .row-main { gap: 2px; }
.plan-list .row-title { font: 540 19px/1.22 var(--font-display); letter-spacing: -.01em; }
.plan-list > .row-sealed .row-icon { width: 44px; background: none; box-shadow: none; }
.plan-list > .row-sealed .row-icon > svg { width: 38px; height: 38px; filter: drop-shadow(0 2px 2px color-mix(in srgb, var(--art-loco) 40%, transparent)); }

/* Day by day: three storybook cards, each with its big moment and the drawings of its stops */
.days-strip { display: flex; flex-direction: column; gap: 10px; }
.day-card {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 4px 12px;
  padding: 14px 16px 14px 18px;
  border-radius: var(--r-l);
  background: var(--sheen), var(--surface);
  box-shadow: var(--shadow-1), 0 0 0 1px var(--edge);
  color: var(--text);
  text-decoration: none;
  transition: transform .15s var(--ease), box-shadow .15s var(--ease);
}
.day-card:active { transform: scale(.985); }
.day-card > .eyebrow { grid-column: 1; }
.day-card-title { grid-column: 1; font: 540 21px/1.2 var(--font-display); letter-spacing: -.01em; color: var(--heading); text-shadow: var(--heading-glow); }
.day-card-pics { grid-column: 1; display: flex; gap: 6px; margin-top: 6px; }
.day-card-pics > i { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 12px; background: var(--tile); box-shadow: var(--tile-glow); }
.day-card-pics svg { width: 30px; height: 30px; }
.day-card > .chev { grid-column: 2; grid-row: 1 / span 3; align-self: center; color: var(--text-3); }

/* A step that waits on the other adult: their mark, whose turn it is, and the way to that screen */
.next-wait { min-height: 76px; box-shadow: var(--shadow-1), 0 0 0 1px var(--edge); }
.next-wait > .card-media { width: 48px; height: 48px; border-radius: 50%; background: none; box-shadow: none; }
.next-wait > .card-media > .avatar { width: 48px; height: 48px; box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--gold) 65%, transparent); }
.next-wait > .card-media > .avatar svg { width: 22px; height: 22px; }
.next-wait .card-title { font-size: 19px; }
.screen.plan > .next-wait, .screen.approve-screen > .changed-note { margin-top: 2px; }

/* ============================== The days ============================== */

.screen.day > .head { margin-top: 6px; }

/* Where the text of a stop starts: the time column, its gap, the dot column, the next gap. */
.timeline { --tl-text: 116px; }

/* Every stop is one tap: the whole row lifts softly under the finger and shows its chevron */
.timeline > .tl-item:not(.is-skipped) { isolation: isolate; }
.timeline > .tl-item > :not(.tl-time):not(.tl-dot):not(.tl-hit) { padding-right: 30px; }
.tl-hit {
  position: absolute;
  z-index: 2;
  top: -9px;
  bottom: 11px;
  left: calc(var(--tl-text) - 14px);
  right: 0;
  display: flex;
  align-items: flex-start;
  justify-content: flex-end;
  padding: 13px 8px 0 0;
  border: 0;
  border-radius: var(--r-m);
  background: transparent;
  color: var(--text-3);
  cursor: pointer;
  transition: background-color .15s var(--ease), box-shadow .15s var(--ease);
}
.tl-item:last-child > .tl-hit { bottom: -9px; }
.tl-hit svg { width: 18px; height: 18px; }
.tl-hit:hover { background: color-mix(in srgb, var(--text) 4%, transparent); }
.tl-hit:active { background: color-mix(in srgb, var(--gold) 12%, transparent); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--gold) 40%, transparent); }
.tl-hit:focus-visible { outline-offset: -2px; }
/* A button inside a stop (Reveal it) sits above the row's own tap */
.tl-item > .tl-action, .tl-item .tl-back { position: relative; z-index: 3; }

/* Tags under a stop share one wrapping line: the big one, who pays, a wish, a change, a stamp */
.tl-tags { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-top: 8px; }
.tl-tags > .tl-tag { margin: 0; gap: 5px; }
.tl-tag.is-big { background: transparent; box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--gold) 85%, transparent); color: var(--text); }
.tl-tag.is-big svg { width: 15px; height: 15px; flex: none; color: var(--gold-ink); }
.tl-tag.is-money { font-variant-numeric: tabular-nums; }
.tl-tag.is-changed { background: color-mix(in srgb, var(--wait) 17%, transparent); color: var(--wait); }
.tl-tag.is-pick { background: color-mix(in srgb, var(--good) 15%, transparent); color: var(--good); }
.tl-tag.is-pick .mk svg { width: 14px; height: 14px; }
.tl-tag.is-pick .mk .shape { fill: currentColor; }
.tl-tag.is-stamped { min-height: 26px; padding: 2px 9px; border-radius: 7px; background: transparent; box-shadow: inset 0 0 0 1.5px color-mix(in srgb, var(--good) 80%, transparent); color: var(--good); font: 750 12.5px/1 var(--font-ui); letter-spacing: .12em; text-transform: uppercase; transform: rotate(-2deg); }

/* A stamped stop: its dot fills with the good tone and holds a check */
.tl-item.is-done > .tl-dot { display: grid; place-items: center; width: 15px; height: 15px; margin-top: 4px; color: var(--bg); }
.tl-item.is-done > .tl-dot svg { width: 10px; height: 10px; }

/* The train: the day's key moment, a softly lit card in the timeline with the one accent dot.
   The card keeps to the page's right margin, like every other block. */
.timeline > .tl-item.is-star { margin-top: -4px; padding-top: 16px; padding-bottom: 42px; }
.timeline > .tl-item.is-star::after {
  content: "";
  position: absolute;
  z-index: -1;
  top: 0;
  bottom: 24px;
  left: calc(var(--tl-text) - 14px);
  right: 0;
  border-radius: var(--r-l);
  background: linear-gradient(118deg, color-mix(in srgb, var(--accent) 11%, transparent), transparent 64%), var(--surface);
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--accent) 26%, transparent), var(--shadow-1);
}
.timeline > .tl-item.is-star > .tl-dot { margin-top: 5px; }
.timeline > .tl-item.is-star > .tl-hit { top: 0; bottom: 24px; border-radius: var(--r-l); padding-top: 20px; }

/* A wrapped surprise: a small gift that wiggles once when the day opens */
.tl-title:has(> .tl-gift) { display: flex; align-items: center; gap: 8px; }
.tl-gift { display: inline-grid; place-items: center; flex: none; width: 40px; height: 40px; border-radius: 12px; background: var(--tile); box-shadow: var(--tile-glow); }
.tl-gift svg { width: 32px; height: 32px; }
.tl-item.is-wrapped .tl-gift svg { animation: trip-wiggle 1.1s .5s var(--ease) both; transform-origin: 50% 80%; }
@keyframes trip-wiggle { 0%, 100% { transform: rotate(0); } 20% { transform: rotate(-9deg); } 40% { transform: rotate(7deg); } 60% { transform: rotate(-4deg); } 80% { transform: rotate(2deg); } }

/* A stop this phone skipped: faint, at its old time, with Put it back */
.tl-item.is-skipped > .tl-time, .tl-item.is-skipped > .tl-title { opacity: .5; }
.tl-item.is-skipped > .tl-title span { text-decoration: line-through; text-decoration-thickness: 1px; text-decoration-color: color-mix(in srgb, var(--text) 45%, transparent); }
.tl-item.is-skipped > .tl-dot { border-style: dashed; background: transparent; }
.tl-tag.is-skip { background: transparent; box-shadow: inset 0 0 0 1px var(--edge-strong); color: var(--text-3); }
.tl-back {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 40px;
  padding: 0 14px 0 10px;
  border: 0;
  border-radius: 999px;
  background: color-mix(in srgb, var(--gold) 16%, transparent);
  color: var(--text);
  font: 600 14.5px/1 var(--font-ui);
  cursor: pointer;
}
.tl-back svg { width: 16px; height: 16px; }

/* The line of the present moment, on Today */
.timeline > .tl-now { position: relative; height: 0; margin: -11px 0 11px; list-style: none; }
.tl-now::before { content: ""; position: absolute; left: calc(72px + 12px + 4px); right: 0; top: 0; height: 2px; border-radius: 2px; background: var(--accent); box-shadow: var(--accent-glow); }
.tl-now::after { content: ""; position: absolute; left: calc(72px + 12px + 4px - 4px); top: -4px; width: 10px; height: 10px; border-radius: 50%; background: var(--accent); }
.tl-now > span { position: absolute; right: calc(100% - 72px); top: -9px; font: 700 12px/18px var(--font-ui); letter-spacing: .1em; text-transform: uppercase; color: var(--accent); }

/* For a few seconds after a skip: what came off the day, and Undo */
.undo-bar {
  position: fixed;
  left: 0;
  right: 0;
  bottom: calc(var(--tabbar-h) + 16px + env(safe-area-inset-bottom));
  z-index: 70;
  display: flex;
  align-items: center;
  gap: 14px;
  width: fit-content;
  max-width: calc(100% - 32px);
  min-height: 52px;
  margin: 0 auto;
  padding: 6px 6px 6px 20px;
  border-radius: 999px;
  background: var(--text);
  color: var(--bg);
  font: 550 15px/1.3 var(--font-ui);
  box-shadow: var(--shadow-2);
  animation: ui-toast .42s var(--ease-out) both;
}
.undo-btn { flex: none; min-height: 40px; padding: 0 16px; border: 0; border-radius: 999px; background: color-mix(in srgb, var(--bg) 16%, transparent); color: var(--bg); font: 700 15px/1 var(--font-ui); cursor: pointer; }

@media (max-width: 340px) {
  .timeline { --tl-text: 102px; }
  .tl-now::before { left: calc(62px + 10px + 4px); }
  .tl-now::after { left: calc(62px + 10px); }
  .tl-now > span { right: calc(100% - 62px); }
}

/* ============================== A stop, opened ============================== */

/* The top of the sheet: the drawing on a lit tile beside when it is and its name */
.stop-head { display: flex; align-items: center; gap: 16px; margin-top: 2px; }
.stop-art { display: grid; place-items: center; flex: none; width: 84px; height: 84px; border-radius: 24px; background: var(--tile); box-shadow: var(--tile-glow), var(--shadow-1); }
.stop-art > svg { width: 64px; height: 64px; }
.stop-art > .avatar { width: 64px; height: 64px; box-shadow: none; }
.stop-art > .avatar svg { width: 30px; height: 30px; }
.stop-words { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.stop-words .h2 { font-size: 26px; line-height: 1.15; text-wrap: balance; }
.stop-line { margin: 0; font: italic 500 19px/1.4 var(--font-display); color: var(--flourish); text-wrap: pretty; }
.stop-hand { margin: 0; font: 400 18px/1.35 var(--font-hand); color: var(--gold-ink); }

/* Facts: a small label, then the value; the address carries Open in Maps */
.facts { display: flex; flex-direction: column; margin: 0; border-radius: var(--r-l); background: var(--surface); box-shadow: var(--shadow-1), 0 0 0 1px var(--edge); }
.fact { display: grid; grid-template-columns: minmax(98px, max-content) minmax(0, 1fr); gap: 12px; padding: 13px 16px; }
.fact + .fact { border-top: 1px solid var(--line); }
.fact dt { padding-top: 2px; font: 700 11.5px/1.4 var(--font-ui); letter-spacing: .08em; text-transform: uppercase; color: var(--gold-ink); overflow-wrap: normal; }   /* a label never breaks inside a word */
.fact dd { margin: 0; font-size: 16px; line-height: 1.45; color: var(--text); font-variant-numeric: tabular-nums; }
.fact dd > .map-link { display: flex; margin: 2px 0 -10px; }
.fact dd > .pill { margin-left: 4px; vertical-align: 1px; }
.sheet .stop-change { display: flex; flex-direction: column; gap: 8px; margin-top: 4px; }
.sheet .stop-change > .fine, .sheet > .fine { display: flex; align-items: flex-start; gap: 8px; }
.sheet .stop-change > .fine svg, .sheet > .fine svg { flex: none; width: 18px; height: 18px; margin-top: 1px; color: var(--text-3); }
.sheet > .check { margin-top: 2px; }

/* The confirmation, ready to copy */
.code-chip {
  display: inline-flex;
  align-items: baseline;
  gap: 10px;
  min-height: 40px;
  padding: 6px 14px;
  border: 1.5px dashed color-mix(in srgb, var(--gold) 70%, transparent);
  border-radius: var(--r-s);
  background: color-mix(in srgb, var(--gold) 8%, transparent);
  color: var(--text);
  cursor: pointer;
}
.code-chip b { font: 700 18px/1.3 var(--font-ui); letter-spacing: .12em; font-variant-numeric: tabular-nums; }
.code-chip small { display: inline-flex; align-items: center; gap: 4px; font-size: 13px; color: var(--text-2); }
.code-chip small svg { width: 15px; height: 15px; }

/* Keep it on your phone: two numbered steps with their icons */
.home-steps { display: flex; flex-direction: column; gap: 10px; margin: 0; padding: 0; list-style: none; counter-reset: step; }
.home-steps li { display: flex; align-items: center; gap: 14px; min-height: 56px; padding: 8px 16px; border-radius: var(--r-m); background: var(--surface); box-shadow: 0 0 0 1px var(--edge); font-size: 16.5px; counter-increment: step; }
.home-steps li::before { content: counter(step); display: grid; place-items: center; flex: none; width: 26px; height: 26px; border-radius: 50%; background: var(--accent); color: var(--on-accent); font: 700 14px/1 var(--font-ui); }
.home-ic { display: grid; place-items: center; flex: none; color: var(--text-2); }

/* ============================== The train ============================== */

.cars .option { min-height: 112px; transition: opacity .3s var(--ease), transform .3s var(--ease), box-shadow .3s var(--ease); }
.cars .option-price { margin-top: 6px; font-variant-numeric: lining-nums tabular-nums; }
.cars.is-tossing .option { pointer-events: none; }
.car-theirs { gap: 6px; padding-left: 7px; background: color-mix(in srgb, var(--text) 7%, transparent); color: var(--text); }
.car-theirs .mk svg { width: 16px; height: 16px; }
.car-won { gap: 5px; }
.car-won svg { width: 13px; height: 13px; }
/* The car the coin turned down rests quietly, with a kind line */
.cars .option.is-lost { opacity: .62; box-shadow: none; background: transparent; border-style: dashed; }
.cars .option.is-lost .option-art { filter: saturate(.4); }
.car-lost { font-style: italic; }
/* The winner lights up as the coin lands */
.cars .option.is-live { animation: trip-win .9s var(--ease-out) both; }
@keyframes trip-win { 0% { transform: scale(.98); box-shadow: 0 0 0 0 color-mix(in srgb, var(--accent) 0%, transparent); } 40% { transform: scale(1.02); box-shadow: 0 0 0 10px color-mix(in srgb, var(--accent) 22%, transparent), var(--accent-glow); } 100% { transform: none; } }
.car-treat { display: flex; align-items: center; gap: 8px; margin: -2px 2px 0; }
.car-treat svg { flex: none; width: 18px; height: 18px; color: var(--gold-ink); }
.zayde-list .row { min-height: 72px; }
.zayde-list .row-title { font: 540 19px/1.22 var(--font-display); letter-spacing: -.01em; }
.zayde-list .option-price { margin-top: 2px; }

/* The conductor's coin: gold, Akshay's star on one face and Krista's heart on the other */
.coin-toss {
  appearance: none;
  align-self: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  min-width: 48px;
  padding: 8px 18px 4px;
  border: 0;
  border-radius: var(--r-l);
  background: none;
  color: var(--text);
  font: 600 15.5px/1.3 var(--font-ui);
  cursor: pointer;
  perspective: 800px;
}
.coin-toss.is-landed, .coin-toss.is-tossing { cursor: default; }
.coin-toss.is-landed .coin-label { color: var(--text-2); font-weight: 500; }
.coin-toss.is-landed.is-live .coin-label { color: var(--text); font: italic 500 19px/1.3 var(--font-display); animation: ui-land .5s .1s var(--ease) both; }
.coin-legend { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px 16px; font: 500 14.5px/1.3 var(--font-ui); color: var(--text-2); }
.coin-legend > span { display: inline-flex; align-items: center; gap: 6px; }
.coin-legend .mk svg { width: 16px; height: 16px; }
.coin-legend .mk .shape { fill: var(--gold-ink); }
.toss-coin { position: relative; display: block; width: 84px; height: 84px; transform-style: preserve-3d; transition: transform .25s var(--ease); }
.coin-toss.is-landed .toss-coin { width: 64px; height: 64px; }
.toss-coin .face {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: radial-gradient(circle at 34% 28%, var(--bulb-gold), var(--gold) 58%, color-mix(in srgb, var(--gold) 72%, var(--art-loco)) 100%);
  box-shadow: inset 0 0 0 2px color-mix(in srgb, var(--bulb-gold) 70%, transparent), inset 0 0 0 6px color-mix(in srgb, var(--gold) 90%, var(--art-loco)), inset 0 0 0 7px color-mix(in srgb, var(--bulb-gold) 50%, transparent), var(--shadow-1);
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
}
.toss-coin .face svg { width: 44%; height: 44%; filter: drop-shadow(0 1px 0 color-mix(in srgb, var(--bulb-gold) 70%, transparent)); }
.toss-coin .face .shape { fill: var(--art-coach-dark); stroke: none; }
.toss-coin .back { transform: rotateY(180deg); }
.toss-coin.show-back { transform: rotateY(180deg); }
button.coin-toss:hover .toss-coin { transform: translateY(-3px) rotate(-8deg); }
button.coin-toss:active .toss-coin { transform: scale(.96); }
.toss-coin.is-spinning { animation: trip-spin .5s linear infinite; }
.toss-coin.land-front { animation: trip-land-front 1.4s cubic-bezier(.25, .7, .35, 1) both; }
.toss-coin.land-back { animation: trip-land-back 1.4s cubic-bezier(.25, .7, .35, 1) both; }
@keyframes trip-spin { from { transform: translateY(-30px) rotateY(0); } to { transform: translateY(-30px) rotateY(720deg); } }
@keyframes trip-land-front { 0% { transform: translateY(0) rotateY(0) scale(1); } 40% { transform: translateY(-110px) rotateY(1260deg) scale(1.15); } 85% { transform: translateY(4px) rotateY(2120deg) scale(1); } 100% { transform: translateY(0) rotateY(2160deg); } }
@keyframes trip-land-back { 0% { transform: translateY(0) rotateY(0) scale(1); } 40% { transform: translateY(-110px) rotateY(1260deg) scale(1.15); } 85% { transform: translateY(4px) rotateY(2300deg) scale(1); } 100% { transform: translateY(0) rotateY(2340deg); } }
.coin-toss.is-landed.is-live .toss-coin { animation: trip-settle .5s var(--ease-out) both; }
@keyframes trip-settle { 0% { scale: 1.12; } 100% { scale: 1; } }
.screen.train > .train-next { margin-top: 4px; }

/* ============================== Who pays what ============================== */

/* Akshay's aside in his hand, under the header */
.hand-aside { margin-top: -4px; font: 400 20px/1.35 var(--font-hand); color: var(--gold-ink); }
.cost-list > .row { min-height: 66px; }
.cost-list .row-trail { gap: 10px; }
.cost-list .amount { font: 600 16px/1.2 var(--font-ui); color: var(--text); font-variant-numeric: lining-nums tabular-nums; }
.cost-list .amount.is-day { font: 500 13.5px/1.25 var(--font-ui); color: var(--text-3); white-space: nowrap; }
.pays-none { padding: 2px 2px 0; font-size: 15.5px; color: var(--text-2); }
.screen.costs .sealed-gate { display: flex; flex-direction: column; align-items: center; gap: 14px; padding: 18px 0 4px; text-align: center; }
.screen.costs .sealed-gate .lede { max-width: 26ch; }

/* ============================== The trip's sheets ============================== */

.sheet > .eyebrow + .h2 { margin-top: -8px; }
.sheet > .muted { margin-top: -6px; font-size: 16px; line-height: 1.45; text-wrap: pretty; }
.sheet > .stop-line + .muted { margin-top: -8px; }
.sheet .sheet-list { margin-top: 2px; }
.sheet .sheet-list > .row { min-height: 64px; }
.sheet .sheet-list > form.row { padding: 12px 14px 14px; }
.sheet .sheet-foot { display: flex; flex-direction: column; gap: 4px; margin-top: 6px; }
.sheet .sheet-foot > .btn-quiet { margin-top: 0; }
.sheet .options .option { min-height: 78px; }
.sheet .options + .btn-lg { margin-top: 4px; }
.sheet .road-later { display: flex; flex-direction: column; gap: 10px; }
.sheet .road-later input {
  width: 100%;
  min-height: 56px;
  padding: 0 14px;
  border: 1px solid var(--edge-strong);
  border-radius: var(--r-m);
  background: var(--surface);
  color: var(--text);
  font: 600 22px/1.2 var(--font-ui);
  font-variant-numeric: tabular-nums;
}
.sheet .road-later input:focus { outline: none; border-color: var(--focus); box-shadow: 0 0 0 3px color-mix(in srgb, var(--focus) 35%, transparent); }

/* ============================== Approve ============================== */

.screen.approve-screen > .steps { margin: 2px 0; }
.todo > .row { min-height: 68px; }
.todo > button.row { width: 100%; text-align: left; }
.todo .row-trail { gap: 10px; }
.todo-mark { display: grid; place-items: center; width: 26px; height: 26px; border-radius: 50%; box-shadow: inset 0 0 0 1.5px color-mix(in srgb, var(--text) 40%, transparent); }
.todo-mark.is-done { background: var(--good); box-shadow: none; color: var(--bg); }
.todo-mark svg { width: 14px; height: 14px; }

/* The plan both of you seal: one card, its facts, and the two wax seals at its foot */
.plan-card .card-body { gap: 10px; padding-bottom: 18px; }
.plan-card-title { font: 540 26px/1.15 var(--font-display); letter-spacing: -.012em; color: var(--heading); text-shadow: var(--heading-glow); }
.plan-card .facts { background: transparent; box-shadow: none; border-top: 1px solid var(--line); border-radius: 0; }
.plan-card .fact { padding: 10px 0; grid-template-columns: minmax(76px, max-content) minmax(0, 1fr); }
.plan-card .fact:last-child dd { font-weight: 600; }
.seals { display: flex; justify-content: center; gap: 36px; padding: 14px 0 2px; border-top: 1px solid var(--line); }
.seal-slot { display: flex; flex-direction: column; align-items: center; gap: 6px; }
.seal-slot small { font: 600 13px/1.2 var(--font-ui); color: var(--text-2); }
.seal-wax { display: grid; place-items: center; width: 66px; height: 66px; }
.seal-wax > svg { width: 58px; height: 58px; filter: drop-shadow(0 3px 3px color-mix(in srgb, var(--art-loco) 45%, transparent)); }
.seal-ring { display: grid; place-items: center; width: 58px; height: 58px; border-radius: 50%; border: 2px dashed color-mix(in srgb, var(--gold) 70%, transparent); }
.seal-ring svg { width: 22px; height: 22px; }
.seal-ring .shape { fill: none; stroke: color-mix(in srgb, var(--gold-ink) 80%, transparent); stroke-width: 1.6; }
.seal-slot.is-pressing .seal-wax > svg { animation: trip-press .62s cubic-bezier(.2, .9, .3, 1.25) both; }
@keyframes trip-press { 0% { transform: translateY(-46px) scale(1.6) rotate(-14deg); opacity: 0; } 55% { transform: translateY(0) scale(.92) rotate(3deg); opacity: 1; } 75% { transform: scale(1.05); } 100% { transform: none; } }
.seals-line { margin: 0; text-align: center; font: italic 500 17px/1.35 var(--font-display); color: var(--text-2); }

/* Booking: the cheat sheet of what to book, then the booking page and the confirmation */
.book-card .card-body { gap: 10px; }
.book-card .card-sub { margin-bottom: 4px; }
.book-card .field { margin-top: 8px; padding-top: 16px; border-top: 1px solid var(--line); }
.book-card .field .actions { margin-top: 2px; }
.cheat { display: flex; flex-direction: column; gap: 6px; margin: 2px 0 6px; padding: 14px 16px 6px; border-radius: var(--r-m); background: color-mix(in srgb, var(--gold) 8%, transparent); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--gold) 45%, transparent); }
.cheat-lines { display: flex; flex-direction: column; gap: 4px; margin: 0; padding: 0; list-style: none; font-size: 16px; line-height: 1.4; font-variant-numeric: lining-nums tabular-nums; }
.cheat-lines .is-lead { font: 600 17px/1.35 var(--font-ui); }
.cheat-copy { align-self: flex-start; gap: 8px; min-height: 44px; margin-left: -10px; padding: 0 10px; }
.cheat-copy svg { width: 18px; height: 18px; }

/* Booked: the ticket prints out of its slot and the Booked stamp punches down */
.booked-print { position: relative; }
.booked-print .print-slot { display: none; }
.booked-print.is-printing { padding-top: 10px; }
.booked-print.is-printing .print-slot { display: block; position: absolute; z-index: 2; top: 0; left: -6px; right: -6px; height: 12px; border-radius: 6px; background: var(--surface-2); box-shadow: inset 0 3px 4px color-mix(in srgb, var(--art-loco) 50%, transparent); }
.booked-print.is-printing .ticket { animation: trip-print 1.1s cubic-bezier(.2, .8, .25, 1) both; clip-path: inset(0 -20px -40px -20px); }
@keyframes trip-print { 0% { transform: translateY(-62%); opacity: .2; } 70% { transform: translateY(2%); opacity: 1; } 100% { transform: none; } }
.screen.approve-screen.is-booked > .btn-primary { margin-top: 2px; }

/* ============================== The ticket ============================== */

/* The first open after the booking: the ticket slides up like a pass and the stamp punches */
.booked-hello { margin: 2px 0 -6px; text-align: center; font: italic 500 20px/1.35 var(--font-display); color: var(--flourish); animation: ui-land .5s var(--ease) both; }
.ticket-wrap.is-arriving > .ticket { animation: trip-arrive .9s cubic-bezier(.16, 1, .3, 1) both; }
@keyframes trip-arrive { from { transform: translateY(70px) scale(.96); opacity: 0; } to { transform: none; opacity: 1; } }
.ticket-wrap.is-arriving .stamp:not(.wait) { animation: stamp .36s .7s cubic-bezier(.2, .9, .3, 1.3) both; }

/* The stub as the day's guide, the stamps Zayde pressed, and the confirmation */
.ticket-stub .stub-line { color: var(--text-2); font-size: 15.5px; line-height: 1.4; }
.ticket-stub .guide { display: flex; flex-direction: column; gap: 8px; margin-top: 4px; }
.guide-row { display: grid; grid-template-columns: 52px minmax(0, 1fr) auto; align-items: baseline; gap: 8px; }
.guide-row b { font: 600 16.5px/1.3 var(--font-ui); }
.guide-row small { font-size: 14px; color: var(--text-2); font-variant-numeric: tabular-nums; }
.guide-train { display: flex; align-items: center; gap: 8px; margin-top: 2px; font: italic 500 19px/1.3 var(--font-display); color: var(--flourish); font-variant-numeric: lining-nums tabular-nums; }
.guide-train svg { flex: none; width: 18px; height: 18px; color: var(--gold-ink); }
.ticket-stub .stub-today { margin-top: 8px; }
.tk-stamps { display: flex; flex-direction: column; gap: 6px; margin-top: 10px; padding-top: 12px; border-top: 1px dashed var(--line); }
.tk-stamps .keep-stamps { padding-top: 2px; }
.tk-stamps .stamp small, .keep-stamps .stamp small { display: block; margin-top: 3px; font-size: 10.5px; letter-spacing: .1em; opacity: .8; }
.stub-code { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; margin-top: 10px; padding-top: 12px; border-top: 1px dashed var(--line); }

.pack-card .card-body { gap: 10px; }
.pack-card .pack-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px 16px; margin: 2px 0 0; padding: 0; list-style: none; font-size: 15.5px; line-height: 1.35; }
.pack-card .pack-list li { position: relative; padding-left: 16px; }
.pack-card .pack-list li::before { content: ""; position: absolute; left: 1px; top: .5em; width: 7px; height: 7px; border-radius: 50%; box-shadow: inset 0 0 0 1.5px var(--gold); }
.pack-card .check { margin-top: 4px; padding-top: 14px; border-top: 1px solid var(--line); }
.ready-card .card-body { padding: 8px 20px; }
.tools .row-icon { color: var(--text-2); }
.tools > button.row { width: 100%; text-align: left; }

/* ============================== Trip days ============================== */

.welcome-card .card-title { font-size: 24px; }

/* Now, Next and Leave by: one calm card with a live countdown */
.now-card .card-body { gap: 0; padding: 18px 20px 0; }
.now-main { position: relative; display: flex; flex-direction: column; gap: 4px; padding-bottom: 16px; }
.now-title { font: 540 28px/1.12 var(--font-display); letter-spacing: -.016em; text-wrap: balance; }
.now-count { font: italic 500 34px/1.1 var(--font-display); letter-spacing: -.01em; color: var(--flourish); text-shadow: var(--heading-glow); }
.now-count + .now-title { font-size: 22px; }
.now-cells { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); margin: 0 -20px; border-top: 1px solid var(--line); }
.now-cell { display: flex; flex-direction: column; gap: 2px; min-width: 0; padding: 14px 20px 16px; }
.now-cell + .now-cell { border-left: 1px solid var(--line); }
.now-cell b { display: inline-flex; align-items: center; gap: 6px; font: 600 17px/1.25 var(--font-ui); color: var(--text); }
.now-cell b svg { width: 18px; height: 18px; flex: none; }
.now-cell .n { font-size: 14.5px; line-height: 1.35; color: var(--text-2); font-variant-numeric: tabular-nums; }
.now-cell .n.is-count { font-weight: 650; color: var(--wait); }
.now-cell.is-leave b { color: var(--wait); font-variant-numeric: tabular-nums; }
.now-card:not(:has(.now-cells)) .now-main { padding-bottom: 18px; }
.now-stamps { display: flex; align-items: center; gap: 8px; margin: 0 -20px; padding: 12px 20px 14px; border-top: 1px solid var(--line); font: 600 14.5px/1.3 var(--font-ui); color: var(--good); }
.now-stamps svg { width: 16px; height: 16px; flex: none; }
.map-link { display: inline-flex; align-items: center; gap: 6px; align-self: flex-start; min-height: 44px; margin: 0 0 -10px; color: var(--text); font: 600 15px/1.3 var(--font-ui); text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1px; }
.map-link svg { width: 18px; height: 18px; flex: none; color: var(--text-2); }
/* Zayde's stamp, pressed onto the card once the stop is stamped: an ink thump */
.now-stamp { position: absolute; top: -2px; right: -4px; }
.now-stamp .stamp { transform: rotate(-8deg); }
.now-stamp.live .stamp { animation: trip-stamp .46s cubic-bezier(.2, .9, .3, 1.35) both; }
.now-stamp.live::after { content: ""; position: absolute; inset: -10px; border-radius: 14px; box-shadow: 0 0 0 2px color-mix(in srgb, var(--good) 50%, transparent); animation: trip-ink .6s .12s var(--ease-out) both; pointer-events: none; }
@keyframes trip-stamp { 0% { transform: rotate(-8deg) scale(2.6); opacity: 0; } 55% { transform: rotate(-8deg) scale(.9); opacity: 1; } 100% { transform: rotate(-8deg) scale(1); opacity: 1; } }
@keyframes trip-ink { from { transform: scale(.6); opacity: 1; } to { transform: scale(1.5); opacity: 0; } }
.now-stamp + .eyebrow, .now-stamp ~ .now-title { padding-right: 96px; }
/* Train day: the sky lantern glows on Today */
.today-lantern > .row { min-height: 68px; }
.today-lantern .row-icon { background: radial-gradient(circle at 50% 40%, color-mix(in srgb, var(--bulb-amber) 30%, transparent), transparent 70%), var(--tile); box-shadow: var(--tile-glow), 0 0 22px -6px var(--bulb-amber); }
.today-lantern .row-title { font: 540 19px/1.25 var(--font-display); }
.stamp-btn { gap: 10px; }
.stamp-btn svg { width: 22px; height: 22px; }

/* The road check on the morning of Day 1; once called, just the call */
.road-card .card-body { gap: 8px; }
.road-card .card-title { font-size: 24px; }
.road-card.is-called .card-body { gap: 6px; padding-bottom: 14px; }
.road-card.is-called .card-title { font-size: 19px; }
.road-called { display: flex; align-items: center; gap: 8px; }
.road-call { margin: 2px 0 0; }
.road-called .road-call { flex: 1 1 auto; min-width: 0; margin: 0; }
.road-call .pill { white-space: normal; text-align: left; }
.road-call .pill svg { width: 13px; height: 13px; }
.road-change { min-height: 40px; margin: 0 0 0 auto; padding: 0 12px; }
.road-links { margin-top: 6px; background: var(--surface-2); box-shadow: none; }
.road-links > .row { min-height: 52px; }
.road-card .card-body > .btn { margin-top: 8px; }
.road-card .card-body > .btn-secondary { margin-top: 0; gap: 8px; }
.road-card .card-body > .btn-secondary svg { width: 20px; height: 20px; }

/* ============================== The keepsake ============================== */

.keepsake-ornament { padding-top: 2px; }
.moments > .row { align-items: start; padding-block: 13px; }
.moments .row-main { gap: 3px; }
.moments .row-title { font: 500 18px/1.38 var(--font-display); letter-spacing: -.005em; text-wrap: pretty; }
.keep-stamps { display: flex; flex-wrap: wrap; gap: 12px 8px; padding: 6px 2px 2px; }
.keep-stamps .stamp:nth-child(2n) { transform: rotate(3deg); }
.keep-stamps .stamp:nth-child(3n) { transform: rotate(-2deg); }
/* Where we went: all three days; what Zayde stamped in ink, the rest in plain type */
.went { display: flex; flex-direction: column; gap: 16px; }
.went-day { display: flex; flex-direction: column; gap: 4px; }
.went-stop { display: inline-flex; align-items: center; min-height: 30px; padding: 5px 9px; border-radius: 9px; box-shadow: inset 0 0 0 1px var(--edge-strong); color: var(--text-3); font: 600 12.5px/1 var(--font-ui); letter-spacing: .08em; text-transform: uppercase; }
/* Every note, kept: his words line by line, and her reply under each in her own color */
.note.kept .kept-one { display: flex; flex-direction: column; gap: 8px; }
.kept-reply { display: flex; align-items: flex-start; gap: 8px; margin-left: 14px; font-family: var(--font-display); font-style: italic; font-size: .82em; color: var(--note-ink-2); }
.kept-reply .mk svg { width: 14px; height: 14px; margin-top: 5px; }
.kept-reply .mk .shape { fill: var(--bulb-red); }
.kept-reply small { display: block; font: 600 11.5px/1.4 var(--font-ui); letter-spacing: .1em; text-transform: uppercase; font-style: normal; color: var(--note-ink-2); }

/* The keepsake on paper */
@media print {
  .keep-print { display: flex; flex-direction: column; gap: 18px; max-width: 6.5in; margin: 0 auto; }
  .keep-print .keepsake-ornament { display: flex; justify-content: center; }
  .keep-print .went-stop { box-shadow: inset 0 0 0 1px currentColor; }
}

@media (prefers-reduced-motion: reduce) {
  .toss-coin, .now-stamp .stamp, .now-stamp::after, .seal-slot .seal-wax > svg, .booked-print .ticket, .ticket-wrap .ticket, .ticket-wrap .stamp,
  .cars .option, .tl-gift svg, .booked-hello, .coin-toss .coin-label, .undo-bar { animation: none !important; transition: none !important; }
}
