/* ============================================================
   Bible in a Nutshell — premium dark theme
   ============================================================ */

:root {
  --bg: #06070b;
  --bg-soft: #0a0c12;
  --ink: #eef0f6;
  --ink-dim: #a6abbd;
  --ink-faint: #767d90; /* 4.9:1 on --bg at 13px — the old #6b7183 sat below AA */
  --gold: #d9ab5a;
  --gold-bright: #f2cd8a;
  --gold-deep: #a97c2f;
  --blue: #5b7cfa;
  --glass: rgba(255, 255, 255, 0.04);
  --glass-strong: rgba(255, 255, 255, 0.07);
  --stroke: rgba(255, 255, 255, 0.09);
  --stroke-soft: rgba(255, 255, 255, 0.06);
  --radius: 20px;
  --font-display: "Instrument Serif", Georgia, serif;
  --font-body: "Inter", -apple-system, BlinkMacSystemFont, sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  /* clip (not hidden): kills iOS sideways panning from any stray
     over-wide element without creating a scroll container */
  overflow-x: clip;
}

body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  /* clip, NEVER hidden: overflow-x:hidden makes <body> a scroll container,
     which silently rebinds every animation-timeline: view() to a scrollport
     that never scrolls (the roadmap line froze mid-draw). clip clips
     without scroll-container semantics. */
  overflow-x: clip;
  -webkit-font-smoothing: antialiased;
}

::selection { background: rgba(217, 171, 90, 0.35); }

/* Images carrying width/height attributes: the attributes must only
   reserve the pre-load box via aspect-ratio — height:auto hands the loaded
   size back to CSS width + intrinsic ratio. WITHOUT this, the height
   attribute acts as a real height and a width-constrained portrait renders
   stretched to its full natural pixel height (the 2026-08-21 giant-busts
   regression). :where() keeps this at ZERO specificity so every component
   rule (.ep-card img, .card-glass .bust, .stage-chip img, .band-bg img…)
   wins — a bare img[width][height] selector is (0,2,1) and silently BEATS
   (0,1,1) component rules regardless of source order; that mistake cropped
   carousel heads and shrank cards in verification. Author rules at any
   specificity still override the attribute's presentational hint. */
img:where([width][height]) { height: auto; }

/* keyboard focus wears the brand: a gold ring, only for :focus-visible so
   pointer clicks stay clean. Placed early — component rules may override. */
:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 3px;
  border-radius: 2px;
}

.skip-link {
  position: absolute;
  left: 16px; top: -60px;
  z-index: 400;
  padding: 12px 20px;
  background: var(--bg-soft);
  color: var(--gold-bright);
  font: 600 13px/1 var(--font-body);
  letter-spacing: 0.08em;
  text-decoration: none;
  border: 1px solid rgba(217, 171, 90, 0.4);
  clip-path: polygon(8px 0, 100% 0, 100% calc(100% - 8px), calc(100% - 8px) 100%, 0 100%, 0 8px);
  transition: top 0.2s ease;
}
.skip-link:focus-visible { top: 16px; }

/* the bevel clip-path crops an outline entirely — beveled controls show
   keyboard focus in their border and wash instead (same language as hover) */
.book-nav a:focus-visible, .stage-chip:focus-visible, .amt:focus-visible,
.footer-social a:focus-visible, .ra-tile:focus-visible,
.hc-card:focus-visible, .bk-cast:focus-visible {
  outline: none;
  border-color: var(--gold);
  background: rgba(217, 171, 90, 0.12);
}
.ep-card:focus-visible { outline: none; border-color: var(--gold); }

.container {
  width: min(1160px, calc(100% - 48px));
  margin: 0 auto;
}

/* ---------- ambient background orbs ---------- */

.bg-orbs {
  position: fixed;
  inset: 0;
  z-index: -1;
  overflow: hidden;
  background:
    radial-gradient(ellipse 80% 50% at 50% -10%, rgba(91, 124, 250, 0.08), transparent 60%),
    var(--bg);
}

.orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(120px);
  opacity: 0.5;
  animation: drift 24s ease-in-out infinite alternate;
}

.orb-gold {
  width: 560px; height: 560px;
  top: -180px; right: -120px;
  background: radial-gradient(circle, rgba(217, 171, 90, 0.16), transparent 65%);
}

.orb-blue {
  width: 640px; height: 640px;
  bottom: -260px; left: -200px;
  background: radial-gradient(circle, rgba(91, 124, 250, 0.10), transparent 65%);
  animation-delay: -12s;
}

@keyframes drift {
  from { transform: translate3d(0, 0, 0) scale(1); }
  to   { transform: translate3d(60px, 40px, 0) scale(1.15); }
}

/* ---------- glass primitives ---------- */

.glass {
  background: var(--glass);
  border: 1px solid var(--stroke);
  border-radius: var(--radius);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
}

/* spotlight cards — glow follows the cursor (set via JS custom props) */
.spotlight {
  position: relative;
  overflow: hidden;
  transition: border-color 0.35s ease, transform 0.35s ease, box-shadow 0.35s ease;
}

.spotlight::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: radial-gradient(
    420px circle at var(--mx, 50%) var(--my, 50%),
    rgba(217, 171, 90, 0.10),
    transparent 55%
  );
  opacity: 0;
  transition: opacity 0.35s ease;
  pointer-events: none;
}

.spotlight:hover::before { opacity: 1; }

.spotlight:hover {
  border-color: rgba(217, 171, 90, 0.28);
  transform: translateY(-3px);
  box-shadow: 0 18px 50px -18px rgba(0, 0, 0, 0.6);
}

/* ---------- typography helpers ---------- */

.grad-text {
  background: linear-gradient(100deg, var(--gold-bright), var(--gold) 45%, #e8e2d2 90%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 16px;
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: 0.3em;
  text-indent: 0.3em;
  text-transform: uppercase;
  color: var(--gold);
  text-shadow: 0 0 18px rgba(217, 171, 90, 0.35);
  white-space: nowrap;
}

.eyebrow::before,
.eyebrow::after {
  content: "";
  height: 1px;
  width: clamp(28px, 6vw, 58px);
  flex-shrink: 0;
}

.eyebrow::before {
  background: linear-gradient(90deg, transparent, rgba(217, 171, 90, 0.75));
}

.eyebrow::after {
  background: linear-gradient(90deg, rgba(217, 171, 90, 0.75), transparent);
}

/* the 6-item nav (Episodes/.../YouTube + CTA) needs ~900px on one row —
   collapse to the hamburger menu well before it clips */
@media (max-width: 940px) {
  .nav-toggle { display: flex; }

  /* keep the CTA in the bar beside the burger; shorten to "Support" */
  .nav-cta { margin-left: auto; margin-right: 14px; }
  .nav-cta .nav-cta-x { display: none; }

  .nav-links {
    position: absolute;
    top: calc(100% + 10px);
    right: 24px;
    flex-direction: column;
    align-items: stretch;
    gap: 6px;
    padding: 18px;
    min-width: 220px;
    background: rgba(10, 12, 18, 0.92);
    border: 1px solid var(--stroke);
    border-radius: 16px;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    opacity: 0;
    transform: translateY(-8px);
    pointer-events: none;
    /* visibility keeps the closed menu's links OUT of the Tab order —
       opacity alone leaves invisible focus stops */
    visibility: hidden;
    box-shadow: 0 0 0 100vmax rgba(3, 4, 7, 0);
    transition: opacity 0.25s ease, transform 0.25s ease, box-shadow 0.3s ease,
                visibility 0s 0.25s;
  }

  .nav-links.open {
    opacity: 1;
    transform: none;
    pointer-events: auto;
    visibility: visible;
    transition: opacity 0.25s ease, transform 0.25s ease, box-shadow 0.3s ease,
                visibility 0s;
    /* scrim: dim the page behind the open menu */
    box-shadow: 0 0 0 100vmax rgba(3, 4, 7, 0.55);
  }

  .nav-links a:not(.btn) { padding: 10px 8px; }
  .nav-links .btn { margin-top: 8px; }

  .nav-toggle[aria-expanded="true"] span:first-child { transform: translateY(4px) rotate(45deg); }
  .nav-toggle[aria-expanded="true"] span:last-child { transform: translateY(-4px) rotate(-45deg); }

}

@media (max-width: 680px) {
  .eyebrow { white-space: normal; letter-spacing: 0.14em; text-indent: 0.14em; text-wrap: balance; }
}

@keyframes pulse {
  0%, 100% { transform: scale(1); opacity: 1; }
  50%      { transform: scale(0.7); opacity: 0.6; }
}

.section-eyebrow {
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 14px;
}

.section-title {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(34px, 4.6vw, 54px);
  line-height: 1.12;
  letter-spacing: -0.01em;
  margin-bottom: 18px;
}

.section-sub {
  color: var(--ink-dim);
  font-size: 17px;
  max-width: 640px;
  margin-bottom: 48px;
}

.inline-link {
  color: var(--gold);
  text-decoration: none;
  border-bottom: 1px solid rgba(217, 171, 90, 0.4);
  transition: border-color 0.2s;
}
.inline-link:hover { border-color: var(--gold); }

/* ---------- buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--font-body);
  font-size: 15px;
  font-weight: 600;
  padding: 14px 28px;
  border-radius: 14px;
  border: 1px solid transparent;
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.25s ease, box-shadow 0.25s ease, background 0.25s ease, border-color 0.25s ease;
}

.btn:active { transform: scale(0.97); }

.btn-gold {
  color: #1a1204;
  background: linear-gradient(135deg, var(--gold-bright), var(--gold) 55%, var(--gold-deep));
  box-shadow:
    0 0 0 1px rgba(242, 205, 138, 0.25),
    0 8px 30px -8px rgba(217, 171, 90, 0.55);
}

.btn-gold:hover {
  transform: translateY(-2px);
  box-shadow:
    0 0 0 1px rgba(242, 205, 138, 0.4),
    0 14px 40px -8px rgba(217, 171, 90, 0.7);
}

.btn-ghost {
  color: var(--ink);
  background: var(--glass);
  border-color: var(--stroke);
  backdrop-filter: blur(12px);
}

.btn-ghost:hover {
  background: var(--glass-strong);
  border-color: rgba(255, 255, 255, 0.18);
  transform: translateY(-2px);
}

.btn-small { padding: 10px 20px; font-size: 14px; border-radius: 11px; }
.btn-full { width: 100%; }

/* ---------- nav ---------- */

.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  padding: 18px 0;
  transition: padding 0.3s ease, background 0.3s ease, border-color 0.3s ease, backdrop-filter 0.3s ease;
  border-bottom: 1px solid transparent;
}

.nav.scrolled {
  padding: 10px 0;
  background: rgba(6, 7, 11, 0.72);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom-color: var(--stroke-soft);
}

.nav-inner {
  width: min(1160px, calc(100% - 48px));
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--ink);
}

.brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1;
}

.brand-top {
  font-family: var(--font-display);
  font-size: 24px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  background: linear-gradient(
    105deg,
    #f7f0e3 0%,
    #e8d5ae 28%,
    var(--gold-bright) 46%,
    #fdf6e3 50%,
    var(--gold-bright) 54%,
    #e8d5ae 72%,
    #f7f0e3 100%
  );
  background-size: 250% 100%;
  background-position: 0% 0;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-shadow: 0 0 26px rgba(217, 171, 90, 0.22);
  transition: background-position 0.9s ease, letter-spacing 0.5s ease;
}

.brand:hover .brand-top {
  background-position: 100% 0;
  letter-spacing: 0.18em;
}

.brand-sub {
  margin-top: 6px;
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 0.44em;
  text-indent: 0.44em; /* balances the trailing tracking space */
  text-transform: uppercase;
  color: var(--gold);
  opacity: 0.92;
  white-space: nowrap;
}

.brand-sub::before,
.brand-sub::after {
  content: "";
  height: 1px;
  width: 15px;
  flex-shrink: 0;
  transition: width 0.5s ease;
}

.brand-sub::before {
  background: linear-gradient(90deg, transparent, rgba(217, 171, 90, 0.75));
}

.brand-sub::after {
  background: linear-gradient(90deg, rgba(217, 171, 90, 0.75), transparent);
}

.brand:hover .brand-sub::before,
.brand:hover .brand-sub::after {
  width: 24px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 30px;
  /* right-align the links group even though .nav-cta now sits beside it
     (auto margin absorbs the free space before space-between can) */
  margin-left: auto;
}

/* the gold CTA lives OUTSIDE the collapsing menu so phones never lose it.
   gap: the .btn flex gap (8px) separates the "Support" text node from the
   " the Mission" span — 0.3em reads as a normal word space instead. */
.nav-cta { margin-left: 30px; white-space: nowrap; gap: 0.3em; }

.nav-links a:not(.btn) {
  color: var(--ink-dim);
  text-decoration: none;
  font-size: 15px;
  font-weight: 500;
  transition: color 0.2s;
}
.nav-links a:not(.btn):hover { color: var(--ink); }

.nav-toggle {
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  background: none;
  border: none;
  cursor: pointer;
  /* the ONLY navigation control on a phone — the 8px padding around a
     24x2 glyph gave it a 40x26 target, under the 44px minimum */
  min-width: 44px;
  min-height: 44px;
  padding: 8px;
}
.nav-toggle span {
  display: block;
  width: 24px; height: 2px;
  background: var(--ink);
  border-radius: 2px;
  transition: transform 0.3s, opacity 0.3s;
}

/* ---------- hero ---------- */

.hero {
  position: relative;
  padding: 190px 0 90px;
  text-align: center;
}

.hero-compact { padding: 128px 0 26px; }

/* ---------- the living hero: owner-vetted frames on a slow crossfade ---------- */
.hero-film { position: absolute; inset: 0; overflow: hidden; pointer-events: none; }
/* each shot is a PAIR of frames pulled 0.5s apart from the master clip —
   the .alt frame breathes over the base so the film actually moves
   (water shimmers, the four walk, the streams flow). The Ken Burns and
   crossfade live on the shot wrapper. */
.hf-shot { position: absolute; inset: 0; opacity: 0; transition: opacity 1.6s ease; }
.hf-shot.on { opacity: 1; animation: heroKb 10s ease-out forwards; }
/* brighter shots get a targeted dim so the hero text never fights
   cream highlights (owner legibility standard) */
.hf-shot.dim { filter: brightness(0.74) saturate(0.95); }
.hf-shot img {
  position: absolute; inset: 0;
  width: 100%; height: 100%; object-fit: cover; object-position: center 32%;
}
.hf-shot img.alt { opacity: 0; animation: hfBreathe 7s ease-in-out infinite alternate; }
.hf-shot:not(.on) img.alt { animation-play-state: paused; }
/* real footage rides above the stills and dissolves in once decodable */
.hf-shot video {
  position: absolute; inset: 0;
  width: 100%; height: 100%; object-fit: cover; object-position: center 32%;
  opacity: 0; transition: opacity 0.9s ease;
}
.hf-shot video.ready { opacity: 1; }
.hf-shot.video-live img.alt { animation: none; }
@keyframes hfBreathe { to { opacity: 1; } }
@keyframes heroKb { from { transform: scale(1); } to { transform: scale(1.06); } }
/* the support-page scrim pattern: frames melt into --bg so text contrast
   never depends on the frame */
.hero-film::after {
  content: ""; position: absolute; inset: 0;
  background:
    radial-gradient(120% 90% at 50% 30%, transparent 0%, rgba(6, 7, 11, 0.5) 58%, var(--bg) 100%),
    linear-gradient(180deg, rgba(6, 7, 11, 0.8), rgba(6, 7, 11, 0.5) 38%, var(--bg) 96%);
}
.hero { position: relative; }
.hero .hero-inner { position: relative; z-index: 1; }
/* the credit sits in flow right under the CTAs, where the frames live */
.hero-inner .hero-credit {
  position: static;
  margin-top: 26px;
  animation-delay: 0.48s;
}

/* staggered entrance — replaces .reveal on the four hero text blocks */
.hero-rise { animation: heroRise 0.9s cubic-bezier(0.22, 1, 0.36, 1) backwards; }
h1.hero-rise { animation-delay: 0.12s; }
p.hero-sub.hero-rise { animation-delay: 0.24s; }
.hero-cta.hero-rise { animation-delay: 0.36s; }
@keyframes heroRise { from { opacity: 0; transform: translateY(24px); } }

.cursor-glow {
  /* ABOVE the page as blended light (never clipped into seam lines by
     section backdrops — the old z:-1 version was); below modals/slates */
  position: fixed;
  inset: 0;
  z-index: 120;
  pointer-events: none;
  mix-blend-mode: screen;
  background: radial-gradient(
    520px circle at var(--gx, 50%) var(--gy, 30%),
    rgba(217, 171, 90, 0.07),
    transparent 62%
  );
}

.hero-inner {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.hero-title {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(42px, 6.5vw, 78px);
  line-height: 1.08;
  letter-spacing: -0.015em;
  margin: 28px 0 22px;
}

.hero-sub {
  color: var(--ink-dim);
  font-size: 18px;
  max-width: 620px;
  margin-bottom: 36px;
}

.hero-cta {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  justify-content: center;
}

/* hero stage — the character showcase */
.hero-stage {
  margin-top: 70px;
  width: 100%;
  padding: clamp(28px, 4.5vw, 48px) clamp(16px, 3vw, 40px) clamp(20px, 3vw, 34px);
  background:
    radial-gradient(ellipse 60% 80% at 50% 100%, rgba(217, 171, 90, 0.07), transparent),
    var(--glass);
  box-shadow: 0 40px 100px -40px rgba(0, 0, 0, 0.8);
  overflow: hidden;
}

/* The ring is wider than its panel (deliberately — that is the depth), so the
   outermost cards used to hit overflow:hidden at full opacity and get cut with
   a straight vertical edge. These scrims melt them into the panel instead.
   Painted as overlays, NOT a mask: a mask on this element risks flattening the
   preserve-3d ring inside it. */
.hero-stage::before,
.hero-stage::after {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  width: clamp(40px, 9%, 130px);
  pointer-events: none;
  z-index: 3;
}
.hero-stage::before {
  left: 0;
  background: linear-gradient(90deg, rgba(15, 17, 23, 0.92), rgba(15, 17, 23, 0));
}
.hero-stage::after {
  right: 0;
  background: linear-gradient(270deg, rgba(15, 17, 23, 0.92), rgba(15, 17, 23, 0));
}

.cast-eyebrow {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold);
}

.cast-title {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(20px, 2.6vw, 30px);
  margin: 10px 0 34px;
}

.cast-stage {
  --cardW: clamp(150px, 19vw, 212px);
  --radius: calc(var(--cardW) * 5.01); /* 26 cards: 1.21·N/2π — JS recomputes live */
  position: relative;
  height: calc(var(--cardW) * 1.3 + 118px);
  perspective: 1200px;
  cursor: grab;
  touch-action: pan-y;
  user-select: none;
  -webkit-user-select: none;
}

.cast-stage.dragging { cursor: grabbing; }

.cast-ring {
  position: absolute;
  left: 50%;
  top: 4px;
  width: var(--cardW);
  margin-left: calc(var(--cardW) / -2);
  height: 100%;
  transform-style: preserve-3d;
  will-change: transform;
}

.cast-card {
  position: absolute;
  inset: 0 auto auto 0;
  width: var(--cardW);
  margin: 0;
  transform: rotateY(calc(var(--i) * var(--step, 18deg))) translateZ(var(--radius)); /* --step = 360°/cards, set inline + by JS; JS recomputes this live */
  opacity: 0;
  will-change: opacity;
}

/* modern dark glass slab with beveled corners; transparent bust floats inside */
.card-glass {
  --bevel: 13px;
  position: relative;
  height: calc(var(--cardW) * 1.3);
  background: linear-gradient(155deg, rgba(38, 41, 54, 0.9), rgba(12, 14, 20, 0.96));
  clip-path: polygon(
    var(--bevel) 0, calc(100% - var(--bevel)) 0, 100% var(--bevel),
    100% calc(100% - var(--bevel)), calc(100% - var(--bevel)) 100%,
    var(--bevel) 100%, 0 calc(100% - var(--bevel)), 0 var(--bevel)
  );
  box-shadow:
    inset 0 0 0 1px rgba(217, 171, 90, 0.38),
    inset 0 14px 24px -14px rgba(255, 255, 255, 0.22);
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  overflow: hidden;
}

.bust-glow {
  position: absolute;
  inset: 8% 6% 26%;
  background: radial-gradient(ellipse 60% 55% at 50% 62%, rgba(217, 171, 90, 0.28), rgba(217, 171, 90, 0.05) 60%, transparent 75%);
  filter: blur(6px);
}

.card-glass .bust {
  position: absolute;
  left: 4%;
  bottom: 42px;
  width: 92%;
  height: calc(100% - 56px);
  object-fit: contain;
  object-position: center bottom;
  filter: brightness(var(--dim, 1)) drop-shadow(0 14px 22px rgba(0, 0, 0, 0.6));
  /* dissolve the hard bottom slice of source sheets into the glass */
  -webkit-mask-image: linear-gradient(to bottom, black 80%, transparent 99%);
  mask-image: linear-gradient(to bottom, black 80%, transparent 99%);
}

.bust-glow { opacity: var(--dim, 1); }

.card-glass figcaption {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  padding: 8px 6px 10px;
  text-align: center;
  line-height: 1.22;
  background: linear-gradient(to top, rgba(4, 5, 8, 0.96) 55%, rgba(4, 5, 8, 0.55) 82%, transparent);
  border-top: 1px solid rgba(217, 171, 90, 0.22);
}

.card-glass figcaption strong {
  display: block;
  font-family: var(--font-display);
  font-weight: 400;
  /* long names ("Woman Clothed with the Sun") must not crowd the plate edge
     once the card shrinks to 150px on a phone */
  font-size: clamp(13px, 1.1vw + 9px, 16px);
  letter-spacing: 0.05em;
  color: #fff;
  text-shadow: 0 1px 6px rgba(0, 0, 0, 0.9);
}

.card-glass figcaption span {
  font-size: 8.5px;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gold);
  opacity: 0.85;
}

/* pool of gold light under each card */
.cast-card::after {
  content: "";
  position: absolute;
  left: 6%;
  right: 6%;
  bottom: -30px;
  height: 34px;
  background: radial-gradient(ellipse 60% 55% at 50% 50%, rgba(217, 171, 90, 0.4), rgba(217, 171, 90, 0.08) 60%, transparent 75%);
  filter: blur(7px);
  pointer-events: none;
}

/* character modal */
.cast-modal { position: fixed; inset: 0; z-index: 200; }

.cast-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(3, 4, 7, 0.7);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.cast-modal-panel {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  width: min(680px, calc(100% - 40px));
  display: flex;
  gap: 28px;
  align-items: center;
  padding: 34px;
  background: linear-gradient(155deg, rgba(30, 33, 44, 0.95), rgba(10, 12, 18, 0.98));
  animation: modalIn 0.35s ease;
}

@keyframes modalIn {
  from { opacity: 0; transform: translate(-50%, -46%); }
  to   { opacity: 1; transform: translate(-50%, -50%); }
}

.modal-art {
  flex: 0 0 42%;
  background: radial-gradient(ellipse 70% 60% at 50% 65%, rgba(217, 171, 90, 0.22), transparent 75%);
}

.modal-art img {
  display: block;
  width: 100%;
  max-height: 340px;
  object-fit: contain;
  filter: drop-shadow(0 18px 30px rgba(0, 0, 0, 0.65));
}

.modal-info h3 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: 34px;
  margin: 6px 0 10px;
}

.modal-bio {
  color: var(--ink-dim);
  font-size: 15px;
  margin-bottom: 20px;
}

.modal-art img {
  -webkit-mask-image: linear-gradient(to bottom, black 80%, transparent 99%);
  mask-image: linear-gradient(to bottom, black 80%, transparent 99%);
}

/* film production meter */
.film-status { margin-bottom: 22px; }

.film-track {
  height: 7px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--stroke-soft);
  overflow: hidden;
}

.film-fill {
  height: 100%;
  width: 0;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--gold-deep), var(--gold), var(--gold-bright));
  box-shadow: 0 0 12px rgba(217, 171, 90, 0.6);
  transition: width 0.9s cubic-bezier(0.22, 1, 0.36, 1);
}

.film-label {
  margin-top: 8px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gold);
}

.modal-actions { display: flex; gap: 12px; flex-wrap: wrap; }

/* ---------- storybook ---------- */

.story-entry { padding: 70px 0; border-top: 1px solid var(--stroke-soft); }
.story-entry:first-of-type { border-top: none; }

.story-grid {
  display: grid;
  grid-template-columns: 0.8fr 1.2fr;
  gap: 56px;
  align-items: center;
}

.story-entry:nth-of-type(even) .story-art { order: 2; }

.story-art {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
  padding: 30px 10px 0;
  background: radial-gradient(ellipse 70% 55% at 50% 68%, rgba(217, 171, 90, 0.16), transparent 75%);
}

.story-art > img {
  width: min(100%, 340px);
  transition: opacity 0.3s ease;
  filter: drop-shadow(0 24px 40px rgba(0, 0, 0, 0.65));
  -webkit-mask-image: linear-gradient(to bottom, black 80%, transparent 99%);
  mask-image: linear-gradient(to bottom, black 80%, transparent 99%);
}

.story-text h2 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(30px, 3.6vw, 42px);
  margin: 8px 0 10px;
}

.story-hook {
  font-family: var(--font-display);
  font-style: italic;
  font-size: 18px;
  color: var(--gold-bright);
  margin-bottom: 16px;
}

.story-text > p:not(.story-hook):not(.section-eyebrow) {
  color: var(--ink-dim);
  font-size: 15.5px;
  margin-bottom: 14px;
  max-width: 560px;
}

.story-text .film-status { margin-top: 22px; max-width: 380px; }
.story-read-btn { margin-top: 20px; }

@media (max-width: 860px) {
  .story-grid { grid-template-columns: 1fr; gap: 28px; }
  .story-entry:nth-of-type(even) .story-art { order: 0; }
  .story-art > img { width: min(70%, 280px); }
}

/* ---------- comic story pages ---------- */

.comic { max-width: 860px; padding-bottom: 40px; }

.comic-text {
  max-width: 640px;
  margin: 44px auto;
}

.comic-text p {
  color: var(--ink-dim);
  font-size: 16.5px;
  line-height: 1.75;
  margin-bottom: 16px;
}

.comic-text em { color: var(--ink); font-style: italic; }

p.comic-quote {
  position: relative;
  font-family: var(--font-display);
  font-style: italic;
  font-size: clamp(21px, 2.8vw, 28px);
  line-height: 1.55;
  text-align: center;
  color: var(--gold-bright);
  max-width: 560px;
  margin: 48px auto;
  padding-top: 30px;
}

.comic-quote::before {
  content: "\201C";
  position: absolute;
  top: -28px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 110px;
  line-height: 1;
  color: rgba(217, 171, 90, 0.22);
  font-style: normal;
}

.comic-quote span {
  display: block;
  margin-top: 16px;
  font-family: var(--font-body);
  font-style: normal;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--gold);
}

/* drop cap on the story opener */
.comic-text.opener > p:first-child::first-letter {
  font-family: var(--font-display);
  font-size: 3.6em;
  line-height: 0.82;
  float: left;
  padding: 6px 10px 0 0;
  color: var(--gold-bright);
}

/* scene chapter markers */
.scene-mark {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 18px;
  margin: 74px 0 14px;
}

.scene-mark::before,
.scene-mark::after {
  content: "";
  height: 1px;
  width: clamp(34px, 8vw, 80px);
  flex-shrink: 0;
}
.scene-mark::before { background: linear-gradient(90deg, transparent, rgba(217, 171, 90, 0.7)); }
.scene-mark::after { background: linear-gradient(90deg, rgba(217, 171, 90, 0.7), transparent); }

.scene-mark span {
  font-family: var(--font-display);
  font-size: clamp(17px, 2vw, 21px);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold);
  white-space: nowrap;
}

/* magazine rows: panel beside a text card */
.panel-row {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: clamp(22px, 4vw, 44px);
  align-items: center;
  margin: 34px auto;
  max-width: 720px;
}

.panel-row .panel { margin: 0; max-width: none; }
.panel-row.rev .panel { order: 2; }

.side-note .lead {
  font-family: var(--font-display);
  font-size: clamp(19px, 2.2vw, 24px);
  line-height: 1.45;
  color: var(--ink);
  margin-bottom: 14px;
}

.side-note p:not(.lead) {
  color: var(--ink-dim);
  font-size: 15.5px;
  line-height: 1.8;
}

@media (max-width: 760px) {
  .panel-row { grid-template-columns: 1fr; }
  .panel-row.rev .panel { order: 0; }
}

/* frameless floating stills — one shared 720px alignment column */
.panel {
  position: relative;
  margin: 34px auto;
  max-width: 720px;
}

.panel .img-wrap {
  position: relative;
  overflow: hidden;
  border-radius: 10px;
  box-shadow:
    0 30px 70px -26px rgba(0, 0, 0, 0.9),
    0 0 0 1px rgba(255, 255, 255, 0.05);
  transition: box-shadow 0.5s ease;
}

.panel:hover .img-wrap {
  box-shadow:
    0 32px 74px -24px rgba(0, 0, 0, 0.95),
    0 0 44px -10px rgba(217, 171, 90, 0.3),
    0 0 0 1px rgba(217, 171, 90, 0.25);
}

/* caption etched into the image, documentary lower-third */
.panel .third {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  padding: 54px 24px 15px;
  background: linear-gradient(to top, rgba(4, 5, 8, 0.88), rgba(4, 5, 8, 0.35) 60%, transparent);
  pointer-events: none;
}

.panel .rule {
  display: block;
  width: 44px;
  height: 2px;
  background: linear-gradient(90deg, var(--gold), transparent);
  margin-bottom: 9px;
}

.panel .cap {
  font-family: var(--font-display);
  font-style: italic;
  font-size: clamp(14px, 1.9vw, 17px);
  line-height: 1.4;
  color: #efe9db;
  max-width: 80%;
}

.panel .verse {
  margin-top: 5px;
  font-size: 9.5px;
  font-weight: 600;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--gold);
}

/* ambilight: the scene's own light bleeds out behind the still */
.panel .haze {
  position: absolute;
  inset: -4% -3.5%;
  z-index: -1;
  background-size: cover;
  background-position: center;
  filter: blur(42px) saturate(1.25) brightness(0.8);
  opacity: 0.26;
  border-radius: 30px;
  pointer-events: none;
  transition: opacity 0.5s ease;
}

.panel:hover .haze { opacity: 0.4; }

.panel-grid .panel .cap { font-size: 13.5px; max-width: 92%; }
.panel-grid .panel .third { padding: 40px 16px 12px; }

/* editorial crops in side-by-side rows; --obj recenters the subject */
.panel-row .panel img {
  aspect-ratio: 4 / 3.1;
  object-fit: cover;
  object-position: var(--obj, 50% 35%);
}

.panel img {
  display: block;
  width: 100%;
}

.panel-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 22px;
  margin: 26px auto;
  max-width: 720px;
}

.panel-grid .panel { margin: 0; max-width: none; }

.comic-footer { text-align: center; }
.comic-footer .film-status { max-width: 420px; margin: 0 auto; }

/* flip cards — hover to spin */
.flip-eyebrow {
  display: flex;
  justify-content: center;
  margin: 60px 0 24px;
}

.flip-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  max-width: 720px;
  margin: 0 auto;
}

.flip {
  perspective: 900px;
  aspect-ratio: 4 / 5;
  cursor: pointer;
  outline: none;
}

.flip-inner {
  position: relative;
  width: 100%;
  height: 100%;
  transform-style: preserve-3d;
  transition: transform 0.8s cubic-bezier(0.22, 1, 0.36, 1);
}

.flip:hover .flip-inner,
.flip:focus-visible .flip-inner { transform: rotateY(180deg); }

.flip-face {
  position: absolute;
  inset: 0;
  border-radius: 16px;
  overflow: hidden;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  border: 1px solid rgba(217, 171, 90, 0.4);
  box-shadow: 0 20px 50px -20px rgba(0, 0, 0, 0.8);
}

.flip-front img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.flip-front span {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  padding: 10px 8px 12px;
  text-align: center;
  font-family: var(--font-display);
  font-size: 16px;
  color: #fff;
  background: linear-gradient(to top, rgba(4, 5, 8, 0.9), transparent);
}

.flip-back {
  transform: rotateY(180deg);
  background:
    radial-gradient(ellipse 70% 55% at 50% 40%, rgba(217, 171, 90, 0.14), transparent 70%),
    linear-gradient(160deg, #1a1d28, #0b0d14);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 18px;
  text-align: center;
}

.flip-back p {
  font-family: var(--font-display);
  font-style: italic;
  font-size: clamp(13px, 1.6vw, 17px);
  line-height: 1.5;
  color: var(--gold-bright);
}

.flip-back span {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold);
}

/* story quiz */
.quiz-box {
  max-width: 720px;
  margin: 70px auto 0;
  padding: 44px clamp(24px, 5vw, 54px);
}

.quiz-box h3 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(24px, 3vw, 32px);
  margin: 6px 0 26px;
}

.quiz-q { margin-bottom: 28px; }

.quiz-question {
  font-weight: 600;
  font-size: 15.5px;
  margin-bottom: 12px;
}

.quiz-opts { display: flex; flex-wrap: wrap; gap: 10px; }

.quiz-opts button {
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 500;
  color: var(--ink);
  background: var(--glass);
  border: 1px solid var(--stroke);
  border-radius: 11px;
  padding: 10px 18px;
  cursor: pointer;
  transition: border-color 0.25s, background 0.25s, transform 0.2s;
}

.quiz-opts button:hover:not(:disabled) {
  border-color: rgba(217, 171, 90, 0.5);
  transform: translateY(-1px);
}

.quiz-opts button:disabled { cursor: default; opacity: 0.55; }

.quiz-opts button.right {
  opacity: 1;
  color: #1a1204;
  background: linear-gradient(135deg, var(--gold-bright), var(--gold));
  border-color: transparent;
  box-shadow: 0 0 18px -4px rgba(217, 171, 90, 0.6);
}

.quiz-opts button.wrong {
  opacity: 1;
  color: #f0b9b9;
  border-color: rgba(220, 110, 110, 0.5);
  background: rgba(220, 110, 110, 0.08);
}

.quiz-expl {
  margin-top: 10px;
  font-size: 13.5px;
  color: var(--ink-dim);
  font-style: italic;
}

.quiz-score {
  margin-top: 6px;
  text-align: center;
  font-family: var(--font-display);
  font-size: 22px;
  color: var(--gold-bright);
}

@media (max-width: 680px) {
  .flip-row { grid-template-columns: 1fr; max-width: 260px; }
}

@media (max-width: 680px) {
  .panel-grid { grid-template-columns: 1fr; }
}

.modal-close {
  position: absolute;
  top: 4px;
  right: 6px;
  /* the glyph is ~15px wide — the 44px grid box is the real tap target */
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  background: none;
  border: none;
  color: var(--ink-dim);
  font-size: 26px;
  line-height: 1;
  cursor: pointer;
  transition: color 0.2s;
}
.modal-close:hover { color: var(--ink); }


/* ---------- stats ---------- */

.stats { padding: 30px 0 10px; }

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

.stat {
  padding: 28px 24px;
  text-align: center;
}

.stat-num, .stat-plus {
  font-family: var(--font-display);
  font-size: 44px;
  line-height: 1;
  color: var(--gold-bright);
  text-shadow: 0 0 30px rgba(217, 171, 90, 0.35);
}

.stat p {
  margin-top: 10px;
  color: var(--ink-dim);
  font-size: 14px;
}

/* ---------- sections & cards ---------- */

.section { padding: 110px 0; }

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

.card { padding: 34px 30px; }

.card-icon {
  width: 52px;
  height: 52px;
  display: grid;
  place-items: center;
  margin-bottom: 20px;
  color: var(--gold);
  border-radius: 15px;
  border: 1px solid rgba(217, 171, 90, 0.28);
  background: linear-gradient(160deg, rgba(217, 171, 90, 0.12), rgba(217, 171, 90, 0.03));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    0 0 24px -6px rgba(217, 171, 90, 0.35);
}

.card-icon svg {
  width: 24px;
  height: 24px;
  filter: drop-shadow(0 0 6px rgba(217, 171, 90, 0.5));
}

.btn-icon { width: 15px; height: 15px; }

.inst-icon {
  width: 18px;
  height: 18px;
  color: var(--gold);
  flex-shrink: 0;
  filter: drop-shadow(0 0 5px rgba(217, 171, 90, 0.45));
}

.card h3 {
  font-size: 19px;
  font-weight: 600;
  margin-bottom: 10px;
}

.card p { color: var(--ink-dim); font-size: 15px; }

/* ---------- vision (roadmap) — the reel itself lives in the
   ROADMAP v2 · THE REEL block near the end of this file ---------- */

.vision {
  background:
    radial-gradient(ellipse 70% 60% at 50% 0%, rgba(91, 124, 250, 0.05), transparent),
    var(--bg-soft);
  border-top: 1px solid var(--stroke-soft);
  border-bottom: 1px solid var(--stroke-soft);
}


/* the closing wall: the library itself, dimmed behind the final CTA —
   built by script.js from the shelf's already-loaded thumbs (zero bytes) */
.cta-band { position: relative; overflow: hidden; }
.cta-wall {
  position: absolute; inset: -16%;
  display: grid; grid-template-columns: repeat(8, 1fr); gap: 10px;
  align-content: center;
  pointer-events: none; z-index: 0;
  opacity: 0.8;
  /* the drift keyframes own the transform — keep base + keyframes in sync */
  transform: rotate(-4deg) scale(1.18);
  animation: wallDrift 50s ease-in-out infinite alternate;
}
@keyframes wallDrift {
  from { transform: rotate(-4deg) scale(1.18) translate3d(0, 0, 0); }
  to   { transform: rotate(-4deg) scale(1.18) translate3d(-2.5%, -3%, 0); }
}
.cta-wall img { width: 100%; height: auto; display: block; filter: brightness(0.72) saturate(0.9); }
.cta-band::after {
  content: ""; position: absolute; inset: 0; z-index: 1; pointer-events: none;
  /* the vertical layer melts the wall's top/bottom edges into the page —
     without it the tilted grid starts at a hard seam (owner-caught) */
  background:
    linear-gradient(180deg, var(--bg) 0%, transparent 16%, transparent 84%, var(--bg) 100%),
    radial-gradient(80% 85% at 50% 50%, rgba(6, 7, 11, 0.42), rgba(6, 7, 11, 0.78) 86%, var(--bg));
}
.cta-band .container { position: relative; z-index: 2; }
@media (max-width: 680px) { .cta-wall { grid-template-columns: repeat(4, 1fr); } }

/* ---------- book landing pages ---------- */
.bk-hero .hero-inner { position: relative; z-index: 1; }
.bk-hero .lib-count { margin-top: 14px; }
.bk-cast-row { display: flex; flex-wrap: wrap; gap: 14px; }
.bk-cast {
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  width: 108px; padding: 14px 10px 12px; text-decoration: none;
  background: var(--glass); border: 1px solid var(--stroke);
  clip-path: polygon(10px 0, 100% 0, 100% calc(100% - 10px), calc(100% - 10px) 100%, 0 100%, 0 10px);
  transition: border-color 0.25s, transform 0.25s;
}
.bk-cast:hover { border-color: rgba(217, 171, 90, 0.5); transform: translateY(-2px); }
.bk-cast img {
  width: 74px; height: 88px; object-fit: contain; object-position: bottom;
  -webkit-mask-image: linear-gradient(to bottom, black 84%, transparent 100%);
  mask-image: linear-gradient(to bottom, black 84%, transparent 100%);
}
.bk-cast span {
  /* NEBUCHADNEZZAR never fit the 108px tile on one line (measured: needs
     ~94px+ at any legible size) — so legibility wins: 10px, and hyphens
     give the one unavoidable break a proper hyphen instead of a bare snap */
  font: 600 10px/1.35 var(--font-body); letter-spacing: 0.03em; text-transform: uppercase;
  color: var(--ink-dim); text-align: center;
  max-width: 100%; overflow-wrap: break-word; hyphens: auto;
}
.bk-next-row { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
@media (max-width: 680px) { .bk-next-row { flex-direction: column; } .bk-next-row .btn { width: 100%; } }

/* ---------- reader memory: continue slab, journey map, seals ---------- */
.home-continue { margin-bottom: 34px; position: relative; z-index: 1; }
.hc-card {
  display: flex; align-items: center; gap: 18px;
  padding: 14px 20px 14px 14px; text-decoration: none;
  border: 1px solid rgba(217, 171, 90, 0.35);
  clip-path: polygon(14px 0, 100% 0, 100% calc(100% - 14px), calc(100% - 14px) 100%, 0 100%, 0 14px);
  transition: border-color 0.25s, transform 0.25s;
}
.hc-card:hover { border-color: var(--gold); transform: translateY(-2px); }
.hc-card img { width: 148px; height: auto; flex: 0 0 auto;
  clip-path: polygon(8px 0, 100% 0, 100% calc(100% - 8px), calc(100% - 8px) 100%, 0 100%, 0 8px); }
.hc-meta { flex: 1; min-width: 0; }
.hc-eyebrow {
  display: block; font: 600 10px/1 var(--font-body);
  letter-spacing: 0.2em; text-transform: uppercase; color: var(--gold); margin-bottom: 6px;
}
.hc-title { display: block; font: 400 21px/1.2 var(--font-display); color: var(--ink); }
.hc-pos { display: block; margin-top: 5px; font-size: 12.5px; color: var(--ink-dim); }
.hc-go {
  flex: 0 0 auto; font: 600 12px/1 var(--font-body); letter-spacing: 0.1em;
  text-transform: uppercase; color: var(--gold-bright);
}
@media (max-width: 640px) {
  .hc-card { flex-wrap: wrap; }
  .hc-card img { width: 100%; }
}

.journey-strip {
  display: flex; flex-wrap: wrap; align-items: flex-end; gap: 14px 22px;
  margin-top: 22px;
}
.jb { display: flex; flex-direction: column; gap: 6px; }
.jb-name {
  font: 600 10.5px/1 var(--font-body); letter-spacing: 0.16em;
  text-transform: uppercase; color: var(--ink-faint);
}
.jb-dots { display: flex; gap: 4px; }
.jd {
  width: 8px; height: 8px; border-radius: 50%;
  position: relative; /* the ::after pad grows the 8px dot to a real target */
  background: rgba(255, 255, 255, 0.13);
  transition: background 0.25s, box-shadow 0.25s, transform 0.15s;
}
.jd::after { content: ""; position: absolute; inset: -8px; }
/* touch: 24px centers, abutting non-overlapping 24x24 targets — desktop keeps
   its tight 12px spacing (mouse precision makes overlap harmless there) */
@media (pointer: coarse) {
  .jb-dots { gap: 12px; }
  .jd { width: 12px; height: 12px; }
  .jd::after { inset: -6px; }
}
.jd:hover { transform: scale(1.5); background: rgba(217, 171, 90, 0.5); }
.jd.half { background: rgba(217, 171, 90, 0.45); }
.jd.lit { background: var(--gold); box-shadow: 0 0 8px rgba(217, 171, 90, 0.65); }
.jr-count {
  align-self: center; margin-left: 8px;
  font: 600 10.5px/1 var(--font-body); letter-spacing: 0.16em;
  text-transform: uppercase; color: var(--gold);
}

.lib-grid .ep-card.read { border-color: rgba(217, 171, 90, 0.45); }
.ep-seal {
  position: absolute; top: 12px; left: 12px;
  padding: 6px 10px;
  font: 600 10px/1 var(--font-body); letter-spacing: 0.16em; text-transform: uppercase;
  color: #171308; background: var(--gold);
  clip-path: polygon(5px 0, 100% 0, 100% calc(100% - 5px), calc(100% - 5px) 100%, 0 100%, 0 5px);
}

/* ---------- The Library (episodes.html) ---------- */
.book-jump {
  /* pins BELOW the fixed nav (z100, ~65px tall) — top:0 buried it */
  position: sticky; top: 64px; z-index: 40;
  background: rgba(6, 7, 11, 0.86);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--stroke-soft);
  padding: 10px 0;
}
.book-jump .book-nav { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 auto; }
@media (max-width: 680px) {
  /* one horizontally scrolling chip row instead of a ~3-row wall that,
     with the fixed nav, ate a third of a phone viewport */
  .book-jump .book-nav {
    flex-wrap: nowrap; justify-content: flex-start; overflow-x: auto;
    -webkit-overflow-scrolling: touch; scrollbar-width: none;
    max-width: none; padding-bottom: 2px;
  }
  .book-jump .book-nav::-webkit-scrollbar { display: none; }
  .book-jump .book-nav a { flex: 0 0 auto; min-height: 44px; }
}
.lib-book { padding: 46px 0 12px; scroll-margin-top: 150px; }
.lib-book:last-of-type { padding-bottom: 70px; }
.lib-head { display: flex; align-items: baseline; gap: 16px; flex-wrap: wrap; margin-bottom: 18px; }
.lib-head h2 { font: 400 clamp(26px, 3.2vw, 34px)/1.15 var(--font-display); }
.lib-count {
  font: 600 11px/1 var(--font-body); letter-spacing: 0.18em; text-transform: uppercase;
  color: var(--ink-faint);
}
.lib-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
/* library cards reuse the shelf card's look, grid-sized instead of conveyor-sized */
.lib-grid .ep-card { flex: none; width: auto; }
@media (max-width: 980px) { .lib-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px) { .lib-grid { grid-template-columns: 1fr; } }
.lib-continue { margin-top: 22px; }
.play-note { margin-top: 26px; text-align: center; color: var(--ink-faint); font-size: 13.5px; }

/* ---------- footer site map ---------- */
.footer-map-inner { align-items: flex-start; }
.footer-top {
  /* center the short brand block against the taller book map — top-aligning
     left a dead gap under the brand that the owner flagged */
  display: flex; justify-content: space-between; align-items: center;
  gap: 44px; flex-wrap: wrap; width: 100%;
}
.footer-map { display: flex; gap: 46px; flex-wrap: wrap; }
.fm-col { display: flex; flex-direction: column; gap: 8px; min-width: 96px; }
/* the Books column runs 9 links; two internal columns keep the footer short */
.fm-grid {
  display: grid; grid-template-columns: repeat(2, auto);
  column-gap: 26px; row-gap: 8px;
}
.footer-bar {
  display: flex; justify-content: space-between; align-items: center;
  gap: 16px 24px; flex-wrap: wrap; width: 100%;
  border-top: 1px solid var(--stroke-soft); padding-top: 22px;
}
.fm-head {
  font: 600 10.5px/1 var(--font-body); letter-spacing: 0.2em; text-transform: uppercase;
  color: var(--gold); margin-bottom: 4px;
}
.fm-col a { color: var(--ink-dim); text-decoration: none; font-size: 13.5px; transition: color 0.2s; }
.fm-col a:hover { color: var(--ink); }
.nav-links a.on { color: var(--gold-bright); }

/* ---------- 404 rescue row ---------- */
.rescue-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-top: 34px; }
.rescue-row .ep-card { flex: none; width: auto; }
.rescue-label {
  font: 600 11px/1 var(--font-body); letter-spacing: 0.2em; text-transform: uppercase;
  color: var(--ink-faint); margin: 40px 0 0;
}
@media (max-width: 720px) { .rescue-row { grid-template-columns: 1fr; } }

/* one gradient sweep across a stat once its counter lands (script.js).
   Gold-based ends: the number must SETTLE in the same gold-bright the
   .stat-plus suffix wears, or the pair reads as a glitch */
.stat-num.shimmer {
  background: linear-gradient(105deg, var(--gold-bright) 42%, #fdf6e3 50%, var(--gold-bright) 58%);
  background-size: 240% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: statSweep 1.1s ease-out 1 both;
}
@keyframes statSweep { from { background-position: 130% 0; } to { background-position: -30% 0; } }


/* ---------- bento FAQ ---------- */

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

.bento-card { padding: 30px 28px; }

.bento-card.big { grid-column: span 2; grid-row: span 2; }
.bento-card.wide { grid-column: span 2; }

.bento-card h3 {
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 10px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}

.bento-card.big h3 { font-size: 22px; }

.bento-card p { color: var(--ink-dim); font-size: 15px; }

.chev {
  color: var(--gold);
  font-size: 22px;
  transition: transform 0.3s ease;
  flex-shrink: 0;
}

/* collapsible behavior on small faq cards — the control is the .faq-btn
   inside the h3 (real <button>, aria-expanded/aria-controls); the card
   click is a pointer convenience wired in script.js */
.faq-toggle { cursor: pointer; }
.faq-toggle h3 { margin-bottom: 0; } /* no ghost gap under the title when collapsed */
.faq-btn {
  display: flex; justify-content: space-between; align-items: center; gap: 12px;
  width: 100%; background: none; border: 0; padding: 0;
  font: inherit; color: inherit; text-align: left; cursor: pointer;
}
.faq-btn:focus-visible { outline: 2px solid var(--gold); outline-offset: 4px; }
.faq-toggle p {
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  /* visibility keeps collapsed answers (and their links) out of the tab
     order and screen-reader flow — opacity/max-height alone do not */
  visibility: hidden;
  transition: max-height 0.45s ease, opacity 0.35s ease, margin-top 0.35s ease,
    visibility 0.45s;
  margin-top: 0;
}
.faq-toggle.open p { max-height: 220px; opacity: 1; margin-top: 14px; visibility: visible; }
.faq-toggle.open .chev { transform: rotate(90deg); }

/* ---------- cta band ---------- */

.cta-band { padding: 96px 0 150px; } /* room for the tile wall to breathe around the card */

.cta-card {
  position: relative;
  overflow: hidden;
  text-align: center;
  padding: 80px 40px;
}

.cta-glow {
  position: absolute;
  inset: -40%;
  background: radial-gradient(ellipse 50% 45% at 50% 55%, rgba(217, 171, 90, 0.13), transparent 65%);
  pointer-events: none;
}

.cta-card h2 {
  position: relative;
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(30px, 4vw, 46px);
  line-height: 1.15;
  margin-bottom: 14px;
}

.cta-card p {
  position: relative;
  color: var(--ink-dim);
  margin-bottom: 32px;
}

.cta-card .hero-cta { position: relative; }

/* ---------- support page: tiers ---------- */

.tiers {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  align-items: stretch;
}

.tier {
  position: relative;
  overflow: visible; /* the featured badge sits above the card edge */
  padding: 36px 30px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.tier h3 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: 28px;
}

.tier-desc { color: var(--ink-dim); font-size: 15px; flex-grow: 1; }

.tier.featured {
  border-color: rgba(217, 171, 90, 0.4);
  background: linear-gradient(180deg, rgba(217, 171, 90, 0.07), var(--glass));
  box-shadow: 0 20px 60px -25px rgba(217, 171, 90, 0.35);
}

.tier-badge {
  position: absolute;
  top: -13px; left: 50%;
  transform: translateX(-50%);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #1a1204;
  background: linear-gradient(135deg, var(--gold-bright), var(--gold));
  border-radius: 999px;
  padding: 5px 14px;
  white-space: nowrap;
}

.give-note {
  margin-top: 30px;
  text-align: center;
  color: var(--ink-faint);
  font-size: 14px;
}

.give-note { transition: color 0.35s, background 0.35s, box-shadow 0.35s; }
.give-note.flash {
  color: var(--gold);
  background: rgba(217, 171, 90, 0.08);
  box-shadow: inset 0 0 0 1px rgba(217, 171, 90, 0.35);
}
.give-note:focus { outline: none; } /* script.js moves focus here for SR announcement */
.give-note a {
  color: var(--gold);
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-color: rgba(217, 171, 90, 0.45);
}
.give-note a:hover { text-decoration-color: var(--gold); }

.give-trust svg { width: 15px; height: 15px; vertical-align: -2px; margin-right: 6px; color: var(--gold); }
.give-trust[hidden] { display: none; }

/* The hidden attribute outranks component display rules — without this a
   `.film-endcard { display: flex }` (or .journey-strip) paints over the page
   while still marked hidden, and JS toggling el.hidden does nothing. */
[hidden] { display: none !important; }

/* ---------- support page: institutions ---------- */

.institutions { padding-top: 0; }

.inst-card {
  position: relative;
  overflow: hidden;
  padding: 70px 60px;
}

.inst-card .section-sub { margin-bottom: 40px; }

.inst-grid {
  position: relative;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px 40px;
  margin-bottom: 44px;
}

.inst-item {
  padding: 20px 22px;
  border: 1px solid var(--stroke-soft);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.02);
}

.inst-item h3 {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 6px;
  display: flex;
  align-items: center;
  gap: 9px;
}
.inst-item p { color: var(--ink-dim); font-size: 14px; }

/* ---------- footer ---------- */

.footer {
  border-top: 1px solid var(--stroke-soft);
  padding: 50px 0;
  background: var(--bg-soft);
}

.footer-inner {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 34px;
}

/* the studio credit reads like a film card: small caps, quiet, gold name —
   and it IS the channel link now, so it earns a hover */
.footer-studio {
  display: block;
  margin-top: 10px;
  font: 600 10.5px/1.6 var(--font-body);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink-faint);
  text-decoration: none;
  transition: color 0.2s;
}
.footer-studio strong { font-weight: 600; color: var(--gold); transition: color 0.2s; }
.footer-studio:hover { color: var(--ink-dim); }
.footer-studio:hover strong { color: var(--gold-bright); }

.give-entity {
  margin-top: 14px;
  text-align: center;
  color: var(--ink-faint);
  font-size: 13px;
}
.give-entity strong { color: var(--gold-bright); font-weight: 600; }

.footer-tag {
  color: var(--ink-faint);
  font-size: 14px;
  margin-top: 8px;
  font-style: italic;
  font-family: var(--font-display);
}

/* must wrap: six links are ~540px in one line — wider than a phone, and
   one overflowing row hands iOS a sideways pan for the whole page */
.footer-links { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px 24px; }

.footer-links a {
  color: var(--ink-dim);
  text-decoration: none;
  font-size: 14px;
  transition: color 0.2s;
}
.footer-links a:hover { color: var(--ink); }

.footer-copy { color: var(--ink-faint); font-size: 13px; }
.footer-copy a {
  color: inherit; text-decoration: underline;
  text-underline-offset: 2px; transition: color 0.2s;
}
.footer-copy a:hover { color: var(--ink); }

/* ---------- scroll reveal ---------- */

.reveal {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal.in {
  opacity: 1;
  transform: none;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }.orb { animation: none; }
  /* the living hero holds its first frame, text appears instantly —
     the higher-specificity .on/.alt selectors must be named or they win */
  .hc-card, .jd { transition: none; }
  .hc-card:hover { transform: none; }
  .jd:hover { transform: none; }
  .hf-shot, .hf-shot.on { transition: none; animation: none; }
  .hf-shot img.alt { animation: none; opacity: 0; }
  .hf-shot video { display: none; } /* script.js never loads it either */
  .cta-wall { animation: none; }
  .hero-rise { animation: none; }
  .stat-num.shimmer { animation: none; background: none; color: inherit; }
}

/* keyboard access to the cast ring: the glass carries the focus, since the
   card itself is a 3D-transformed figure. INSET shadows only — the glass's
   beveled clip-path clips everything painted outside it (outer box-shadows
   included, same trap as the outline), and border-color would paint
   nothing on a border-less element */
.cast-card:focus-visible { outline: none; }
.cast-card:focus-visible .card-glass {
  box-shadow: inset 0 0 0 2px var(--gold), inset 0 0 30px rgba(217, 171, 90, 0.35);
}

/* ---------- responsive ---------- */

@media (max-width: 980px) {
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .cards-3 { grid-template-columns: 1fr; }
  .bento { grid-template-columns: repeat(2, 1fr); }
  .bento-card.big { grid-column: span 2; grid-row: auto; }
  .tiers { grid-template-columns: 1fr; }
  .tier.featured { order: -1; }
  .inst-card { padding: 50px 30px; }
  .inst-grid { grid-template-columns: 1fr; }
}

@media (max-width: 680px) {
  .hero { padding-top: 150px; padding-bottom: 48px; }
  .hero-title { text-wrap: balance; }
  .stats { padding: 10px 0; }
  .cast-stage { perspective: 850px; height: calc(var(--cardW) * 1.3 + 40px); }
  .card-glass figcaption span { display: none; }
  .cast-modal-panel {
    flex-direction: column; text-align: center; padding: 24px 22px;
    max-height: 86svh; overflow-y: auto;
  }
  .modal-art { flex-basis: auto; width: 56%; }
  .modal-art img { max-height: 190px; }
  .modal-actions { justify-content: center; }
  .bento { grid-template-columns: 1fr; }
  .bento-card.big, .bento-card.wide { grid-column: auto; }

  /* footer: stacked, no space-between voids — brand, then the map as a
     two-column grid (Books spanning both), then the © + socials bar */
  .footer-top { flex-direction: column; align-items: stretch; gap: 30px; }
  .footer-map { display: grid; grid-template-columns: 1fr 1fr; gap: 28px 20px; width: 100%; }
  .fm-col-books { grid-column: 1 / -1; }
  .footer-bar { flex-direction: column-reverse; align-items: center; text-align: center; gap: 14px; }
}

/* ---------- cinematic page transition (storybook → story pages) ---------- */

.page-slate {
  position: fixed; inset: 0; z-index: 300;
  visibility: hidden; pointer-events: none;
}
.page-slate.on { visibility: visible; pointer-events: all; }

.page-slate .ps-bar {
  position: absolute; left: 0; right: 0; height: 50.5%;
  background: #04050a;
  transform: scaleY(0);
  transition: transform 0.6s cubic-bezier(0.76, 0, 0.24, 1);
}
.page-slate .ps-top { top: 0; transform-origin: top; border-bottom: 1px solid rgba(217, 171, 90, 0.3); }
.page-slate .ps-bot { bottom: 0; transform-origin: bottom; border-top: 1px solid rgba(217, 171, 90, 0.3); }
.page-slate.on .ps-bar { transform: scaleY(1); }

.page-slate .ps-card {
  position: absolute; inset: 0; z-index: 2;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 18px; text-align: center; padding: 0 24px;
  opacity: 0; translate: 0 16px;
  transition: opacity 0.5s ease 0.35s, translate 0.65s cubic-bezier(0.22, 0.61, 0.36, 1) 0.35s;
}
.page-slate.on .ps-card { opacity: 1; translate: 0 0; }

.ps-eyebrow {
  display: inline-flex; align-items: center; gap: 9px;
  font: 600 11px/1 var(--font-body);
  letter-spacing: 0.3em; text-transform: uppercase;
  color: var(--gold);
}
.ps-eyebrow i {
  width: 5px; height: 5px; border-radius: 50%;
  background: var(--gold); box-shadow: 0 0 10px var(--gold);
}
.ps-title {
  font: 400 clamp(40px, 7vw, 84px)/1.05 var(--font-display);
  letter-spacing: -0.01em; color: var(--ink);
  text-shadow: 0 6px 60px rgba(0, 0, 0, 0.9);
}
.ps-title em {
  display: block; font-style: italic;
  background: linear-gradient(100deg, var(--gold-bright), var(--gold) 55%, var(--gold-deep));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.ps-line {
  width: 0; height: 1px;
  background: linear-gradient(90deg, transparent, var(--gold), transparent);
  transition: width 0.8s ease 0.5s;
}
.page-slate.on .ps-line { width: min(260px, 44vw); }

/* ---------- storybook: "through the years" life-stage strip ---------- */

.stage-strip {
  position: relative; z-index: 2;
  display: flex; gap: 10px; justify-content: center; flex-wrap: wrap;
}
.stage-chip {
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  width: 92px; padding: 12px 8px 10px; cursor: pointer;
  background: linear-gradient(155deg, rgba(38, 41, 54, 0.9), rgba(12, 14, 20, 0.96));
  border: 1px solid var(--stroke);
  clip-path: polygon(8px 0, 100% 0, 100% calc(100% - 8px), calc(100% - 8px) 100%, 0 100%, 0 8px);
  transition: border-color 0.25s, transform 0.25s;
}
.stage-chip img {
  width: 62px; height: 74px; object-fit: contain; object-position: bottom;
  pointer-events: none; filter: brightness(0.85);
  -webkit-mask-image: linear-gradient(to bottom, black 82%, transparent 100%);
  mask-image: linear-gradient(to bottom, black 82%, transparent 100%);
  transition: filter 0.25s;
}
.stage-chip span {
  font: 600 9.5px/1 var(--font-body); white-space: nowrap;
  letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--ink-faint); transition: color 0.25s;
}
.stage-chip:hover { border-color: rgba(217, 171, 90, 0.45); transform: translateY(-2px); }
.stage-chip.is-active { border-color: var(--gold); }
.stage-chip.is-active img { filter: none; }
.stage-chip.is-active span { color: var(--gold); }

/* ==========================================================================
   EPISODES SHELF · ROADMAP EXTRAS · CHARACTER PEEKERS · SOCIALS  (v27)
   ========================================================================== */

/* ---- interactive episodes shelf ---- */
.episodes { padding-bottom: 90px; }
.shelf-wrap { position: relative; margin-top: 44px; }
.shelf {
  overflow: hidden; /* the conveyor track inside moves via transform, not scroll */
  touch-action: pan-y; /* the shelf drives horizontal itself; vertical stays native */
  padding: 8px max(calc((100vw - 1140px) / 2), 24px) 22px;
  /* premium rails: cards dissolve into the dark at both edges */
  --shelf-fade: 96px;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 var(--shelf-fade), #000 calc(100% - var(--shelf-fade)), transparent);
          mask-image: linear-gradient(90deg, transparent, #000 var(--shelf-fade), #000 calc(100% - var(--shelf-fade)), transparent);
}
/* built by script.js around the ep-cards; sub-pixel translate3d is what
   keeps the slow parade glassy where scrollLeft would tick in 1px steps */
.shelf-track { display: flex; gap: 18px; width: max-content; will-change: transform; }
.ep-card {
  position: relative; flex: 0 0 350px; aspect-ratio: 16 / 10;
  display: block; overflow: hidden;
  background: var(--bg-soft, #0a0c12);
  border: 1px solid rgba(255, 255, 255, 0.09);
  clip-path: polygon(16px 0, 100% 0, 100% calc(100% - 16px), calc(100% - 16px) 100%, 0 100%, 0 16px);
  transform: translateZ(0);
}
.ep-card img {
  width: 100%; height: 100%; object-fit: cover; display: block;
  transition: transform 0.7s cubic-bezier(0.22, 0.61, 0.36, 1);
}
.ep-card:hover img, .ep-card:focus-visible img { transform: scale(1.06); }
.ep-scrim {
  position: absolute; inset: 0;
  /* calibrated on dark (enoch 004), mid (exodus 022) and bright (sealed
     189) frames together: the letter halos carry legibility on bright
     frames, so the plate stays light enough to keep the imagery — the
     heavier 0.6/0.93 version crushed night scenes */
  background: linear-gradient(180deg, rgba(6, 7, 11, 0.04), rgba(6, 7, 11, 0.1) 30%, rgba(6, 7, 11, 0.42) 50%, rgba(6, 7, 11, 0.8) 74%, rgba(6, 7, 11, 0.96));
}
.ep-meta {
  position: absolute; left: 22px; right: 22px; bottom: 18px;
  display: flex; flex-direction: column; gap: 5px;
}
.ep-book {
  font: 600 10.5px/1 var(--font-body, "Inter", sans-serif);
  letter-spacing: 0.2em; text-transform: uppercase;
  color: var(--gold-bright, #f2cd8a);
  /* the label sits highest, where the scrim is thinnest — the stacked
     halo is its own local scrim */
  text-shadow: 0 1px 2px rgba(4, 5, 8, 0.95), 0 0 9px rgba(4, 5, 8, 0.9), 0 0 18px rgba(4, 5, 8, 0.7);
}
.ep-title {
  font: 400 26px/1.15 var(--font-display, "Instrument Serif", serif);
  color: #fff;
  text-shadow: 0 1px 2px rgba(4, 5, 8, 0.95), 0 2px 10px rgba(4, 5, 8, 0.88), 0 6px 26px rgba(4, 5, 8, 0.6);
}
.ep-title em { font-style: italic; color: var(--gold-bright, #f2cd8a); }
.ep-read {
  margin-top: 5px;
  font: 600 10.5px/1 var(--font-body, "Inter", sans-serif);
  letter-spacing: 0.16em; text-transform: uppercase; color: var(--ink-dim);
  text-shadow: 0 1px 2px rgba(4, 5, 8, 0.95), 0 0 8px rgba(4, 5, 8, 0.85);
  transition: color 0.25s ease;
}
.ep-read::after { content: " ›"; color: var(--gold); }
.ep-card:hover .ep-read, .ep-card:focus-visible .ep-read { color: var(--gold-bright, #f2cd8a); }
/* the shelf's six playable episodes wear a small glass chip */
.ep-badge {
  position: absolute; top: 12px; right: 12px;
  display: inline-flex; align-items: center; gap: 6px;
  padding: 7px 11px;
  font: 600 10px/1 var(--font-body, "Inter", sans-serif);
  letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--gold-bright, #f2cd8a);
  background: rgba(6, 7, 11, 0.62);
  border: 1px solid rgba(217, 171, 90, 0.38);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  clip-path: polygon(6px 0, 100% 0, 100% calc(100% - 6px), calc(100% - 6px) 100%, 0 100%, 0 6px);
}
.ep-badge svg { width: 14px; height: 14px; }
.ep-count {
  font: 600 11px/1 var(--font-body, "Inter", sans-serif);
  letter-spacing: 0.2em; text-transform: uppercase;
  color: var(--ink-faint);
  margin: -34px 0 0;
}
.shelf-more { text-align: center; margin-top: 26px; }

/* book chips: jump the conveyor to a book's first card */
.shelf-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; position: relative; z-index: 2; }
.shelf-chips button {
  font: 600 11px/1 var(--font-body); letter-spacing: 0.05em;
  color: var(--ink-dim); cursor: pointer;
  display: inline-flex; align-items: center;
  min-height: 40px; /* real thumbs need real targets */
  background: rgba(255, 255, 255, 0.03); border: 1px solid var(--stroke);
  padding: 8px 14px;
  clip-path: polygon(6px 0, 100% 0, 100% calc(100% - 6px), calc(100% - 6px) 100%, 0 100%, 0 6px);
  transition: color 0.2s, border-color 0.2s, background 0.2s;
}
.shelf-chips button:hover { color: var(--gold-bright); border-color: rgba(217, 171, 90, 0.4); }
.shelf-chips button.on { color: var(--gold-bright); border-color: var(--gold); background: rgba(217, 171, 90, 0.1); }
.shelf-chips button:focus-visible { outline: none; border-color: var(--gold); background: rgba(217, 171, 90, 0.12); }

/* play band: three game vignettes under the shelf */
.play-band { margin-top: 54px; }
.pb-eyebrow {
  font: 600 11px/1 var(--font-body); letter-spacing: 0.2em; text-transform: uppercase;
  color: var(--gold); margin-bottom: 16px;
}
.pb-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.pb-card {
  display: block; text-decoration: none; overflow: hidden;
  border: 1px solid var(--stroke);
  clip-path: polygon(14px 0, 100% 0, 100% calc(100% - 14px), calc(100% - 14px) 100%, 0 100%, 0 14px);
  transition: border-color 0.25s, transform 0.25s;
}
.pb-card:hover { border-color: rgba(217, 171, 90, 0.45); transform: translateY(-3px); }
.pb-card:focus-visible { outline: none; border-color: var(--gold); }
.pb-card img { width: 100%; height: auto; display: block; filter: brightness(0.82); transition: filter 0.3s; }
.pb-card:hover img { filter: brightness(1); }
.pb-meta { display: block; padding: 14px 16px 16px; }
.pb-name { display: block; font: 400 20px/1.2 var(--font-display); color: var(--ink); }
.pb-name::after { content: " ›"; color: var(--gold); }
.pb-hook { display: block; margin-top: 5px; font-size: 13px; color: var(--ink-dim); }
@media (max-width: 980px) { .pb-grid { grid-template-columns: 1fr; } }

.yt-band {
  margin-top: 48px; padding: 30px 34px;
  display: flex; align-items: center; justify-content: space-between; gap: 26px;
}
.yt-band-text h2, .yt-band-text h3 { font-size: 22px; font-weight: 600; }
.yt-band-text p { color: var(--ink-dim); font-size: 14px; margin-top: 6px; }
.yt-band .btn { flex: 0 0 auto; }

/* ---- character peekers (decorative busts around the page) ---- */
.section > .container, .cta-band .container { position: relative; }
.peek {
  position: absolute; z-index: 0;
  pointer-events: none; user-select: none;
  opacity: 0.92;
  filter: drop-shadow(0 24px 44px rgba(0, 0, 0, 0.55));
  -webkit-mask-image: linear-gradient(180deg, #000 76%, transparent);
  mask-image: linear-gradient(180deg, #000 76%, transparent);
  animation: peekFloat 7s ease-in-out infinite;
}
@keyframes peekFloat { 50% { translate: 0 -8px; } }
/* keep real content painting above the peekers */
.section-eyebrow, .section-title, .section-sub, .cards-3, .bento,
.reel, .yt-band, .cta-card, .shelf-wrap { position: relative; z-index: 1; }
.peek-jonah   { width: 132px; left: -38px;  top: -96px;  rotate: -6deg; animation-delay: 0.8s; }
.peek-david   { width: 150px; right: -26px; top: -70px;  rotate: 5deg; }
.peek-enoch   { width: 170px; right: -30px; top: 190px;  rotate: 3deg;  animation-delay: 1.6s; }
.peek-solomon { width: 150px; right: 5%;    top: -62px;  rotate: 4deg;  animation-delay: 2.4s; }
.peek-hannah  { width: 140px; right: -20px; top: -60px;  rotate: 4deg; }

/* ---- footer socials ---- */
.footer-social { display: flex; gap: 12px; }
.footer-social a {
  width: 44px; height: 44px; display: grid; place-items: center;
  color: var(--ink-dim); border: 1px solid rgba(255, 255, 255, 0.12);
  clip-path: polygon(8px 0, 100% 0, 100% calc(100% - 8px), calc(100% - 8px) 100%, 0 100%, 0 8px);
  transition: color 0.25s ease, border-color 0.25s ease;
}
.footer-social a:hover { color: var(--gold-bright, #f2cd8a); border-color: rgba(217, 171, 90, 0.45); }
.footer-social svg { width: 18px; height: 18px; }

@media (max-width: 900px) {
  .peek { display: none; }
  .yt-band { flex-direction: column; text-align: center; }
}
@media (max-width: 720px) {
  .ep-card { flex-basis: 80vw; }
  .ep-title { font-size: 23px; }
  .shelf { padding-left: 18px; padding-right: 18px; --shelf-fade: 40px; }
  .shelf-track { gap: 12px; }
}
@media (prefers-reduced-motion: reduce) {
  .peek { animation: none; }
  .ep-card img, .ep-card:hover img { transition: none; transform: none; }
}

/* ==========================================================================
   SHELF DRAG SMOOTHING · (v29)
   ========================================================================== */

/* The shelf is a conveyor now — scroll-snap is gone for good (it re-snapped
   on every scrollLeft write, which both stepped the drag card-by-card and
   would fight the idle drift). The class only handles grab feedback. */
.shelf { cursor: grab; }
.shelf.dragging { cursor: grabbing; user-select: none; }

/* ==========================================================================
   BOOK-GROUPED STORYBOOK  (v29)
   ========================================================================== */

/* jump strip under the storybook hero */
.book-nav {
  display: flex; flex-wrap: wrap; justify-content: center; gap: 8px;
  margin: 26px auto 0; max-width: 780px; position: relative; z-index: 1;
}
.book-nav a {
  font: 600 11px/1 var(--font-body); letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--ink-dim); text-decoration: none;
  background: var(--glass); border: 1px solid var(--stroke);
  padding: 9px 13px;
  min-height: 40px; display: inline-flex; align-items: center; /* shelf-chips precedent */
  clip-path: polygon(6px 0, 100% 0, 100% calc(100% - 6px), calc(100% - 6px) 100%, 0 100%, 0 6px);
  transition: color 0.25s ease, border-color 0.25s ease;
}
.book-nav a:hover { color: var(--gold-bright); border-color: rgba(217, 171, 90, 0.45); }


/* ==========================================================================
   SUPPORT PAGE — SPONSORSHIP EXPERIENCE  (v29)
   ========================================================================== */

/* film-frame hero backdrop */
.support-hero { position: relative; overflow: hidden; }
.hero-backdrop { position: absolute; inset: 0; pointer-events: none; }
.hero-backdrop img { width: 100%; height: 100%; object-fit: cover; object-position: center 30%; }
.hero-backdrop::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(6, 7, 11, 0.78), rgba(6, 7, 11, 0.58) 45%, var(--bg) 97%);
}
.support-hero .hero-inner { position: relative; z-index: 1; }
.hero-credit {
  position: absolute; right: 18px; bottom: 14px; z-index: 1;
  font: 600 10.5px/1 var(--font-body);
  letter-spacing: 0.12em; text-transform: uppercase;
  color: rgba(238, 240, 246, 0.42);
}

/* film-frame band backdrops (mid-page sections) */
.band { position: relative; overflow: hidden; }
.band > .container { position: relative; z-index: 1; }
.band-bg { position: absolute; inset: 0; pointer-events: none; }
.band-bg img { width: 100%; height: 100%; object-fit: cover; }
.band-bg::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, var(--bg), rgba(6, 7, 11, 0.78) 16%, rgba(6, 7, 11, 0.78) 84%, var(--bg));
}
.band-deep .band-bg::after {
  background: linear-gradient(180deg, var(--bg), rgba(6, 7, 11, 0.88) 16%, rgba(6, 7, 11, 0.88) 84%, var(--bg));
}

/* what your gift animates */
.gift-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; margin-top: 44px; }
.gift-card { padding: 30px 26px; }
.gift-amt { display: block; font-family: var(--font-display); font-size: 30px; line-height: 1; color: var(--gold-bright); margin: 16px 0 6px; }
.gift-amt i { font-style: normal; font-size: 15px; color: var(--ink-dim); }
.gift-card h3 { font-size: 17px; margin-bottom: 8px; }
.gift-card p { color: var(--ink-dim); font-size: 14px; }
.gift-note { margin-top: 20px; color: var(--ink-faint); font-size: 13px; }

/* film progress panel */
.prog-panel { margin-top: 40px; padding: 34px 38px; display: grid; grid-template-columns: repeat(2, 1fr); gap: 24px 44px; }
.prog-head { grid-column: 1 / -1; }
.prog-head h3 { font-family: var(--font-display); font-weight: 400; font-size: 26px; }
.prog-head p { color: var(--ink-dim); font-size: 14px; margin-top: 6px; }
.prog-item .film-status { margin-bottom: 0; }

/* monthly amount tiers */
.amt-list { display: flex; flex-direction: column; gap: 10px; margin-top: 18px; }
.amt {
  display: flex; align-items: center; justify-content: space-between; gap: 14px;
  width: 100%; padding: 14px 18px; cursor: pointer; text-align: left;
  text-decoration: none; /* populated buttons become real anchors (script.js) */
  background: rgba(255, 255, 255, 0.03); color: var(--ink);
  border: 1px solid var(--stroke); font-family: var(--font-body);
  clip-path: polygon(10px 0, 100% 0, 100% calc(100% - 10px), calc(100% - 10px) 100%, 0 100%, 0 10px);
  transition: border-color 0.25s ease, background 0.25s ease, transform 0.25s ease;
}
.amt { min-height: 62px; } /* keep the four rungs an even stack whatever the tag wraps to */
.amt:hover { border-color: rgba(217, 171, 90, 0.5); background: rgba(217, 171, 90, 0.07); transform: translateY(-2px); }
.amt-sum { font-family: var(--font-display); font-size: 22px; line-height: 1; color: var(--gold-bright); white-space: nowrap; }
.amt-sum i { font-style: normal; font-size: 13px; color: var(--ink-dim); }
.amt-tag { flex: 1; font-size: 13px; color: var(--ink-dim); }
.amt-go { color: var(--gold); font-size: 20px; line-height: 1; flex: 0 0 auto; }
.amt-featured { border-color: rgba(217, 171, 90, 0.55); background: rgba(217, 171, 90, 0.06); }

/* where every krona goes */
.krona-bar { margin-top: 44px; }
.krona-track {
  height: 14px; border-radius: 999px; overflow: hidden;
  background: rgba(255, 255, 255, 0.07); border: 1px solid var(--stroke-soft);
}
.krona-fill {
  height: 100%; width: 100%; border-radius: 999px;
  background: linear-gradient(90deg, var(--gold-deep), var(--gold), var(--gold-bright));
  box-shadow: 0 0 18px rgba(217, 171, 90, 0.5);
}
.krona-caption {
  display: flex; justify-content: space-between; gap: 12px; margin: 10px 2px 34px;
  font: 600 12px/1.4 var(--font-body); letter-spacing: 0.1em; text-transform: uppercase; color: var(--gold);
}
.pledges { display: flex; flex-wrap: wrap; gap: 22px; margin-top: 30px; }
.pledge { display: flex; gap: 10px; align-items: flex-start; flex: 1 1 240px; color: var(--ink-dim); font-size: 14px; }
.pledge svg { width: 20px; height: 20px; color: var(--gold); flex: 0 0 auto; margin-top: 2px; }

/* sponsor faq */
.faq-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; margin-top: 44px; }

@media (max-width: 900px) {
  .gift-grid { grid-template-columns: repeat(2, 1fr); }
  .prog-panel { grid-template-columns: 1fr; padding: 28px 24px; }
}
@media (max-width: 680px) {
  .gift-grid { grid-template-columns: 1fr; }
  .faq-grid { grid-template-columns: 1fr; }
  .amt { flex-wrap: wrap; }
  .hero-credit { display: none; }
}

/* links inside stat labels + FAQ answers stay on-brand (default blue jars on dark) */
.stat p a, .faq-toggle p a[href] {
  color: var(--gold); text-decoration: underline;
  text-underline-offset: 3px; text-decoration-color: rgba(217, 171, 90, 0.45);
}
.stat p a:hover, .faq-toggle p a[href]:hover { color: var(--gold-bright); }

/* nav hamburger cascade fix: the ≤940px nav media block sits ABOVE the base
   .nav-toggle { display:none } rule in source order, so at equal specificity
   the base rule was winning at every width — the menu button vanished
   site-wide on mobile (live bug since the v27 nav reshuffle). Re-assert the
   mobile state here, after the base rule. */
@media (max-width: 940px) {
  .nav-toggle { display: flex; }
}


/* ==========================================================================
   BAND EDGE BLEED  (v35) — bands' opaque backdrops ended in a sharp line
   against the page background (originally exposed by the since-removed
   cursor glow, still true without it). Fade the frame AND the veil to
   transparent at the edges: no boundary, nothing for the glow to clip on.
   ========================================================================== */
.band-bg img {
  -webkit-mask-image: linear-gradient(180deg, transparent, #000 16%, #000 84%, transparent);
  mask-image: linear-gradient(180deg, transparent, #000 16%, #000 84%, transparent);
}
.band-bg::after {
  background: linear-gradient(180deg, rgba(6, 7, 11, 0), rgba(6, 7, 11, 0.78) 16%, rgba(6, 7, 11, 0.78) 84%, rgba(6, 7, 11, 0));
}
.band-deep .band-bg::after {
  background: linear-gradient(180deg, rgba(6, 7, 11, 0), rgba(6, 7, 11, 0.88) 16%, rgba(6, 7, 11, 0.88) 84%, rgba(6, 7, 11, 0));
}

/* ============================================================
   PHASE 5 — THE GIVING LOOP (letter, ledger, credits roll,
   giving-rung pulse, thank-you page)
   ============================================================ */

/* ---- the founder's letter ---- */
.letter {
  max-width: 760px;
  margin: 0 auto;
  padding: 44px 48px 38px;
}
.letter .section-eyebrow { margin-bottom: 18px; }
.letter-body p {
  font-family: var(--font-display);
  font-size: 20px;
  line-height: 1.62;
  color: var(--ink-dim);
  margin-bottom: 18px;
}
.letter-body p em { color: var(--gold); font-style: italic; }
@media (max-width: 640px) {
  .letter { padding: 32px 24px 28px; }
  .letter-body p { font-size: 18px; }
}

/* ---- gift cards are now doors into the giving rungs ---- */
a.gift-card { color: inherit; text-decoration: none; display: block; }

/* ---- the rung pulse (bevel law: inset glow + background only —
   outlines and outer shadows die under the slab clip-path) ---- */
@keyframes givePulse {
  0% { box-shadow: inset 0 0 0 2px rgba(217, 171, 90, 0.95), inset 0 0 44px rgba(217, 171, 90, 0.3); }
  100% { box-shadow: inset 0 0 0 1px rgba(217, 171, 90, 0), inset 0 0 44px rgba(217, 171, 90, 0); }
}
.give-pulse { animation: givePulse 1.9s ease-out both; }
@media (prefers-reduced-motion: reduce) {
  .give-pulse { animation: none; box-shadow: inset 0 0 0 2px rgba(217, 171, 90, 0.7); }
}


/* ---- the supporters' credits roll ---- */
.credits-roll {
  max-width: 640px;
  margin: 0 auto;
  text-align: center;
}
.cr-empty {
  border: 1px dashed rgba(217, 171, 90, 0.35);
  background: var(--glass);
  padding: 44px 30px;
  /* same bevel as the founding-partner reserved slots */
  clip-path: polygon(10px 0, 100% 0, 100% calc(100% - 10px), calc(100% - 10px) 100%, 0 100%, 0 10px);
}
.cr-reserved {
  font-family: var(--font-display);
  font-size: 26px;
  color: var(--gold);
  margin-bottom: 10px;
}
.cr-empty p:not(.cr-reserved) { color: var(--ink-dim); font-size: 14px; max-width: 420px; margin: 0 auto; }
.credits-roll.live {
  height: 320px;
  overflow: clip;
  -webkit-mask-image: linear-gradient(180deg, transparent, #000 22%, #000 78%, transparent);
  mask-image: linear-gradient(180deg, transparent, #000 22%, #000 78%, transparent);
}
.cr-track { animation: crRoll var(--cr-dur, 30s) linear infinite; }
.cr-name {
  font-family: var(--font-display);
  font-size: 21px;
  color: var(--ink);
  padding: 10px 0;
}
@keyframes crRoll {
  from { transform: translateY(0); }
  to { transform: translateY(-50%); }
}
@media (prefers-reduced-motion: reduce) {
  .cr-track { animation: none; }
  .cr-list[aria-hidden] { display: none; }
  .credits-roll.live { height: auto; -webkit-mask-image: none; mask-image: none; }
}

/* ---- thank-you page: gold dust settling over the hero ---- */
.thanks-hero { overflow: clip; }
.gold-dust { position: absolute; inset: 0; pointer-events: none; z-index: 3; }
.gold-dust span {
  position: absolute;
  top: -14px;
  left: var(--x);
  width: var(--w);
  height: var(--w);
  border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, #f4d9a4, var(--gold) 55%, rgba(217, 171, 90, 0));
  opacity: 0;
  animation: dustFall var(--d) linear var(--delay) both;
}
@keyframes dustFall {
  0% { transform: translateY(0) translateX(0); opacity: 0; }
  10% { opacity: 0.85; }
  78% { opacity: 0.5; }
  100% { transform: translateY(72vh) translateX(14px); opacity: 0; }
}

/* ---- the support film (click-to-play cut under the support hero) ---- */
.support-film-band { padding-top: 34px; }
.support-film {
  position: relative;
  max-width: 900px;
  margin: 0 auto;
  padding: 0;
  overflow: clip;
}
.support-film video { display: block; width: 100%; height: auto; cursor: pointer; }
.support-film.playing { cursor: pointer; }
.support-film.playing video { background: #000; }
.film-play {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  width: 100%;
  border: 0;
  background: linear-gradient(180deg, rgba(6, 7, 11, 0.1), rgba(6, 7, 11, 0.55));
  color: var(--ink);
  cursor: pointer;
  transition: background 0.3s ease, opacity 0.3s ease;
}
.film-play:hover, .film-play:focus-visible { background: linear-gradient(180deg, rgba(6, 7, 11, 0.02), rgba(6, 7, 11, 0.42)); }
/* while the film plays the button stays in the tab order, just faded —
   keyboard users keep a pause control (a11y round 2, 2026-08-26) */
.film-play.fp-playing { opacity: 0; }
.film-play.fp-playing:hover, .film-play.fp-playing:focus-visible { opacity: 1; }
.film-play:focus-visible .fp-ring { box-shadow: inset 0 0 0 2px rgba(217, 171, 90, 0.95); }
.fp-ring {
  display: grid;
  place-items: center;
  width: 74px;
  height: 74px;
  border-radius: 50%;
  border: 1.6px solid rgba(217, 171, 90, 0.85);
  background: rgba(6, 7, 11, 0.55);
  color: var(--gold);
  transition: transform 0.25s ease, background 0.25s ease;
}
.film-play:hover .fp-ring { transform: scale(1.08); background: rgba(217, 171, 90, 0.16); }
.fp-ring svg { width: 30px; height: 30px; margin-left: 3px; }
.fp-label {
  font-size: 13px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-dim);
}
.film-endcard {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 20px;
  background: rgba(6, 7, 11, 0.84);
  text-align: center;
  padding: 20px;
}
.fe-title {
  font-family: var(--font-display);
  font-size: clamp(24px, 4vw, 34px);
  color: var(--ink);
}
.fe-row { display: flex; gap: 14px; flex-wrap: wrap; justify-content: center; }
.film-note {
  text-align: center;
  color: var(--ink-dim);
  font-size: 14px;
  max-width: 560px;
  margin: 20px auto 0;
}

/* ---------- contact page: form + booking (the site's first form) ---------- */

.contact-grid {
  display: grid; grid-template-columns: 1.4fr 1fr; gap: 22px; align-items: start;
}
@media (max-width: 900px) { .contact-grid { grid-template-columns: 1fr; } }

.contact-form { padding: 38px 34px; }
.contact-form .form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
@media (max-width: 640px) {
  .contact-form { padding: 28px 22px; }
  .contact-form .form-row { grid-template-columns: 1fr; }
}
.field { display: flex; flex-direction: column; gap: 7px; margin-bottom: 16px; }
.field label {
  font: 600 11px/1 var(--font-body); letter-spacing: 0.16em;
  text-transform: uppercase; color: var(--gold);
}
.field input, .field select, .field textarea {
  font: 400 15px/1.5 var(--font-body); color: var(--ink);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.14);
  padding: 12px 14px; border-radius: 0; width: 100%;
  clip-path: polygon(8px 0, 100% 0, 100% calc(100% - 8px), calc(100% - 8px) 100%, 0 100%, 0 8px);
  transition: border-color 0.2s, background 0.2s;
}
.field textarea { min-height: 150px; resize: vertical; }
.field input:focus-visible, .field select:focus-visible, .field textarea:focus-visible {
  outline: none; border-color: var(--gold); background: rgba(217, 171, 90, 0.06);
}
.field select { appearance: none; -webkit-appearance: none; cursor: pointer; }
.field select option { background: #0b0d14; color: var(--ink); }
.form-note { color: var(--ink-faint); font-size: 13px; margin-top: 14px; }
.form-status {
  border: 1px solid rgba(217, 171, 90, 0.4);
  background: rgba(217, 171, 90, 0.08);
  padding: 14px 16px; color: var(--ink); font-size: 14px; margin-bottom: 18px;
  clip-path: polygon(8px 0, 100% 0, 100% calc(100% - 8px), calc(100% - 8px) 100%, 0 100%, 0 8px);
}
.form-status[hidden] { display: none; }
/* the [hidden]-vs-display trap: .btn sets display, so guard it explicitly */
#bookCall[hidden], #contactForm[hidden] { display: none; }
button.btn { font: inherit; cursor: pointer; }
button.btn[aria-disabled="true"] { opacity: 0.55; cursor: not-allowed; }

.contact-aside { display: flex; flex-direction: column; gap: 22px; }
.contact-card { padding: 30px 28px; }
.contact-card h2, .contact-card h3 { font-family: var(--font-display); font-size: 22px; margin-bottom: 10px; }
.contact-card p { color: var(--ink-dim); font-size: 14.5px; line-height: 1.6; margin-bottom: 14px; }
.contact-card .inline-link { word-break: break-all; }

/* ==========================================================================
   ROADMAP v2 — THE REEL: five cinematic acts told on real film frames.
   Finished acts wear frames from finished eras, the present act carries the
   live production meters (fed by FILM_PROGRESS via [data-films] in
   script.js), the future stays deliberately unlit — a closed door, then a
   road of light. Namespaced ra- (story-engine.css owns bare .act). The
   rail itself tells the story: solid gold through the finished acts,
   sketched dots toward the goal.
   ========================================================================== */

.reel {
  position: relative; z-index: 1; margin-top: 44px; padding-left: 34px;
  --ink-over-frame: #b6bccd;
  --ink-over-frame-bright: #c6ccdb;
}

.reel-rail {
  position: absolute; left: 8px; top: 12px; bottom: 12px; width: 2px;
  /* done = solid gold, ahead = sketched dots (the dotted layer shows where
     the solid layer has faded out) */
  background:
    linear-gradient(to bottom,
      var(--gold) 0%, var(--gold) 46%,
      rgba(217, 171, 90, 0.6) 54%, transparent 66%),
    repeating-linear-gradient(to bottom,
      rgba(217, 171, 90, 0.35) 0 5px, transparent 5px 13px);
  transform-origin: top;
}
/* scroll-driven: the rail draws downward, each dot wakes as it arrives.
   Guarded — without scroll-driven animations (and under reduced motion)
   the finished state simply shows, which is also the reduced-motion
   contract. (Body stays overflow-x: clip — hidden would rebind view().) */
@supports (animation-timeline: view()) {
  @media not (prefers-reduced-motion: reduce) {
    .reel-rail {
      animation: reelDraw linear both;
      animation-timeline: view();
      animation-range: entry 10% cover 70%;
    }
    .reel-dot {
      animation: reelWake linear both;
      animation-timeline: view();
      animation-range: entry 5% entry 45%;
    }
  }
}
@keyframes reelDraw { from { transform: scaleY(0); } to { transform: scaleY(1); } }
@keyframes reelWake { from { opacity: 0.35; } to { opacity: 1; } }

.reel-item { position: relative; margin-bottom: 22px; }
.reel-item:last-child { margin-bottom: 0; }

.reel-dot {
  position: absolute; left: -34px; top: 30px;
  width: 18px; height: 18px;
  border-radius: 50%;
  background: var(--bg);
  border: 2px solid var(--ink-faint);
}
.reel-dot.done {
  border-color: var(--gold);
  background: var(--gold);
  box-shadow: 0 0 18px 2px rgba(217, 171, 90, 0.55);
}

/* ---- the act slab: a beveled widescreen frame of film ---- */
.ra {
  position: relative;
  display: flex; align-items: center;
  min-height: 280px;
  background: rgba(10, 12, 18, 0.72);
  border: 1px solid var(--stroke);
  clip-path: polygon(14px 0, 100% 0, 100% calc(100% - 14px), calc(100% - 14px) 100%, 0 100%, 0 14px);
  transition: border-color 0.35s ease;
}
.ra:hover { border-color: rgba(217, 171, 90, 0.4); }

/* filmstrip perforation — only on the frame-backed middle acts, so one
   motif owns the strip idea and the dark opener/finale keep their drama */
.ra-world::before, .ra-leap::before, .ra-door::before {
  content: ""; position: absolute; left: 12px; top: 12px; bottom: 12px; width: 5px;
  background: repeating-linear-gradient(180deg, rgba(242, 205, 138, 0.22) 0 9px, transparent 9px 22px);
  z-index: 2; pointer-events: none;
}

.ra-bg { position: absolute; inset: 0; pointer-events: none; }
.ra-bg img { width: 100%; height: 100%; object-fit: cover; }
.ra-bg::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(100deg,
    rgba(6, 7, 11, 0.95) 0%, rgba(6, 7, 11, 0.86) 34%,
    rgba(6, 7, 11, 0.5) 62%, rgba(6, 7, 11, 0.14) 100%);
}
@media (prefers-reduced-motion: no-preference) {
  .ra-bg img { transition: transform 4.5s cubic-bezier(0.22, 1, 0.36, 1); }
  .ra:hover .ra-bg img { transform: scale(1.045); }
}

/* ghost act numerals — movie-poster typography */
.ra-no {
  position: absolute; right: 28px; top: 6px; z-index: 1;
  font: 400 clamp(64px, 9vw, 116px)/1 var(--font-display);
  color: rgba(242, 205, 138, 0.14);
  text-shadow: 0 2px 26px rgba(6, 7, 11, 0.6);
  pointer-events: none; user-select: none;
}

.ra-content {
  position: relative; z-index: 2;
  max-width: 600px;
  padding: 34px 38px 36px 40px;
}
.ra-title { font-size: 22px; font-weight: 600; margin: 0 0 8px; }
.ra-copy { color: var(--ink-over-frame); font-size: 15px; text-shadow: 0 1px 10px rgba(6, 7, 11, 0.65); }

/* the act tag, in the site's bevel-chip language */
.ra-tag {
  display: inline-block; padding: 7px 12px; margin-bottom: 12px;
  font: 600 10.5px/1 var(--font-body); letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--ink-dim);
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--stroke);
  clip-path: polygon(6px 0, 100% 0, 100% calc(100% - 6px), calc(100% - 6px) 100%, 0 100%, 0 6px);
}
.ra-tag.done {
  color: var(--gold-bright);
  border-color: rgba(217, 171, 90, 0.45);
  background: rgba(217, 171, 90, 0.08);
}
.ra-tag.live {
  color: var(--gold-bright);
  border-color: rgba(217, 171, 90, 0.55);
  background: rgba(217, 171, 90, 0.1);
}
.live-dot {
  display: inline-block; width: 7px; height: 7px; border-radius: 50%;
  margin-right: 8px; vertical-align: 1px;
  background: var(--gold-bright);
  box-shadow: 0 0 8px 1px rgba(242, 205, 138, 0.7);
}
@media (prefers-reduced-motion: no-preference) {
  .live-dot { animation: livePulse 2.2s ease-in-out infinite; }
}
@keyframes livePulse { 50% { opacity: 0.35; } }

/* honesty as set dressing: every backdrop names its source */
.ra-src {
  position: absolute; right: 16px; bottom: 12px; z-index: 2;
  font: 600 10px/1 var(--font-body);
  letter-spacing: 0.12em; text-transform: uppercase;
  color: rgba(238, 240, 246, 0.55);
  text-shadow: 0 1px 8px rgba(6, 7, 11, 0.8);
}

/* ---- ACT I: the dark screen it all started on ---- */
.ra-sparks {
  min-height: 200px;
  background:
    radial-gradient(ellipse 46% 100% at 16% 92%, rgba(217, 171, 90, 0.12), transparent 62%),
    radial-gradient(ellipse 34% 60% at 84% 6%, rgba(91, 124, 250, 0.06), transparent),
    #07080d;
}
.ra-sparks::after {
  content: ""; position: absolute; right: 24%; top: 40%;
  width: 3px; height: 3px; border-radius: 50%;
  background: var(--gold-bright);
  box-shadow: 0 0 16px 4px rgba(242, 205, 138, 0.45);
}
@media (prefers-reduced-motion: no-preference) {
  .ra-sparks::after { animation: sparkFlicker 4.2s ease-in-out infinite; }
}
@keyframes sparkFlicker { 0%, 100% { opacity: 1; } 12% { opacity: 0.35; } 24% { opacity: 0.9; } 58% { opacity: 0.5; } }

/* ---- per-act crops and grades ---- */
.ra-world .ra-bg img { object-position: center 12%; } /* full helmet in frame — never crop heads */
.ra-world .ra-content { max-width: 660px; }

/* the era's numbers, sitting on the frames that earned them */
.ra-tiles {
  margin-top: 18px;
  display: grid; grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px; max-width: 620px;
}
.ra-tile {
  position: relative; display: block; aspect-ratio: 16 / 10; overflow: hidden;
  border: 1px solid var(--stroke); text-decoration: none;
  clip-path: polygon(8px 0, 100% 0, 100% calc(100% - 8px), calc(100% - 8px) 100%, 0 100%, 0 8px);
  transition: border-color 0.25s ease;
}
.ra-tile:hover { border-color: rgba(217, 171, 90, 0.5); }
.ra-tile img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.ra-tile::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(6, 7, 11, 0.08), rgba(6, 7, 11, 0.8));
}
.ra-tile-num {
  position: absolute; z-index: 1; left: 10px; bottom: 24px;
  font: 400 22px/1 var(--font-display);
  color: #fff; text-shadow: 0 1px 12px rgba(6, 7, 11, 0.8);
}
.ra-tile-label {
  position: absolute; z-index: 1; left: 10px; bottom: 9px; right: 8px;
  font: 600 10px/1 var(--font-body); letter-spacing: 0.1em; text-transform: uppercase;
  color: rgba(238, 240, 246, 0.75);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}

.ra-leap { min-height: 330px; }
.ra-leap .ra-bg img { object-position: center 24%; }
.ra-leap .ra-content { max-width: 660px; }

/* the future stays unlit: darkest grade on the reel */
.ra-door { min-height: 250px; }
.ra-door .ra-bg img { object-position: center 82%; filter: brightness(0.66) saturate(0.82); }
.ra-door .ra-bg::after {
  background: linear-gradient(100deg,
    rgba(6, 7, 11, 0.92) 0%, rgba(6, 7, 11, 0.74) 44%,
    rgba(6, 7, 11, 0.3) 70%, rgba(6, 7, 11, 0.14) 100%);
}

/* ---- live meters (rewritten from FILM_PROGRESS by script.js) ---- */
.ra-meters {
  margin-top: 18px;
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px 18px;
}
.ra-meter-label {
  display: flex; justify-content: space-between; align-items: baseline;
  margin-bottom: 6px;
  font: 600 10.5px/1 var(--font-body);
  letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--ink-over-frame);
}
.ra-meter-label b {
  font: 600 12px/1 var(--font-body);
  letter-spacing: 0.04em;
  color: var(--gold-bright);
}

/* ---- ACT V: the road — the finale earns its own composition ----
   (bevel law: the lift is border + INSET glow only; outer shadows die
   under the slab clip-path) */
.ra-road {
  min-height: 430px;
  justify-content: center; text-align: center;
  border-color: rgba(217, 171, 90, 0.4);
  box-shadow: inset 0 0 90px rgba(217, 171, 90, 0.07);
}
.ra-road .ra-bg img { object-position: center 22%; }
.ra-road .ra-bg::after {
  background:
    radial-gradient(ellipse 85% 68% at 50% 58%, rgba(6, 7, 11, 0.16), rgba(6, 7, 11, 0.62) 96%),
    linear-gradient(180deg, rgba(6, 7, 11, 0.55), rgba(6, 7, 11, 0.1) 32%, rgba(6, 7, 11, 0.16) 68%, rgba(6, 7, 11, 0.72));
}
.ra-road .ra-content { max-width: 680px; margin: 0 auto; padding: 58px 30px; }
.ra-road .ra-title {
  font: 400 clamp(30px, 4.4vw, 46px)/1.12 var(--font-display);
  letter-spacing: 0.01em;
  margin: 4px 0 14px;
}
.ra-road .ra-copy { font-size: 16px; color: var(--ink-over-frame-bright); }
.ra-kicker {
  display: block; margin-top: 24px;
  font: 600 12px/1 var(--font-body);
  letter-spacing: 0.22em; text-transform: uppercase;
  color: var(--gold-bright);
  text-shadow: 0 0 18px rgba(242, 205, 138, 0.35);
}

/* the elder peeks over the section header instead of hiding behind the
   full-width slabs */
.vision .peek-enoch { top: -104px; right: 2%; }

/* ---- mobile ---- */
@media (max-width: 680px) {
  .reel { padding-left: 0; margin-top: 36px; }
  .reel-rail, .reel-dot { display: none; }
  .ra { display: block; min-height: 0; }
  .ra-world::before, .ra-leap::before, .ra-door::before { display: none; }
  .ra-content { max-width: none; padding: 26px 22px 40px; }
  .ra-bg::after,
  .ra-door .ra-bg::after {
    background: linear-gradient(180deg,
      rgba(6, 7, 11, 0.9) 0%, rgba(6, 7, 11, 0.84) 55%, rgba(6, 7, 11, 0.6) 100%);
  }
  .ra-no { right: 14px; top: 8px; font-size: 56px; color: rgba(242, 205, 138, 0.11); }
  .ra-src { right: 12px; bottom: 10px; }
  .ra-sparks, .ra-world, .ra-leap, .ra-door { min-height: 0; }
  .ra-tiles { grid-template-columns: 1fr 1fr; max-width: none; }
  .ra-meters { grid-template-columns: 1fr; gap: 12px; }
  .ra-road { min-height: 380px; display: flex; }
  .ra-road .ra-content { padding: 52px 22px; }
  .ra-road .ra-bg::after {
    background:
      radial-gradient(ellipse 85% 68% at 50% 58%, rgba(6, 7, 11, 0.16), rgba(6, 7, 11, 0.62) 96%),
      linear-gradient(180deg, rgba(6, 7, 11, 0.55), rgba(6, 7, 11, 0.1) 32%, rgba(6, 7, 11, 0.16) 68%, rgba(6, 7, 11, 0.72));
  }
}

/* ==========================================================================
   POLISH ROUND (2026-08-23 evening) — library anchor strips, book-hub
   micro-links, journey trophy state, footer epigraph, contact peek
   ========================================================================== */

/* three anchor books in the Library get a short real-frame strip behind
   their header — the head only, never the grid (the v30 law: frames must
   not compete with the cards) */
.lib-band { display: flex; align-items: center; min-height: 250px; margin-bottom: 10px; }
.lib-band .container { width: 100%; }
@media (max-width: 680px) { .lib-band { min-height: 190px; } }

/* header-register micro-link to the book's own hub page */
.lib-more {
  margin-left: auto;
  font: 600 11px/1 var(--font-body); letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--gold); text-decoration: none;
  transition: color 0.2s;
}
.lib-more:hover { color: var(--gold-bright); }

/* a finished book on the journey strip turns gold — quiet trophy shelf */
.jb.done .jb-name {
  color: var(--gold-bright);
  display: inline-flex; align-items: center; gap: 4px;
}
.jb.done .jb-name svg { width: 10px; height: 10px; }

/* jumped-to cast entries clear the fixed nav (also fixes the cross-page
   storybook.html#name links from every book page) */
.story-entry { scroll-margin-top: 92px; }

/* the messenger peeks over the contact form */
.peek-gabriel { width: 150px; right: -22px; top: -64px; rotate: 4deg; }

/* footer epigraph — injected daily by script.js, an epigraph not a widget */
.footer-verse {
  max-width: 46ch; margin-inline: auto; text-align: center;
  font-family: var(--font-display); font-size: 17px; line-height: 1.5;
  color: var(--ink-dim);
}
.footer-verse span {
  display: block; margin-top: 4px;
  font: 600 10.5px/1 var(--font-body); letter-spacing: 0.14em;
  text-transform: uppercase; color: var(--gold);
}

/* visually-hidden text for screen readers */
.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

/* ---- the premiere bell: one email per premiere, nothing else ---- */
.bell-band {
  display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 34px;
  align-items: center; padding: 34px 38px;
}
.bell-band h2 {
  font-family: var(--font-display); font-weight: 400;
  font-size: clamp(24px, 3vw, 32px); margin: 8px 0 10px;
}
.bell-sub { color: var(--ink-dim); font-size: 14.5px; line-height: 1.6; }
.bell-form { display: flex; gap: 10px; }
.bell-form input[type="email"] {
  flex: 1; min-width: 0; padding: 14px 16px;
  background: rgba(6, 7, 11, 0.55); border: 1px solid var(--stroke);
  border-radius: 12px; color: var(--ink); font: 500 15px/1.2 var(--font-body);
}
.bell-form input[type="email"]:focus-visible {
  outline: none; border-color: rgba(217, 171, 90, 0.55);
}
.bell-done { color: var(--gold-bright); font-size: 15px; }
@media (max-width: 780px) {
  .bell-band { grid-template-columns: 1fr; padding: 26px 22px; gap: 20px; }
  .bell-form { flex-direction: column; }
}
