/* ═══════════════════════════════════════════════════════════════════════
   BIG BITE · Food Festival Flyer — styles
   Bold, mouthwatering poster look. Single-viewport shell: only the active
   panel scrolls. Progressive enhancement: without JS every panel stacks
   and the page scrolls normally.

   Customize by editing the CSS custom properties below (palette, fonts,
   radii, shadows). Everything else inherits.
   ═══════════════════════════════════════════════════════════════════════ */

:root {
  /* palette — tomato / mustard / basil on cream */
  --cream:    #FFF6E9;
  --paper:    #FFFBF2;
  --tomato:   #E43A2B;
  --tomato-deep: #B32A1D;
  --mustard:  #F6B72E;
  --mustard-deep: #C98A12;
  --basil:    #2F7D3C;
  --basil-deep: #1F5B28;
  --ink:      #2B2017;
  --ink-soft: #6B5842;
  --line:     #EAD9BE;

  --radius:   18px;
  --shadow:   0 18px 40px rgba(43, 32, 23, .16);
  --hard-shadow: 4px 4px 0 rgba(43, 32, 23, .9);

  --font-display: "Alfa Slab One", Georgia, "Times New Roman", serif;
  --font-body: "Work Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

/* ── reset / base ─────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.55;
  color: var(--ink);
  background: var(--cream);
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }
ul, dl { margin: 0; padding: 0; list-style: none; }
p, h1, h2, h3, h4 { margin: 0; }

/* `hidden` must win over any author display rule (e.g. greeting chip,
   countdown) — otherwise hidden nodes would render as empty pills */
[hidden] { display: none !important; }

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

/* skip link (visible on keyboard focus) */
.skip-link {
  position: absolute;
  left: -999px;
  top: 10px;
  z-index: 100;
  padding: 10px 18px;
  border-radius: 10px;
  background: var(--ink);
  color: #fff;
  font-weight: 700;
  text-decoration: none;
}
.skip-link:focus { left: 10px; }

/* ── shell: single-viewport app ──────────────────────────────────────── */
.shell { min-height: 100vh; min-height: 100dvh; }

/* JavaScript on → fixed viewport shell; only the active panel scrolls */
html.js body { overflow: hidden; }

.js .shell {
  height: 100vh;
  height: 100dvh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.js .shell-body {
  flex: 1 1 auto;
  min-height: 0;          /* allow children to scroll internally */
  position: relative;
}

.js .panel {
  position: absolute;
  inset: 0;
  overflow-y: auto;
  overflow-x: hidden;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
  display: none;
}
.js .panel.is-active { display: block; }

/* ── header ──────────────────────────────────────────────────────────── */
.shell-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 10px clamp(14px, 4vw, 32px);
  background: var(--paper);
  border-bottom: 3px solid var(--ink);
  position: relative;
  z-index: 20;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-family: var(--font-display);
  font-size: 21px;
  letter-spacing: .02em;
  color: var(--ink);
  text-decoration: none;
  white-space: nowrap;
}
.brand-mark { font-size: 24px; line-height: 1; }
.brand-accent { color: var(--tomato); }
.brand:hover .brand-mark { transform: rotate(-8deg) scale(1.08); }

/* nav — hidden without JS (buttons need JS); fixed bottom bar on mobile,
   inline pills in the header on desktop. It is a plain text-pill bar (not
   a slide/carousel), so every section stays reachable on mobile without
   prev/next arrows; on very narrow screens the bar scrolls horizontally
   (native swipe) instead of clipping the last pills. */
.shell-nav { display: none; }

.js .shell-nav {
  display: flex;
  gap: 6px;
  align-items: center;
  justify-content: flex-start;
  flex-wrap: nowrap;
  overflow-x: auto;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
  position: fixed;
  left: 0; right: 0; bottom: 0;
  z-index: 40;
  padding: 10px 12px calc(10px + env(safe-area-inset-bottom));
  background: rgba(255, 251, 242, .95);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  border-top: 3px solid var(--ink);
}
.js .shell-nav::-webkit-scrollbar { display: none; }
.js .shell-nav.is-hidden { display: none; }

.nav-item {
  appearance: none;
  border: 2px solid transparent;
  background: transparent;
  font: inherit;
  font-weight: 700;
  font-size: 13.5px;
  letter-spacing: .05em;
  text-transform: uppercase;
  color: var(--ink-soft);
  padding: 9px 15px;
  border-radius: 999px;
  cursor: pointer;
  min-height: 44px;
  flex: 0 0 auto;
  white-space: nowrap;
  transition: color .15s ease, background .15s ease, box-shadow .15s ease;
}
.nav-item:hover { color: var(--ink); }
.nav-item[aria-current="true"] {
  color: var(--ink);
  background: var(--mustard);
  border-color: var(--ink);
  box-shadow: 3px 3px 0 rgba(43, 32, 23, .9);
}
.nav-item:focus-visible { outline-offset: 2px; }

@media (min-width: 701px) {
  .js .shell-nav {
    position: static;
    justify-content: flex-end;
    background: none;
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
    border-top: 0;
    padding: 0;
    overflow-x: visible;
  }
}

@media (max-width: 400px) {
  .nav-item { padding: 9px 10px; font-size: 12px; }
}

/* ── panel scaffolding ───────────────────────────────────────────────── */
.panel-inner {
  max-width: 1000px;
  margin: 0 auto;
  padding: clamp(24px, 5vw, 56px) clamp(16px, 4vw, 32px)
           calc(96px + env(safe-area-inset-bottom)); /* room for mobile nav */
}
.panel-inner--narrow { max-width: 700px; }

.panel-head { text-align: center; margin-bottom: clamp(26px, 5vw, 44px); }
.panel-eyebrow {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--tomato-deep);
}
.panel-title {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(2.1rem, 6vw, 3.4rem);
  text-transform: uppercase;
  letter-spacing: .01em;
  margin: 8px 0 10px;
}
.panel-sub { max-width: 58ch; margin: 0 auto; color: var(--ink-soft); }

.panel-section { margin-top: clamp(34px, 6vw, 56px); }
.section-title {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(1.4rem, 3.4vw, 1.9rem);
  text-transform: uppercase;
  letter-spacing: .02em;
  margin-bottom: 20px;
  padding-left: 12px;
  border-left: 6px solid var(--mustard);
}

/* ── PANEL 1 · the poster ────────────────────────────────────────────── */
.panel-cover { background: var(--cream); }

.js .poster { min-height: 100%; }

.poster {
  max-width: 1080px;
  margin: 0 auto;
  padding: clamp(30px, 6vh, 60px) clamp(16px, 4vw, 40px)
           calc(110px + env(safe-area-inset-bottom));
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: clamp(14px, 2.4vh, 26px);
  text-align: center;
}

/* greeting chip — filled in by main.js when the platform passes a name */
.greeting {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 18px;
  border-radius: 999px;
  background: var(--basil);
  color: #fff;
  font-weight: 700;
  font-size: 15px;
  box-shadow: 3px 3px 0 rgba(43, 32, 23, .9);
}

.poster-eyebrow {
  font-size: clamp(11px, 1.6vw, 13px);
  font-weight: 700;
  letter-spacing: .26em;
  text-transform: uppercase;
  color: var(--tomato-deep);
}

.poster-title {
  font-family: var(--font-display);
  font-weight: 400;
  line-height: .9;
  text-transform: uppercase;
  position: relative;
  z-index: 2;
  margin-bottom: 4px;
}
.poster-title .line { display: block; }
.poster-title .line-a {
  font-size: clamp(3.6rem, 19vw, 12rem);
  color: var(--tomato);
  transform: rotate(-2deg);
}
.poster-title .line-b {
  font-size: clamp(3.6rem, 19vw, 12rem);
  color: var(--ink);
  transform: rotate(1.5deg);
}
.line-burger {
  display: inline-block;
  font-size: .62em;
  margin-left: .12em;
  transform: rotate(10deg);
}
.swoosh {
  position: absolute;
  left: 50%;
  bottom: -10px;
  transform: translateX(-50%);
  width: min(68%, 430px);
  z-index: -1;
}

.poster-sub {
  font-size: clamp(1.05rem, 2.4vw, 1.45rem);
  font-weight: 600;
  color: var(--ink);
  letter-spacing: .01em;
}

/* event date chip — answers "when" on the first screen. Bound to the
   Main Date morph like the facts bar; empty values leave it empty and
   :empty removes it, so a missing date never shows a bare pill. */
.poster-date-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(0.95rem, 2.1vw, 1.15rem);
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--ink);
  background: var(--mustard);
  border: 2px solid var(--ink);
  border-radius: 999px;
  padding: 8px 18px;
  box-shadow: 3px 3px 0 rgba(43, 32, 23, .85);
}
.poster-date-chip:empty { display: none; }

/* optional hero photo — a rounded photo band under the tagline, in the same
   sticker/tile design language. Shows branded placeholder art by default;
   remove the <figure> to hide the slot entirely. Clicking it opens the
   full-screen photo viewer (main.js). */
.poster-photo {
  width: 100%;
  max-width: 860px;
  margin: 0 auto;
  position: relative;
  background: var(--paper);      /* fallback while loading / if the file is missing */
  border: 3px solid var(--ink);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}
.poster-photo-link { display: block; }
.poster-photo-link img {
  width: 100%;
  height: auto;
  aspect-ratio: 12 / 7;          /* any photo size crops cleanly to the band */
  object-fit: cover;
  display: block;
  transition: transform .3s ease;
}
.poster-photo-link:hover img { transform: scale(1.02); }
.poster-photo-link:focus-visible { outline-offset: -6px; }

/* "view" badge — gently signals the photo is clickable */
.photo-view-hint {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 6px 12px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--ink);
  background: var(--mustard);
  border: 2px solid var(--ink);
  border-radius: 999px;
  box-shadow: 2px 2px 0 rgba(43, 32, 23, .85);
  pointer-events: none;
}

/* scrolling lineup ticker */
.marquee {
  width: 100%;
  overflow: hidden;
  background: var(--mustard);
  border-block: 3px solid var(--ink);
  padding: 10px 0;
}
.marquee-track {
  display: flex;
  width: max-content;
  animation: marquee 32s linear infinite;
  will-change: transform;
}
.marquee-copy { display: flex; align-items: center; }
.marquee-item {
  font-family: var(--font-display);
  font-size: clamp(1rem, 2.6vw, 1.5rem);
  text-transform: uppercase;
  letter-spacing: .05em;
  white-space: nowrap;
  padding: 0 14px;
}

@keyframes marquee {
  to { transform: translateX(-50%); }
}

/* flavor tiles — food-first visuals that need no photos */
.flavor-strip {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
}
.flavor-tile {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  width: 88px;
  padding: 13px 8px 11px;
  background: var(--paper);
  border: 2px solid var(--ink);
  border-radius: 16px;
  box-shadow: 3px 3px 0 rgba(43, 32, 23, .85);
}
.tile-emoji { font-size: 34px; line-height: 1; }
.tile-label {
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
}

/* event essentials fact bar */
.facts {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  width: 100%;
  max-width: 860px;
  background: var(--paper);
  border: 3px solid var(--ink);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}
.fact-item { padding: 16px 12px; text-align: center; }
.fact-item + .fact-item { border-left: 2px dashed var(--line); }
.fact-label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--tomato-deep);
}
.fact-value {
  font-weight: 700;
  font-size: clamp(13.5px, 1.9vw, 16.5px);
  margin-top: 5px;
}

/* call to action row */
.cta-row { display: flex; flex-wrap: wrap; gap: 14px; justify-content: center; }

.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
  font-weight: 400;
  font-size: 17px;
  letter-spacing: .04em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--ink);
  padding: 14px 28px;
  border: 3px solid var(--ink);
  border-radius: 999px;
  background: var(--paper);
  cursor: pointer;
  box-shadow: 4px 4px 0 rgba(43, 32, 23, .9);
  transition: transform .15s ease, box-shadow .15s ease, background .15s ease;
}
.btn:hover { transform: translate(-2px, -2px); box-shadow: 6px 6px 0 rgba(43, 32, 23, .9); }
.btn:active { transform: translate(2px, 2px); box-shadow: 1px 1px 0 rgba(43, 32, 23, .9); }
.btn-primary { background: var(--tomato); color: #fff; }
.btn-ghost { background: var(--paper); color: var(--ink); }
.btn-lg { font-size: 19px; padding: 16px 34px; }
.btn-arrow { width: 16px; height: 16px; }

.poster-foot {
  font-size: 13px;
  font-weight: 600;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--ink-soft);
}

/* decorative stickers & stamp */
.sticker {
  position: absolute;
  z-index: 1;
  display: grid;
  place-items: center;
  width: clamp(52px, 6vw, 66px);
  height: clamp(52px, 6vw, 66px);
  font-size: clamp(26px, 3.4vw, 36px);
  background: var(--paper);
  border: 2px solid var(--ink);
  border-radius: 16px;
  box-shadow: 3px 3px 0 rgba(43, 32, 23, .85);
  animation: floaty 6s ease-in-out infinite;
  pointer-events: none;
}
.sticker-1 { top: 7%; left: 3%; rotate: -10deg; }
.sticker-2 { top: 14%; right: 3%; rotate: 9deg; animation-delay: 1.4s; }
.sticker-3 { bottom: 30%; left: 2%; rotate: 8deg; animation-delay: 2.6s; }
.sticker-4 { bottom: 22%; right: 2%; rotate: -8deg; animation-delay: 3.6s; }

@keyframes floaty {
  0%, 100% { translate: 0 0; }
  50%      { translate: 0 -10px; }
}

.stamp-badge {
  position: absolute;
  top: 16%;
  right: 4%;
  width: clamp(96px, 11vw, 128px);
  height: clamp(96px, 11vw, 128px);
  z-index: 3;
  pointer-events: none;
}
.stamp-badge svg { width: 100%; height: 100%; animation: spin 24s linear infinite; }
.stamp-badge svg text {
  font-family: var(--font-display);
  font-size: 10.5px;
  letter-spacing: .12em;
  fill: var(--ink);
}
.stamp-emoji {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  font-size: 40px;
}

@keyframes spin { to { transform: rotate(360deg); } }

/* ── PANEL 2 · lineup & details ──────────────────────────────────────── */
.panel-details { background: var(--cream); }

.lineup-list {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
}
.vendor-item {
  display: flex;
  flex-direction: column;
  gap: 9px;
  background: var(--paper);
  border: 3px solid var(--ink);
  border-radius: var(--radius);
  padding: 18px;
  box-shadow: var(--hard-shadow);
  transition: transform .15s ease;
}
.vendor-item:hover { transform: translate(-2px, -2px); }
.vendor-icon {
  display: grid;
  place-items: center;
  width: 54px;
  height: 54px;
  font-size: 30px;
  background: var(--mustard);
  border: 2px solid var(--ink);
  border-radius: 14px;
}
.vendor-name {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: 18.5px;
  text-transform: uppercase;
  letter-spacing: .02em;
  line-height: 1.15;
}
.vendor-dish { font-size: 14px; color: var(--ink-soft); flex: 1; }
.vendor-tag {
  align-self: flex-start;
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: #fff;
  background: var(--basil);
  border-radius: 999px;
  padding: 4px 11px;
}

/* schedule timeline */
.schedule-list {
  max-width: 680px;
  margin: 0 auto;
  padding-left: 26px;
  border-left: 3px dashed var(--tomato);
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.schedule-item {
  position: relative;
  background: var(--paper);
  border: 2px solid var(--ink);
  border-radius: 14px;
  padding: 14px 20px;
}
.schedule-item::before {
  content: "";
  position: absolute;
  left: -34px;
  top: 20px;
  width: 13px;
  height: 13px;
  border-radius: 50%;
  background: var(--mustard);
  border: 3px solid var(--ink);
}
.schedule-time {
  font-family: var(--font-display);
  font-size: 14px;
  letter-spacing: .06em;
  color: var(--tomato-deep);
}
.schedule-title { font-size: 18px; font-weight: 700; margin-top: 2px; }
.schedule-note { font-size: 14px; color: var(--ink-soft); margin-top: 2px; }

/* practical info cards */
.info-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}
.info-card {
  background: var(--paper);
  border: 2px solid var(--line);
  border-radius: var(--radius);
  padding: 20px;
}
.info-title {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: 17px;
  text-transform: uppercase;
  letter-spacing: .03em;
  margin-bottom: 6px;
}
.info-text { font-size: 14.5px; color: var(--ink-soft); }

/* ── Official flyer / banner (optional — see README to hide) ────────── */
.banner-flyer {
  margin-top: clamp(34px, 6vw, 56px);
  text-align: center;
  position: relative;
}
.banner-flyer-link {
  display: block;
  position: relative;
  border: 3px solid var(--ink);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}
.banner-flyer-link img {
  display: block;
  width: 100%;
  aspect-ratio: 8 / 3;           /* any flyer/poster size crops cleanly */
  object-fit: cover;
  transition: transform .3s ease;
}
.banner-flyer-link:hover img { transform: scale(1.02); }
.banner-flyer-link:focus-visible { outline-offset: 4px; }
.banner-flyer figcaption {
  margin-top: 10px;
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--ink-soft);
}

/* ── Festival Film · optional video embed (data-video-url on .film-card) ─ */
.film-intro {
  max-width: 58ch;
  margin: -8px auto 22px;
  text-align: center;
  color: var(--ink-soft);
  font-size: 15px;
}
.film-frame {
  position: relative;
  width: 100%;
  max-width: 760px;
  margin: 0 auto;
  background: var(--paper);
  border: 3px solid var(--ink);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}
.film-open {
  display: block;
  position: relative;
  width: 100%;
  padding: 0;
  border: 0;
  background: none;
  cursor: pointer;
}
.film-open img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}
.film-open::after {              /* soft overlay keeps play button legible */
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(43, 32, 23, .55), rgba(43, 32, 23, .12));
  pointer-events: none;
}
.film-play {
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  display: grid;
  place-items: center;
  width: 74px; height: 74px;
  border-radius: 50%;
  background: var(--tomato);
  border: 3px solid var(--ink);
  box-shadow: 3px 3px 0 rgba(43, 32, 23, .9);
  z-index: 2;
  transition: transform .15s ease;
}
.film-play svg { width: 30px; height: 30px; margin-left: 4px; }
.film-open:hover .film-play { transform: translate(-50%, -50%) scale(1.08); }
.film-hint {
  position: absolute;
  left: 0; right: 0; bottom: 16px;
  z-index: 2;
  text-align: center;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: #fff;
  text-shadow: 0 2px 4px rgba(0, 0, 0, .5);
  pointer-events: none;
}
.film-frame iframe {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  border: 0;
}
.film-note {
  padding: 40px 20px;
  text-align: center;
  color: var(--ink-soft);
  font-weight: 600;
}
.film-external-wrap { text-align: center; margin-top: 14px; }
.film-external {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-weight: 700;
  color: var(--tomato-deep);
  text-decoration: underline;
  text-underline-offset: 3px;
}
.film-external:hover { color: var(--ink); }
.film-external[hidden] { display: none; }

/* ── Festival Moments · photo gallery (optional — see README to hide) ── */
.moments-section { scroll-margin-top: 20px; }
.moments-intro {
  max-width: 58ch;
  margin: -8px auto 22px;
  text-align: center;
  color: var(--ink-soft);
  font-size: 15px;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}

/* each card is a plain link: works as a lightbox trigger with JS, and as a
   plain "open the image" link without it */
.gallery-item {
  display: block;
  position: relative;
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  background: var(--paper);       /* fallback while loading / if missing */
  border: 3px solid var(--ink);
  border-radius: var(--radius);
  box-shadow: var(--hard-shadow);
  transition: transform .15s ease;
}
.gallery-item:hover { transform: translate(-2px, -2px); }
.gallery-item img {
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 3;            /* any photo size crops cleanly to the card */
  object-fit: cover;
  display: block;
  transition: transform .3s ease;
}
.gallery-item:hover img { transform: scale(1.04); }
.gallery-item figcaption {
  position: absolute;
  inset: auto 0 0 0;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 5px;
  padding: 34px 14px 12px;
  background: linear-gradient(to top, rgba(43, 32, 23, .82), rgba(43, 32, 23, 0));
  color: #fff;
}
.gallery-tag {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--ink);
  background: var(--mustard);
  border-radius: 999px;
  padding: 3px 9px;
}
.gallery-caption {
  font-weight: 700;
  font-size: 15px;
  text-shadow: 0 1px 2px rgba(0, 0, 0, .45);
}
.gallery-item:focus-visible { outline-offset: 4px; }

/* responsive grid rules — placed AFTER the base .lineup-list/.gallery-grid
   declarations so they win at smaller widths (the gallery is 3-up on
   desktop, 2-up on tablets, single column on phones) */
@media (max-width: 900px) {
  .lineup-list { grid-template-columns: repeat(2, 1fr); }
  .gallery-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 560px) {
  .lineup-list { grid-template-columns: 1fr; }
  .gallery-grid { grid-template-columns: 1fr; }
}

/* ── photo viewer (lightbox) — opened by main.js on any photo tap ──────
   Zoom: tap the photo or the 🔍 button — the image renders at full size
   and the viewer scrolls so you can pan around. Arrows / swipe move
   between photos; the ↗ button opens the original file in a new tab. */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgba(43, 32, 23, .92);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
  overflow: hidden;
}
.lightbox.is-zoomed {
  display: block;
  overflow: auto;
  padding: 0;
  overscroll-behavior: contain;
}
.lightbox.is-zoomed .lightbox-figure {
  width: max-content;
  min-width: 100%;
  margin: 48px auto;
}
.lightbox.is-zoomed .lightbox-img {
  max-width: none;
  max-height: none;
  width: auto;
  height: auto;
  margin: 0;
}
.lightbox-figure {
  max-width: min(960px, 92vw);
  text-align: center;
}
.lightbox-img {
  max-width: 100%;
  max-height: 78vh;
  width: auto;
  margin: 0 auto;
  border: 3px solid var(--ink);
  border-radius: var(--radius);
  background: var(--paper);
  cursor: zoom-in;
}
.lightbox.is-zoomed .lightbox-img { cursor: zoom-out; }
.lightbox-figure figcaption {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-top: 14px;
  color: #fff;
}
.lightbox-tag {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--ink);
  background: var(--mustard);
  border-radius: 999px;
  padding: 4px 10px;
}
.lightbox-caption { font-weight: 600; font-size: 16px; }

/* viewer controls — fixed so they stay put while a zoomed photo pans */
.lightbox-btn {
  position: fixed;
  z-index: 2;
  appearance: none;
  display: grid;
  place-items: center;
  font: inherit;
  font-weight: 700;
  font-size: 20px;
  line-height: 1;
  color: #fff;
  background: var(--tomato);
  border: 3px solid var(--ink);
  border-radius: 50%;
  width: 46px;
  height: 46px;
  cursor: pointer;
  box-shadow: 3px 3px 0 rgba(0, 0, 0, .45);
}
.lightbox-btn:hover { background: var(--tomato-deep); }
.lightbox-close { top: 16px; right: 16px; }
.lightbox-prev { left: 14px; top: 50%; transform: translateY(-50%); }
.lightbox-next { right: 14px; top: 50%; transform: translateY(-50%); }
.lightbox-zoom { font-size: 17px; }
.lightbox-zoom[aria-pressed="true"] {
  background: var(--mustard);
  color: var(--ink);
}
.lightbox-toolbar {
  position: fixed;
  bottom: 18px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;
  display: flex;
  gap: 10px;
}
.lightbox-toolbar .lightbox-btn { position: static; transform: none; }
.lightbox-open {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border: 3px solid var(--ink);
  border-radius: 50%;
  background: var(--mustard);
  color: var(--ink);
  font-weight: 700;
  font-size: 18px;
  text-decoration: none;
  box-shadow: 3px 3px 0 rgba(0, 0, 0, .45);
}
.lightbox-open:hover { background: var(--mustard-deep); color: var(--ink); }

@media (max-width: 560px) {
  .lightbox-btn, .lightbox-open { width: 40px; height: 40px; font-size: 17px; }
  .lightbox-prev { left: 8px; }
  .lightbox-next { right: 8px; }
  .lightbox-toolbar { bottom: 12px; }
}

/* end-of-panel CTA */
.panel-cta {
  margin-top: clamp(30px, 5vw, 48px);
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
}
.panel-cta-text { font-size: 15.5px; font-weight: 600; color: var(--ink-soft); }

/* ── brand footer (placeholder, tucked into the last panel by main.js) ── */
.app-footer { padding: 4px 0 6px; text-align: center; }
.footer-brand {
  font-family: var(--font-display);
  font-size: 13px;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--ink-soft);
}
.footer-brand-heart { color: var(--tomato); }
.footer-brand-name { color: var(--tomato); }

/* ── PANEL 3 · RSVP form ─────────────────────────────────────────────── */
.rsvp-wrap { background: var(--cream); }

.form-card {
  max-width: 640px;
  margin: 0 auto;
  background: var(--paper);
  border: 3px solid var(--ink);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: clamp(22px, 4vw, 38px);
}

.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}
.form-group { display: flex; flex-direction: column; gap: 6px; }
.form-group--full { grid-column: 1 / -1; }

.form-group label {
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.form-group .required::after { content: " *"; color: var(--tomato); }

.form-control {
  width: 100%;
  font: inherit;
  color: var(--ink);
  background: #fff;
  border: 2px solid var(--ink);
  border-radius: 10px;
  padding: 12px 14px;
}
.form-control::placeholder { color: #A08E76; }
textarea.form-control { resize: vertical; min-height: 70px; }
select.form-control {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='9' viewBox='0 0 14 9'%3E%3Cpath d='M1 1l6 6 6-6' fill='none' stroke='%232B2017' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 40px;
}

.error {
  display: block;
  min-height: 1.25em;   /* reserve space → no layout jump when shown */
  font-size: 13px;
  font-weight: 600;
  color: var(--tomato-deep);
}
.form-hint { font-size: 12.5px; color: var(--ink-soft); }

/* when "not attending", soften fields that only matter if coming */
.optional-field { transition: opacity .2s ease; }
form.is-not-attending .optional-field { opacity: .5; }

.submit-row { display: flex; justify-content: center; margin-top: 10px; }

.loading {
  display: none;                       /* platform toggles via inline style */
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-top: 18px;
  font-weight: 600;
  color: var(--ink-soft);
}
.loading .spinner {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  border: 3px solid var(--line);
  border-top-color: var(--tomato);
  animation: spin .8s linear infinite;
}

/* countdown (shown only when a deadline is configured) */
.countdown { margin-top: 22px; }
.countdown-label {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--tomato-deep);
}
.countdown-grid {
  display: flex;
  gap: 10px;
  justify-content: center;
  margin-top: 10px;
}
.count-box {
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 66px;
  background: var(--ink);
  color: #fff;
  border-radius: 12px;
  padding: 10px 8px;
}
.count-box .count-day, .count-box .count-hour,
.count-box .count-minute, .count-box .count-second {
  font-family: var(--font-display);
  font-size: 25px;
  line-height: 1;
  color: #fff;
}
.count-box small {
  font-size: 10px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--mustard);
  margin-top: 5px;
}

/* ── PANEL 4 · guestbook (mount points + styling for injected markup) ── */.guestbook-section { background: var(--paper); }
.guestbook-body { max-width: 640px; margin: 0 auto; }

/* the platform injects #guestbookForm with .form-control fields */
.guestbook-section .form-control { margin-bottom: 6px; }

.guestbook-wrap {
  margin-top: 26px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.guestbook-entry {
  background: var(--cream);
  border: 2px solid var(--line);
  border-radius: 14px;
  padding: 16px 18px;
}
.guestbook-entry h5 { margin: 0 0 4px; font-size: 16px; font-weight: 700; }
.guestbook-entry p { margin: 0 0 4px; font-size: 14.5px; color: var(--ink-soft); }
.guestbook-entry small { font-size: 12px; color: var(--ink-soft); opacity: .8; }

.more-guestbook-wrap { text-align: center; margin-top: 22px; }
#load-more { font-family: var(--font-body); font-weight: 700; }

.loading-guestbook {
  display: none;
  text-align: center;
  color: var(--ink-soft);
  font-weight: 600;
  margin-top: 16px;
}

/* the platform replaces .guestbook-body with #guestbookForm (form + list +
   pager). Mirror the RSVP .form-card look so the injected form matches the
   template's own design. */
#guestbookForm {
  background: var(--paper);
  border: 3px solid var(--ink);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: clamp(22px, 4vw, 34px);
  margin-top: 24px;
}
#guestbookForm .form-group { margin-bottom: 14px; }
.guestbook-chapta { margin: 4px 0 12px; }
.guestbook-chapta > div { margin-inline: auto; }
#guestbookForm button[type="submit"] {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin: 8px auto 0;
  background: var(--tomato);
  color: #fff;
  border: 3px solid var(--tomato);
  border-radius: 999px;
  font-family: var(--font-display);
  font-weight: 400;
  font-size: 17px;
  letter-spacing: .04em;
  text-transform: uppercase;
  padding: 14px 28px;
  cursor: pointer;
  box-shadow: 4px 4px 0 rgba(43, 32, 23, .9);
  transition: transform .15s ease, box-shadow .15s ease, background .15s ease;
}
#guestbookForm button[type="submit"]:hover {
  transform: translate(-2px, -2px);
  box-shadow: 6px 6px 0 rgba(43, 32, 23, .9);
}

/* ── PANEL 5 · free page (optional — see README to hide / re-order) ── */
.panel-free { background: var(--cream); }

.free-blocks {
  display: flex;
  flex-direction: column;
  gap: 22px;
  max-width: 700px;
  margin: 0 auto;
}
.free-block {
  background: var(--paper);
  border: 3px solid var(--ink);
  border-radius: var(--radius);
  box-shadow: var(--hard-shadow);
  padding: clamp(20px, 4.5vw, 30px);
}
.free-title {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(1.15rem, 3vw, 1.5rem);
  text-transform: uppercase;
  letter-spacing: .03em;
  margin-bottom: 8px;
}
.free-content {
  font-size: 15px;
  line-height: 1.7;
  color: var(--ink-soft);
}
.free-content p { margin: 0; }

/* optional photo inside a free block — a plain link like every other
   photo slot: opens the full-screen viewer with zoom (main.js) and the
   image file without JS. When the host leaves it empty the engine removes
   the img and the whole .free-figure wrapper, so the block reads as a
   clean title + text with no broken frame. */
.free-figure {
  margin: 16px 0 0;
  background: var(--paper);
  border: 2px solid var(--ink);
  border-radius: 14px;
  overflow: hidden;
}
.free-open { display: block; }
.free-open img {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  transition: transform .3s ease;
}
.free-open:hover img { transform: scale(1.02); }
.free-open:focus-visible { outline-offset: -6px; }

/* ── powered-by brand strip (full-width platform line) ─────────────────
   Sits under the panels in the app shell (and at the end of the stacked
   document without JS). The engine swaps the Kundangi token inside
   .link-footer for the platform name; the cockpit's Free Powered By
   field can override the whole line. */
.powered-by {
  width: 100%;
  text-align: center;
  padding: 10px 14px calc(10px + env(safe-area-inset-bottom));
  border-top: 3px solid var(--ink);
  background: var(--paper);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--ink-soft);
  flex: 0 0 auto;
}
.powered-by .link-footer { color: var(--tomato); }

@media (max-width: 700px) {
  /* clear the fixed bottom nav bar on mobile so the brand line is visible */
  .powered-by { padding-bottom: calc(72px + env(safe-area-inset-bottom)); }
}

/* ── responsive tweaks ───────────────────────────────────────────────── */
@media (max-width: 640px) {
  .facts { grid-template-columns: 1fr 1fr; }
  .fact-item + .fact-item { border-left: 0; }
  .fact-item:nth-child(even) { border-left: 2px dashed var(--line); }
  .fact-item:nth-child(n + 3) { border-top: 2px dashed var(--line); }
  .info-grid { grid-template-columns: 1fr; }
  .form-grid { grid-template-columns: 1fr; }
  /* flavor tiles: shrink a touch so more fit per row on narrow phones and
     longer labels keep breathing room */
  .flavor-strip { gap: 10px; }
  .flavor-tile { width: clamp(74px, 22vw, 88px); padding: 12px 7px 10px; }
  .tile-emoji { font-size: 30px; }
  .sticker-1 { left: 1%; }
  .sticker-2 { right: 1%; }
  .sticker-3, .sticker-4 { display: none; }
  .stamp-badge { right: 2%; }
}

/* ── prefers-reduced-motion: calm everything down ────────────────────── */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
    scroll-behavior: auto !important;
  }
  .marquee-track { animation: none; width: auto; }
  .marquee-copy:last-child { display: none; }
  .marquee { overflow-x: auto; scrollbar-width: none; }
  .marquee::-webkit-scrollbar { display: none; }
  .stamp-badge svg, .loading .spinner { animation: none; }
  .sticker { animation: none; }
  .poster-photo-link:hover img,
  .banner-flyer-link:hover img { transform: none; }
}

/* ── print: a clean, flat invitation ─────────────────────────────────── */
@media print {
  @page { margin: 14mm; }

  html.js body { overflow: visible; }
  .js .shell { height: auto; overflow: visible; display: block; }
  .js .shell-body { position: static; overflow: visible; }
  .js .panel {
    position: static;
    display: block !important;
    overflow: visible;
    height: auto;
  }
  .js .poster { min-height: 0; }
  .panel-inner { padding: 0; }

  .shell-head, .shell-nav, .skip-link,
  .rsvp-wrap, .guestbook-section, .sticker, .stamp-badge,
  .moments-section, .film-card, .panel-free, .powered-by,
  .photo-view-hint, .lightbox { display: none !important; }

  body { background: #fff; color: #000; }
  .poster { gap: 14px; }
  .facts, .vendor-item, .info-card, .schedule-item, .poster-photo,
  .banner-flyer-link, .lightbox-img { box-shadow: none; }
  .swoosh { stroke: #C98A12; }
  .cta-row .btn { display: none; }
  .panel-cover, .panel-details, .rsvp-wrap, .guestbook-section { break-inside: avoid; }
}
