/* ═════════════════════════════════════════════════════════════════════════
   ADMIT ONE · Movie-Night Birthday — Card (cinema ticket)
   Mood: a real ticket on a dark marquee stage — cream paper, marquee red,
   gold, teal ink. Deck: 100dvh shell, one active panel scrolls, bottom
   section tabs (text + icon) built from the panels that actually exist.

   Optional media (all hidden by deleting the block — see index.html and
   assets/img/README.md):
     · .ticket-photo   honoree photo on the ticket (lightbox)
     · .stage-photo    dimmed backdrop behind the ticket (lightbox)
     · .banner-flyer   official flyer / poster in Showtimes (lightbox)
     · .story-gallery  highlights gallery in the Highlights panel (lightbox)
     · .film-card      video URL embed in the Highlights panel (no file)
   Every photo opens the full-screen viewer built by main.js (zoom + pan +
   "open original"); every slot ships an on-theme SVG placeholder.
   ═════════════════════════════════════════════════════════════════════════ */

/* ── 1 · Design tokens ─────────────────────────────────────────────────── */
:root {
  /* stage (dark theatre) */
  --stage:        #131019;
  --stage-solid:  #17131f;
  --stage-2:      #1b1626;
  --stage-3:      #241d33;

  /* ticket paper & ink */
  --paper:        #f4ead2;
  --paper-2:      #ecdfc0;
  --paper-3:      #e2d3ae;
  --ink:          #2a2118;
  --ink-soft:     rgba(42, 33, 24, .78);
  --ink-muted:    rgba(42, 33, 24, .58);
  --ink-faint:    rgba(42, 33, 24, .34);

  /* cinema accents */
  --red:          #b3202e;
  --red-deep:     #861c26;
  --red-soft:     #c94a56;
  --gold:         #e0b24a;
  --gold-deep:    #a97e1f;
  --gold-soft:    rgba(224, 178, 74, .45);
  --teal:         #2a6f6b;
  --teal-deep:    #1c4d4a;

  /* light text on dark screens */
  --cream:        #f4ead2;
  --cream-dim:    rgba(244, 234, 210, .78);
  --muted:        rgba(244, 234, 210, .55);
  --faint:        rgba(244, 234, 210, .36);
  --line:         rgba(224, 178, 74, .35);
  --line-soft:    rgba(224, 178, 74, .16);

  --danger:       #ff9aa4;
  --ok:           #9fd6a4;

  --font-marquee: "Limelight", "Copperplate", "Bebas Neue", sans-serif;
  --font-display: "Bebas Neue", "Oswald", Impact, "Arial Narrow", sans-serif;
  --font-script:  "Great Vibes", "Segoe Script", "Brush Script MT", cursive;
  --font-body:    "Jost", "Avenir Next", "Segoe UI", system-ui, sans-serif;
  --font-mono:    "Courier Prime", "Courier New", monospace;

  --radius: 14px;
  --ease-out: cubic-bezier(.22, .8, .24, 1);
  --ease-out-expo: cubic-bezier(.16, 1, .3, 1);
  --shadow-panel: 0 30px 80px rgba(0, 0, 0, .55);
}

/* ── 2 · Reset & base ──────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }

html, body { height: 100%; }

body {
  margin: 0;
  font-family: var(--font-body);
  font-weight: 300;
  color: var(--cream);
  background: var(--stage);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overscroll-behavior: none;
}

h1, h2, h3, p, dl, dd, figure { margin: 0; }

img { max-width: 100%; }

button { font-family: inherit; }

::selection { background: rgba(224, 178, 74, .35); color: var(--ink); }

:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; }

.sr-only {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

/* ── 3 · Deck shell — 100dvh, only the active panel scrolls ───────────── */
.site {
  position: fixed;
  inset: 0;
  height: 100vh;
  height: 100dvh;
  overflow: hidden;
  background: var(--stage);
  display: flex;
  flex-direction: column;
}

.deck { position: relative; flex: 1 1 auto; min-height: 0; }

.panel {
  position: absolute;
  inset: 0;
  overflow: hidden;                    /* inactive panels do not scroll */
  opacity: 0;
  visibility: hidden;
  transform: scale(.985) translateY(14px);
  transition: opacity .55s var(--ease-out), transform .55s var(--ease-out), visibility 0s linear .55s;
  pointer-events: none;
}

.panel.is-active {
  opacity: 1;
  visibility: visible;
  transform: none;
  transition: opacity .55s var(--ease-out), transform .55s var(--ease-out);
  pointer-events: auto;
  overflow-y: auto;                    /* ← only the active panel scrolls */
  overflow-x: hidden;                  /* decorative off-canvas art never creates a scrollbar */
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
  scrollbar-width: thin;
  scrollbar-color: var(--gold-deep) transparent;
}

.panel.is-active::-webkit-scrollbar { width: 8px; }
.panel.is-active::-webkit-scrollbar-thumb { background: var(--gold-deep); border-radius: 8px; }
.panel.is-active::-webkit-scrollbar-track { background: transparent; }

/* Sections that need room to breathe inside a scrolling panel */
.panel-scroll {
  max-width: 680px;
  margin: 0 auto;
  padding: clamp(48px, 9vh, 88px) clamp(18px, 5vw, 36px) clamp(72px, 12vh, 110px);
}

/* ── staggered entrance for panel content (main.js stamps --stagger) ────
   The ticket and paper cards cascade into place on every panel change.
   prefers-reduced-motion disables it (see §13). */
.panel.is-active .ticket-main > *,
.panel.is-active .paper > *:not(.paper-edge) {
  animation: rise-in .55s var(--ease-out-expo) both;
  animation-delay: calc(.08s + var(--stagger, 0) * 55ms);
}
.panel.is-active .detail-row {
  animation: rise-in .5s var(--ease-out-expo) both;
  animation-delay: calc(.3s + var(--stagger, 0) * 55ms);
}
@keyframes rise-in {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: none; }
}

/* ── 4 · Bottom section tabs (text + icon) ──────────────────────────────
   Built by main.js from the panels actually present, so a stripped RSVP /
   Guestbook / Highlights never leaves an orphan tab. Scrolls horizontally
   on narrow screens (scrollbar hidden) — always easy to spot and operate. */
.shell-nav {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 8px calc(12px + env(safe-area-inset-right)) calc(10px + env(safe-area-inset-bottom)) calc(12px + env(safe-area-inset-left));
  border-top: 1px solid var(--line-soft);
  background: rgba(19, 16, 25, .92);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  -ms-overflow-style: none;
}
.shell-nav::-webkit-scrollbar { display: none; }

.nav-tab {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 9px 14px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--muted);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: .14em;
  text-transform: uppercase;
  cursor: pointer;
  white-space: nowrap;
  transition: background-color .25s var(--ease-out), color .25s;
}
.nav-tab svg { width: 15px; height: 15px; flex: none; }
.nav-tab:hover { color: var(--cream); }
.nav-tab[aria-selected="true"] {
  background: linear-gradient(135deg, var(--red-soft), var(--red-deep));
  color: var(--paper);
  box-shadow: 0 4px 14px rgba(0, 0, 0, .35);
}
.nav-tab:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }

/* ── 5 · Cover — the ticket on the marquee stage ──────────────────────── */
.stage {
  position: relative;
  min-height: 100%;
  display: flex;
  padding: clamp(24px, 5vh, 56px) clamp(14px, 4vw, 40px);
  background:
    repeating-linear-gradient(90deg, transparent 0 2px, rgba(0, 0, 0, .18) 2px 3px),
    var(--stage-solid);
}

/* Optional photo backdrop behind the ticket (decorative — pointer clicks
   on the dark stage open it in the viewer; see main.js). Delete the
   .stage-photo div in index.html to hide it. */
.stage-photo {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
}
.stage-photo img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: .5;
  filter: saturate(.75) brightness(.5);
}
.stage-photo::after {                 /* scrim + faint marquee stripes */
  content: "";
  position: absolute;
  inset: 0;
  background:
    repeating-linear-gradient(90deg, transparent 0 2px, rgba(0, 0, 0, .1) 2px 3px),
    linear-gradient(180deg, rgba(19, 16, 25, .45), rgba(19, 16, 25, .72));
}

.stage-glow {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(70% 55% at 50% 42%, rgba(224, 178, 74, .13), transparent 70%),
    radial-gradient(90% 70% at 50% 110%, rgba(179, 32, 46, .16), transparent 60%);
}

.ticket {
  position: relative;
  z-index: 2;
  margin: auto;                        /* centers, and scrolls safely if the
                                          ticket outgrows the viewport */
  display: flex;
  width: min(680px, 96vw);
  border-radius: 10px;
  background:
    repeating-linear-gradient(0deg, rgba(42, 33, 24, .028) 0 1px, transparent 1px 4px),
    linear-gradient(180deg, var(--paper) 0%, var(--paper-2) 100%);
  color: var(--ink);
  box-shadow: 0 34px 90px rgba(0, 0, 0, .6), 0 0 0 1px rgba(42, 33, 24, .55);
  overflow: hidden;
}

/* perforation punch holes — the circles sit on the stub seam and match
   the solid stage colour so they read as genuine ticket notches */
.ticket::before,
.ticket::after {
  content: "";
  position: absolute;
  left: 96px;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--stage-solid);
  transform: translateX(-50%);
  z-index: 3;
}

.ticket::before { top: -13px; }
.ticket::after { bottom: -13px; }

/* ── stub ─────────────────────────────────────────────────────────────── */
.ticket-stub {
  position: relative;
  z-index: 2;
  width: 96px;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  padding: 22px 10px 18px;
  border-right: 2px dashed rgba(42, 33, 24, .4);
  background: rgba(42, 33, 24, .035);
  text-align: center;
}

.stub-admit {
  font-family: var(--font-marquee);
  font-size: 17px;
  line-height: 1.15;
  letter-spacing: .06em;
  color: var(--red);
}

.stub-barcode {
  display: flex;
  align-items: flex-end;
  gap: 2.5px;
  height: 34px;
  padding: 0 2px;
}

.stub-barcode i {
  display: block;
  width: 3px;
  height: 100%;
  background: var(--ink);
}

.stub-barcode i:nth-child(2) { width: 1px; }
.stub-barcode i:nth-child(3) { width: 4px; }
.stub-barcode i:nth-child(4) { width: 1.5px; }
.stub-barcode i:nth-child(5) { width: 2px; height: 82%; }
.stub-barcode i:nth-child(6) { width: 4px; }
.stub-barcode i:nth-child(7) { width: 1px; height: 92%; }
.stub-barcode i:nth-child(8) { width: 2.5px; }
.stub-barcode i:nth-child(9) { width: 1px; height: 78%; }
.stub-barcode i:nth-child(10) { width: 3px; }
.stub-barcode i:nth-child(11) { width: 1.5px; height: 88%; }
.stub-barcode i:nth-child(12) { width: 4px; }
.stub-barcode i:nth-child(13) { width: 2px; }

.stub-no {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: .14em;
  color: var(--ink-muted);
}

.stub-age {
  font-family: var(--font-mono);
  font-size: 9.5px;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--ink-faint);
  line-height: 1.4;
}

.stub-age span { font-size: 15px; color: var(--red); font-weight: 700; }

/* ── ticket body ──────────────────────────────────────────────────────── */
.ticket-main {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: clamp(18px, 3vh, 30px) clamp(18px, 3.6vw, 34px) clamp(20px, 3.4vh, 32px);
}

.ticket-marquee {
  display: flex;
  justify-content: center;
  gap: clamp(7px, 1.2vw, 12px);
  margin-bottom: clamp(10px, 1.6vh, 16px);
}

.bulb {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--paper-3);
  box-shadow: inset 0 -2px 3px rgba(42, 33, 24, .4), 0 1px 2px rgba(42, 33, 24, .2);
  animation: bulb-chase 3.2s infinite;
}

@keyframes bulb-chase {
  0%, 12% { background: var(--paper-3); box-shadow: inset 0 -2px 3px rgba(42, 33, 24, .4), 0 1px 2px rgba(42, 33, 24, .2); }
  4% { background: var(--gold); box-shadow: 0 0 10px 2px rgba(224, 178, 74, .85); }
}

.bulb:nth-child(2) { animation-delay: .4s; }
.bulb:nth-child(3) { animation-delay: .8s; }
.bulb:nth-child(4) { animation-delay: 1.2s; }
.bulb:nth-child(5) { animation-delay: 1.6s; }
.bulb:nth-child(6) { animation-delay: 2s; }
.bulb:nth-child(7) { animation-delay: 2.4s; }
.bulb:nth-child(8) { animation-delay: 2.8s; }

.ticket-premiere {
  font-family: var(--font-marquee);
  font-size: clamp(13px, 1.7vw, 16px);
  letter-spacing: .28em;
  color: var(--red);
  margin-bottom: 6px;
}

.ticket-admit {
  font-family: var(--font-mono);
  font-size: clamp(10px, 1.2vw, 12px);
  letter-spacing: .26em;
  text-transform: uppercase;
  color: var(--ink-muted);
  margin-bottom: clamp(8px, 1.4vh, 14px);
}

.ticket-title {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(52px, 9vw, 104px);
  line-height: .95;
  letter-spacing: .03em;
  text-transform: uppercase;
  color: var(--ink);
  text-shadow: 0.04em 0.04em 0 rgba(179, 32, 46, .9);
}

.ticket-title .honoree-name--alt { color: var(--red); }

.ticket-sub {
  font-family: var(--font-script);
  font-size: clamp(19px, 2.5vw, 27px);
  color: var(--teal-deep);
  margin: clamp(4px, .8vh, 10px) 0 clamp(12px, 2vh, 20px);
}

/* ── optional honoree photo on the ticket ───────────────────────────────
   Framed like a real film still printed on the ticket: cream mat, ink
   ring, mono caption. Clicking it opens the full-screen viewer (main.js). */
.ticket-photo {
  position: relative;
  width: min(78%, 420px);
  margin: 0 auto clamp(12px, 2vh, 18px);
  padding: 5px;
  background: rgba(255, 255, 255, .55);
  border: 1.5px solid var(--ink);
  border-radius: 4px;
  box-shadow: 0 0 0 3px rgba(255, 255, 255, .35), 0 0 0 4px var(--ink);
  cursor: zoom-in;
}
.ticket-photo img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border-radius: 2px;
  background: var(--paper-3);         /* soft tone while loading / if the file is missing */
}
.ticket-photo figcaption {
  margin-top: 6px;
  font-family: var(--font-mono);
  font-size: 9.5px;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--red);
}
.ticket-photo::after {                /* tiny "view" badge — shows it's clickable */
  content: "";
  position: absolute;
  top: 9px; right: 9px;
  width: 28px; height: 28px;
  border-radius: 50%;
  background: rgba(244, 234, 210, .94)
    url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23b3202e' stroke-width='2.2' stroke-linecap='round'%3E%3Ccircle cx='10.5' cy='10.5' r='6.5'/%3E%3Cpath d='M15.5 15.5L21 21'/%3E%3C/svg%3E")
    center / 15px no-repeat;
  border: 1px solid rgba(42, 33, 24, .35);
  box-shadow: 0 4px 12px -4px rgba(42, 33, 24, .45);
  opacity: 0;
  transform: translateY(-3px);
  transition: opacity .2s, transform .2s;
  pointer-events: none;
}
.ticket-photo:hover::after,
.ticket-photo:focus-within::after { opacity: 1; transform: none; }

.ticket-facts {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  width: 100%;
  max-width: 460px;
  border: 1.5px solid var(--ink);
  border-radius: 6px;
  overflow: hidden;
}

.ticket-fact {
  padding: 10px 14px;
  text-align: left;
  background: rgba(255, 255, 255, .35);
  border-bottom: 1px solid rgba(42, 33, 24, .28);
}

.ticket-fact:nth-child(odd) { border-right: 1px solid rgba(42, 33, 24, .28); }
.ticket-fact:nth-child(n+3) { border-bottom: 0; }

.ticket-fact dt {
  font-family: var(--font-display);
  font-size: 11px;
  letter-spacing: .3em;
  text-transform: uppercase;
  color: var(--red);
}

.ticket-fact dd {
  font-family: var(--font-mono);
  font-size: clamp(11.5px, 1.4vw, 13.5px);
  line-height: 1.4;
  color: var(--ink);
  margin-top: 2px;
}

.ticket-fine {
  font-family: var(--font-mono);
  font-size: clamp(9.5px, 1.1vw, 11px);
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--ink-muted);
  margin: clamp(10px, 1.8vh, 16px) 0 0;
}

.ticket-cta {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  margin-top: clamp(14px, 2.4vh, 22px);
}

/* ── 6 · Buttons ──────────────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 0;
  border-radius: 4px;
  padding: 11px 22px;
  font-family: var(--font-display);
  font-size: 16px;
  letter-spacing: .14em;
  text-transform: uppercase;
  cursor: pointer;
  transition: transform .18s var(--ease-out), box-shadow .18s, background .18s, color .18s;
}

.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0); }

.btn:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 3px;
}

.btn--primary {
  background: var(--red);
  color: var(--paper);
  box-shadow: 0 6px 18px rgba(179, 32, 46, .45);
}

.btn--primary:hover { background: var(--red-deep); box-shadow: 0 8px 22px rgba(179, 32, 46, .55); }

.btn--ghost {
  background: transparent;
  color: var(--ink);
  border: 2px solid var(--ink);
}

.btn--ghost:hover { background: var(--ink); color: var(--paper); }

.btn-arrow { font-size: .9em; }

/* ── 7 · Paper panels (showtimes / highlights / rsvp / star notes) ────── */
.paper {
  position: relative;
  background:
    repeating-linear-gradient(0deg, rgba(42, 33, 24, .028) 0 1px, transparent 1px 4px),
    linear-gradient(180deg, var(--paper) 0%, var(--paper-2) 100%);
  color: var(--ink);
  border-radius: 10px;
  padding: clamp(26px, 4.5vw, 44px);
  box-shadow: var(--shadow-panel), 0 0 0 1px rgba(42, 33, 24, .5);
}

.paper-edge {                     /* perforated top edge */
  position: absolute;
  top: -9px;
  left: 8%;
  right: 8%;
  height: 18px;
  background-image: radial-gradient(circle 4.5px at 9px 9px, var(--paper) 4.5px, transparent 5px);
  background-size: 18px 18px;
  background-repeat: repeat-x;
}

.paper-eyebrow {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: .3em;
  text-transform: uppercase;
  color: var(--red);
  margin-bottom: 8px;
}

.paper-title {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(40px, 6.5vw, 60px);
  line-height: .95;
  letter-spacing: .03em;
  text-transform: uppercase;
  color: var(--ink);
  text-shadow: 0.035em 0.035em 0 rgba(179, 32, 46, .85);
}

.paper-sub {
  font-size: 15px;
  font-weight: 400;
  line-height: 1.6;
  color: var(--ink-soft);
  margin: 10px 0 22px;
}

.paper-sub .editable { font-weight: 500; color: var(--red-deep); }

/* details list */
.details-list {
  border: 1.5px solid var(--ink);
  border-radius: 6px;
  overflow: hidden;
}

.detail-row {
  display: grid;
  grid-template-columns: 130px 1fr;
  gap: 12px;
  padding: 14px 16px;
  border-bottom: 1px solid rgba(42, 33, 24, .28);
  background: rgba(255, 255, 255, .3);
}

.detail-row:last-child { border-bottom: 0; }

.detail-row dt {
  font-family: var(--font-display);
  font-size: 13px;
  letter-spacing: .24em;
  text-transform: uppercase;
  color: var(--red);
  padding-top: 3px;
}

.detail-row dd {
  font-size: 14.5px;
  font-weight: 400;
  line-height: 1.55;
  color: var(--ink);
}

.detail-row dd small {
  display: block;
  color: var(--ink-muted);
  font-size: 12.5px;
  margin-top: 2px;
}

.address-lines {
  display: flex;
  flex-direction: column;
}

.address-line { display: block; }

.map-link {
  display: inline-block;
  margin-top: 8px;
  font-family: var(--font-mono);
  font-size: 11.5px;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--teal-deep);
  text-decoration: none;
  border-bottom: 1px solid var(--teal);
}

.map-link:hover { color: var(--red-deep); }

/* ── official flyer / banner (optional, in Showtimes) ───────────────────
   A wide framed slot for hosts who already have a designed poster for the
   night — guests can confirm they're in the right place. Clicking it
   opens the same full-screen viewer as the photos. */
.banner-flyer {
  margin: clamp(24px, 5vh, 36px) auto 0;
  max-width: 560px;
  text-align: center;
  position: relative;
}
.banner-flyer img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 8 / 3;
  object-fit: cover;
  padding: 5px;
  background: linear-gradient(160deg, rgba(224, 178, 74, .4), rgba(169, 126, 31, .12));
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 14px 30px -22px rgba(0, 0, 0, .5);
  cursor: zoom-in;
}
.banner-flyer figcaption {
  margin-top: 8px;
  font-size: 10px;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--gold-deep);
}

/* note */
.note {
  display: flex;
  gap: 12px;
  margin-top: 18px;
  padding: 14px 16px;
  border: 1.5px dashed var(--red-soft);
  border-radius: 6px;
  background: rgba(179, 32, 46, .06);
}

.note-icon { font-size: 17px; line-height: 1.4; }

.note p {
  font-size: 13.5px;
  font-weight: 400;
  line-height: 1.6;
  color: var(--ink-soft);
}

.note strong { color: var(--red-deep); }

.paper-foot {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  margin-top: 26px;
}

/* ── Highlights gallery (optional panel) ────────────────────────────────
   Four framed photo slots; each <figure class="gallery-item"> is one
   photo. Delete the .story-gallery section (or the whole Highlights
   panel) in index.html to remove it — the tabs, cover button and
   lightbox adapt automatically. */
.story-gallery {
  margin-top: 4px;
  text-align: center;
}
.gallery-label {
  font-size: 10.5px;
  letter-spacing: .3em;
  text-transform: uppercase;
  color: var(--gold-deep);
  margin-bottom: 14px;
}
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
  text-align: left;
}
.gallery-item {
  margin: 0;
  padding: 5px;                     /* the gold frame around the photo */
  background: linear-gradient(160deg, rgba(224, 178, 74, .4), rgba(169, 126, 31, .12));
  border: 1px solid var(--line);
  border-radius: 10px;
  cursor: zoom-in;
  transition: transform .3s var(--ease-out), box-shadow .3s;
}
.gallery-item:hover {
  transform: translateY(-3px);
  box-shadow: 0 14px 30px rgba(0, 0, 0, .4);
}
.gallery-item img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: 6px;
  background: var(--paper-3);       /* shows behind broken / missing images */
  transition: transform .45s var(--ease-out);
}
.gallery-item:hover img { transform: scale(1.05); }
.gallery-item figcaption {
  margin-top: 8px;
  font-size: 10px;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--gold-deep);
  text-align: center;
}

/* every clickable photo hints at it: zoom cursor + a small magnifier
   badge on hover / keyboard focus (the viewer itself is built by JS) */
.banner-flyer::after, .gallery-item::after {
  content: "";
  position: absolute;
  top: 10px; right: 10px;
  width: 30px; height: 30px;
  border-radius: 50%;
  background: rgba(244, 234, 210, .94)
    url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23a97e1f' stroke-width='2.2' stroke-linecap='round'%3E%3Ccircle cx='10.5' cy='10.5' r='6.5'/%3E%3Cpath d='M15.5 15.5L21 21'/%3E%3C/svg%3E")
    center / 16px no-repeat;
  border: 1px solid var(--line);
  box-shadow: 0 4px 12px -4px rgba(42, 33, 24, .45);
  opacity: 0;
  transform: translateY(-3px);
  transition: opacity .2s, transform .2s;
  pointer-events: none;
  z-index: 2;
}
.banner-flyer:hover::after, .banner-flyer:focus-within::after,
.gallery-item:hover::after, .gallery-item:focus-within::after { opacity: 1; transform: none; }

/* ── optional film feature (video URL embed, in Highlights) ─────────────
   A poster + play button that lazy-loads an <iframe> from the URL in
   data-video-url (YouTube / Vimeo / any embeddable URL). Nothing loads
   until the guest taps play — fast, and consent-friendly. */
.film-card {
  margin-top: clamp(26px, 5vh, 38px);
  text-align: center;
}
.film-frame {
  position: relative;
  width: 100%;
  max-width: 560px;
  margin: 0 auto;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-radius: 10px;
  background: var(--paper-3);       /* mat behind the poster / while loading */
  border: 1px solid var(--line);
  box-shadow: 0 16px 34px -24px rgba(0, 0, 0, .5);
}
.film-open {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  padding: 0;
  border: 0;
  background: none;
  cursor: pointer;
}
.film-open img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.film-play {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: clamp(56px, 12vmin, 72px);
  height: clamp(56px, 12vmin, 72px);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--paper);
  background: radial-gradient(circle at 32% 28%, #c94a56, var(--red) 55%, var(--red-deep));
  border: 1px solid rgba(224, 178, 74, .55);
  box-shadow: 0 12px 28px -12px rgba(0, 0, 0, .65);
  animation: film-pulse 2.6s ease-in-out infinite;
  transition: transform .25s var(--ease-out);
}
.film-play svg { width: 26px; height: 26px; margin-left: 3px; }
.film-open:hover .film-play { transform: translate(-50%, -50%) scale(1.08); }
.film-open:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; }
.film-hint {
  position: absolute;
  left: 50%;
  bottom: 12px;
  transform: translateX(-50%);
  padding: 6px 14px;
  border-radius: 999px;
  background: rgba(19, 16, 25, .66);
  color: var(--cream);
  font-size: 10px;
  letter-spacing: .18em;
  text-transform: uppercase;
  pointer-events: none;
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
}
.film-frame iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}
.film-note {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0;
  padding: 0 18px;
  color: var(--ink-muted);
  font-size: 13.5px;
  font-style: italic;
  text-align: center;
  background: var(--paper-3);
}
.film-external {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 14px;
  font-size: 11px;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--gold-deep);
  text-decoration: none;
  border-bottom: 1px solid var(--line);
  padding-bottom: 2px;
  transition: color .2s, border-color .2s;
}
.film-external:hover { color: var(--gold); border-color: var(--gold); }
.film-external[hidden] { display: none; }
@keyframes film-pulse {
  0%, 100% { box-shadow: 0 12px 28px -12px rgba(0, 0, 0, .65), 0 0 0 0 rgba(224, 178, 74, .4); }
  50%      { box-shadow: 0 12px 28px -12px rgba(0, 0, 0, .65), 0 0 0 14px rgba(224, 178, 74, 0); }
}

/* ── 7b · Free page (optional panel, repeatable free blocks) ───────────
   The .free-blocks container holds one .free-block per host row (free
   title + free text + optional photo). The render engine clones the
   first block per row and removes the whole .panel-free section when
   there are none (or when the host toggles the Free Page section off),
   so the tab main.js builds disappears with it — no orphaned nav. The
   .free-figure figure collapses via the engine's css_if_empty when the
   block has no photo, so a text-only block still reads cleanly. */
.free-blocks {
  margin-top: 6px;
  text-align: center;
}
.free-block {
  margin: 0 0 clamp(24px, 5vh, 36px);
}
.free-block:last-child { margin-bottom: 0; }
.free-title {
  margin: 0 0 12px;
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(24px, 4.6vw, 32px);
  line-height: 1.05;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--red-deep);
  text-shadow: 0.03em 0.03em 0 rgba(179, 32, 46, .18);
  overflow-wrap: anywhere;
}
.free-title:focus { outline: none; }
.free-content {
  margin: 0 auto;
  max-width: 46ch;
  text-align: left;
  font-size: 15px;
  line-height: 1.75;
  color: var(--ink-soft);
  white-space: pre-line;              /* host line breaks are kept */
  overflow-wrap: anywhere;
}
.free-figure {
  position: relative;
  margin: 14px auto 0;
  max-width: 460px;
  padding: 5px;                       /* the gold frame, like the gallery */
  background: linear-gradient(160deg, rgba(224, 178, 74, .4), rgba(169, 126, 31, .12));
  border: 1px solid var(--line);
  border-radius: 10px;
  cursor: zoom-in;
  transition: transform .3s var(--ease-out), box-shadow .3s;
}
.free-figure:hover {
  transform: translateY(-3px);
  box-shadow: 0 14px 30px rgba(0, 0, 0, .4);
}
/* text-only block: the engine removes the empty <img> but keeps the frame
   and caption, so hide the whole figure when it has no image (same graceful
   :has() pattern as the countdown reveal — older engines just keep the
   frame, never a broken image). */
.free-figure:not(:has(img)) { display: none; }
.free-figure img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: 6px;
  background: var(--paper-3);       /* shows behind broken / missing images */
}
.free-cap {
  margin-top: 8px;
  font-size: 10px;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--gold-deep);
  text-align: center;
}
/* magnifier badge on hover / keyboard focus, like the gallery photos */
.free-figure::after {
  content: "";
  position: absolute;
  top: 10px; right: 10px;
  width: 30px; height: 30px;
  border-radius: 50%;
  background: rgba(244, 234, 210, .94)
    url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23a97e1f' stroke-width='2.2' stroke-linecap='round'%3E%3Ccircle cx='10.5' cy='10.5' r='6.5'/%3E%3Cpath d='M15.5 15.5L21 21'/%3E%3C/svg%3E")
    center / 16px no-repeat;
  border: 1px solid var(--line);
  box-shadow: 0 4px 12px -4px rgba(42, 33, 24, .45);
  opacity: 0;
  transform: translateY(2px);
  transition: opacity .25s, transform .25s;
}
.free-figure:hover::after, .free-figure:focus-within::after { opacity: 1; transform: none; }

/* ── 8 · RSVP form ────────────────────────────────────────────────────── */
.rsvp-form { margin-top: 4px; }

.rsvp-form-display {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px 18px;
}

.form-group { display: flex; flex-direction: column; gap: 6px; }
.form-group--half { grid-column: span 1; }

.form-group label {
  font-family: var(--font-display);
  font-size: 14px;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--red-deep);
}

.form-control {
  width: 100%;
  font-family: var(--font-body);
  font-size: 15.5px;
  font-weight: 400;
  color: var(--ink);
  background: rgba(255, 255, 255, .55);
  border: 1.5px solid var(--ink-faint);
  border-radius: 4px;
  padding: 11px 13px;
  transition: border-color .2s, box-shadow .2s, background .2s;
}

.form-control::placeholder { color: var(--ink-faint); }

.form-control:focus {
  outline: none;
  border-color: var(--red);
  background: #fff;
  box-shadow: 0 0 0 3px rgba(179, 32, 46, .14);
}

textarea.form-control { resize: vertical; min-height: 62px; }

select.form-control { appearance: none; -webkit-appearance: none; cursor: pointer;
  background-image: linear-gradient(45deg, transparent 50%, var(--red-deep) 50%), linear-gradient(135deg, var(--red-deep) 50%, transparent 50%);
  background-position: calc(100% - 18px) 50%, calc(100% - 13px) 50%;
  background-size: 5px 5px, 5px 5px;
  background-repeat: no-repeat;
}

.error {
  font-size: 12.5px;
  font-weight: 400;
  color: var(--red);
  min-height: 0;
}

.field-hint {
  grid-column: 1 / -1;
  font-size: 12.5px;
  line-height: 1.5;
  color: var(--ink-muted);
}

.attend-extras { grid-column: 1 / -1; display: grid; grid-template-columns: 1fr 1fr; gap: 16px 18px; }

.attend-extras .form-group:first-child { grid-column: 1 / -1; }

.form-actions {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  margin-top: 22px;
}

.loading {
  font-family: var(--font-mono);
  font-size: 12.5px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--ink-muted);
}

#rsvp-form.is-declining .attend-extras { display: none; }

/* platform "thank you" / "closed" states */
#rsvp-form .thank-you-message h3 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: 30px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--red);
}

#rsvp-form .thank-you-message p {
  font-size: 15px;
  line-height: 1.6;
  color: var(--ink-soft);
}

#rsvp-form .thank-you-message small { color: var(--ink-muted); line-height: 1.5; display: block; }

/* RSVP deadline countdown (populated by the platform only when the host sets a deadline) */
.rsvp-countdown {
  display: none;
  text-align: center;
  margin: 0 auto 18px;
  padding: 12px 16px;
  border: 1.5px dashed var(--red-soft);
  border-radius: 6px;
  background: rgba(179, 32, 46, .05);
}
.rsvp-countdown:has(.count-day:not(:empty)) { display: block; }
.rsvp-countdown-label {
  display: block;
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: .28em;
  text-transform: uppercase;
  color: var(--red-deep);
  margin-bottom: 10px;
}
.rsvp-countdown-units {
  display: flex;
  justify-content: center;
  gap: 18px;
}
.rsvp-unit { display: flex; flex-direction: column; align-items: center; min-width: 54px; }
.rsvp-unit:has(.count-day:empty),
.rsvp-unit:has(.count-hour:empty),
.rsvp-unit:has(.count-minute:empty),
.rsvp-unit:has(.count-second:empty) { display: none; }
.rsvp-unit .count-day,
.rsvp-unit .count-hour,
.rsvp-unit .count-minute,
.rsvp-unit .count-second {
  font-family: var(--font-display);
  font-size: 30px;
  line-height: 1;
  color: var(--ink);
}
.rsvp-unit em {
  font-style: normal;
  font-size: 10px;
  letter-spacing: .24em;
  text-transform: uppercase;
  color: var(--ink-muted);
  margin-top: 4px;
}

/* ── 9 · Guestbook (platform-injected, Style A) ───────────────────────── */
.guestbook-body #guestbookForm {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px 18px;
  border: 1.5px solid var(--ink);
  border-radius: 6px;
  background: rgba(255, 255, 255, .3);
  padding: 18px;
}

.guestbook-body #guestbookForm .form-group { display: flex; flex-direction: column; gap: 6px; }
.guestbook-body #guestbookForm .form-group:has(textarea) { grid-column: 1 / -1; }

.guestbook-body #guestbookForm label {
  font-family: var(--font-display);
  font-size: 14px;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--red-deep);
}

.guestbook-body #guestbookForm .form-control {
  width: 100%;
  font-family: var(--font-body);
  font-size: 15.5px;
  font-weight: 400;
  color: var(--ink);
  background: rgba(255, 255, 255, .55);
  border: 1.5px solid var(--ink-faint);
  border-radius: 4px;
  padding: 11px 13px;
}

.guestbook-body #guestbookForm .form-control:focus {
  outline: none;
  border-color: var(--red);
  background: #fff;
  box-shadow: 0 0 0 3px rgba(179, 32, 46, .14);
}

.guestbook-body #guestbookForm .error { font-size: 12.5px; color: var(--red); }

.guestbook-body #guestbookForm .d-flex,
.guestbook-body #guestbookForm .guestbook-chapta { grid-column: 1 / -1; justify-content: center; }

.guestbook-body #guestbookForm button[type="submit"] {
  grid-column: 1 / -1;
  justify-self: center;
  width: auto;
  background: var(--red);
  color: var(--paper);
  border: 0;
  border-radius: 4px;
  padding: 11px 26px;
  font-family: var(--font-display);
  font-size: 16px;
  letter-spacing: .14em;
  text-transform: uppercase;
  cursor: pointer;
}

.guestbook-body #guestbookForm .loading-guestbook { grid-column: 1 / -1; text-align: center; font-family: var(--font-mono); font-size: 12px; text-transform: uppercase; letter-spacing: .12em; color: var(--ink-muted); }

.guestbook-wrap {
  margin-top: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  max-height: 46vh;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding-right: 4px;
}

.guestbook-entry {
  border: 1px solid rgba(42, 33, 24, .28);
  border-left: 3px solid var(--red);
  border-radius: 6px;
  background: rgba(255, 255, 255, .35);
  padding: 13px 16px;
}

.guestbook-entry h5 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: 16px;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--ink);
  margin: 0 0 4px;
}

.guestbook-entry p {
  font-size: 14px;
  font-weight: 400;
  line-height: 1.6;
  color: var(--ink-soft);
  margin: 0 0 4px;
}

.guestbook-entry small {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--ink-muted);
}

.more-guestbook-wrap {
  display: flex;
  justify-content: center;
  margin-top: 14px;
}

#load-more {
  background: transparent;
  color: var(--ink);
  border: 2px solid var(--ink);
  border-radius: 4px;
  padding: 9px 20px;
  font-family: var(--font-display);
  font-size: 14px;
  letter-spacing: .16em;
  text-transform: uppercase;
  cursor: pointer;
}

#load-more:hover { background: var(--ink); color: var(--paper); }

/* ── 9b · Photo viewer (lightbox) — click any photo to view it ─────────
   One full-screen viewer for every [data-lightbox] slot (honoree photo,
   flyer, gallery stills, backdrop). Built by main.js only when a photo
   slot exists, so hiding features leaves no orphaned UI. Prev/next +
   swipe to browse; click / pinch / wheel / toolbar buttons to zoom (the
   image pans by dragging while zoomed); "open original" opens the file
   at full resolution in a new tab. */
.photo-viewer {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: none;
  align-items: center;
  justify-content: center;
  padding: env(safe-area-inset-top) env(safe-area-inset-right) env(safe-area-inset-bottom) env(safe-area-inset-left);
  background: rgba(13, 10, 18, .93);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
.photo-viewer.is-open { display: flex; }
.photo-viewer figure {
  margin: 0;
  max-width: min(92vw, 960px);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  text-align: center;
}
.photo-viewer img {
  display: block;
  max-width: 100%;
  max-height: 74vh;
  max-height: 74dvh;
  width: auto;
  height: auto;
  border: 1px solid rgba(224, 178, 74, .45);
  border-radius: 14px;
  background: var(--stage-2);        /* mat while loading / if missing */
  box-shadow: 0 40px 110px rgba(0, 0, 0, .75);
  cursor: zoom-in;
  user-select: none;
  -webkit-user-drag: none;
  touch-action: none;                /* pointer events drive pan / pinch */
  transform-origin: center center;
  transition: transform .25s var(--ease-out);
}
.photo-viewer img.pv-zoomed { cursor: grab; }
.photo-viewer img.pv-zoomed:active { cursor: grabbing; }
.photo-viewer figcaption {
  text-align: center;
  font-size: 11px;
  letter-spacing: .24em;
  text-transform: uppercase;
  color: var(--gold-soft);
}
.photo-viewer .pv-unavailable {
  display: block;
  width: min(72vw, 520px);
  padding: 40px 24px;
  border: 1px solid rgba(224, 178, 74, .45);
  border-radius: 14px;
  background: var(--stage-2);
  color: var(--muted);
  font-size: 14px;
  font-style: italic;
  text-align: center;
}

.pv-toolbar {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 8px;
}
.pv-tool {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  min-height: 34px;
  padding: 6px 13px;
  border-radius: 999px;
  border: 1px solid rgba(224, 178, 74, .4);
  background: rgba(27, 22, 38, .85);
  color: var(--cream);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: .08em;
  cursor: pointer;
  text-decoration: none;
  transition: background-color .2s, color .2s, border-color .2s;
}
.pv-tool:hover { border-color: var(--gold); background: rgba(36, 29, 51, .95); }
.pv-zoom-val {
  min-width: 46px;
  text-align: center;
  font-size: 11px;
  letter-spacing: .12em;
  color: var(--gold-soft);
}

.pv-btn {
  position: absolute;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 1px solid rgba(224, 178, 74, .5);
  background: rgba(19, 16, 25, .88);
  color: var(--gold-soft);
  font-size: 24px;
  line-height: 1;
  cursor: pointer;
  box-shadow: 0 10px 24px -12px rgba(0, 0, 0, .6);
  transition: transform .2s var(--ease-out), color .2s, border-color .2s;
}
.pv-btn:hover { transform: scale(1.06); color: var(--cream); border-color: var(--gold); }
.pv-close { top: calc(14px + env(safe-area-inset-top)); right: calc(14px + env(safe-area-inset-right)); }
.pv-prev  { left: 12px;  top: 50%; transform: translateY(-50%); }
.pv-next  { right: 12px; top: 50%; transform: translateY(-50%); }
.pv-prev:hover, .pv-next:hover { transform: translateY(-50%) scale(1.06); }
.photo-viewer :focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; }

/* ── 9c · Brand footer (placeholder) — tucked into the last panel ──────
   Hidden where it starts (after </main>); main.js moves it into the last
   panel's paper card so it reads as the closing line of the invitation —
   even when RSVP / Guestbook / Highlights are stripped. */
.app-footer { display: none; }
.panel .app-footer {
  display: block;
  margin-top: clamp(26px, 5vh, 40px);
  padding-top: 16px;
  border-top: 1px solid rgba(42, 33, 24, .25);
}
.footer-brand {
  margin: 0;
  font-size: 10.5px;
  font-weight: 500;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--ink-muted);
}
.footer-brand-name {
  font-family: var(--font-script);
  font-size: 1.35em;
  text-transform: none;
  letter-spacing: .02em;
  color: var(--teal-deep);
}

/* ── 9d · Powered-by brand strip (full width) ──────────────────────────
   A slim full-width footer line above the bottom tabs: "Powered by
   Kundangi". The engine swaps the brand token for the platform name at
   render; the cockpit's Free Powered By field can override the whole
   line. Lives between the deck and the tab bar in the flex column. */
.powered-by {
  flex: 0 0 auto;
  width: 100%;
  text-align: center;
  padding: 7px 16px 9px;
  border-top: 1px solid var(--line-soft);
  background: rgba(19, 16, 25, .9);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  font-size: 9.5px;
  font-weight: 500;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--muted);
}
.powered-by .link-footer { color: var(--gold-soft); }

/* ── 10 · Responsive ──────────────────────────────────────────────────── */
@media (max-width: 820px) {
  .detail-row { grid-template-columns: 1fr; gap: 6px; }
  .detail-row dt { padding-top: 0; }
  .rsvp-form-display { grid-template-columns: 1fr; }
  .attend-extras { grid-template-columns: 1fr; }
  .guestbook-body #guestbookForm { grid-template-columns: 1fr; }
}

@media (max-width: 560px) {
  .ticket { flex-direction: column; }
  .ticket::before, .ticket::after { left: 50%; }
  .ticket-stub {
    width: 100%;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 12px 18px;
    border-right: 0;
    border-bottom: 2px dashed rgba(42, 33, 24, .4);
  }
  .stub-admit { font-size: 15px; }
  .stub-barcode { height: 26px; }
  .stub-age { display: none; }
  .ticket-photo { width: 100%; }
  .ticket-facts { grid-template-columns: 1fr; }
  .ticket-fact:nth-child(odd) { border-right: 0; }
  .ticket-fact:nth-child(n+2) { border-bottom: 1px solid rgba(42, 33, 24, .28); }
  .ticket-fact:last-child { border-bottom: 0; }
  .gallery-grid { grid-template-columns: 1fr; }
  .nav-tab { padding: 9px 11px; font-size: 10.5px; }
  .photo-viewer { flex-direction: column; gap: 10px; }
  .photo-viewer img { max-height: 60vh; max-height: 60dvh; }
  .pv-prev, .pv-next { position: static; transform: none; }
  .pv-prev:hover, .pv-next:hover { transform: scale(1.06); }
  .pv-prev, .pv-next { width: 40px; height: 40px; }
  .photo-viewer figure { flex: 1 1 auto; justify-content: center; }
  .photo-viewer .pv-close { top: calc(10px + env(safe-area-inset-top)); right: calc(10px + env(safe-area-inset-right)); }
}

/* Narrowest phones: the tab bar left-aligns so overflowing pills stay
   reachable by scrolling (a centered flex would clip the first tab). */
@media (max-width: 480px) {
  .shell-nav { justify-content: flex-start; }
}

/* ── 11 · Reduced motion ──────────────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-delay: 0s !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
    scroll-behavior: auto !important;
  }
  .panel { transform: none; }
  .bulb { animation: none; background: var(--paper-3); }
  .film-play { animation: none; }
}

/* ── 12 · Print — each panel becomes its own page ─────────────────────── */
@media print {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  html, body { height: auto; background: #fff; }
  .site { position: static; height: auto; overflow: visible; background: var(--stage); display: block; }
  .deck { position: static; }
  .panel {
    position: relative;
    inset: auto;
    height: auto;
    min-height: 0;
    opacity: 1 !important;
    visibility: visible !important;
    transform: none !important;
    overflow: visible !important;
    break-after: page;
    page-break-after: always;
  }
  .panel.is-active { overflow: visible !important; }
  .shell-nav, .paper-foot, .ticket-cta, .stage-photo, .photo-viewer, .powered-by { display: none !important; }
  .panel-scroll { max-width: none; padding: 24px 10mm; }
  .stage { min-height: 96vh; }
  .ticket, .paper { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  .ticket::before, .ticket::after { display: none; }
  .film-frame iframe { display: none; } /* a playing video can't print — the poster prints instead */
  .guestbook-wrap { max-height: none; overflow: visible; }
}
