/* ============================================================
   Tales of the Elfin Oak · talesoftheelfinoak.com
   Palette per Tale 12 Production Pack:
   moonlit blue #B0C4D8 · ambers #E8A020 / #F5C842 · storybook white #FFFCEA
   ============================================================ */

:root {
  --night: #0b1424;
  --night-2: #101d33;
  --night-3: #16263f;
  --moon: #b0c4d8;
  --amber: #e8a020;
  --gold: #f5c842;
  --cream: #fffcea;
  --cream-dim: rgba(255, 252, 234, 0.78);
  --serif-display: "Cormorant Garamond", "EB Garamond", Garamond, Georgia, serif;
  --serif-body: "EB Garamond", Garamond, Georgia, serif;
}

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

html { scroll-behavior: smooth; }

body {
  background: var(--night);
  color: var(--cream);
  font-family: var(--serif-body);
  font-size: 19px;
  line-height: 1.65;
  overflow-x: hidden;
}

img { max-width: 100%; display: block; }

a { color: var(--gold); text-decoration: none; }

::selection { background: rgba(245, 200, 66, 0.35); }

h1, h2, h3, h4 { font-family: var(--serif-display); font-weight: 600; }

/* ---------- ornamental section heading ---------- */
.section-head { text-align: center; margin-bottom: 3rem; }
.section-head .kicker {
  display: block;
  letter-spacing: 0.35em;
  text-transform: uppercase;
  font-size: 0.72rem;
  color: var(--amber);
  margin-bottom: 0.8rem;
}
.section-head h2 {
  font-size: clamp(2rem, 4.5vw, 3.1rem);
  color: var(--cream);
  text-shadow: 0 0 24px rgba(245, 200, 66, 0.18), 0 2px 14px rgba(0,0,0,0.55);
}
.section-head .flourish {
  width: 190px; margin: 1.1rem auto 0; display: block; opacity: 0.9;
}

section { position: relative; padding: 6.5rem 1.5rem; }
.wrap { max-width: 1120px; margin: 0 auto; position: relative; z-index: 2; }

/* ---------- navigation ---------- */
nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  display: flex; align-items: center; justify-content: space-between;
  padding: 0.65rem 1.4rem;
  background: linear-gradient(rgba(8, 13, 24, 0.97), rgba(8, 13, 24, 0.88));
  border-bottom: 1px solid rgba(245, 200, 66, 0.16);
  transition: transform 0.35s ease;
}
nav .brand { display: flex; align-items: center; gap: 0.7rem; }
nav .brand img { height: 44px; width: auto; filter: drop-shadow(0 0 6px rgba(245,200,66,0.35)); }
nav .brand span {
  font-family: var(--serif-display); font-size: 1.15rem; letter-spacing: 0.06em;
  color: var(--cream);
}
nav ul { display: flex; gap: 1.5rem; list-style: none; }
nav ul a {
  color: var(--cream-dim); font-size: 0.98rem; letter-spacing: 0.05em;
  padding-bottom: 3px; border-bottom: 1px solid transparent;
  transition: color 0.25s, border-color 0.25s;
}
nav ul a:hover { color: var(--gold); border-color: rgba(245,200,66,0.5); }
.nav-toggle { display: none; background: none; border: none; color: var(--gold); font-size: 1.7rem; cursor: pointer; }

/* ---------- hero ---------- */
header.hero {
  min-height: 100svh;
  display: flex; flex-direction: column; justify-content: center; align-items: center;
  text-align: center; position: relative; overflow: hidden;
  padding: 7rem 1.5rem 5rem;
}
.hero-bg {
  position: absolute; inset: 0;
  background: url("../img/hero-forest.jpg") center 30% / cover no-repeat;
  transform: scale(1.06);
  animation: heroDrift 40s ease-in-out infinite alternate;
}
@keyframes heroDrift {
  from { transform: scale(1.06) translateY(0); }
  to   { transform: scale(1.12) translateY(-1.8%); }
}
.hero-veil {
  position: absolute; inset: 0;
  background:
    radial-gradient(ellipse at 0% 0%, rgba(11,20,36,0.55) 0%, rgba(11,20,36,0) 42%),
    radial-gradient(ellipse at 100% 0%, rgba(11,20,36,0.45) 0%, rgba(11,20,36,0) 42%),
    radial-gradient(ellipse at 50% 42%, rgba(11,20,36,0) 0%, rgba(11,20,36,0.42) 68%, rgba(11,20,36,0.94) 100%),
    linear-gradient(rgba(11,20,36,0.25), rgba(11,20,36,0.1) 45%, var(--night) 98%);
}
#fireflies { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }

.hero-inner { position: relative; z-index: 3; max-width: 860px; }
.hero-inner .hero-logo {
  height: 128px; width: auto; margin: 0 auto 1.6rem;
  filter: drop-shadow(0 0 18px rgba(245, 200, 66, 0.55));
  animation: glowPulse 5s ease-in-out infinite;
}
@keyframes glowPulse {
  0%, 100% { filter: drop-shadow(0 0 12px rgba(245,200,66,0.4)); }
  50% { filter: drop-shadow(0 0 26px rgba(245,200,66,0.75)); }
}
.hero-inner h1 {
  font-size: clamp(2.7rem, 7vw, 5rem);
  line-height: 1.08;
  color: var(--cream);
  text-shadow: 0 0 34px rgba(245, 200, 66, 0.3), 0 4px 26px rgba(0, 0, 0, 0.75);
}
.hero-inner .subtitle {
  margin-top: 1.15rem;
  font-size: clamp(1.05rem, 2.4vw, 1.4rem);
  font-style: italic;
  color: var(--moon);
  text-shadow: 0 2px 12px rgba(0,0,0,0.8);
}
.hero-inner .byline {
  margin-top: 0.7rem; letter-spacing: 0.3em; text-transform: uppercase;
  font-size: 0.8rem; color: var(--gold);
}
.hero-ctas { margin-top: 2.4rem; display: flex; gap: 1.1rem; justify-content: center; flex-wrap: wrap; }

.btn {
  display: inline-flex; align-items: center; gap: 0.55rem;
  font-family: var(--serif-display); font-size: 1.05rem; letter-spacing: 0.08em;
  padding: 0.85rem 2.1rem; border-radius: 999px; cursor: pointer;
  transition: transform 0.25s, box-shadow 0.25s, background 0.25s;
  border: 1px solid rgba(245, 200, 66, 0.65);
}
.btn-gold {
  background: linear-gradient(160deg, #f8d565, var(--amber));
  color: #241703; font-weight: 600;
  box-shadow: 0 4px 26px rgba(232, 160, 32, 0.4);
}
.btn-gold:hover { transform: translateY(-2px); box-shadow: 0 8px 34px rgba(232,160,32,0.55); }
.btn-ghost { background: rgba(11, 20, 36, 0.55); color: var(--cream); }
.btn-ghost:hover { background: rgba(245, 200, 66, 0.12); transform: translateY(-2px); }

.scroll-hint {
  position: absolute; bottom: 2.2rem; left: 50%; transform: translateX(-50%);
  z-index: 3; color: var(--moon); font-size: 1.6rem; opacity: 0.8;
  animation: bob 2.4s ease-in-out infinite;
}
@keyframes bob { 0%,100% { transform: translate(-50%, 0); } 50% { transform: translate(-50%, 9px); } }

/* ---------- reveal on scroll ---------- */
.reveal { opacity: 0; transform: translateY(34px); transition: opacity 0.9s ease, transform 0.9s ease; }
.reveal.visible { opacity: 1; transform: none; }

/* ---------- true story ---------- */
#story { background: linear-gradient(var(--night), var(--night-2)); }
.story-grid { display: grid; grid-template-columns: 1.15fr 0.85fr; gap: 3.2rem; align-items: start; }
.story-text p { margin-bottom: 1.15rem; color: var(--cream-dim); }
.story-text p strong { color: var(--cream); }
.story-art img {
  border-radius: 14px;
  box-shadow: 0 18px 60px rgba(0,0,0,0.6), 0 0 0 1px rgba(245,200,66,0.22);
}
.story-art figcaption { text-align: center; font-style: italic; font-size: 0.9rem; color: var(--moon); margin-top: 0.8rem; }

.timeline { margin-top: 4.5rem; display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.2rem; }
.timeline .tl-item {
  background: rgba(255, 252, 234, 0.045);
  border: 1px solid rgba(245, 200, 66, 0.18);
  border-radius: 12px; padding: 1.3rem 1.1rem; text-align: center;
  transition: transform 0.3s, border-color 0.3s;
}
.timeline .tl-item:hover { transform: translateY(-5px); border-color: rgba(245,200,66,0.5); }
.timeline .year { font-family: var(--serif-display); font-size: 1.65rem; color: var(--gold); }
.timeline p { font-size: 0.92rem; color: var(--cream-dim); margin-top: 0.4rem; line-height: 1.45; }

/* ---------- book ---------- */
#book {
  background:
    radial-gradient(ellipse at 80% 20%, rgba(232, 160, 32, 0.09), transparent 55%),
    linear-gradient(var(--night-2), var(--night));
}
.book-grid { display: grid; grid-template-columns: 0.9fr 1.1fr; gap: 4rem; align-items: center; }
.book-cover-wrap { perspective: 1200px; display: flex; justify-content: center; }
.book-cover {
  width: min(360px, 82vw); border-radius: 6px 14px 14px 6px;
  box-shadow:
    -14px 18px 50px rgba(0, 0, 0, 0.65),
    0 0 90px rgba(245, 200, 66, 0.16),
    inset 4px 0 12px rgba(255,255,255,0.08);
  transform: rotateY(-12deg) rotateX(2deg);
  transition: transform 0.5s ease;
}
.book-cover-wrap:hover .book-cover { transform: rotateY(-4deg) rotateX(0deg) scale(1.02); }
.book-copy h3 { font-size: 1.9rem; margin-bottom: 1rem; color: var(--cream); }
.book-copy p { color: var(--cream-dim); margin-bottom: 1.05rem; }
.book-specs { display: flex; flex-wrap: wrap; gap: 0.7rem; margin: 1.4rem 0 1.9rem; }
.book-specs span {
  border: 1px solid rgba(176, 196, 216, 0.35); color: var(--moon);
  border-radius: 999px; padding: 0.32rem 1rem; font-size: 0.88rem; letter-spacing: 0.04em;
}

/* ---------- peek inside ---------- */
#inside { background: var(--night); }
.gallery {
  display: grid; grid-auto-flow: column; grid-auto-columns: minmax(240px, 300px);
  gap: 1.3rem; overflow-x: auto; padding: 0.6rem 0.2rem 1.6rem;
  scroll-snap-type: x mandatory;
  scrollbar-color: rgba(245,200,66,0.45) rgba(255,252,234,0.06);
}
.gallery figure {
  scroll-snap-align: center; cursor: pointer; position: relative;
  border-radius: 12px; overflow: hidden;
  box-shadow: 0 10px 34px rgba(0,0,0,0.55), 0 0 0 1px rgba(245,200,66,0.16);
  transition: transform 0.35s;
}
.gallery figure:hover { transform: translateY(-7px); }
.gallery figcaption {
  position: absolute; left: 0; right: 0; bottom: 0;
  padding: 1.6rem 0.9rem 0.7rem; font-size: 0.9rem; text-align: center;
  background: linear-gradient(transparent, rgba(8, 13, 24, 0.92));
  color: var(--cream-dim); font-style: italic;
}
.gallery-note { text-align: center; color: var(--moon); font-size: 0.92rem; font-style: italic; }

/* lightbox */
.lightbox {
  position: fixed; inset: 0; z-index: 200; display: none;
  align-items: center; justify-content: center; flex-direction: column;
  background: rgba(5, 9, 17, 0.93); padding: 2.5rem 1rem;
}
.lightbox.open { display: flex; }
.lightbox img { max-height: 82vh; max-width: 94vw; border-radius: 10px; box-shadow: 0 0 80px rgba(245,200,66,0.2); }
.lightbox .lb-caption { margin-top: 1rem; color: var(--cream-dim); font-style: italic; }
.lightbox .lb-close {
  position: absolute; top: 1.2rem; right: 1.6rem; font-size: 2.2rem; color: var(--gold);
  background: none; border: none; cursor: pointer;
}

/* ---------- tales ---------- */
#tales { background: linear-gradient(var(--night), var(--night-3) 60%, var(--night)); }
.tales-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.4rem; }
.tale-card {
  position: relative;
  background: rgba(255, 252, 234, 0.045);
  border: 1px solid rgba(245, 200, 66, 0.16);
  border-radius: 14px; padding: 1.7rem 1.5rem 1.5rem;
  transition: transform 0.3s, border-color 0.3s, background 0.3s;
  overflow: hidden;
}
.tale-card:hover {
  transform: translateY(-6px);
  border-color: rgba(245, 200, 66, 0.5);
  background: rgba(245, 200, 66, 0.07);
}
.tale-card .num {
  font-family: var(--serif-display); font-size: 2.6rem; line-height: 1;
  color: rgba(245, 200, 66, 0.4); margin-bottom: 0.5rem;
}
.tale-card h3 { font-size: 1.32rem; color: var(--cream); margin-bottom: 0.55rem; }
.tale-card p { font-size: 0.96rem; color: var(--cream-dim); line-height: 1.5; }

/* ---------- characters ---------- */
#characters {
  background:
    radial-gradient(ellipse at 15% 10%, rgba(176, 196, 216, 0.07), transparent 50%),
    var(--night);
}
.char-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(205px, 1fr)); gap: 1.5rem; }
.char-card {
  cursor: pointer; border-radius: 16px; overflow: hidden; position: relative;
  border: 1px solid rgba(245, 200, 66, 0.18);
  box-shadow: 0 10px 30px rgba(0,0,0,0.5);
  transition: transform 0.35s, box-shadow 0.35s;
  background: var(--night-2);
}
.char-card:hover {
  transform: translateY(-8px);
  border-color: rgba(245, 200, 66, 0.95);
  box-shadow:
    0 0 26px rgba(245, 200, 66, 0.6),
    0 0 70px rgba(245, 200, 66, 0.32),
    0 18px 44px rgba(0, 0, 0, 0.6);
  animation: cardGlow 2.2s ease-in-out infinite;
}
.char-card img { aspect-ratio: 1; object-fit: cover; width: 100%; }
.char-card .char-label {
  padding: 0.9rem 0.9rem 1.05rem; text-align: center;
  background: linear-gradient(180deg, rgba(245, 200, 66, 0.1), rgba(245, 200, 66, 0.02));
  border-top: 1px solid rgba(245, 200, 66, 0.3);
}
.char-card .char-label h3 {
  font-size: 1.32rem; letter-spacing: 0.02em;
  line-height: 1.3; padding-bottom: 0.1em;
  background: linear-gradient(120deg, #fff3c4 20%, #f5c842 50%, #ffe9a8 80%);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: #ffe9a8;
  filter: drop-shadow(0 1px 6px rgba(232, 160, 32, 0.45));
}
.char-card .char-label p {
  display: inline-block; margin-top: 0.45rem;
  font-size: 0.78rem; letter-spacing: 0.06em;
  color: #ffdf8e; padding: 0.2rem 0.85rem; border-radius: 999px;
  border: 1px solid rgba(245, 200, 66, 0.45);
  background: rgba(232, 160, 32, 0.14);
}

/* character modal */
.char-modal {
  position: fixed; inset: 0; z-index: 210; display: none;
  align-items: center; justify-content: center; padding: 1.2rem;
  background: rgba(5, 9, 17, 0.9);
}
.char-modal.open { display: flex; }
.char-modal .cm-box {
  display: grid; grid-template-columns: 0.9fr 1.1fr; max-width: 880px; width: 100%;
  background: linear-gradient(150deg, var(--night-3), var(--night-2));
  border: 1px solid rgba(245, 200, 66, 0.75); border-radius: 18px;
  position: relative;
  box-shadow:
    0 0 30px rgba(245, 200, 66, 0.55),
    0 0 90px rgba(245, 200, 66, 0.3),
    0 30px 90px rgba(0, 0, 0, 0.7);
  animation: cardGlow 2.2s ease-in-out infinite;
}
.char-modal img { height: 100%; object-fit: cover; border-radius: 17px 0 0 17px; }
.char-modal .cm-box > .dust { z-index: 20; }
.char-modal .cm-copy { padding: 2.2rem 2.2rem 2rem; }
.char-modal .cm-copy h3 {
  font-size: 2.5rem; line-height: 1.28;
  padding-bottom: 0.14em; margin-bottom: 0.15rem;
  background: linear-gradient(110deg, #fff3c4 25%, #f5c842 50%, #ffe9a8 75%);
  background-size: 200% 100%;
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: #ffe9a8;
  filter: drop-shadow(0 2px 10px rgba(232, 160, 32, 0.5));
  animation: shimmer 6s linear infinite;
}
.char-modal .cm-copy .cm-role {
  display: inline-block; margin: 0.75rem 0 1.1rem;
  font-style: italic; font-size: 0.95rem; color: #ffdf8e;
  padding: 0.3rem 1.1rem; border-radius: 999px;
  border: 1px solid rgba(245, 200, 66, 0.5);
  background: rgba(232, 160, 32, 0.15);
  box-shadow: 0 0 16px rgba(232, 160, 32, 0.2);
}
.char-modal .cm-copy p { color: var(--cream-dim); font-size: 1rem; }
.char-modal .cm-traits { margin-top: 1.2rem; display: flex; flex-wrap: wrap; gap: 0.55rem; }
.char-modal .cm-traits span {
  font-size: 0.84rem; font-weight: 600; color: #2b1c04;
  background: linear-gradient(160deg, #f8d565, #e8a020);
  padding: 0.32rem 0.95rem; border-radius: 999px; border: none;
  box-shadow: 0 3px 12px rgba(232, 160, 32, 0.35);
  animation: chipPop 0.45s cubic-bezier(.3,1.6,.5,1) backwards;
}
.char-modal.open .cm-traits span:nth-child(1) { animation-delay: 0.1s; }
.char-modal.open .cm-traits span:nth-child(2) { animation-delay: 0.18s; }
.char-modal.open .cm-traits span:nth-child(3) { animation-delay: 0.26s; }
.char-modal.open .cm-traits span:nth-child(4) { animation-delay: 0.34s; }
.char-modal.open .cm-traits span:nth-child(5) { animation-delay: 0.42s; }
@keyframes chipPop { from { opacity: 0; transform: scale(0.4); } to { opacity: 1; transform: scale(1); } }
.cm-rel-wrap { margin-top: 1.4rem; }
.cm-rel-title {
  font-family: var(--serif-display); font-size: 1.05rem; color: var(--gold);
  letter-spacing: 0.08em; margin-bottom: 0.55rem;
}
.cm-rel { list-style: none; }
.cm-rel li {
  font-size: 0.94rem; color: var(--cream-dim); padding: 0.3rem 0 0.3rem 1.3rem;
  border-bottom: 1px solid rgba(245, 200, 66, 0.1); line-height: 1.45;
  position: relative;
}
.cm-rel li::before {
  content: "✦"; position: absolute; left: 0; top: 0.3rem;
  color: var(--gold); font-size: 0.8rem;
  text-shadow: 0 0 8px rgba(245, 200, 66, 0.8);
}
.cm-rel li:last-child { border-bottom: none; }
.cm-rel li strong { color: #ffe9a8; font-weight: 600; }

/* living character portraits */
.char-card { position: relative; }
.char-card .live-video {
  position: absolute; top: 0; left: 0; width: 100%; aspect-ratio: 1;
  object-fit: cover; border-radius: 15px 15px 0 0;
  opacity: 0; transition: opacity 0.55s ease; pointer-events: none;
}
.char-card:hover .live-video.ready, .char-card.selected .live-video.ready { opacity: 1; }
.cm-video {
  width: 100%; height: 100%; object-fit: cover; border-radius: 17px 0 0 17px;
}
@media (max-width: 900px) {
  .cm-video { max-height: 42vh; border-radius: 17px 17px 0 0; }
}

/* gold pixie dust on card hover */
.char-card { overflow: visible; }
.char-card img { border-radius: 15px 15px 0 0; }

/* gold illumination when a card is selected */
.char-card.selected {
  border-color: rgba(245, 200, 66, 0.95);
  box-shadow:
    0 0 26px rgba(245, 200, 66, 0.6),
    0 0 70px rgba(245, 200, 66, 0.32),
    0 18px 44px rgba(0, 0, 0, 0.6);
  animation: cardGlow 2.2s ease-in-out infinite;
  transform: translateY(-6px);
}
@keyframes cardGlow {
  0%, 100% {
    box-shadow:
      0 0 22px rgba(245, 200, 66, 0.55),
      0 0 60px rgba(245, 200, 66, 0.28),
      0 18px 44px rgba(0, 0, 0, 0.6);
  }
  50% {
    box-shadow:
      0 0 34px rgba(245, 200, 66, 0.85),
      0 0 95px rgba(245, 200, 66, 0.45),
      0 18px 44px rgba(0, 0, 0, 0.6);
  }
}
.dust {
  position: absolute; pointer-events: none; z-index: 8;
  width: 6px; height: 6px; border-radius: 50%;
  background: radial-gradient(circle, #fff6cf 0%, #f5c842 55%, rgba(245,200,66,0) 100%);
  box-shadow: 0 0 8px rgba(245, 200, 66, 0.9);
  opacity: 0;
  animation: dustFloat var(--life, 1.3s) ease-out forwards;
}
@keyframes dustFloat {
  0%   { opacity: 0; transform: translate(0, 0) scale(0.4); }
  18%  { opacity: 1; }
  100% { opacity: 0; transform: translate(var(--dx, 0px), var(--dy, -34px)) scale(var(--ds, 1)); }
}

.char-modal .cm-close {
  position: absolute; top: 1.1rem; right: 1.4rem; font-size: 2.1rem; color: var(--gold);
  background: none; border: none; cursor: pointer;
}

/* ---------- music ---------- */
#music {
  background:
    radial-gradient(ellipse at 50% 100%, rgba(232, 160, 32, 0.1), transparent 60%),
    linear-gradient(var(--night), var(--night-2));
}
.tracks { max-width: 780px; margin: 0 auto; display: flex; flex-direction: column; gap: 1rem; }
.track {
  background: rgba(255, 252, 234, 0.05);
  border: 1px solid rgba(245, 200, 66, 0.18);
  border-radius: 14px; overflow: hidden;
  transition: border-color 0.3s;
}
.track.playing { border-color: rgba(245, 200, 66, 0.6); box-shadow: 0 0 34px rgba(245,200,66,0.12); }
.track .t-main { display: flex; align-items: center; gap: 1.1rem; padding: 1rem 1.2rem; }
.track .t-play {
  flex: none; width: 52px; height: 52px; border-radius: 50%;
  border: 1px solid rgba(245, 200, 66, 0.7);
  background: linear-gradient(160deg, #f8d565, var(--amber));
  color: #241703; font-size: 1.15rem; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: transform 0.2s, box-shadow 0.2s;
}
.track .t-play:hover { transform: scale(1.07); box-shadow: 0 0 22px rgba(245,200,66,0.5); }
.track .t-info { flex: 1; min-width: 0; }
.track .t-info h3 { font-size: 1.18rem; color: var(--cream); }
.track .t-info .t-sub { font-size: 0.85rem; color: var(--moon); font-style: italic; }
.track .t-progress {
  margin-top: 0.5rem; height: 5px; border-radius: 999px;
  background: rgba(255, 252, 234, 0.12); cursor: pointer; position: relative;
}
.track .t-progress .t-fill {
  height: 100%; width: 0%; border-radius: 999px;
  background: linear-gradient(90deg, var(--amber), var(--gold));
}
.track .t-time { flex: none; font-size: 0.85rem; color: var(--moon); font-variant-numeric: tabular-nums; }
.track .t-lyrics-btn {
  flex: none; background: none; border: none; color: var(--gold); cursor: pointer;
  font-family: var(--serif-body); font-size: 0.9rem; letter-spacing: 0.05em;
  border-bottom: 1px dotted rgba(245,200,66,0.6); padding-bottom: 1px;
}
.track .t-lyrics { display: none; padding: 0 1.4rem 1.4rem; }
.track .t-lyrics.open { display: block; }
.track .t-lyrics pre {
  white-space: pre-wrap; font-family: var(--serif-body); font-size: 0.98rem;
  color: var(--cream-dim); line-height: 1.7;
  border-top: 1px solid rgba(245, 200, 66, 0.18); padding-top: 1.1rem;
}

/* ---------- storyteller ---------- */
#author { background: var(--night-2); }
.author-grid { display: grid; grid-template-columns: 0.85fr 1.15fr; gap: 3.5rem; align-items: center; }
.author-art img {
  border-radius: 16px;
  box-shadow: 0 18px 60px rgba(0,0,0,0.6), 0 0 0 1px rgba(245,200,66,0.22);
}
.author-copy .drop-quote {
  font-family: var(--serif-display); font-size: 1.45rem; font-style: italic; line-height: 1.5;
  color: var(--cream); margin-bottom: 1.4rem;
}
.author-copy .drop-quote::before { content: "“"; color: var(--gold); font-size: 2rem; }
.author-copy .drop-quote::after { content: "”"; color: var(--gold); font-size: 2rem; }
.author-copy p { color: var(--cream-dim); margin-bottom: 1.05rem; }
.author-copy .signature {
  font-family: var(--serif-display); font-style: italic; font-size: 1.5rem; color: var(--gold);
  margin-top: 1.4rem;
}

/* ---------- visit ---------- */
#visit {
  background:
    linear-gradient(rgba(11, 20, 36, 0.88), rgba(11, 20, 36, 0.94)),
    url("../img/spreads/page-15.jpg") center / cover no-repeat fixed;
  text-align: center;
}
#visit .wrap { max-width: 760px; }
#visit p { color: var(--cream-dim); margin-bottom: 1.1rem; font-size: 1.08rem; }
#visit .visit-quote { font-style: italic; color: var(--moon); }
#visit .btn { margin-top: 1.4rem; }

/* ---------- footer ---------- */
footer {
  background: #070d18; padding: 3.5rem 1.5rem 2.5rem; text-align: center;
  border-top: 1px solid rgba(245, 200, 66, 0.14);
}
footer .f-logo { height: 90px; margin: 0 auto 1.2rem; filter: drop-shadow(0 0 10px rgba(245,200,66,0.35)); }
footer .f-title { font-family: var(--serif-display); font-size: 1.4rem; color: var(--cream); }
footer .f-links { margin: 1.2rem 0; display: flex; gap: 1.8rem; justify-content: center; flex-wrap: wrap; }
footer .f-links a { color: var(--cream-dim); font-size: 0.95rem; }
footer .f-links a:hover { color: var(--gold); }
footer .f-copy { color: rgba(176, 196, 216, 0.55); font-size: 0.85rem; margin-top: 1rem; }

/* ---------- responsive ---------- */
@media (max-width: 900px) {
  .story-grid, .book-grid, .author-grid { grid-template-columns: 1fr; }
  .tales-grid { grid-template-columns: repeat(2, 1fr); }
  .timeline { grid-template-columns: repeat(2, 1fr); }
  .char-modal .cm-box { grid-template-columns: 1fr; max-height: 92vh; overflow-y: auto; }
  .char-modal img { max-height: 42vh; width: 100%; border-radius: 17px 17px 0 0; }
  nav ul {
    position: fixed; top: 60px; right: 0; flex-direction: column;
    background: rgba(8, 13, 24, 0.97); padding: 1.6rem 2.2rem; gap: 1.1rem;
    border-left: 1px solid rgba(245,200,66,0.2); border-bottom: 1px solid rgba(245,200,66,0.2);
    border-radius: 0 0 0 14px; transform: translateX(110%); transition: transform 0.3s;
  }
  nav ul.open { transform: none; }
  .nav-toggle { display: block; }
}
@media (max-width: 560px) {
  .tales-grid { grid-template-columns: 1fr; }
  .timeline { grid-template-columns: 1fr; }
  body { font-size: 17px; }
  .track .t-time { display: none; }
}

/* ============================================================
   ENCHANTMENT LAYER — sitewide animation
   ============================================================ */

/* sitewide drifting stardust */
#stardust {
  position: fixed; inset: 0; width: 100%; height: 100%;
  z-index: 60; pointer-events: none; opacity: 0.5;
}

/* nav hidden over the hero — slides in after scrolling */
nav#siteNav {
  transform: translateY(-110%);
  visibility: hidden;
  transition: transform 0.45s cubic-bezier(.22,.9,.3,1), visibility 0s linear 0.45s;
}
nav#siteNav.show { transform: none; visibility: visible; transition-delay: 0s; }

/* hero entrance sequence */
.fade-seq { opacity: 0; transform: translateY(26px); animation: seqIn 1.1s ease forwards; }
.hero-inner h1.fade-seq { animation-delay: 0.25s; }
.hero-inner .subtitle.fade-seq { animation-delay: 0.65s; }
.hero-inner .byline.fade-seq { animation-delay: 1.0s; }
.hero-inner .hero-ctas.fade-seq { animation-delay: 1.35s; }
@keyframes seqIn { to { opacity: 1; transform: none; } }

.hero-inner h1 {
  background: linear-gradient(100deg, var(--cream) 38%, #ffe9a8 50%, var(--cream) 62%);
  background-size: 220% 100%;
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: seqIn 1.1s ease 0.25s forwards, shimmer 7s linear 2s infinite;
}
@keyframes shimmer { from { background-position: 120% 0; } to { background-position: -120% 0; } }

/* gentle idle float for the book cover */
.book-cover { animation: floatBook 6.5s ease-in-out infinite; }
@keyframes floatBook {
  0%, 100% { transform: rotateY(-12deg) rotateX(2deg) translateY(0); }
  50% { transform: rotateY(-12deg) rotateX(2deg) translateY(-12px); }
}
.book-cover-wrap:hover .book-cover { animation-play-state: paused; }

/* Ken Burns drift inside gallery cards */
.gallery figure { overflow: hidden; }
.gallery img { transition: transform 6s ease; transform: scale(1.03); }
.gallery figure:hover img { transform: scale(1.14) translate(-1.5%, -1.5%); }

/* character cards: soft idle bob (staggered via nth-child) */
.char-card { animation: cardBob 7s ease-in-out infinite; }
.char-card:nth-child(3n) { animation-delay: -2.3s; }
.char-card:nth-child(3n+1) { animation-delay: -4.6s; }
@keyframes cardBob { 0%,100% { translate: 0 0; } 50% { translate: 0 -6px; } }

/* ---------- kingdom / map ---------- */
#kingdom {
  background:
    radial-gradient(ellipse at 50% 0%, rgba(232,160,32,0.10), transparent 55%),
    linear-gradient(var(--night-2), var(--night));
}
.kingdom-sub { margin-top: 0.9rem; font-style: italic; color: var(--moon); font-size: 1.05rem; }
.map-frame {
  border-radius: 18px; padding: 10px;
  background: linear-gradient(140deg, rgba(245,200,66,0.5), rgba(245,200,66,0.08) 40%, rgba(245,200,66,0.35));
  box-shadow: 0 24px 80px rgba(0,0,0,0.6);
}
.map-stage { position: relative; border-radius: 12px; overflow: hidden; }
.map-img { width: 100%; display: block; }

.map-stage { --s: 1; }
.poi {
  position: absolute; left: calc(var(--x) * 1%); top: calc(var(--y) * 1%);
  width: 22px; height: 22px;
  transform: translate(-50%, -50%) scale(calc(1 / var(--s)));
  border-radius: 50%; border: none; cursor: pointer;
  background: radial-gradient(circle, #fff6cf 0%, var(--gold) 45%, rgba(245,200,66,0) 72%);
  box-shadow: 0 0 12px rgba(245, 200, 66, 0.9);
  animation: poiPulse 2.6s ease-in-out infinite;
}
.poi:nth-child(2n) { animation-delay: -1.3s; }
.poi:nth-child(3n) { animation-delay: -0.7s; }
@keyframes poiPulse {
  0%, 100% { box-shadow: 0 0 10px rgba(245,200,66,0.75), 0 0 0 0 rgba(245,200,66,0.45); }
  50% { box-shadow: 0 0 18px rgba(245,200,66,1), 0 0 0 12px rgba(245,200,66,0); }
}
.poi:hover, .poi.active { scale: 1.35; }

.poi-card {
  position: absolute; z-index: 5; width: min(280px, 62vw);
  background: linear-gradient(150deg, rgba(16,29,51,0.97), rgba(11,20,36,0.97));
  border: 1px solid rgba(245, 200, 66, 0.55); border-radius: 12px;
  padding: 0.9rem 1.05rem; pointer-events: none;
  opacity: 0; translate: 0 8px; transition: opacity 0.3s, translate 0.3s;
  box-shadow: 0 14px 40px rgba(0,0,0,0.6);
}
.poi-card.show { opacity: 1; translate: 0 0; }
.poi-card h4 { font-size: 1.12rem; color: var(--gold); margin-bottom: 0.25rem; }
.poi-card p { font-size: 0.9rem; color: var(--cream-dim); line-height: 1.5; }

.linklike {
  background: none; border: none; color: var(--gold); cursor: pointer;
  font-family: var(--serif-body); font-size: inherit; font-style: inherit;
  border-bottom: 1px dotted rgba(245,200,66,0.6);
}

/* ---------- door entrance animation ---------- */
.door-overlay {
  position: fixed; inset: 0; z-index: 400; display: none; overflow: hidden;
  background: var(--night);
}
.door-overlay.on { display: block; animation: overlayIn 0.45s ease; }
@keyframes overlayIn { from { opacity: 0; } to { opacity: 1; } }
.door-video { display: none; position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.door-overlay.video-mode .door-video { display: block; }
.door-overlay.video-mode .door-art { display: none; }
.door-overlay.video-mode.on .door-flash { animation: doorFlash 5.1s ease-in forwards; }
/* during the film: rays and stardust join in as the camera crosses the threshold */
.door-overlay.video-mode.on .door-rays { animation: raysTurn 2.1s ease-in 3s forwards; }
.door-overlay.video-mode.on .door-sparkles { animation: sparkFly 1.9s cubic-bezier(.5,.05,.4,1) 3.1s forwards; }
.door-overlay.video-mode.on .door-sparkles-2 { animation: sparkFly 1.7s cubic-bezier(.5,.05,.4,1) 3.5s forwards; transform: rotate(47deg); }

/* golden arrival shimmer on the kingdom map */
.map-frame.arrived { animation: mapArrive 2s ease; }
@keyframes mapArrive {
  0% { box-shadow: 0 0 0 rgba(245,200,66,0), 0 24px 80px rgba(0,0,0,0.6); }
  30% { box-shadow: 0 0 70px rgba(245, 200, 66, 0.65), 0 0 140px rgba(245,200,66,0.3), 0 24px 80px rgba(0,0,0,0.6); }
  100% { box-shadow: 0 0 0 rgba(245,200,66,0), 0 24px 80px rgba(0,0,0,0.6); }
}
.door-art {
  position: absolute; inset: 0;
  background: url("../img/door.jpg") center / cover no-repeat;
  transform-origin: 50% 58%;
}
.door-overlay.on .door-art { animation: doorZoom 2.6s cubic-bezier(.55,.06,.35,1) forwards; }
@keyframes doorZoom {
  0%   { transform: scale(1); filter: brightness(1) saturate(1); }
  14%  { transform: scale(1.015); filter: brightness(1.18) saturate(1.15); }
  26%  { transform: scale(1.05); filter: brightness(1.28) saturate(1.2); }
  85%  { transform: scale(7.5); filter: brightness(1.7) saturate(1.25); }
  100% { transform: scale(9.5); filter: brightness(2.5) saturate(1.3); }
}

/* rotating golden light rays pouring from the doorway */
.door-rays {
  position: absolute; left: 50%; top: 58%; width: 160vmax; height: 160vmax;
  margin: -80vmax 0 0 -80vmax; opacity: 0; mix-blend-mode: screen;
  background: repeating-conic-gradient(
    from 0deg,
    rgba(255, 224, 130, 0.22) 0deg 7deg,
    rgba(255, 224, 130, 0) 7deg 24deg
  );
  -webkit-mask-image: radial-gradient(circle, black 0%, transparent 62%);
  mask-image: radial-gradient(circle, black 0%, transparent 62%);
}
.door-overlay.on .door-rays { animation: raysTurn 2.6s ease-in forwards; }
@keyframes raysTurn {
  0%   { opacity: 0; transform: rotate(0deg) scale(0.6); }
  20%  { opacity: 0.5; }
  70%  { opacity: 0.85; }
  100% { opacity: 1; transform: rotate(38deg) scale(1.6); }
}

/* golden sparkles rushing past as you fly through */
.door-sparkles {
  position: absolute; left: 50%; top: 58%; width: 10px; height: 10px;
  opacity: 0; pointer-events: none;
  background: transparent;
  border-radius: 50%;
  box-shadow:
    -18vw -12vh 2px 3px rgba(255,238,170,0.9),   14vw -20vh 1px 2px rgba(255,224,130,0.8),
     24vw   8vh 2px 4px rgba(255,238,170,0.9),  -26vw  14vh 1px 2px rgba(245,200,66,0.85),
      6vw  22vh 2px 3px rgba(255,238,170,0.85), -10vw -24vh 1px 2px rgba(255,224,130,0.8),
     30vw -14vh 1px 3px rgba(245,200,66,0.8),   -32vw  -4vh 2px 3px rgba(255,238,170,0.85),
     12vw -30vh 1px 2px rgba(255,224,130,0.85), -20vw  26vh 2px 3px rgba(245,200,66,0.8),
     34vw  20vh 1px 2px rgba(255,238,170,0.8),   -8vw  32vh 1px 3px rgba(255,224,130,0.85);
}
.door-overlay.on .door-sparkles { animation: sparkFly 2.6s cubic-bezier(.5,.05,.4,1) forwards; }
.door-overlay.on .door-sparkles-2 { animation: sparkFly 2.6s cubic-bezier(.5,.05,.4,1) 0.45s forwards; transform: rotate(47deg); }
@keyframes sparkFly {
  0%   { opacity: 0; transform: scale(0.12); }
  25%  { opacity: 0.6; }
  60%  { opacity: 1; }
  100% { opacity: 0.9; transform: scale(3.4); }
}
.door-flash {
  position: absolute; inset: 0; opacity: 0;
  background: radial-gradient(circle at 50% 58%, #fff3c4 0%, rgba(245,200,66,0.85) 35%, rgba(232,160,32,0.4) 60%, transparent 80%);
}
.door-overlay.on .door-flash { animation: doorFlash 2.3s ease-in forwards; }
@keyframes doorFlash {
  0%, 55% { opacity: 0; }
  88% { opacity: 1; }
  100% { opacity: 1; }
}
.door-overlay.fadeout { animation: overlayFade 0.7s ease forwards; }
@keyframes overlayFade { to { opacity: 0; } }

/* ============================================================
   WORLD-CLASS PASS — video hero, story media, map zoom, mobile
   ============================================================ */

/* hero video */
.hero-video {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: cover; object-position: center 38%;
}

/* story media */
.story-media { margin: 1.6rem 0 1.1rem; }
.story-media video {
  width: 100%; border-radius: 14px; display: block;
  box-shadow: 0 16px 50px rgba(0,0,0,0.6), 0 0 0 1px rgba(245,200,66,0.25);
  background: #000;
}
.story-track { margin-top: 1rem; }

/* full story reader */
.full-story {
  margin-top: 3.2rem;
  border: 1px solid rgba(245, 200, 66, 0.22); border-radius: 16px;
  background: rgba(255, 252, 234, 0.04);
  overflow: hidden;
}
.full-story summary {
  cursor: pointer; list-style: none; text-align: center;
  padding: 1.25rem 1.5rem;
  font-family: var(--serif-display); font-size: 1.25rem; color: var(--gold);
  letter-spacing: 0.04em;
  transition: background 0.3s;
}
.full-story summary::-webkit-details-marker { display: none; }
.full-story summary:hover { background: rgba(245, 200, 66, 0.08); }
.full-story[open] summary { border-bottom: 1px solid rgba(245,200,66,0.18); }
.full-story-body {
  max-width: 720px; margin: 0 auto; padding: 2.2rem 1.6rem 2.6rem;
  columns: 1;
}
.full-story-body p { margin-bottom: 1.15rem; color: var(--cream-dim); font-size: 1.05rem; }
.full-story-body p:first-child::first-letter {
  font-family: var(--serif-display); font-size: 3.4em; float: left;
  line-height: 0.82; padding-right: 0.09em; color: var(--gold);
}

/* map viewport: pan & zoom */
.map-viewport {
  position: relative; border-radius: 12px; overflow: hidden;
  touch-action: none; cursor: grab;
}
.map-viewport.dragging { cursor: grabbing; }
.map-stage { transform-origin: 0 0; will-change: transform; }
.map-controls {
  position: absolute; right: 22px; bottom: 22px; z-index: 6;
  display: flex; flex-direction: column; gap: 8px;
}
.map-controls button {
  width: 42px; height: 42px; border-radius: 50%;
  border: 1px solid rgba(245, 200, 66, 0.6);
  background: rgba(11, 20, 36, 0.85); color: var(--gold);
  font-size: 1.25rem; cursor: pointer; backdrop-filter: blur(4px);
  transition: background 0.25s, transform 0.2s;
}
.map-controls button:hover { background: rgba(245,200,66,0.2); transform: scale(1.08); }
.map-frame { position: relative; }

/* footer animated logo (black bg blends away on dark footer) */
.f-logo-video {
  width: 150px; height: 150px; margin: 0 auto 1rem; display: block;
  mix-blend-mode: screen; border-radius: 50%;
  filter: drop-shadow(0 0 14px rgba(245,200,66,0.3));
}

/* ---------- review pass: hero link, morals, featured tale, join ---------- */
.hero-song-link { margin-top: 1.2rem; animation-delay: 1.7s !important; }
.hero-song-link .linklike { font-size: 1.02rem; color: var(--moon); border-color: rgba(176,196,216,0.5); }
.hero-song-link .linklike:hover { color: var(--gold); }
.hero-inner .subtitle { max-width: 640px; margin-left: auto; margin-right: auto; }

.tale-moral {
  margin-top: 0.8rem; padding-top: 0.65rem;
  border-top: 1px solid rgba(245, 200, 66, 0.16);
  font-style: italic; font-size: 0.88rem !important;
  color: var(--amber) !important;
}

.featured-tale { margin-bottom: 3.2rem; }
.ft-label {
  text-align: center; letter-spacing: 0.22em; text-transform: uppercase;
  font-size: 0.78rem; color: var(--gold); margin-bottom: 1.4rem;
}
.ft-panels { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.4rem; }
.ft-panel {
  border-radius: 14px; overflow: hidden;
  background: rgba(255, 252, 234, 0.045);
  border: 1px solid rgba(245, 200, 66, 0.2);
  box-shadow: 0 12px 36px rgba(0,0,0,0.5);
  transition: transform 0.35s, border-color 0.35s;
}
.ft-panel:hover { transform: translateY(-6px); border-color: rgba(245,200,66,0.55); }
.ft-panel img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.ft-panel figcaption { padding: 1rem 1.1rem 1.2rem; font-size: 0.95rem; color: var(--cream-dim); line-height: 1.5; }
.ft-panel figcaption strong { color: var(--cream); font-weight: 500; }

.cm-tales { font-size: 0.85rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--moon); margin: -0.6rem 0 1rem; }

#join {
  background:
    radial-gradient(ellipse at 50% 120%, rgba(232, 160, 32, 0.14), transparent 60%),
    var(--night-2);
  text-align: center;
}
.join-title { font-size: clamp(1.7rem, 3.5vw, 2.4rem); color: var(--cream); }
.join-sub { max-width: 560px; margin: 0.9rem auto 1.8rem; color: var(--cream-dim); }
.join-form { display: flex; gap: 0.8rem; justify-content: center; flex-wrap: wrap; }
.join-form input {
  width: min(360px, 100%); padding: 0.85rem 1.4rem; border-radius: 999px;
  border: 1px solid rgba(245, 200, 66, 0.4); background: rgba(11, 20, 36, 0.7);
  color: var(--cream); font-family: var(--serif-body); font-size: 1rem; outline: none;
}
.join-form input:focus { border-color: var(--gold); box-shadow: 0 0 18px rgba(245,200,66,0.25); }
.join-schools { margin-top: 1.6rem; font-size: 0.95rem; color: var(--moon); }

@media (max-width: 700px) {
  .ft-panels { grid-template-columns: 1fr; }
}

/* ============================================================
   WONDER PACK — cursor dust, hidden fairies, bedtime, fireflies
   ============================================================ */

/* cursor pixie dust */
.cursor-dust {
  position: fixed; pointer-events: none; z-index: 300;
  width: 6px; height: 6px; border-radius: 50%;
  background: radial-gradient(circle, #fff6cf 0%, #f5c842 55%, rgba(245,200,66,0) 100%);
  box-shadow: 0 0 8px rgba(245, 200, 66, 0.85);
  animation: dustFloat var(--life, 1.1s) ease-out forwards;
}

/* hidden fairies */
.hidden-fairy {
  position: absolute; width: 26px; height: 26px; z-index: 6;
  background: none; border: none; cursor: pointer; padding: 0;
}
.hidden-fairy::before {
  content: ""; display: block; width: 100%; height: 100%;
  background:
    radial-gradient(circle at 50% 55%, #fff6cf 0%, rgba(245,200,66,0.9) 30%, rgba(245,200,66,0) 70%);
  border-radius: 50%;
  filter: drop-shadow(0 0 6px rgba(245, 200, 66, 0.9));
  animation: fairyTwinkle 3.4s ease-in-out infinite;
}
.hidden-fairy::after {
  content: "✧"; position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  color: #fff8dc; font-size: 13px; text-shadow: 0 0 6px rgba(255,240,180,1);
  animation: fairyTwinkle 3.4s ease-in-out infinite reverse;
}
@keyframes fairyTwinkle {
  0%, 100% { opacity: 0.25; transform: scale(0.8); }
  50% { opacity: 0.9; transform: scale(1.15); }
}
.hidden-fairy.found { display: none; }

/* toast */
.fairy-toast {
  position: fixed; left: 50%; bottom: 26px; transform: translate(-50%, 20px);
  z-index: 320; padding: 0.75rem 1.6rem; border-radius: 999px;
  background: linear-gradient(150deg, rgba(16,29,51,0.97), rgba(11,20,36,0.97));
  border: 1px solid rgba(245, 200, 66, 0.65); color: var(--cream);
  font-family: var(--serif-display); font-size: 1.05rem; letter-spacing: 0.03em;
  box-shadow: 0 10px 40px rgba(0,0,0,0.6), 0 0 24px rgba(245,200,66,0.25);
  opacity: 0; pointer-events: none; transition: opacity 0.35s, transform 0.35s;
}
.fairy-toast.show { opacity: 1; transform: translate(-50%, 0); }

/* certificate */
.cert-overlay {
  position: fixed; inset: 0; z-index: 340; display: none;
  align-items: center; justify-content: center; padding: 1.4rem;
  background: rgba(5, 9, 17, 0.88);
}
.cert-overlay.open { display: flex; }
.cert-card {
  max-width: 560px; width: 100%; text-align: center;
  background:
    radial-gradient(ellipse at 50% 0%, rgba(245, 200, 66, 0.14), transparent 60%),
    linear-gradient(160deg, #1a2b47, #101d33);
  border: 2px solid rgba(245, 200, 66, 0.85); border-radius: 20px;
  padding: 2.6rem 2.4rem 2.2rem;
  box-shadow: 0 0 50px rgba(245, 200, 66, 0.4), 0 40px 90px rgba(0,0,0,0.7);
  animation: certIn 0.6s cubic-bezier(.3,1.4,.5,1);
}
@keyframes certIn { from { opacity: 0; transform: scale(0.7); } to { opacity: 1; transform: scale(1); } }
.cert-stars { color: var(--gold); letter-spacing: 0.6em; margin-bottom: 0.8rem; }
.cert-card h3 {
  font-size: 2.1rem;
  background: linear-gradient(110deg, #fff3c4 25%, #f5c842 50%, #ffe9a8 75%);
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 2px 8px rgba(232,160,32,0.5));
  margin-bottom: 1rem;
}
.cert-body { color: var(--cream-dim); font-size: 1.05rem; margin-bottom: 1.1rem; }
.cert-sign { font-style: italic; color: var(--moon); font-size: 0.92rem; margin-bottom: 1.6rem; }
.cert-btns { display: flex; gap: 1.2rem; justify-content: center; align-items: center; flex-wrap: wrap; }

/* bedtime mode */
#bedtimeToggle {
  position: fixed; right: 20px; bottom: 20px; z-index: 120;
  width: 52px; height: 52px; border-radius: 50%;
  border: 1px solid rgba(245, 200, 66, 0.5);
  background: rgba(11, 20, 36, 0.85); font-size: 1.45rem; cursor: pointer;
  box-shadow: 0 6px 24px rgba(0,0,0,0.5);
  transition: transform 0.25s, box-shadow 0.25s, background 0.25s;
}
#bedtimeToggle:hover { transform: scale(1.1); box-shadow: 0 0 24px rgba(245,200,66,0.4); }
body.bedtime #bedtimeToggle { background: rgba(245, 200, 66, 0.22); }
.night-veil {
  position: fixed; inset: 0; z-index: 54; pointer-events: none;
  background:
    radial-gradient(ellipse at 50% 0%, rgba(6, 10, 22, 0.25), rgba(4, 7, 16, 0.55) 80%);
  opacity: 0; transition: opacity 1.2s ease;
}
body.bedtime .night-veil { opacity: 1; }
body.bedtime .hero-video { filter: brightness(0.72); }
body.bedtime section, body.bedtime footer { filter: brightness(0.86) saturate(0.92); }

/* lightbox page-flip arrows */
.lb-arrow {
  position: absolute; top: 50%; transform: translateY(-50%);
  z-index: 210; width: 54px; height: 54px; border-radius: 50%;
  border: 1px solid rgba(245, 200, 66, 0.6); cursor: pointer;
  background: rgba(11, 20, 36, 0.8); color: var(--gold); font-size: 1.9rem;
  transition: background 0.25s, transform 0.2s;
}
.lb-arrow:hover { background: rgba(245,200,66,0.2); transform: translateY(-50%) scale(1.08); }
.lb-prev { left: 3vw; }
.lb-next { right: 3vw; }
.lightbox img.flipping { animation: pageFlip 0.5s ease; }
@keyframes pageFlip {
  0% { transform: perspective(1200px) rotateY(0deg); }
  50% { transform: perspective(1200px) rotateY(-88deg); opacity: 0.4; }
  100% { transform: perspective(1200px) rotateY(0deg); }
}

@media (max-width: 700px) {
  #bedtimeToggle { right: 12px; bottom: 12px; width: 46px; height: 46px; }
  .lb-prev { left: 6px; } .lb-next { right: 6px; }
  .lb-arrow { width: 44px; height: 44px; font-size: 1.5rem; }
}

@media (prefers-reduced-motion: reduce) {
  .hidden-fairy::before, .hidden-fairy::after { animation: none; opacity: 0.7; }
  .cursor-dust { display: none; }
}

/* ============================================================
   STORY TIME · SHOP · WILD FIREFLIES · GOLDEN PASS
   ============================================================ */

/* read-along */
#readalong {
  background:
    radial-gradient(ellipse at 20% 0%, rgba(176, 196, 216, 0.08), transparent 55%),
    linear-gradient(var(--night), var(--night-2));
}
.reader {
  max-width: 900px; margin: 0 auto;
  border-radius: 18px; overflow: hidden;
  border: 1px solid rgba(245, 200, 66, 0.3);
  background: linear-gradient(170deg, var(--night-3), var(--night-2));
  box-shadow: 0 24px 70px rgba(0,0,0,0.6);
}
.reader-art { position: relative; }
.reader-art img { width: 100%; display: block; transition: opacity 0.5s ease; }
.reader-art img.fading { opacity: 0; }
.reader-art-veil {
  position: absolute; left: 0; right: 0; bottom: 0; height: 60px;
  background: linear-gradient(transparent, rgba(22, 38, 63, 0.95));
}
.reader-scene-label {
  position: absolute; top: 12px; right: 14px;
  background: rgba(11, 20, 36, 0.75); border: 1px solid rgba(245,200,66,0.4);
  color: var(--gold); font-size: 0.8rem; letter-spacing: 0.1em;
  padding: 0.25rem 0.9rem; border-radius: 999px;
}
.reader-panel { padding: 1.4rem 1.6rem 1.8rem; }
.reader-controls { display: flex; align-items: center; gap: 0.9rem; margin-bottom: 1.2rem; }
.r-play {
  width: 60px; height: 60px; border-radius: 50%;
  border: 1px solid rgba(245, 200, 66, 0.7);
  background: linear-gradient(160deg, #f8d565, var(--amber));
  color: #241703; font-size: 1.3rem; cursor: pointer;
  box-shadow: 0 4px 22px rgba(232,160,32,0.45);
  transition: transform 0.2s;
}
.r-play:hover { transform: scale(1.07); }
.r-btn {
  width: 44px; height: 44px; border-radius: 50%;
  border: 1px solid rgba(176,196,216,0.4); background: rgba(255,252,234,0.05);
  color: var(--moon); font-size: 1.3rem; cursor: pointer;
  transition: background 0.2s, color 0.2s;
}
.r-btn:hover { background: rgba(245,200,66,0.15); color: var(--gold); }
.r-dots { display: flex; gap: 8px; margin-left: auto; }
.r-dots button {
  width: 13px; height: 13px; border-radius: 50%; border: 1px solid rgba(245,200,66,0.6);
  background: transparent; cursor: pointer; transition: background 0.25s, transform 0.25s;
}
.r-dots button.active { background: var(--gold); transform: scale(1.25); box-shadow: 0 0 10px rgba(245,200,66,0.7); }
.reader-lines {
  max-height: 300px; overflow-y: auto; padding-right: 0.5rem;
  scrollbar-color: rgba(245,200,66,0.4) rgba(255,252,234,0.05);
}
.reader-lines p {
  font-family: var(--serif-display); font-size: 1.22rem; line-height: 1.55;
  color: rgba(255, 252, 234, 0.4); padding: 0.22rem 0.6rem; border-radius: 8px;
  transition: color 0.4s, background 0.4s, text-shadow 0.4s;
}
.reader-lines p.done { color: rgba(255, 252, 234, 0.62); }
.reader-lines p.active {
  color: #ffe9a8;
  background: rgba(245, 200, 66, 0.09);
  text-shadow: 0 0 18px rgba(245, 200, 66, 0.55);
}

/* read-along text over the artwork */
.r-overlay { position: absolute; inset: 0; pointer-events: none; }
.r-block { position: absolute; text-align: center; }
.r-block p {
  font-family: var(--serif-display); line-height: 1.5; margin: 0 0 0.35em;
  color: transparent;
}
.r-block .r-word, .reader-lines .r-word {
  color: rgba(255, 252, 234, 0.55);
  text-shadow: 0 0 8px rgba(0, 0, 0, 0.65), 0 1px 3px rgba(0, 0, 0, 0.8);
  transition: color 0.25s, text-shadow 0.25s;
}
.r-block .r-title .r-word { font-size: 1.6em; letter-spacing: 0.04em; }
.r-word.lit {
  color: #ffe9a8;
  text-shadow: 0 0 14px rgba(245, 200, 66, 0.85), 0 1px 3px rgba(0, 0, 0, 0.8);
}
.r-word.current {
  color: #fff6cf;
  text-shadow: 0 0 20px rgba(255, 236, 150, 1), 0 0 34px rgba(245, 200, 66, 0.7), 0 1px 3px rgba(0,0,0,0.8);
}
/* desktop: text lives on the art; mobile: panel below */
@media (min-width: 1000px) {
  .reader-lines { display: none; }
  .reader-art-veil { display: none; }
}
@media (max-width: 999px) {
  .r-overlay { display: none; }
  .reader-lines p { padding: 0.22rem 0.6rem; }
}

/* shop */
#shop {
  background:
    radial-gradient(ellipse at 85% 10%, rgba(232, 160, 32, 0.09), transparent 55%),
    var(--night-2);
}
.shop-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 1.6rem; }
.shop-card {
  position: relative; border-radius: 16px;
  border: 1px solid rgba(245, 200, 66, 0.3);
  background:
    radial-gradient(ellipse at 50% 0%, rgba(245, 200, 66, 0.12), transparent 65%),
    rgba(255, 252, 234, 0.05);
  box-shadow: 0 12px 36px rgba(0,0,0,0.5);
  transition: transform 0.35s, border-color 0.35s, box-shadow 0.35s;
  animation: cardBob 8s ease-in-out infinite;
  overflow: visible;
}
.shop-card:nth-child(2n) { animation-delay: -3s; }
.shop-card:nth-child(3n) { animation-delay: -5.5s; }
.shop-card:hover {
  transform: translateY(-8px);
  border-color: rgba(245, 200, 66, 0.95);
  box-shadow:
    0 0 26px rgba(245, 200, 66, 0.55),
    0 0 70px rgba(245, 200, 66, 0.28),
    0 18px 44px rgba(0, 0, 0, 0.6);
  animation: cardGlow 2.2s ease-in-out infinite;
}
.shop-card .shop-img-wrap {
  overflow: hidden; border-radius: 15px 15px 0 0; position: relative;
}
.shop-card img {
  width: 100%; aspect-ratio: 4/3; object-fit: cover; background: #dfe9f2;
  display: block; transition: transform 4s ease;
  border-radius: 15px 15px 0 0;
}
.shop-card:hover img { transform: scale(1.07); }
.shop-badge {
  position: absolute; top: 14px; right: -12px; z-index: 4;
  background: linear-gradient(160deg, #f8d565, var(--amber)); color: #241703;
  font-size: 0.74rem; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase;
  padding: 0.42rem 1.2rem; border-radius: 999px 0 0 999px;
  box-shadow: 0 4px 14px rgba(0,0,0,0.45), 0 0 18px rgba(245,200,66,0.45);
  white-space: nowrap;
  animation: badgeGlow 2.6s ease-in-out infinite;
}
.shop-badge::after {
  content: ""; position: absolute; right: 0; top: 100%;
  border: 6px solid transparent; border-top-color: #a86e12; border-right-color: #a86e12;
}
@keyframes badgeGlow {
  0%, 100% { box-shadow: 0 4px 14px rgba(0,0,0,0.45), 0 0 12px rgba(245,200,66,0.35); }
  50% { box-shadow: 0 4px 14px rgba(0,0,0,0.45), 0 0 26px rgba(245,200,66,0.75); }
}
.shop-card figcaption {
  padding: 1.05rem 1.1rem 1.3rem; text-align: center;
  border-top: 1px solid rgba(245, 200, 66, 0.25);
  background: linear-gradient(180deg, rgba(245, 200, 66, 0.08), rgba(245, 200, 66, 0.02));
  border-radius: 0 0 15px 15px;
}
.shop-card h3 {
  font-size: 1.28rem; margin-bottom: 0.35rem;
  background: linear-gradient(120deg, #fff3c4 20%, #f5c842 50%, #ffe9a8 80%);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: #ffe9a8;
  filter: drop-shadow(0 1px 6px rgba(232, 160, 32, 0.4));
}
.shop-card p { font-size: 0.88rem; color: var(--cream-dim); line-height: 1.45; }

/* wild fireflies (clickable, sitewide) */
.wild-fly {
  position: absolute; width: 30px; height: 30px; z-index: 6;
  background: none; border: none; cursor: pointer; padding: 0;
}
.wild-fly::before {
  content: ""; display: block; width: 12px; height: 12px; margin: 9px;
  border-radius: 50%;
  background: radial-gradient(circle, #fff8d0 0%, #f5c842 50%, rgba(245,200,66,0) 75%);
  box-shadow: 0 0 10px rgba(245, 200, 66, 0.9), 0 0 22px rgba(245, 200, 66, 0.4);
  animation: flyPulse 2.8s ease-in-out infinite;
}
.wild-fly { animation: flyDrift 9s ease-in-out infinite alternate; }
@keyframes flyDrift {
  from { transform: translate(0, 0); }
  to { transform: translate(var(--fx, 30px), var(--fy, -24px)); }
}
@keyframes flyPulse {
  0%, 100% { opacity: 0.35; transform: scale(0.8); }
  50% { opacity: 1; transform: scale(1.15); }
}

/* shop fairy sprite */
.shop-fairy {
  position: absolute; left: 0; top: 0; width: 90px; z-index: 9;
  pointer-events: none;
  filter: drop-shadow(0 0 14px rgba(245, 200, 66, 0.75));
}
.shop-fairy img {
  width: 100%; display: block;
  animation: fairyBob 1.5s ease-in-out infinite;
}
@keyframes fairyBob {
  0%, 100% { translate: 0 0; rotate: -3deg; }
  50% { translate: 0 -9px; rotate: 3deg; }
}

/* golden pass image in certificate */
.cert-img {
  width: 100%; border-radius: 12px; margin-bottom: 1.2rem;
  box-shadow: 0 10px 34px rgba(0,0,0,0.5), 0 0 30px rgba(245,200,66,0.25);
}
.cert-card { max-width: 640px; }

nav ul { gap: 1.15rem; }
nav ul a { font-size: 0.92rem; }

@media (max-width: 700px) {
  .reader-panel { padding: 1rem 0.9rem 1.2rem; }
  .reader-lines p { font-size: 1.05rem; }
  .r-play { width: 52px; height: 52px; }
  .shop-grid { grid-template-columns: repeat(2, 1fr); gap: 0.9rem; }
}

/* ---------- intro splash ---------- */
.intro-splash { display: none; }
html.show-intro .intro-splash {
  display: flex; align-items: center; justify-content: center;
  position: fixed; inset: 0; z-index: 500; background: #000;
  opacity: 1; transition: opacity 0.9s ease;
}
html.show-intro { overflow: hidden; }
.intro-splash video {
  width: 100%; height: 100%; object-fit: contain; background: #000;
}
.intro-splash.leaving { opacity: 0; pointer-events: none; }
.intro-skip {
  position: absolute; bottom: 2rem; right: 2.2rem;
  background: rgba(255, 252, 234, 0.07); color: rgba(255, 252, 234, 0.75);
  border: 1px solid rgba(245, 200, 66, 0.35); border-radius: 999px;
  padding: 0.5rem 1.3rem; font-family: var(--serif-body); font-size: 0.95rem;
  letter-spacing: 0.06em; cursor: pointer; opacity: 0;
  animation: skipIn 0.8s ease 1.6s forwards;
  transition: background 0.25s, color 0.25s;
}
.intro-skip:hover { background: rgba(245, 200, 66, 0.18); color: var(--cream); }
@keyframes skipIn { to { opacity: 1; } }

/* ---------- deeper mobile pass ---------- */
@media (max-width: 700px) {
  section { padding: 4.2rem 1.1rem; }
  .section-head { margin-bottom: 2.2rem; }
  .hero-inner h1 { font-size: 2.55rem; }
  .hero-ctas { flex-direction: column; align-items: center; gap: 0.8rem; }
  .btn { padding: 0.8rem 1.8rem; font-size: 1rem; }
  .story-grid, .book-grid, .author-grid { gap: 2rem; }
  .book-cover { width: min(280px, 78vw); }
  .char-grid { grid-template-columns: repeat(2, 1fr); gap: 0.9rem; }
  .char-card .char-label h3 { font-size: 1rem; }
  .char-card .char-label p { font-size: 0.72rem; }
  .gallery { grid-auto-columns: minmax(200px, 240px); }
  .track .t-main { padding: 0.85rem 0.9rem; gap: 0.8rem; }
  .track .t-play { width: 44px; height: 44px; }
  .full-story-body { padding: 1.6rem 1.2rem 2rem; }
  .map-controls { right: 10px; bottom: 10px; }
  .map-controls button { width: 38px; height: 38px; }
  /* POI card becomes a bottom sheet on phones */
  .poi-card {
    position: fixed; left: 50% !important; top: auto !important;
    bottom: 14px; transform: translateX(-50%) !important;
    width: min(420px, calc(100vw - 28px)); z-index: 130;
    pointer-events: auto;
  }
  .poi { width: 30px; height: 30px; }
  .f-logo-video { width: 120px; height: 120px; }
  .footer .f-links { gap: 1rem; }
}

@media (prefers-reduced-motion: reduce) {
  .hero-bg, .scroll-hint, .book-cover, .char-card, .poi, .char-modal .cm-box { animation: none; }
  .fade-seq, .hero-inner h1 { animation: none; opacity: 1; transform: none;
    -webkit-text-fill-color: unset; background: none; }
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .door-overlay.on .door-art, .door-overlay.on .door-flash,
  .door-overlay.on .door-rays, .door-overlay.on .door-sparkles { animation: none; }
  #stardust { display: none; }
  nav#siteNav { transform: none; }
}

/* when the Golden Woodland Pass artwork is present, let it lead */
.cert-card.has-img .cert-stars,
.cert-card.has-img h3,
.cert-card.has-img .cert-sign { display: none; }
.cert-card.has-img .cert-body { font-size: 0.98rem; margin-bottom: 1.3rem; }

/* static scene title in the read-along (not part of narration timing) */
.r-title-static {
  font-size: 1.7em !important; letter-spacing: 0.04em;
  color: #ffe9a8 !important;
  text-shadow: 0 0 16px rgba(245, 200, 66, 0.7), 0 1px 3px rgba(0, 0, 0, 0.8) !important;
  margin-bottom: 0.5em !important;
}

/* toy box lights up when the fairy lands on it */
.shop-card.fairy-visit {
  border-color: rgba(245, 200, 66, 0.95);
  box-shadow:
    0 0 30px rgba(245, 200, 66, 0.7),
    0 0 85px rgba(245, 200, 66, 0.38),
    0 18px 44px rgba(0, 0, 0, 0.6);
  animation: cardGlow 1.1s ease-in-out infinite;
}

/* the storybook frame glows gold while the tale is being read */
.reader.playing {
  border-color: rgba(245, 200, 66, 0.9);
  box-shadow:
    0 0 30px rgba(245, 200, 66, 0.5),
    0 0 90px rgba(245, 200, 66, 0.26),
    0 24px 70px rgba(0, 0, 0, 0.6);
  animation: cardGlow 2.4s ease-in-out infinite;
}
@media (prefers-reduced-motion: reduce) {
  .shop-card.fairy-visit, .reader.playing { animation: none; }
}

/* fairy flutters harder while flying between boxes */
.shop-fairy.flying img { animation: fairyFlutter 0.28s ease-in-out infinite; }
@keyframes fairyFlutter {
  0%, 100% { translate: 0 0; rotate: 6deg; scale: 1 1; }
  50% { translate: 0 -5px; rotate: -2deg; scale: 1.04 0.97; }
}

/* kingdom fly-in player */
.flyin-overlay {
  position: fixed; inset: 0; z-index: 260; display: none;
  align-items: center; justify-content: center; padding: 1.5rem;
  background: rgba(5, 9, 17, 0.93);
}
.flyin-overlay.open { display: flex; }
.flyin-box { max-width: 960px; width: 100%; }
.flyin-box video {
  width: 100%; border-radius: 14px; background: #000;
  box-shadow: 0 0 60px rgba(245, 200, 66, 0.3), 0 30px 90px rgba(0,0,0,0.7);
  border: 1px solid rgba(245, 200, 66, 0.5);
}
.flyin-title {
  text-align: center; margin-top: 0.9rem;
  font-family: var(--serif-display); font-size: 1.3rem; color: #ffe9a8;
  text-shadow: 0 0 14px rgba(245, 200, 66, 0.5);
}
.poi.has-flyin::after {
  content: "▶"; position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  font-size: 8px; color: #241703; opacity: 0.85;
}

/* flying-loop fairy (transparent video) */
.shop-fairy video { width: 100%; display: none; }
.shop-fairy.video-fairy video { display: block; }
.shop-fairy.video-fairy img { display: none; }
.shop-fairy.video-fairy { width: 120px; }


/* ---- embedded kingdom scene: video comes alive in place, on the map plane ---- */
.map-scene {
  position: absolute; left: 0; top: 0; width: 40%;
  aspect-ratio: 16 / 9; z-index: 6;
  transform: scale(0.02); transform-origin: 50% 50%;
  opacity: 0; visibility: hidden; pointer-events: none;
  border-radius: 10px; overflow: hidden;
  box-shadow: 0 0 0 2px rgba(245,200,66,0.7), 0 0 24px 5px rgba(245,200,66,0.45), 0 12px 36px rgba(0,0,0,0.6);
  transition: transform 0.55s cubic-bezier(.19,.9,.24,1), opacity 0.4s ease, visibility 0s linear 0.55s;
}
.map-scene.open {
  transform: scale(1); opacity: 1; visibility: visible; pointer-events: auto;
  transition: transform 0.55s cubic-bezier(.19,.9,.24,1), opacity 0.4s ease, visibility 0s;
}
.scene-video { width: 100%; height: 100%; object-fit: cover; display: block; background: #05070d; }
.scene-title {
  position: absolute; left: 0; right: 0; bottom: 0; margin: 0;
  padding: 0.65rem 0.6rem 0.42rem; text-align: center; pointer-events: none;
  font-family: var(--serif-display); color: #ffe9a8;
  font-size: clamp(0.6rem, 2.4cqw, 1.05rem);
  text-shadow: 0 2px 8px rgba(0,0,0,0.9);
  background: linear-gradient(to top, rgba(4,7,14,0.82), transparent);
}
.scene-close {
  position: absolute; top: 5%; right: 4%; z-index: 2;
  width: 9%; min-width: 20px; max-width: 32px; aspect-ratio: 1; padding: 0;
  border-radius: 50%; border: 1px solid rgba(245,200,66,0.55);
  background: rgba(8,14,26,0.78); color: var(--gold);
  font-size: 0.95rem; line-height: 1; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: background 0.2s, transform 0.2s;
}
.scene-close:hover { background: rgba(245,200,66,0.28); transform: scale(1.1); }
.map-scene { container-type: inline-size; }
@media (prefers-reduced-motion: reduce) {
  .map-scene { transition: opacity 0.3s ease, visibility 0s; }
  .map-scene.open { transform: scale(1); }
  .map-scene:not(.open) { transform: scale(1); }
}

/* ============================================================
   v50 · The book is ready: final art, trailer, tale theatre,
   Map of the Realm, the Oak Promise, the Reader's Door
   ============================================================ */

/* hero ribbon */
.hero-ribbon {
  display: inline-block; margin-bottom: 1.3rem; padding: 0.42rem 1.5rem;
  border: 1px solid rgba(245, 200, 66, 0.6); border-radius: 999px;
  background: rgba(11, 20, 36, 0.55); backdrop-filter: blur(4px);
  font-family: var(--serif-display); font-size: clamp(0.82rem, 1.7vw, 1rem);
  letter-spacing: 0.22em; text-transform: uppercase; color: #ffe9a8;
  box-shadow: 0 0 26px rgba(245, 200, 66, 0.25);
}
.hero-ribbon span { color: var(--gold); animation: ribbonTwinkle 2.4s ease-in-out infinite; display: inline-block; }
.hero-ribbon span:last-child { animation-delay: -1.2s; }
@keyframes ribbonTwinkle { 0%,100% { opacity: 0.45; transform: scale(0.85); } 50% { opacity: 1; transform: scale(1.2); } }
.hero-inner .hero-ribbon.fade-seq { animation-delay: 0.05s; }

/* ---------- trailer ---------- */
#trailer {
  background:
    radial-gradient(ellipse at 50% 0%, rgba(245, 200, 66, 0.1), transparent 55%),
    linear-gradient(var(--night), var(--night-2));
}
.trailer-stage {
  position: relative; max-width: 1040px; margin: 0 auto; aspect-ratio: 16 / 9;
  border-radius: 18px; overflow: hidden; background: #000;
  border: 1px solid rgba(245, 200, 66, 0.55);
  box-shadow: 0 0 60px rgba(245, 200, 66, 0.22), 0 30px 90px rgba(0, 0, 0, 0.7);
  z-index: 3; transition: box-shadow 0.8s ease, transform 0.8s ease;
}
.trailer-stage.portrait { aspect-ratio: 9 / 16; max-width: min(420px, 92vw); }
.trailer-stage video { width: 100%; height: 100%; object-fit: cover; display: block; background: #000; }
.trailer-play {
  position: absolute; inset: 0; width: 100%; border: none; cursor: pointer;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1rem;
  background: radial-gradient(ellipse at 50% 50%, rgba(11,20,36,0.15), rgba(11,20,36,0.72));
  transition: opacity 0.5s ease;
}
.trailer-play span {
  width: 104px; height: 104px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center; padding-left: 8px;
  font-size: 2.6rem; color: #241703;
  background: linear-gradient(160deg, #f8d565, var(--amber));
  box-shadow: 0 0 0 0 rgba(245, 200, 66, 0.6), 0 8px 40px rgba(232, 160, 32, 0.6);
  animation: trailerPulse 2.2s ease-out infinite;
  transition: transform 0.25s;
}
.trailer-play:hover span { transform: scale(1.08); }
.trailer-play em {
  font-family: var(--serif-display); font-style: normal; letter-spacing: 0.3em; text-transform: uppercase;
  font-size: 0.95rem; color: #ffe9a8; text-shadow: 0 2px 12px rgba(0,0,0,0.9);
}
@keyframes trailerPulse {
  0% { box-shadow: 0 0 0 0 rgba(245,200,66,0.6), 0 8px 40px rgba(232,160,32,0.6); }
  100% { box-shadow: 0 0 0 34px rgba(245,200,66,0), 0 8px 40px rgba(232,160,32,0.6); }
}
.trailer-stage.playing .trailer-play { opacity: 0; pointer-events: none; }
.trailer-missing {
  position: absolute; left: 0; right: 0; bottom: 0; padding: 0.9rem 1.2rem; text-align: center;
  background: rgba(11, 20, 36, 0.9); color: #ffe9a8; font-style: italic; font-size: 0.95rem;
}
.lights-veil {
  position: fixed; inset: 0; z-index: 90; background: rgba(2, 4, 9, 0.9);
  opacity: 0; pointer-events: none; transition: opacity 1.1s ease;
}
body.lights-down .lights-veil { opacity: 1; }
body.lights-down #trailer { z-index: 95; }
body.lights-down #trailer .section-head, body.lights-down #trailer .gallery-note { opacity: 0.25; transition: opacity 1s; }
body.lights-down .trailer-stage {
  box-shadow: 0 0 120px rgba(245, 200, 66, 0.4), 0 40px 120px rgba(0, 0, 0, 0.9);
  transform: scale(1.03);
}
body.lights-down nav#siteNav, body.lights-down #bedtimeToggle { opacity: 0; pointer-events: none; transition: opacity 0.6s; }

/* ---------- day and night ---------- */
.daynight {
  position: relative; aspect-ratio: 3 / 4; border-radius: 16px; overflow: hidden; cursor: pointer;
  box-shadow: 0 18px 60px rgba(0,0,0,0.6), 0 0 0 1px rgba(245,200,66,0.22);
}
.dn-layer {
  position: absolute; inset: 0;
  background-image: url("../img/realm/day-and-night.jpg");
  background-size: 200% 100%; background-repeat: no-repeat;
  transition: opacity 2.2s ease, transform 9s ease;
}
.dn-day { background-position: 0% 50%; }
.dn-night { background-position: 100% 50%; opacity: 0; transform: scale(1.06); }
.daynight.night .dn-night { opacity: 1; transform: scale(1); }
.daynight.night { box-shadow: 0 18px 60px rgba(0,0,0,0.6), 0 0 70px rgba(245,200,66,0.35), 0 0 0 1px rgba(245,200,66,0.6); }
.dn-toggle {
  position: absolute; right: 14px; bottom: 14px; width: 56px; height: 56px; border-radius: 50%;
  border: 1px solid rgba(245, 200, 66, 0.8); cursor: pointer;
  background: rgba(11, 20, 36, 0.78); color: #ffe9a8; font-size: 1.5rem;
  box-shadow: 0 0 22px rgba(245, 200, 66, 0.45);
  animation: poiPulse 2.6s ease-in-out infinite;
}
.dn-toggle .dn-sun { display: none; }
.daynight.night .dn-toggle .dn-sun { display: inline; }
.daynight.night .dn-toggle .dn-moon { display: none; }

/* ---------- Map of the Realm ---------- */
.poi.poi-tale {
  width: 34px; height: 34px;
  font-family: var(--serif-display); font-weight: 600; font-size: 17px; line-height: 1; color: #241703;
  background: radial-gradient(circle at 35% 30%, #fff6cf 0%, #f8d565 38%, var(--amber) 100%);
  border: 2px solid rgba(255, 246, 207, 0.9);
  display: flex; align-items: center; justify-content: center;
}
.poi-card .poi-hint { display: none; margin-top: 0.45rem; font-size: 0.8rem; font-style: italic; color: var(--gold); }
.poi-card.is-tale .poi-hint { display: block; }
.book-note { margin-top: 1rem; font-size: 0.9rem; font-style: italic; color: var(--moon); }

/* ---------- tale cards with final art ---------- */
.tale-card { padding: 0; cursor: pointer; display: flex; flex-direction: column; text-align: left; color: inherit; font: inherit; }
.tale-card:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; }
.tale-thumb { position: relative; display: block; overflow: hidden; aspect-ratio: 3 / 2; }
.tale-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform 5s ease; transform: scale(1.03); }
.tale-card:hover .tale-thumb img { transform: scale(1.16) translate(-1.5%, -1%); }
.tale-thumb::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(rgba(11,20,36,0) 45%, rgba(11,20,36,0.85));
}
.tale-open {
  position: absolute; left: 50%; bottom: 0.8rem; translate: -50% 10px; z-index: 2; white-space: nowrap;
  padding: 0.3rem 1.1rem; border-radius: 999px; border: 1px solid rgba(245,200,66,0.8);
  background: rgba(11,20,36,0.8); color: #ffe9a8; font-family: var(--serif-display); letter-spacing: 0.08em; font-size: 0.9rem;
  opacity: 0; transition: opacity 0.35s, translate 0.35s;
}
.tale-card:hover .tale-open, .tale-card:focus-visible .tale-open { opacity: 1; translate: -50% 0; }
.tale-body { display: block; padding: 1.1rem 1.4rem 1.4rem; position: relative; }
.tale-card .num { display: block; font-size: 2.1rem; margin-bottom: 0.25rem; color: rgba(245, 200, 66, 0.55); }
.tale-card .tale-p { display: block; font-size: 0.96rem; color: var(--cream-dim); line-height: 1.5; }
.tale-card .tale-moral { display: block; margin-top: 0.7rem; font-size: 0.86rem; font-style: italic; color: var(--gold); }

/* ---------- tale theatre ---------- */
.tale-theatre {
  position: fixed; inset: 0; z-index: 230; display: none;
  align-items: center; justify-content: center; padding: 1.2rem;
  background: rgba(4, 7, 14, 0.95);
}
.tale-theatre.open { display: flex; animation: ttIn 0.5s ease; }
@keyframes ttIn { from { opacity: 0; } to { opacity: 1; } }
.tale-theatre .lb-close { position: absolute; top: 14px; right: 18px; z-index: 5; }
.tt-box { width: min(1180px, 100%); max-height: 96vh; display: flex; flex-direction: column; gap: 0.9rem; }
.tt-stage {
  position: relative; width: 100%; aspect-ratio: 2400 / 1612; max-height: 72vh; margin: 0 auto;
  border-radius: 16px; overflow: hidden; background: #000;
  border: 1px solid rgba(245, 200, 66, 0.55);
  box-shadow: 0 0 80px rgba(245, 200, 66, 0.25), 0 30px 90px rgba(0, 0, 0, 0.8);
}
.tt-img {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
  opacity: 0; transition: opacity 1.1s ease;
}
.tt-img.show { opacity: 1; animation: ttBurns 9s ease-out forwards; }
.tt-img.show.alt { animation-name: ttBurnsAlt; }
@keyframes ttBurns { from { transform: scale(1.0) translate(0, 0); } to { transform: scale(1.12) translate(-2%, -1.5%); } }
@keyframes ttBurnsAlt { from { transform: scale(1.12) translate(2%, 1%); } to { transform: scale(1.0) translate(0, 0); } }
.tt-caption {
  position: absolute; left: 0; right: 0; bottom: 0; margin: 0; padding: 2.6rem 4.5rem 2.2rem; text-align: center;
  font-family: var(--serif-display); font-size: clamp(1rem, 2vw, 1.4rem); color: #fff6cf;
  background: linear-gradient(rgba(4,7,14,0), rgba(4,7,14,0.88));
  text-shadow: 0 2px 10px rgba(0,0,0,0.9);
}
.tt-dots { position: absolute; left: 0; right: 0; bottom: 0.7rem; display: flex; gap: 8px; justify-content: center; }
.tt-dots button {
  width: 11px; height: 11px; border-radius: 50%; border: 1px solid rgba(245,200,66,0.7);
  background: transparent; cursor: pointer; padding: 0;
}
.tt-dots button.active { background: var(--gold); box-shadow: 0 0 10px rgba(245,200,66,0.8); }
.tt-arrow {
  position: absolute; top: 50%; translate: 0 -50%; z-index: 3;
  width: 52px; height: 52px; border-radius: 50%; cursor: pointer;
  border: 1px solid rgba(245,200,66,0.6); background: rgba(11,20,36,0.6); color: #ffe9a8; font-size: 1.8rem;
  transition: background 0.2s, scale 0.2s;
}
.tt-arrow:hover { background: rgba(245,200,66,0.25); scale: 1.08; }
.tt-prev { left: 12px; } .tt-next { right: 12px; }
.tt-info { text-align: center; }
.tt-num { font-family: var(--serif-display); letter-spacing: 0.3em; text-transform: uppercase; font-size: 0.8rem; color: var(--gold); }
.tt-info h3 { font-size: clamp(1.5rem, 3.2vw, 2.3rem); color: var(--cream); line-height: 1.15; }
.tt-verse { font-family: var(--serif-display); font-style: italic; font-size: clamp(0.98rem, 1.8vw, 1.18rem); color: #ffe9a8; margin-top: 0.3rem; line-height: 1.4; }
.tt-moral { font-size: 0.9rem; color: var(--moon); margin-top: 0.25rem; }
.tt-nav { display: flex; gap: 1.6rem; justify-content: center; align-items: center; margin-top: 0.6rem; flex-wrap: wrap; }
.tt-nav .btn { padding: 0.5rem 1.5rem; font-size: 0.95rem; }

/* ---------- read-along with final layout ---------- */
.reader { max-width: 1120px; }
.r-block p { line-height: 1.42; margin: 0 0 0.1em; }
.r-block .r-word, .reader-lines .r-word { color: rgba(255, 252, 234, 0.72); text-shadow: 0 0 6px rgba(0,0,0,0.9), 0 1px 3px rgba(0,0,0,0.95), 0 0 14px rgba(0,0,0,0.6); }
.r-word.lit { color: #ffe9a8; text-shadow: 0 0 14px rgba(245, 200, 66, 0.85), 0 1px 3px rgba(0, 0, 0, 0.9); }
.r-voice {
  margin-left: 0.4rem; padding: 0.42rem 1rem; border-radius: 999px; cursor: pointer;
  border: 1px solid rgba(176,196,216,0.45); background: rgba(255,252,234,0.05);
  color: var(--moon); font-family: var(--serif-body); font-size: 0.88rem;
}
.r-voice[aria-pressed="true"] { border-color: rgba(245,200,66,0.8); color: #ffe9a8; background: rgba(245,200,66,0.12); }

/* ---------- characters: Book Two visitors ---------- */
.char-card.char-book2::before {
  content: "Book Two"; position: absolute; top: 10px; left: 10px; z-index: 4;
  padding: 0.16rem 0.7rem; border-radius: 999px;
  background: linear-gradient(160deg, #f8d565, var(--amber)); color: #241703;
  font-family: var(--serif-display); font-weight: 600; font-size: 0.74rem; letter-spacing: 0.12em; text-transform: uppercase;
  box-shadow: 0 0 16px rgba(245,200,66,0.6);
}

/* ---------- Queen Titania's message ---------- */
#message {
  background:
    radial-gradient(ellipse at 20% 20%, rgba(245, 200, 66, 0.08), transparent 55%),
    linear-gradient(var(--night), #0d1a33 55%, var(--night));
}
.message-grid { display: grid; grid-template-columns: 0.8fr 1.2fr; gap: 3.2rem; align-items: center; max-width: 1000px; margin: 0 auto; }
.message-art img {
  border-radius: 16px; width: 100%;
  box-shadow: 0 18px 60px rgba(0,0,0,0.6), 0 0 70px rgba(245,200,66,0.18), 0 0 0 1px rgba(245,200,66,0.35);
}
.message-scroll { position: relative; filter: drop-shadow(0 20px 40px rgba(0,0,0,0.55)); }
.scroll-rod {
  height: 22px; margin: 0 -14px; border-radius: 11px;
  background: linear-gradient(#f7dd8a, #c8912a 55%, #8a5d12);
  box-shadow: inset 0 2px 3px rgba(255,255,255,0.5);
  position: relative; z-index: 2;
}
.scroll-paper {
  background:
    radial-gradient(ellipse at 50% 0%, rgba(255,255,255,0.5), transparent 60%),
    linear-gradient(#f9ecc4, #f1dca0 60%, #ead08d);
  padding: 2.4rem 2rem 2rem; text-align: center; margin: -4px 0;
  max-height: 0; overflow: hidden; padding-top: 0; padding-bottom: 0;
  transition: max-height 2.2s cubic-bezier(.3,.8,.3,1), padding 2.2s cubic-bezier(.3,.8,.3,1);
}
.message-scroll.visible .scroll-paper { max-height: 640px; padding-top: 2.4rem; padding-bottom: 2rem; }
.ms-line {
  font-family: var(--serif-display); font-style: italic; font-weight: 500;
  font-size: clamp(1.2rem, 2.4vw, 1.62rem); line-height: 1.5; color: #4a3210;
  opacity: 0; transform: translateY(10px); transition: opacity 1s ease, transform 1s ease;
}
.ms-gap { margin-top: 1.1rem; }
.message-scroll.visible .ms-line { opacity: 1; transform: none; }
.message-scroll.visible .ms-line:nth-child(1) { transition-delay: 1.3s; }
.message-scroll.visible .ms-line:nth-child(2) { transition-delay: 2.1s; }
.message-scroll.visible .ms-line:nth-child(3) { transition-delay: 2.9s; }
.message-scroll.visible .ms-line:nth-child(4) { transition-delay: 3.7s; }
.message-scroll.visible .ms-line:nth-child(5) { transition-delay: 4.7s; }
.message-scroll.visible .ms-line:nth-child(6) { transition-delay: 5.5s; }
.message-scroll.visible .ms-line:nth-child(7) { transition-delay: 6.3s; }
.message-scroll.visible .ms-line:nth-child(8) { transition-delay: 7.1s; }
.ms-sign {
  margin-top: 1.2rem; font-family: var(--serif-display); font-style: italic; font-size: 1.5rem; color: #8a5d12;
  opacity: 0; transition: opacity 1.4s ease 8.2s;
}
.message-scroll.visible .ms-sign { opacity: 1; }

/* the Oak Promise */
.oath {
  max-width: 820px; margin: 4.5rem auto 0; padding: 2.6rem 2rem 2.4rem; text-align: center;
  border-radius: 22px; border: 1px solid rgba(245, 200, 66, 0.45);
  background:
    radial-gradient(ellipse at 50% 0%, rgba(245, 200, 66, 0.14), transparent 65%),
    linear-gradient(160deg, rgba(22,38,63,0.95), rgba(11,20,36,0.95));
  box-shadow: 0 0 60px rgba(245,200,66,0.12), 0 24px 70px rgba(0,0,0,0.55);
}
.oath-kicker { font-family: var(--serif-display); letter-spacing: 0.3em; text-transform: uppercase; font-size: 0.82rem; color: var(--gold); }
.oath h3 { font-size: clamp(1.7rem, 3.6vw, 2.5rem); color: var(--cream); margin: 0.3rem 0 0.6rem; }
.oath-sub { color: var(--cream-dim); max-width: 560px; margin: 0 auto 1.5rem; }
.oath-form { display: flex; gap: 0.7rem; justify-content: center; flex-wrap: wrap; }
.oath-form input, .oath-form select {
  font-family: var(--serif-body); font-size: 1.05rem; padding: 0.8rem 1.2rem; border-radius: 999px;
  border: 1px solid rgba(245, 200, 66, 0.45); background: rgba(11, 20, 36, 0.7); color: var(--cream); outline: none;
  min-width: 190px;
}
.oath-form select option { background: #101d33; color: var(--cream); }
.oath-form input:focus, .oath-form select:focus { border-color: var(--gold); box-shadow: 0 0 18px rgba(245,200,66,0.25); }
.oath-private { margin-top: 0.9rem; font-size: 0.84rem; font-style: italic; color: var(--moon); }
.oath-result { margin-top: 1.8rem; animation: ttIn 1.2s ease; }
.oath-known { color: var(--moon); font-style: italic; }
.oath-elfin {
  font-family: var(--serif-display); font-weight: 600; font-size: clamp(2.2rem, 6vw, 3.8rem); line-height: 1.1;
  background: linear-gradient(100deg, #f8d565 20%, #fff6cf 50%, #e8a020 80%); -webkit-background-clip: text; background-clip: text; color: transparent;
  filter: drop-shadow(0 0 22px rgba(245,200,66,0.45));
  animation: elfinIn 1.6s cubic-bezier(.2,.9,.3,1);
}
@keyframes elfinIn { from { opacity: 0; letter-spacing: 0.4em; transform: scale(0.8); } to { opacity: 1; letter-spacing: normal; transform: none; } }
.oath-folk { color: #ffe9a8; font-family: var(--serif-display); font-size: 1.15rem; letter-spacing: 0.08em; margin-bottom: 1.4rem; }
#oathCanvas { width: min(420px, 100%); height: auto; border-radius: 10px; box-shadow: 0 0 50px rgba(245,200,66,0.3), 0 20px 60px rgba(0,0,0,0.6); }
.oath-btns { margin-top: 1.3rem; display: flex; gap: 1.4rem; justify-content: center; align-items: center; flex-wrap: wrap; }

/* ---------- legacy interlude ---------- */
#legacy { padding: 9rem 1.5rem; overflow: hidden; text-align: center; }
.legacy-bg {
  position: absolute; inset: -6% 0; background: url("../img/realm/oak-path.jpg") center / cover no-repeat;
  animation: heroDrift 26s ease-in-out infinite alternate;
}
#legacy::after {
  content: ""; position: absolute; inset: 0; z-index: 1;
  background:
    radial-gradient(ellipse at 50% 50%, rgba(11,20,36,0.55), rgba(11,20,36,0.86)),
    linear-gradient(var(--night-2), rgba(11,20,36,0) 18%, rgba(11,20,36,0) 82%, var(--night));
}
.legacy-wrap { max-width: 760px; }
.legacy-wrap .kicker { display: block; font-family: var(--serif-display); letter-spacing: 0.34em; text-transform: uppercase; font-size: 0.85rem; color: var(--gold); margin-bottom: 1.6rem; }
.legacy-line { font-family: var(--serif-display); font-size: clamp(1.2rem, 2.6vw, 1.7rem); line-height: 1.5; color: var(--cream); margin-bottom: 1.1rem; text-shadow: 0 2px 16px rgba(0,0,0,0.9); }
.legacy-strong { font-style: italic; color: #ffe9a8; font-size: clamp(1.5rem, 3.4vw, 2.3rem); text-shadow: 0 0 30px rgba(245,200,66,0.45), 0 2px 16px rgba(0,0,0,0.9); }
.legacy-line.reveal { transition-duration: 1.6s; }

/* ---------- the Reader's Door ---------- */
#secret { background: linear-gradient(var(--night), #0a1020 50%, var(--night-2)); }
.secret-grid { display: grid; grid-template-columns: 0.72fr 1.28fr; gap: 3rem; align-items: center; max-width: 1000px; margin: 0 auto; }
.secret-door {
  position: relative; border-radius: 16px; overflow: hidden;
  box-shadow: 0 18px 60px rgba(0,0,0,0.7), 0 0 0 1px rgba(245,200,66,0.25);
  transition: box-shadow 1.4s ease;
}
.secret-door img { width: 100%; filter: brightness(0.42) saturate(0.6); transition: filter 2.4s ease, transform 8s ease; }
.secret-lock {
  position: absolute; left: 50%; top: 50%; translate: -50% -50%;
  width: 84px; height: 84px; border-radius: 50%; display: flex; align-items: center; justify-content: center;
  font-size: 2rem; background: rgba(11,20,36,0.8); border: 1px solid rgba(245,200,66,0.7);
  box-shadow: 0 0 30px rgba(245,200,66,0.35); transition: opacity 1s ease, scale 1s ease;
}
.secret-grid.open .secret-door { box-shadow: 0 0 90px rgba(245,200,66,0.5), 0 18px 60px rgba(0,0,0,0.7), 0 0 0 1px rgba(245,200,66,0.8); }
.secret-grid.open .secret-door img { filter: none; transform: scale(1.08); }
.secret-grid.open .secret-lock { opacity: 0; scale: 2; }
.riddle { margin-bottom: 1.5rem; }
.riddle-q { font-family: var(--serif-display); font-size: 1.3rem; color: var(--cream); margin-bottom: 0.6rem; }
.riddle-q span { display: inline-block; min-width: 2.2rem; color: var(--gold); font-weight: 600; }
.riddle-opts { display: flex; flex-wrap: wrap; gap: 0.6rem; }
.riddle-opts button {
  padding: 0.5rem 1.1rem; border-radius: 999px; cursor: pointer;
  border: 1px solid rgba(176,196,216,0.4); background: rgba(255,252,234,0.05);
  color: var(--cream-dim); font-family: var(--serif-body); font-size: 0.98rem;
  transition: background 0.25s, border-color 0.25s, color 0.25s, transform 0.2s;
}
.riddle-opts button:hover { border-color: rgba(245,200,66,0.7); color: var(--cream); transform: translateY(-2px); }
.riddle-opts button.right { background: linear-gradient(160deg, #f8d565, var(--amber)); color: #241703; border-color: #f8d565; font-weight: 600; box-shadow: 0 0 22px rgba(245,200,66,0.5); }
.riddle-opts button.wrong { animation: riddleShake 0.45s ease; border-color: rgba(214, 96, 96, 0.8); color: rgba(255,200,200,0.9); }
@keyframes riddleShake { 20% { translate: -6px 0; } 40% { translate: 6px 0; } 60% { translate: -4px 0; } 80% { translate: 4px 0; } }
.riddle.solved .riddle-opts button:not(.right) { opacity: 0.35; pointer-events: none; }
.riddle-status { font-style: italic; color: var(--moon); }
.secret-reveal { animation: ttIn 1.6s ease; }
.secret-seal { font-family: var(--serif-display); letter-spacing: 0.3em; text-transform: uppercase; font-size: 0.85rem; color: var(--gold); }
.secret-reveal h3 { font-size: 2rem; color: var(--cream); margin: 0.2rem 0 0.8rem; }
.secret-reveal p { color: var(--cream-dim); margin-bottom: 1rem; }
.secret-verse { font-family: var(--serif-display); font-style: italic; font-size: 1.2rem; line-height: 1.6; color: #ffe9a8 !important; }
.secret-whisper { font-style: italic; color: var(--moon) !important; }

footer .f-tag { font-style: italic; color: var(--moon); font-size: 0.98rem; margin-top: 0.2rem; }

/* ---------- v50 mobile ---------- */
@media (max-width: 900px) {
  .message-grid, .secret-grid { grid-template-columns: 1fr; gap: 2rem; }
  .message-art, .secret-door { max-width: 360px; margin: 0 auto; }
  .daynight { aspect-ratio: 1 / 1; }
}
@media (max-width: 640px) {
  .hero-ribbon { letter-spacing: 0.12em; padding: 0.4rem 1rem; }
  .trailer-play span { width: 78px; height: 78px; font-size: 2rem; }
  .poi.poi-tale { width: 30px; height: 30px; font-size: 14px; }
  .tale-theatre { padding: 0.5rem; }
  .tt-caption { padding: 2rem 1rem 1.9rem; font-size: 0.95rem; }
  .tt-arrow { width: 40px; height: 40px; font-size: 1.4rem; top: 38%; }
  .tt-nav { gap: 0.9rem; }
  .oath { padding: 2rem 1.1rem; margin-top: 3rem; }
  .oath-form input, .oath-form select { width: 100%; }
  #legacy { padding: 6rem 1.2rem; }
  .r-voice { font-size: 0.78rem; padding: 0.35rem 0.7rem; }
  .scroll-paper { padding-left: 1.1rem; padding-right: 1.1rem; }
}
@media (prefers-reduced-motion: reduce) {
  .tt-img.show, .legacy-bg, .trailer-play span, .hero-ribbon span, .dn-toggle { animation: none; }
  .ms-line, .ms-sign { transition: none; opacity: 1; transform: none; }
  .scroll-paper { transition: none; }
}

/* peek inside: landscape spreads from the final book */
.gallery { grid-auto-columns: minmax(340px, 460px); }
.gallery figure img { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; }
@media (max-width: 640px) { .gallery { grid-auto-columns: minmax(270px, 84vw); } }
[hidden] { display: none !important; }

/* ============================================================
   v60 · THE REDESIGN
   A cinematic journey through the Realm: trailer-cut hero,
   illustrated backdrops, chapter gates, gilded frames
   ============================================================ */
:root {
  --caps: "Cinzel", "Cormorant Garamond", Georgia, serif;
  --gilt: linear-gradient(100deg, #b8862b 0%, #f8d565 28%, #fff6cf 50%, #f5c842 72%, #b8862b 100%);
  --ink: #070c18;
}
body { background: var(--ink); }
section { padding: 8rem 1.5rem; isolation: isolate; }
::-webkit-scrollbar { width: 11px; }
::-webkit-scrollbar-track { background: #070c18; }
::-webkit-scrollbar-thumb { background: linear-gradient(#b8862b, #f5c842, #b8862b); border-radius: 8px; border: 2px solid #070c18; }

/* the golden thread: scroll progress */
.thread { position: fixed; top: 0; left: 0; height: 3px; width: 100%; z-index: 150; transform-origin: 0 50%; transform: scaleX(0);
  background: var(--gilt); box-shadow: 0 0 14px rgba(245,200,66,0.8); pointer-events: none; }

/* chapter rail */
.chapter-rail { position: fixed; right: 18px; top: 50%; translate: 0 -50%; z-index: 120; display: flex; flex-direction: column; gap: 13px;
  background: none; border: none; padding: 0; left: auto; opacity: 0; transition: opacity 0.6s; pointer-events: none; }
.chapter-rail.show { opacity: 1; pointer-events: auto; }
.chapter-rail a { position: relative; width: 11px; height: 11px; border-radius: 50%; border: 1px solid rgba(245,200,66,0.65); background: rgba(7,12,24,0.6);
  transition: background 0.3s, scale 0.3s, box-shadow 0.3s; display: block; }
.chapter-rail a span { position: absolute; right: 22px; top: 50%; translate: 8px -50%; white-space: nowrap; pointer-events: none;
  font-family: var(--caps); font-size: 0.68rem; letter-spacing: 0.2em; text-transform: uppercase; color: #ffe9a8;
  background: rgba(7,12,24,0.88); border: 1px solid rgba(245,200,66,0.4); padding: 0.28rem 0.7rem; border-radius: 999px;
  opacity: 0; transition: opacity 0.25s, translate 0.25s; }
.chapter-rail a:hover span { opacity: 1; translate: 0 -50%; }
.chapter-rail a:hover { scale: 1.3; }
.chapter-rail a.active { background: var(--gold); scale: 1.35; box-shadow: 0 0 14px rgba(245,200,66,0.9); }
body.lights-down .chapter-rail, body.lights-down .thread { opacity: 0; }
@media (max-width: 1100px) { .chapter-rail { display: none; } }

/* navigation: glass and small caps */
nav#siteNav { background: linear-gradient(rgba(7,12,24,0.92), rgba(7,12,24,0.72)); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(245,200,66,0.22); padding: 0.55rem 1.6rem; }
nav .brand span { font-family: var(--caps); letter-spacing: 0.16em; font-size: 0.98rem; text-transform: uppercase; }
nav ul { gap: 1.35rem; align-items: center; }
nav ul a { font-family: var(--caps); font-size: 0.7rem; letter-spacing: 0.17em; text-transform: uppercase; }
nav ul a.nav-cta { color: #241703; background: var(--gilt); background-size: 200% 100%; padding: 0.42rem 1rem; border-radius: 999px; border: none;
  font-weight: 600; box-shadow: 0 0 18px rgba(245,200,66,0.35); animation: giltSlide 5s linear infinite; }
nav ul a.nav-cta:hover { color: #241703; box-shadow: 0 0 26px rgba(245,200,66,0.7); }
@keyframes giltSlide { to { background-position: -200% 0; } }

/* ---------- hero: cut from the trailer ---------- */
header.hero.hero-cine { min-height: 100svh; padding: 6rem 1.5rem 7rem; justify-content: flex-end; }
.hero-cine .hero-bg { background: url("../img/realm/trailer-poster.jpg") center / cover no-repeat; animation: none; transform: none; }
.hero-cine .hero-video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.hero-cine .hero-veil {
  background:
    radial-gradient(ellipse at 50% 38%, rgba(7,12,24,0) 0%, rgba(7,12,24,0.35) 55%, rgba(7,12,24,0.9) 100%),
    linear-gradient(rgba(7,12,24,0.55) 0%, rgba(7,12,24,0.05) 26%, rgba(7,12,24,0.25) 55%, rgba(7,12,24,0.94) 88%, var(--ink) 100%);
}
.hero-cine .hero-inner { max-width: 980px; }
.hero-cine .hero-inner h1 {
  font-size: clamp(3.6rem, 12vw, 9.5rem); line-height: 0.92; letter-spacing: 0.01em; font-weight: 600;
  background: var(--gilt); background-size: 220% 100%; -webkit-background-clip: text; background-clip: text; color: transparent;
  filter: drop-shadow(0 6px 30px rgba(0,0,0,0.85)) drop-shadow(0 0 40px rgba(245,200,66,0.28));
  animation: seqIn 1.1s ease forwards, giltSlide 9s linear infinite; animation-delay: 0.25s, 0s;
  text-shadow: none;
}
.hero-cine .hero-inner h1 small { display: block; font-size: 0.3em; letter-spacing: 0.32em; text-transform: uppercase; font-family: var(--caps); font-weight: 400; margin-bottom: 0.55em; }
.hero-cine .hero-inner .subtitle { max-width: 720px; margin-left: auto; margin-right: auto; color: #e8edf5; font-size: clamp(1.05rem, 2.1vw, 1.38rem); text-shadow: 0 2px 16px rgba(0,0,0,0.95); }
.hero-cine .hero-inner .byline { font-family: var(--caps); letter-spacing: 0.4em; font-size: 0.78rem; }
.hero-ribbon { font-family: var(--caps); font-size: clamp(0.66rem, 1.4vw, 0.82rem); letter-spacing: 0.3em; }
.hero-cine .scroll-hint { bottom: 1.4rem; display: flex; flex-direction: column; align-items: center; gap: 0.2rem; font-size: 1.3rem; color: #ffe9a8; }
.hero-cine .scroll-hint span { font-family: var(--caps); font-size: 0.62rem; letter-spacing: 0.34em; text-transform: uppercase; opacity: 0.85; }
.btn { font-family: var(--caps); font-size: 0.84rem; letter-spacing: 0.2em; text-transform: uppercase; padding: 1rem 2.3rem; }
.btn-gold { background: var(--gilt); background-size: 200% 100%; animation: giltSlide 6s linear infinite; border-color: #fff0b8; }
.btn-ghost { background: rgba(7,12,24,0.45); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); }

/* ---------- section heads: gilded titles with a flourish ---------- */
.section-head { margin-bottom: 3.6rem; }
.section-head .kicker, .oath-kicker, .secret-seal, .tt-num, .legacy-wrap .kicker, .ft-label { font-family: var(--caps) !important; letter-spacing: 0.38em; font-size: 0.74rem; }
.section-head h2 {
  font-size: clamp(2.4rem, 5.6vw, 4.2rem); line-height: 1.06; font-weight: 600;
  background: linear-gradient(180deg, #fffcea 20%, #f3d98a 78%, #c99a35 100%); -webkit-background-clip: text; background-clip: text; color: transparent;
  filter: drop-shadow(0 4px 18px rgba(0,0,0,0.6));
}
.section-head h2::after {
  content: ""; display: block; width: min(300px, 62vw); height: 22px; margin: 1.1rem auto 0;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 300 22'%3E%3Cg fill='none' stroke='%23f5c842' stroke-width='1.2'%3E%3Cpath d='M4 11h112M184 11h112'/%3E%3Cpath d='M150 2l9 9-9 9-9-9z' fill='%23f5c842'/%3E%3Cpath d='M128 11l6-5 6 5-6 5zM160 11l6-5 6 5-6 5z'/%3E%3Ccircle cx='4' cy='11' r='2' fill='%23f5c842'/%3E%3Ccircle cx='296' cy='11' r='2' fill='%23f5c842'/%3E%3C/g%3E%3C/svg%3E") center / contain no-repeat;
  opacity: 0.9;
}
.kingdom-sub { font-size: 1.15rem; max-width: 640px; margin-left: auto; margin-right: auto; }

/* ---------- illustrated backdrops: every chapter sits inside the book's world ---------- */
#kingdom::before, #tales::before, #characters::before, #book::before, #story::before, #music::before, #join::before, #secret::before {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background-position: center; background-size: cover; background-repeat: no-repeat;
  -webkit-mask-image: linear-gradient(transparent 0%, #000 16%, #000 84%, transparent 100%);
          mask-image: linear-gradient(transparent 0%, #000 16%, #000 84%, transparent 100%);
}
#trailer, #kingdom, #tales, #readalong, #characters, #message, #secret, #book, #inside, #join, #story, #author, #music { background: var(--ink); }
#kingdom::before { background-image: linear-gradient(rgba(7,12,24,0.78), rgba(7,12,24,0.86)), url("../img/bg/deep-forest.jpg"); }
#tales::before { background-image: linear-gradient(rgba(7,12,24,0.84), rgba(7,12,24,0.9)), url("../img/bg/t05-s4.jpg"); }
#characters::before { background-image: linear-gradient(rgba(7,12,24,0.74), rgba(7,12,24,0.88)), url("../img/bg/oak-path.jpg"); }
#book::before { background-image: linear-gradient(rgba(7,12,24,0.62), rgba(7,12,24,0.82)), url("../img/bg/cover-wrap.jpg"); background-position: left center; }
#story::before { background-image: linear-gradient(rgba(7,12,24,0.84), rgba(7,12,24,0.92)), url("../img/bg/t01-s1.jpg"); }
#music::before { background-image: linear-gradient(rgba(7,12,24,0.84), rgba(7,12,24,0.92)), url("../img/bg/t10-s1.jpg"); }
#join::before { background-image: linear-gradient(rgba(7,12,24,0.7), rgba(7,12,24,0.86)), url("../img/bg/t12-s6.jpg"); }
#secret::before { background-image: radial-gradient(ellipse at 30% 50%, rgba(245,200,66,0.07), transparent 60%); -webkit-mask-image: none; mask-image: none; }
#trailer { background: radial-gradient(ellipse at 50% 30%, rgba(245,200,66,0.09), transparent 60%), var(--ink); }
#message { background: radial-gradient(ellipse at 22% 30%, rgba(245,200,66,0.10), transparent 55%), radial-gradient(ellipse at 80% 80%, rgba(80,110,190,0.14), transparent 55%), #080f22; }
#readalong { background: radial-gradient(ellipse at 50% 40%, rgba(232,160,32,0.08), transparent 60%), var(--ink); }

/* ---------- chapter gates: full-bleed art with a line of verse ---------- */
.gate { position: relative; min-height: 92vh; padding: 0; overflow: hidden; display: flex; align-items: flex-end; justify-content: center; isolation: isolate; }
.gate-img { position: absolute; left: 0; top: -8%; width: 100%; height: 116%; object-fit: cover; z-index: -2; will-change: transform; }
.gate-veil { position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(var(--ink) 0%, rgba(7,12,24,0.1) 16%, rgba(7,12,24,0) 45%, rgba(7,12,24,0.72) 76%, var(--ink) 100%); }
.gate-copy { text-align: center; padding: 0 1.5rem 7.5rem; max-width: 900px; }
.gate-line { font-family: var(--serif-display); font-size: clamp(1.4rem, 3.4vw, 2.5rem); line-height: 1.35; color: #fffcea; text-shadow: 0 2px 20px rgba(0,0,0,0.95), 0 0 40px rgba(0,0,0,0.7); }
.gate-strong { font-style: italic; background: var(--gilt); -webkit-background-clip: text; background-clip: text; color: transparent; text-shadow: none; filter: drop-shadow(0 2px 14px rgba(0,0,0,0.95)); font-size: clamp(1.7rem, 4.2vw, 3.1rem); }
.gate-src { margin-top: 1.2rem; font-family: var(--caps); font-size: 0.72rem; letter-spacing: 0.36em; text-transform: uppercase; color: var(--gold); }
.gate .gate-line.reveal { transition-duration: 1.5s; }
.gate .gate-line:nth-child(2) { transition-delay: 0.35s; } .gate .gate-line:nth-child(3) { transition-delay: 0.7s; } .gate .gate-line:nth-child(4) { transition-delay: 1.05s; }
#legacy { min-height: 92vh; display: flex; align-items: center; }

/* ---------- gilded frames ---------- */
.map-frame, .trailer-stage, .reader, .tt-stage {
  border: 1px solid rgba(245,200,66,0.75);
  box-shadow: 0 0 0 5px rgba(7,12,24,0.9), 0 0 0 6px rgba(245,200,66,0.4), 0 0 70px rgba(245,200,66,0.2), 0 40px 110px rgba(0,0,0,0.75);
}
.trailer-stage { max-width: 1180px; }
.map-frame { max-width: 1240px; margin-left: auto; margin-right: auto; }
#kingdom .wrap, #trailer .wrap, #characters .wrap, #tales .wrap { max-width: 1280px; }

/* ---------- the twelve tales: storybook plates ---------- */
.tales-grid { gap: 1.8rem; }
.tale-card { background: linear-gradient(170deg, rgba(22,34,60,0.92), rgba(9,15,29,0.96)); border: 1px solid rgba(245,200,66,0.32); border-radius: 18px;
  box-shadow: 0 18px 50px rgba(0,0,0,0.55); transition: transform 0.45s cubic-bezier(.2,.8,.2,1), box-shadow 0.45s, border-color 0.45s; }
.tale-card:hover { transform: translateY(-10px) rotate(-0.4deg); border-color: rgba(245,200,66,0.95); background: linear-gradient(170deg, rgba(30,44,74,0.95), rgba(9,15,29,0.96));
  box-shadow: 0 0 40px rgba(245,200,66,0.35), 0 30px 70px rgba(0,0,0,0.7); }
.tale-thumb { aspect-ratio: 16 / 10; }
.tale-card .num { position: absolute; top: -2.4rem; left: 1.2rem; width: 3.6rem; height: 3.6rem; margin: 0; display: flex; align-items: center; justify-content: center;
  border-radius: 50%; font-family: var(--caps); font-size: 1.05rem; color: #241703; background: var(--gilt); border: 2px solid #fff0b8;
  box-shadow: 0 6px 20px rgba(0,0,0,0.6), 0 0 18px rgba(245,200,66,0.45); z-index: 3; }
.tale-body { padding: 1.9rem 1.5rem 1.5rem; }
.tale-card h3 { font-size: 1.5rem; line-height: 1.2; }

/* ---------- the cast: cinematic portrait wall ---------- */
.char-grid { grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 1.6rem; }
.char-card { border-radius: 20px; border: 1px solid rgba(245,200,66,0.4); background: #0a1122; overflow: hidden; animation: none; }
.char-card img { border-radius: 0; aspect-ratio: 4 / 5; object-position: center 22%; transition: transform 1.2s cubic-bezier(.2,.8,.2,1), filter 0.6s; filter: saturate(1.04); }
.char-card:hover img { transform: scale(1.07); }
.char-card .live-video { aspect-ratio: 4 / 5; height: 100%; border-radius: 0; }
.char-card .char-label { position: absolute; left: 0; right: 0; bottom: 0; padding: 3.4rem 1rem 1.05rem; text-align: center; z-index: 3;
  background: linear-gradient(rgba(7,12,24,0), rgba(7,12,24,0.82) 55%, rgba(7,12,24,0.96)); border: none; }
.char-card .char-label h3 { font-size: 1.5rem; color: #fff6cf; text-shadow: 0 2px 10px rgba(0,0,0,0.9); margin: 0; }
.char-card .char-label p { display: inline-block; margin-top: 0.3rem; background: none; border: none; padding: 0; font-family: var(--caps); font-size: 0.62rem; letter-spacing: 0.22em; text-transform: uppercase; color: var(--gold); }
.char-card.selected, .char-card:hover { border-color: rgba(245,200,66,0.95); }
.char-modal .cm-box { max-width: 980px; }

/* ---------- book launch block ---------- */
#book .book-copy h3 { font-size: clamp(1.7rem, 3vw, 2.3rem); line-height: 1.2; }
.book-cover { width: min(420px, 82vw); box-shadow: -18px 24px 70px rgba(0,0,0,0.75), 0 0 110px rgba(245,200,66,0.28), inset 4px 0 12px rgba(255,255,255,0.08); }
.book-specs span { font-family: var(--caps); font-size: 0.64rem; letter-spacing: 0.16em; text-transform: uppercase; border-color: rgba(245,200,66,0.45); background: rgba(7,12,24,0.55); }
.join-wrap { max-width: 760px; padding: 3rem 2rem; border-radius: 26px; border: 1px solid rgba(245,200,66,0.5);
  background: linear-gradient(160deg, rgba(22,34,60,0.82), rgba(7,12,24,0.9)); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
  box-shadow: 0 0 80px rgba(245,200,66,0.14), 0 30px 90px rgba(0,0,0,0.6); }
.join-title { font-size: clamp(2.1rem, 4.6vw, 3.3rem); background: linear-gradient(180deg, #fffcea 20%, #f3d98a 78%, #c99a35 100%); -webkit-background-clip: text; background-clip: text; color: transparent; }

/* tracks, timeline and panels pick up the glass */
.track, .tl-item, .full-story { background: rgba(10,17,34,0.72); backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px); }
footer { background: var(--ink); }

@media (max-width: 640px) {
  section { padding: 5rem 1.1rem; }
  header.hero.hero-cine { padding: 5rem 1.1rem 6.5rem; }
  .hero-cine .hero-inner h1 small { letter-spacing: 0.22em; font-size: 0.34em; }
  .btn { padding: 0.9rem 1.7rem; font-size: 0.76rem; }
  .gate { min-height: 78vh; } .gate-copy { padding-bottom: 5rem; }
  .gate-img { object-position: 60% center; }
  .char-grid { grid-template-columns: repeat(2, 1fr); gap: 0.8rem; }
  .char-card .char-label h3 { font-size: 1.1rem; } .char-card .char-label p { font-size: 0.5rem; letter-spacing: 0.14em; }
  .tale-card .num { width: 3rem; height: 3rem; top: -2rem; font-size: 0.9rem; }
  .join-wrap { padding: 2.2rem 1.2rem; }
  .map-frame, .trailer-stage, .reader, .tt-stage { box-shadow: 0 0 0 3px rgba(7,12,24,0.9), 0 0 0 4px rgba(245,200,66,0.4), 0 0 40px rgba(245,200,66,0.18), 0 20px 60px rgba(0,0,0,0.7); }
}
@media (prefers-reduced-motion: reduce) {
  .btn-gold, nav ul a.nav-cta, .hero-cine .hero-inner h1 { animation: none; opacity: 1; transform: none; }
}

/* v60 refinements */
nav ul { gap: 1.2rem; flex-wrap: nowrap; }
nav ul a, nav .brand span { white-space: nowrap; }
nav ul a { font-size: 0.66rem; letter-spacing: 0.14em; }
@media (max-width: 1240px) {
  nav ul {
    position: fixed; top: 58px; right: 0; flex-direction: column; align-items: flex-start;
    background: rgba(7, 12, 24, 0.97); padding: 1.6rem 2.2rem; gap: 1.1rem;
    border-left: 1px solid rgba(245,200,66,0.2); border-bottom: 1px solid rgba(245,200,66,0.2);
    border-radius: 0 0 0 14px; transform: translateX(110%); transition: transform 0.3s;
  }
  nav ul.open { transform: none; }
  nav ul a { font-size: 0.78rem; }
  .nav-toggle { display: block; }
}
.hero-cine .hero-inner h1 small { -webkit-text-fill-color: #fff6cf; color: #fff6cf; text-shadow: 0 2px 14px rgba(0,0,0,0.95), 0 0 30px rgba(0,0,0,0.8); }
#book::before { background-size: 215% auto; background-position: 0% 40%; background-image: linear-gradient(rgba(7,12,24,0.66), rgba(7,12,24,0.84)), url("../img/bg/cover-wrap.jpg"); }
.hero-cine .hero-inner::before { content: ""; position: absolute; inset: -14% -20% -10%; z-index: -1; pointer-events: none;
  background: radial-gradient(ellipse at 50% 45%, rgba(7,12,24,0.66) 0%, rgba(7,12,24,0.4) 42%, rgba(7,12,24,0) 70%); }

/* ============================================================
   v61 · the Queen's scene and the sleeping Map of the Realm
   ============================================================ */

/* ---------- Queen Titania: a living scene ---------- */
#message { overflow: hidden; }
#message::before {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(ellipse at 28% 38%, rgba(245,200,66,0.16), transparent 46%),
    radial-gradient(ellipse at 74% 46%, rgba(245,200,66,0.10), transparent 50%),
    linear-gradient(rgba(7,12,24,0.55), rgba(7,12,24,0.8)), url("../img/bg/deep-forest.jpg") center / cover no-repeat;
  filter: hue-rotate(150deg) saturate(0.9);
  -webkit-mask-image: linear-gradient(transparent 0%, #000 14%, #000 86%, transparent 100%); mask-image: linear-gradient(transparent 0%, #000 14%, #000 86%, transparent 100%);
}
.queen-scene { position: relative; display: grid; grid-template-columns: 0.82fr 1.18fr; gap: 4.2rem; align-items: center; max-width: 1120px; margin: 0 auto; }
.queen-sparks { position: absolute; inset: -6% -4%; width: 108%; height: 112%; pointer-events: none; z-index: 4; }
.queen-portrait { position: relative; text-align: center; animation: queenFloat 7s ease-in-out infinite; }
@keyframes queenFloat { 0%,100% { translate: 0 0; } 50% { translate: 0 -12px; } }
.queen-rays {
  position: absolute; left: 50%; top: 46%; width: 150%; aspect-ratio: 1; translate: -50% -50%; z-index: -1; border-radius: 50%;
  background: repeating-conic-gradient(from 0deg, rgba(245,200,66,0.16) 0deg 7deg, rgba(245,200,66,0) 7deg 20deg);
  -webkit-mask-image: radial-gradient(circle, #000 18%, transparent 68%); mask-image: radial-gradient(circle, #000 18%, transparent 68%);
  animation: raysTurn 60s linear infinite;
}
@keyframes raysTurn { to { rotate: 360deg; } }
.queen-arch {
  position: relative; overflow: hidden; aspect-ratio: 3 / 4; border-radius: 50% 50% 22px 22px / 34% 34% 22px 22px;
  border: 3px solid #f5c842; outline: 1px solid rgba(245,200,66,0.5); outline-offset: 7px;
  box-shadow: 0 0 0 10px rgba(7,12,24,0.75), 0 0 60px rgba(245,200,66,0.55), 0 0 140px rgba(245,200,66,0.28), 0 30px 80px rgba(0,0,0,0.7);
  animation: archGlow 4.5s ease-in-out infinite;
}
@keyframes archGlow { 50% { box-shadow: 0 0 0 10px rgba(7,12,24,0.75), 0 0 90px rgba(245,200,66,0.8), 0 0 190px rgba(245,200,66,0.4), 0 30px 80px rgba(0,0,0,0.7); } }
.queen-arch img, .queen-arch video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: center 18%; }
.queen-arch img { animation: queenBreath 9s ease-in-out infinite; transform-origin: 50% 30%; }
@keyframes queenBreath { 0%,100% { transform: scale(1.02); } 50% { transform: scale(1.08) translateY(-1%); } }
.queen-arch video { opacity: 0; transition: opacity 1.4s ease; }
.queen-arch.alive video { opacity: 1; }
.queen-arch::after { content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(115deg, rgba(255,255,255,0) 40%, rgba(255,246,207,0.22) 50%, rgba(255,255,255,0) 60%); background-size: 260% 100%; animation: archSheen 7s ease-in-out infinite; }
@keyframes archSheen { 0%, 55% { background-position: 130% 0; } 100% { background-position: -130% 0; } }
.queen-name { margin-top: 1.5rem; font-family: var(--caps); font-size: 0.7rem; letter-spacing: 0.34em; text-transform: uppercase; color: var(--gold); }

.message-scroll { position: relative; filter: drop-shadow(0 26px 46px rgba(0,0,0,0.6)) drop-shadow(0 0 40px rgba(245,200,66,0.22)); opacity: 1; transform: none; }
.scroll-rod { position: relative; height: 26px; margin: 0 -22px; border-radius: 13px; z-index: 2;
  background: linear-gradient(#fbe9a6 0%, #e2b84e 30%, #a8761c 62%, #6d4a0d 100%); box-shadow: inset 0 2px 3px rgba(255,255,255,0.6), 0 4px 10px rgba(0,0,0,0.45); }
.scroll-rod i { position: absolute; top: 50%; width: 30px; height: 30px; translate: 0 -50%; border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #fff3bf, #e2b84e 45%, #8a5d12 100%); box-shadow: 0 0 14px rgba(245,200,66,0.7); }
.scroll-rod i:first-child { left: -16px; } .scroll-rod i:last-child { right: -16px; }
.scroll-paper {
  position: relative; text-align: center; margin: -5px 0; overflow: hidden;
  max-height: 0; padding: 0 2.4rem;
  background:
    radial-gradient(ellipse at 50% 0%, rgba(255,255,255,0.6), transparent 55%),
    radial-gradient(ellipse at 0% 50%, rgba(160,110,30,0.22), transparent 30%),
    radial-gradient(ellipse at 100% 50%, rgba(160,110,30,0.22), transparent 30%),
    repeating-linear-gradient(92deg, rgba(150,105,35,0.05) 0 2px, rgba(255,255,255,0) 2px 7px),
    linear-gradient(#fbefc9, #f3dfa8 55%, #e8cc88);
  transition: max-height 2.4s cubic-bezier(.3,.75,.25,1), padding 2.4s cubic-bezier(.3,.75,.25,1);
}
.message-scroll.open .scroll-paper, .message-scroll.visible .scroll-paper { max-height: 760px; padding: 2.6rem 2.4rem 2.4rem; }
.scroll-paper::before { content: ""; position: absolute; inset: 14px; border: 1px solid rgba(160,110,30,0.45); border-radius: 4px; pointer-events: none;
  box-shadow: inset 0 0 0 4px rgba(251,239,201,0.6), inset 0 0 0 5px rgba(160,110,30,0.28); }
.ms-head { font-family: var(--caps); font-size: 0.72rem; letter-spacing: 0.34em; text-transform: uppercase; color: #8a5d12; margin-bottom: 1.3rem; opacity: 0; transition: opacity 1.2s ease 1s; }
.message-scroll.open .ms-head { opacity: 1; }
.ms-line { opacity: 1 !important; transform: none !important; font-family: var(--serif-display); font-style: italic; font-weight: 600; font-size: clamp(1.3rem, 2.5vw, 1.85rem); line-height: 1.5; margin: 0; transition: none !important; }
.ms-line span {
  display: inline-block; color: transparent;
  background: linear-gradient(100deg, #4a3210 0%, #4a3210 42%, #d9a12e 50%, #4a3210 58%, #4a3210 100%); background-size: 300% 100%; background-position: 100% 0;
  -webkit-background-clip: text; background-clip: text;
  clip-path: inset(-10% 100% -10% 0); transition: clip-path 1.5s cubic-bezier(.4,.1,.3,1), background-position 2.6s ease;
}
.ms-line.inked span { clip-path: inset(-10% -2% -10% 0); background-position: 0% 0; }
.ms-line.speaking span { background: linear-gradient(100deg, #b8862b, #f0c456, #b8862b); -webkit-background-clip: text; background-clip: text; filter: drop-shadow(0 0 10px rgba(245,200,66,0.9)); }
.ms-gap { margin-top: 1.1rem !important; }
.ms-sign { margin-top: 1.3rem; font-family: var(--serif-display); font-style: italic; font-size: 1.9rem; color: #8a5d12; opacity: 0; transition: opacity 1.6s ease; }
.message-scroll.signed .ms-sign { opacity: 1; }
.ms-seal { position: absolute; right: 2.2rem; bottom: 1.5rem; width: 74px; height: 74px; border-radius: 50%; display: flex; align-items: center; justify-content: center;
  font-size: 2.1rem; color: #f8dc8c; text-shadow: 0 1px 2px rgba(0,0,0,0.5);
  background: radial-gradient(circle at 35% 30%, #d5553f, #a3241a 55%, #6d120c 100%);
  box-shadow: 0 0 0 3px rgba(109,18,12,0.5), 0 6px 14px rgba(0,0,0,0.45), inset 0 2px 4px rgba(255,255,255,0.3);
  opacity: 0; transform: scale(2.6) rotate(-25deg); transition: opacity 0.25s ease, transform 0.45s cubic-bezier(.3,1.6,.5,1); }
.message-scroll.signed .ms-seal { opacity: 1; transform: scale(1) rotate(-8deg); transition-delay: 0.9s; }
.queen-actions { margin-top: 2.6rem; display: flex; gap: 1.6rem; justify-content: center; align-items: center; flex-wrap: wrap; }
.queen-actions .btn.playing { box-shadow: 0 0 36px rgba(245,200,66,0.9); }

/* ---------- the sleeping Map of the Realm ---------- */
.map-hud { max-width: 1240px; margin: 0 auto 1.4rem; text-align: center; }
.map-hud-line { font-family: var(--serif-display); font-style: italic; font-size: clamp(1.05rem, 2vw, 1.3rem); color: #ffe9a8; margin-bottom: 1rem; min-height: 1.6em; transition: opacity 0.5s; }
.map-hud-row { display: flex; gap: 1.6rem; align-items: center; justify-content: center; flex-wrap: wrap; }
.map-secrets { display: flex; align-items: center; gap: 0.9rem; padding: 0.5rem 1.2rem; border-radius: 999px; border: 1px solid rgba(245,200,66,0.45); background: rgba(7,12,24,0.7); }
.map-pips { display: flex; gap: 6px; }
.map-pips i { width: 12px; height: 12px; border-radius: 50%; border: 1px solid rgba(245,200,66,0.6); background: rgba(245,200,66,0.06); transition: background 0.5s, box-shadow 0.5s, scale 0.5s; }
.map-pips i.on { background: radial-gradient(circle at 35% 30%, #fff6cf, #f5c842 55%, #b8862b); box-shadow: 0 0 10px rgba(245,200,66,0.9); scale: 1.2; }
.map-count { font-family: var(--caps); font-size: 0.66rem; letter-spacing: 0.2em; text-transform: uppercase; color: var(--cream-dim); }
.map-count b { color: var(--gold); font-size: 1.15em; }
.map-live, .map-life, .map-night { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.map-live { object-fit: cover; opacity: 0; transition: opacity 1.6s ease; }
.map-frame.live .map-live { opacity: 1; }
.map-frame.zoomed .map-live { opacity: 0; }
.map-life { z-index: 2; mix-blend-mode: screen; }
.map-night {
  z-index: 3; opacity: 0; transition: opacity 1.2s ease;
  background: radial-gradient(ellipse at 50% 40%, rgba(6,10,26,0.9), rgba(2,4,12,0.96));
  --lx: 50%; --ly: 45%; --lr: 150px;
  -webkit-mask-image: radial-gradient(circle var(--lr) at var(--lx) var(--ly), rgba(0,0,0,0) 0%, rgba(0,0,0,0.05) 38%, rgba(0,0,0,0.55) 68%, #000 100%);
          mask-image: radial-gradient(circle var(--lr) at var(--lx) var(--ly), rgba(0,0,0,0) 0%, rgba(0,0,0,0.05) 38%, rgba(0,0,0,0.55) 68%, #000 100%);
}
.map-frame.asleep .map-night { opacity: 1; }
.map-frame.asleep .map-viewport { cursor: none; }
.map-frame .poi { z-index: 4; }
.map-frame .poi-card { z-index: 6; }
.map-frame.asleep .poi { opacity: 0; pointer-events: none; transition: opacity 0.5s ease, scale 0.3s; }
.map-frame.asleep .poi.near, .map-frame.asleep .poi.found { opacity: 1; pointer-events: auto; }
.map-frame.asleep .poi.near { animation: secretFound 0.9s ease; }
@keyframes secretFound { 0% { scale: 0.2; } 60% { scale: 1.5; } 100% { scale: 1; } }
.poi.poi-tale.found { box-shadow: 0 0 0 3px rgba(255,246,207,0.9), 0 0 22px rgba(245,200,66,1); }
.poi.poi-tale.pop { animation: secretFound 0.8s cubic-bezier(.3,1.5,.5,1) backwards; }
.map-lantern { position: absolute; z-index: 5; width: 46px; height: 46px; translate: -50% -50%; pointer-events: none; opacity: 0; transition: opacity 0.4s;
  background: radial-gradient(circle, rgba(255,246,207,0.95) 0%, rgba(245,200,66,0.55) 30%, rgba(245,200,66,0) 70%); border-radius: 50%; mix-blend-mode: screen; }
.map-frame.asleep .map-lantern { opacity: 1; }

@media (max-width: 900px) {
  .queen-scene { grid-template-columns: 1fr; gap: 2.6rem; }
  .queen-portrait { max-width: 330px; margin: 0 auto; }
}
@media (max-width: 640px) {
  .scroll-paper { padding-left: 1.2rem; padding-right: 1.2rem; }
  .message-scroll.open .scroll-paper, .message-scroll.visible .scroll-paper { padding: 2.2rem 1.2rem 4.6rem; }
  .ms-seal { width: 58px; height: 58px; font-size: 1.6rem; right: 50%; translate: 50% 0; bottom: 1rem; }
  .scroll-rod { margin: 0 -10px; } .scroll-rod i { display: none; }
  .map-hud-row { gap: 0.9rem; }
  .map-pips i { width: 9px; height: 9px; }
}
@media (prefers-reduced-motion: reduce) {
  .queen-portrait, .queen-rays, .queen-arch, .queen-arch img, .queen-arch::after { animation: none; }
  .ms-line span { clip-path: none; transition: none; }
}

/* ============================================================
   v62 · the book in three dimensions, and the family film
   ============================================================ */
#book .book-grid { display: block; }
.book-show { max-width: 1120px; margin: 0 auto; }
.book3d-stage {
  --bw: 310px; --bh: 414px; --bd: 40px;
  position: relative; height: 660px; perspective: 1900px; perspective-origin: 50% 46%;
  touch-action: pan-y; cursor: grab; user-select: none; -webkit-user-select: none;
}
.book3d-stage.dragging { cursor: grabbing; }
.book3d-stage.opened { cursor: default; }
.bk-aura { position: absolute; left: 50%; top: 58%; width: min(760px, 96%); aspect-ratio: 1.5; translate: -50% -50%; pointer-events: none;
  background: radial-gradient(ellipse, rgba(245,200,66,0.34), rgba(245,200,66,0.10) 42%, rgba(245,200,66,0) 68%); transition: opacity 1.6s, scale 1.6s; opacity: 0.55; }
.book3d-stage.opened .bk-aura { opacity: 1; scale: 1.25; animation: auraPulse 3.6s ease-in-out infinite; }
@keyframes auraPulse { 50% { opacity: 0.72; } }
.book3d { position: absolute; left: 50%; top: 58%; width: 0; height: 0; transform-style: preserve-3d;
  transform: translateX(var(--tx, 0px)) rotateX(var(--rx, -8deg)) rotateY(var(--ry, -28deg)); will-change: transform; }
.bk-face { position: absolute; }
.bk-face img { width: 100%; height: 100%; object-fit: cover; display: block; pointer-events: none; }
.bk-back { width: var(--bw); height: var(--bh); left: calc(var(--bw) / -2); top: calc(var(--bh) / -2); transform: rotateY(180deg) translateZ(calc(var(--bd) / 2)); border-radius: 3px 7px 7px 3px; overflow: hidden; box-shadow: inset 0 0 30px rgba(0,0,0,0.25); }
.bk-spine { width: var(--bd); height: var(--bh); left: calc(var(--bd) / -2); top: calc(var(--bh) / -2); transform: rotateY(-90deg) translateZ(calc(var(--bw) / 2)); overflow: hidden; box-shadow: inset 6px 0 10px rgba(0,0,0,0.35), inset -6px 0 10px rgba(0,0,0,0.35); }
.bk-pages { background:
    repeating-linear-gradient(90deg, #fbf3da 0 1px, #e6d6a8 1px 2px, #f6ecc9 2px 3px),
    #f3e7c0; box-shadow: inset 0 0 12px rgba(120,84,20,0.45); }
.bk-fore { width: calc(var(--bd) - 8px); height: calc(var(--bh) - 12px); left: calc((var(--bd) - 8px) / -2); top: calc((var(--bh) - 12px) / -2); transform: rotateY(90deg) translateZ(calc(var(--bw) / 2 - 5px)); }
.bk-top, .bk-bottom { width: calc(var(--bw) - 6px); height: calc(var(--bd) - 8px); left: calc(var(--bw) / -2 + 1px); top: calc((var(--bd) - 8px) / -2);
  background: repeating-linear-gradient(0deg, #fbf3da 0 1px, #e6d6a8 1px 2px, #f6ecc9 2px 3px), #f3e7c0; }
.bk-top { transform: rotateX(90deg) translateZ(calc(var(--bh) / 2 - 6px)); }
.bk-bottom { transform: rotateX(-90deg) translateZ(calc(var(--bh) / 2 - 6px)); }
.bk-base, .bk-leaf { width: calc(var(--bw) - 7px); height: calc(var(--bh) - 12px); left: calc(var(--bw) / -2 + 1px); top: calc((var(--bh) - 12px) / -2); }
.bk-base { transform: translateZ(calc(var(--bd) / 2 - 6px)); background-size: 200% 100%; background-position: right center; box-shadow: inset 14px 0 22px rgba(60,40,10,0.45); }
.bk-leaf { position: absolute; transform-style: preserve-3d; transform-origin: left center;
  transform: translateZ(calc(var(--bd) / 2 - 2.5px - var(--i) * 0.6px)) rotateY(var(--a, 0deg));
  transition: transform 1.15s cubic-bezier(.35,.1,.25,1); transition-delay: calc((4 - var(--i)) * 0.12s); }
.lf { position: absolute; inset: 0; backface-visibility: hidden; -webkit-backface-visibility: hidden; background-size: 200% 100%; background-color: #f6ecc9; }
.lf-front { background-position: right center; box-shadow: inset 14px 0 22px rgba(60,40,10,0.4); }
.lf-back { background-position: left center; transform: rotateY(180deg); box-shadow: inset -14px 0 22px rgba(60,40,10,0.4); }
.bk-cover { width: var(--bw); height: var(--bh); left: calc(var(--bw) / -2); top: calc(var(--bh) / -2); transform-style: preserve-3d; transform-origin: left center;
  transform: translateZ(calc(var(--bd) / 2)) rotateY(var(--cv, 0deg)); transition: transform 1.5s cubic-bezier(.4,.05,.2,1); transition-delay: 0.7s; }
.cv { position: absolute; inset: 0; backface-visibility: hidden; -webkit-backface-visibility: hidden; border-radius: 3px 7px 7px 3px; overflow: hidden; }
.cv-out { box-shadow: inset 5px 0 12px rgba(255,255,255,0.12), inset -2px 0 6px rgba(0,0,0,0.3); }
.cv-out::after { content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(105deg, rgba(255,255,255,0) 35%, rgba(255,255,255,0.22) 48%, rgba(255,255,255,0) 60%); background-size: 250% 100%; animation: archSheen 6s ease-in-out infinite; }
.cv-in { transform: rotateY(180deg); background-size: 200% 100%; background-position: left center; background-color: #f6ecc9; border-radius: 7px 3px 3px 7px; box-shadow: inset -14px 0 22px rgba(60,40,10,0.4), inset 0 0 0 6px #2b3a66; }
.book3d.open .bk-cover { --cv: -177deg; transition-delay: 0s; }
.book3d.open .bk-leaf { --a: calc(-174deg + var(--i) * 1.4deg); transition-delay: calc(1.3s + var(--i) * 0.55s); }
.book3d::after { content: ""; position: absolute; width: calc(var(--bw) * 1.5); height: 40px; left: calc(var(--bw) * -0.75); top: calc(var(--bh) / 2 + 26px);
  background: radial-gradient(ellipse, rgba(0,0,0,0.6), rgba(0,0,0,0) 70%); transform: rotateX(90deg); filter: blur(6px); pointer-events: none; }

/* things that rise out of the open book */
.bk-popouts { position: absolute; inset: 0; pointer-events: none; }
.bk-pop { position: absolute; left: 50%; top: 58%; height: 178px; width: auto; translate: -50% -50%; scale: 0.08; opacity: 0;
  filter: drop-shadow(0 0 18px rgba(245,200,66,0.75)) drop-shadow(0 10px 18px rgba(0,0,0,0.5));
  transition: left 1.5s cubic-bezier(.2,.9,.25,1), top 1.5s cubic-bezier(.2,.9,.25,1), scale 1.5s cubic-bezier(.3,1.4,.4,1), opacity 0.7s ease; }
.book3d-stage.magic .bk-pop { opacity: 1; scale: 1; animation: popBob 5.5s ease-in-out infinite; }
.book3d-stage.magic .bk-pop[data-i="0"] { left: 7%;  top: 52%; transition-delay: 0.0s; animation-delay: -0.5s; }
.book3d-stage.magic .bk-pop[data-i="1"] { left: 19%; top: 24%; transition-delay: 0.2s; animation-delay: -1.4s; }
.book3d-stage.magic .bk-pop[data-i="2"] { left: 36%; top: 11%; transition-delay: 0.4s; animation-delay: -2.2s; }
.book3d-stage.magic .bk-pop[data-i="3"] { left: 50%; top: 9%;  transition-delay: 0.6s; animation-delay: -3.1s; height: 150px; }
.book3d-stage.magic .bk-pop[data-i="4"] { left: 64%; top: 11%; transition-delay: 0.8s; animation-delay: -0.9s; }
.book3d-stage.magic .bk-pop[data-i="5"] { left: 81%; top: 24%; transition-delay: 1.0s; animation-delay: -4.0s; }
.book3d-stage.magic .bk-pop[data-i="6"] { left: 93%; top: 52%; transition-delay: 1.2s; animation-delay: -2.7s; }
@keyframes popBob { 0%,100% { transform: translateY(0) rotate(-1.5deg); } 50% { transform: translateY(-14px) rotate(1.5deg); } }
.bk-verse { position: absolute; left: 50%; top: 56%; translate: -50% -50%; white-space: nowrap; opacity: 0;
  font-family: var(--serif-display); font-style: italic; font-weight: 600; font-size: clamp(1rem, 2vw, 1.5rem);
  background: var(--gilt); -webkit-background-clip: text; background-clip: text; color: transparent; filter: drop-shadow(0 0 10px rgba(245,200,66,0.8)) drop-shadow(0 2px 6px rgba(0,0,0,0.8)); }
.book3d-stage.magic .bk-verse { animation: verseRise 10s ease-out infinite; }
.bk-verse[data-i="0"] { --k: -0.9; animation-delay: 1.0s !important; } .bk-verse[data-i="1"] { --k: 0.85; animation-delay: 2.6s !important; }
.bk-verse[data-i="2"] { --k: -0.35; animation-delay: 4.2s !important; } .bk-verse[data-i="3"] { --k: 0.4; animation-delay: 5.8s !important; }
.bk-verse[data-i="4"] { --k: -0.65; animation-delay: 7.4s !important; } .bk-verse[data-i="5"] { --k: 0.62; animation-delay: 9.0s !important; }
@keyframes verseRise {
  0% { transform: translate(0, 0) scale(0.4); opacity: 0; }
  12% { opacity: 1; }
  70% { opacity: 1; }
  100% { transform: translate(calc(var(--k) * min(400px, 40vw)), -330px) scale(1.08); opacity: 0; }
}
.bk-controls { text-align: center; margin-top: 0.4rem; }
.bk-hint { margin-top: 0.9rem; font-family: var(--caps); font-size: 0.66rem; letter-spacing: 0.24em; text-transform: uppercase; color: var(--moon); min-height: 1.4em; }
#book .book-copy { max-width: 880px; margin: 3.2rem auto 0; text-align: center; }
#book .book-specs { justify-content: center; }

/* the family film */
.family-film { display: grid; grid-template-columns: 1.25fr 0.75fr; gap: 3rem; align-items: center; max-width: 1120px; margin: 5.5rem auto 0; }
.ff-frame { border-radius: 18px; overflow: hidden; border: 1px solid rgba(245,200,66,0.75);
  box-shadow: 0 0 0 5px rgba(7,12,24,0.9), 0 0 0 6px rgba(245,200,66,0.4), 0 0 70px rgba(245,200,66,0.22), 0 40px 110px rgba(0,0,0,0.75); }
.ff-frame video { width: 100%; display: block; aspect-ratio: 16 / 9; object-fit: cover; }
.ff-copy .kicker { font-family: var(--caps); font-size: 0.74rem; letter-spacing: 0.38em; text-transform: uppercase; color: var(--gold); }
.ff-copy h3 { font-size: clamp(1.7rem, 3vw, 2.4rem); line-height: 1.15; color: var(--cream); margin: 0.6rem 0 0.9rem; }
.ff-copy p { color: var(--cream-dim); }

@media (max-width: 900px) { .family-film { grid-template-columns: 1fr; gap: 1.6rem; margin-top: 3.5rem; } }
@media (max-width: 640px) {
  .book3d-stage { --bw: 178px; --bh: 238px; --bd: 26px; height: 520px; }
  .bk-pop { height: 104px; } .book3d-stage.magic .bk-pop[data-i="3"] { height: 92px; }
  .book3d-stage.magic .bk-pop[data-i="0"] { left: 10%; top: 40%; } .book3d-stage.magic .bk-pop[data-i="6"] { left: 90%; top: 40%; }
  .book3d-stage.magic .bk-pop[data-i="1"] { left: 22%; top: 19%; } .book3d-stage.magic .bk-pop[data-i="5"] { left: 78%; top: 19%; }
  .book3d-stage.magic .bk-pop[data-i="2"] { left: 38%; top: 8%; } .book3d-stage.magic .bk-pop[data-i="4"] { left: 62%; top: 8%; }
  .book3d-stage.magic .bk-pop[data-i="3"] { top: 30%; left: 50%; display: none; }
}
@media (prefers-reduced-motion: reduce) { .bk-pop, .bk-verse, .cv-out::after, .bk-aura { animation: none !important; } }
/* v62 refinements */
.book3d-stage { --bw: 350px; --bh: 467px; --bd: 44px; height: 730px; }
.bk-spine { backface-visibility: hidden; -webkit-backface-visibility: hidden; }
@media (max-width: 640px) { .book3d-stage { --bw: 178px; --bh: 238px; --bd: 26px; height: 520px; } }
.book3d.open .bk-cover { --cv: -179.4deg; }
.book3d.open .bk-leaf { --a: calc(-178.6deg + var(--i) * 0.45deg); }

/* ============================================================
   v63 · every page of the book turns, living character orbs, true spine
   ============================================================ */
.book3d-stage { --bd: 37px; }
.bk-spine img { object-fit: fill; }
.bk-leaf { transform: translateZ(calc(var(--bd) / 2 - 2.5px)) rotateY(var(--a, 0deg)); transition: transform 1.05s cubic-bezier(.4,.08,.25,1); transition-delay: 0s; opacity: 0; }
.bk-leaf.noanim { transition: none; }
.book3d.open .bk-leaf { --a: 0deg; transition-delay: 0s; }
.book3d.paging .bk-leaf { opacity: 1; }
.bk-leaf.turn { --a: -180deg !important; }
.bk-left { width: calc(var(--bw) - 7px); height: calc(var(--bh) - 12px); left: calc(var(--bw) / -2 + 1px - (var(--bw) - 7px)); top: calc((var(--bh) - 12px) / -2);
  transform: translateZ(calc(var(--bd) / 2 - 6px)); background-size: 200% 100%; background-position: left center; background-color: #f6ecc9;
  box-shadow: inset -14px 0 22px rgba(60,40,10,0.4); opacity: 0; transition: opacity 0.5s ease; }
.book3d.paging .bk-left { opacity: 1; }
.bk-base { background-color: #f6ecc9; }
.book3d.open .bk-cover { --cv: -180deg; transform: translateZ(calc(var(--bd) / 2 - 8px)) rotateY(var(--cv, 0deg)); }
.cv-in { background: radial-gradient(ellipse at 60% 40%, #34467c, #1c2748 75%); box-shadow: inset 0 0 0 7px #26335c, inset 0 0 0 8px rgba(245,200,66,0.35); }

/* living characters rise from the pages inside golden orbs */
.bk-orb { position: absolute; left: 50%; top: 58%; width: 150px; aspect-ratio: 1; translate: -50% -50%; scale: 0.06; opacity: 0; border-radius: 50%;
  border: 3px solid #f5c842; overflow: visible;
  box-shadow: 0 0 0 5px rgba(7,12,24,0.7), 0 0 34px rgba(245,200,66,0.85), 0 0 90px rgba(245,200,66,0.35), 0 14px 30px rgba(0,0,0,0.55);
  transition: left 1.6s cubic-bezier(.2,.9,.25,1), top 1.6s cubic-bezier(.2,.9,.25,1), scale 1.6s cubic-bezier(.3,1.5,.4,1), opacity 0.7s ease; }
.bk-orb video { width: 100%; height: 100%; object-fit: cover; object-position: center 20%; border-radius: 50%; display: block; }
.bk-orb::after { content: ""; position: absolute; inset: 0; border-radius: 50%; pointer-events: none;
  background: radial-gradient(circle at 30% 24%, rgba(255,255,255,0.4), rgba(255,255,255,0) 34%), radial-gradient(circle at 50% 50%, rgba(255,255,255,0) 58%, rgba(245,200,66,0.28) 100%); }
.bk-orb span { position: absolute; left: 50%; bottom: -1.7rem; translate: -50% 0; white-space: nowrap; font-family: var(--caps); font-size: 0.6rem; letter-spacing: 0.2em; text-transform: uppercase; color: #ffe9a8; text-shadow: 0 2px 8px rgba(0,0,0,0.9); }
.book3d-stage.magic .bk-orb { opacity: 1; scale: 1; animation: orbFloat 6s ease-in-out infinite; }
.book3d-stage.magic .bk-orb[data-i="0"] { left: 8%;  top: 60%; transition-delay: 0.0s; animation-delay: -0.4s; }
.book3d-stage.magic .bk-orb[data-i="1"] { left: 11%; top: 30%; transition-delay: 0.15s; animation-delay: -1.3s; }
.book3d-stage.magic .bk-orb[data-i="2"] { left: 28%; top: 11%; transition-delay: 0.3s; animation-delay: -2.4s; }
.book3d-stage.magic .bk-orb[data-i="3"] { left: 43%; top: 6%;  transition-delay: 0.45s; animation-delay: -3.2s; width: 128px; }
.book3d-stage.magic .bk-orb[data-i="4"] { left: 57%; top: 6%;  transition-delay: 0.6s; animation-delay: -0.9s; width: 128px; }
.book3d-stage.magic .bk-orb[data-i="5"] { left: 72%; top: 11%; transition-delay: 0.75s; animation-delay: -4.1s; }
.book3d-stage.magic .bk-orb[data-i="6"] { left: 89%; top: 30%; transition-delay: 0.9s; animation-delay: -2.9s; }
.book3d-stage.magic .bk-orb[data-i="7"] { left: 92%; top: 60%; transition-delay: 1.05s; animation-delay: -1.8s; }
@keyframes orbFloat { 0%,100% { transform: translate(0, 0) rotate(-2deg); } 33% { transform: translate(6px, -16px) rotate(1.5deg); } 66% { transform: translate(-6px, -6px) rotate(-0.5deg); } }
@media (max-width: 640px) {
  .book3d-stage { --bd: 19px; }
  .bk-orb { width: 84px; border-width: 2px; } .book3d-stage.magic .bk-orb[data-i="3"], .book3d-stage.magic .bk-orb[data-i="4"] { width: 76px; }
  .bk-orb span { font-size: 0.46rem; bottom: -1.2rem; letter-spacing: 0.12em; }
  .book3d-stage.magic .bk-orb[data-i="0"] { left: 12%; top: 50%; } .book3d-stage.magic .bk-orb[data-i="7"] { left: 88%; top: 50%; }
  .book3d-stage.magic .bk-orb[data-i="1"] { left: 13%; top: 26%; } .book3d-stage.magic .bk-orb[data-i="6"] { left: 87%; top: 26%; }
  .book3d-stage.magic .bk-orb[data-i="2"] { left: 27%; top: 9%; } .book3d-stage.magic .bk-orb[data-i="5"] { left: 73%; top: 9%; }
  .book3d-stage.magic .bk-orb[data-i="3"] { left: 42%; top: 20%; } .book3d-stage.magic .bk-orb[data-i="4"] { left: 58%; top: 20%; }
}
@media (prefers-reduced-motion: reduce) { .bk-orb { animation: none !important; } }
@media (min-width: 641px) {
  .book3d-stage.magic .bk-orb[data-i="0"] { left: 5%;  top: 63%; } .book3d-stage.magic .bk-orb[data-i="7"] { left: 95%; top: 63%; }
  .book3d-stage.magic .bk-orb[data-i="1"] { left: 6%;  top: 31%; } .book3d-stage.magic .bk-orb[data-i="6"] { left: 94%; top: 31%; }
  .book3d-stage.magic .bk-orb[data-i="2"] { left: 22%; top: 10%; } .book3d-stage.magic .bk-orb[data-i="5"] { left: 78%; top: 10%; }
  .book3d-stage.magic .bk-orb[data-i="3"] { left: 41%; top: 7%; }  .book3d-stage.magic .bk-orb[data-i="4"] { left: 59%; top: 7%; }
}

/* v64 · the real 120 pages, one page per side */
.bk-left, .bk-base, .lf { background-size: 100% 100% !important; background-position: center !important; background-repeat: no-repeat; }
.bk-left.endpaper, .bk-base.endpaper, .lf.endpaper { background: radial-gradient(ellipse at 50% 40%, #34467c, #1c2748 78%) !important; box-shadow: inset 0 0 0 7px #26335c, inset 0 0 0 8px rgba(245,200,66,0.35); }
/* verses rise from the top edge of the open book, so the printed pages stay clear */
.bk-verse { top: 27%; }
@keyframes verseRise {
  0% { transform: translate(0, 0) scale(0.4); opacity: 0; }
  14% { opacity: 1; } 70% { opacity: 1; }
  100% { transform: translate(calc(var(--k) * min(420px, 40vw)), -150px) scale(1.08); opacity: 0; }
}

/* v65 · verses pour from the centre fold of the open book; white inside covers */
.bk-verse { top: 58%; z-index: 3; }
@keyframes verseRise {
  0% { transform: translate(0, 0) scale(0.15); opacity: 0; }
  10% { opacity: 1; }
  72% { opacity: 1; }
  100% { transform: translate(calc(var(--k) * min(430px, 40vw)), -420px) scale(1.1); opacity: 0; }
}
.cv-in,
.bk-left.endpaper, .bk-base.endpaper, .lf.endpaper {
  background: linear-gradient(90deg, #ffffff 0%, #fdfcf8 70%, #f1eee6 100%) !important;
  box-shadow: inset 0 0 0 1px rgba(0,0,0,0.06) !important;
}
.cv-in, .bk-left.endpaper { background: linear-gradient(270deg, #ffffff 0%, #fdfcf8 70%, #ebe8df 100%) !important; }
@media (max-width: 640px) {
  @keyframes verseRise {
    0% { transform: translate(0, 0) scale(0.15); opacity: 0; } 10% { opacity: 1; } 72% { opacity: 1; }
    100% { transform: translate(calc(var(--k) * 34vw), -290px) scale(1.05); opacity: 0; }
  }
}

/* v66 · inside covers match the dedication page paper (#FDF9EE) */
.cv-in,
.bk-left.endpaper, .bk-base.endpaper, .lf.endpaper {
  background: #fdf9ee !important;
  box-shadow: none !important;
}
.cv-in, .bk-left.endpaper { box-shadow: inset -14px 0 22px rgba(60,40,10,0.4) !important; }
.bk-base.endpaper, .lf-front.endpaper { box-shadow: inset 14px 0 22px rgba(60,40,10,0.4) !important; }

/* v67 · closed book sits just beneath the heading; it glides down when it opens to make room for the magic */
.book3d-stage { height: calc(var(--bh) + 90px); transition: height 1.3s cubic-bezier(.4,.05,.2,1); }
.book3d-stage.opened { height: 730px; }
.book3d { top: calc(var(--bh) / 2 + 26px); transition: top 1.3s cubic-bezier(.4,.05,.2,1); }
.book3d-stage.opened .book3d { top: 423px; }
.bk-aura { top: 50%; transition: opacity 1.6s, scale 1.6s, top 1.3s; }
.book3d-stage.opened .bk-aura { top: 58%; }
#book .section-head { margin-bottom: 1.6rem; }
@media (max-width: 640px) {
  .book3d-stage { height: calc(var(--bh) + 70px); }
  .book3d-stage.opened { height: 520px; }
  .book3d-stage.opened .book3d { top: 302px; }
}
@media (prefers-reduced-motion: reduce) { .book3d-stage, .book3d { transition: none; } }

/* v68 · the first leaf (Dedication) is in place from the moment the cover lifts */
.book3d.open .bk-leaf { opacity: 1; }

/* ============================================================
   v69 · Colour the Realm
   ============================================================ */
#colouring { background: radial-gradient(ellipse at 50% 20%, rgba(245,200,66,0.10), transparent 55%), var(--ink); }
#colouring .wrap { max-width: 1240px; }
.col-gate { display: grid; grid-template-columns: 1fr 1fr; gap: 1.4rem; max-width: 1000px; margin: 0 auto 1.2rem; }
.col-step { position: relative; display: flex; gap: 1.1rem; align-items: flex-start; padding: 1.4rem 1.5rem; border-radius: 18px;
  border: 1px solid rgba(245,200,66,0.4); background: linear-gradient(160deg, rgba(22,34,60,0.85), rgba(9,15,29,0.92)); transition: border-color 0.5s, box-shadow 0.5s; }
.col-num { flex: none; width: 46px; height: 46px; border-radius: 50%; display: flex; align-items: center; justify-content: center;
  font-family: var(--caps); font-size: 1.1rem; color: #241703; background: var(--gilt); border: 2px solid #fff0b8; box-shadow: 0 0 16px rgba(245,200,66,0.4); }
.col-step-body { flex: 1; min-width: 0; }
.col-step h4 { font-size: 1.35rem; color: var(--cream); line-height: 1.2; }
.col-step p { font-size: 0.95rem; color: var(--cream-dim); margin: 0.3rem 0 0.8rem; line-height: 1.45; }
.col-form { display: flex; gap: 0.6rem; flex-wrap: wrap; }
.col-form input { flex: 1; min-width: 180px; font-family: var(--serif-body); font-size: 1rem; padding: 0.7rem 1.1rem; border-radius: 999px;
  border: 1px solid rgba(245,200,66,0.45); background: rgba(7,12,24,0.7); color: var(--cream); outline: none; }
.col-form input:focus { border-color: var(--gold); box-shadow: 0 0 18px rgba(245,200,66,0.25); }
.col-form .btn { padding: 0.7rem 1.4rem; font-size: 0.74rem; }
.col-tick { position: absolute; top: 12px; right: 14px; width: 34px; height: 34px; border-radius: 50%; display: flex; align-items: center; justify-content: center;
  font-size: 1.1rem; color: #0b1424; background: #8fe3a2; box-shadow: 0 0 18px rgba(143,227,162,0.7); opacity: 0; scale: 0.3; transition: opacity 0.4s, scale 0.5s cubic-bezier(.3,1.6,.5,1); }
.col-step.done { border-color: rgba(143,227,162,0.7); box-shadow: 0 0 30px rgba(143,227,162,0.14); }
.col-step.done .col-tick { opacity: 1; scale: 1; }
.col-step.done .col-form, .col-step.done .col-go { opacity: 0.45; }
.col-step.nudge { animation: riddleShake 0.5s ease; border-color: var(--gold); box-shadow: 0 0 40px rgba(245,200,66,0.4); }
.col-status { text-align: center; font-family: var(--serif-display); font-style: italic; font-size: 1.2rem; color: #ffe9a8; margin-bottom: 2rem; }
.col-grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 1.2rem; }
.col-card { position: relative; display: block; text-align: center; color: inherit; transition: transform 0.4s cubic-bezier(.2,.8,.2,1); }
.col-paper { display: block; background: #fff; border-radius: 6px; overflow: hidden; padding: 4px;
  box-shadow: 0 14px 34px rgba(0,0,0,0.55), 0 0 0 1px rgba(245,200,66,0.35); transition: box-shadow 0.4s, filter 0.6s; }
.col-paper img { width: 100%; display: block; }
.col-name { display: block; margin-top: 0.8rem; font-family: var(--serif-display); font-weight: 600; font-size: 1.2rem; color: var(--cream); }
.col-get { display: inline-block; margin-top: 0.2rem; font-family: var(--caps); font-size: 0.62rem; letter-spacing: 0.2em; text-transform: uppercase; color: var(--gold); }
.col-lock { position: absolute; left: 50%; top: 38%; translate: -50% -50%; width: 58px; height: 58px; border-radius: 50%; display: flex; align-items: center; justify-content: center;
  font-size: 1.4rem; background: rgba(7,12,24,0.88); border: 1px solid rgba(245,200,66,0.8); box-shadow: 0 0 24px rgba(245,200,66,0.4); opacity: 0; scale: 1.6; transition: opacity 0.6s, scale 0.6s; pointer-events: none; }
.col-grid.locked .col-lock { opacity: 1; scale: 1; }
.col-grid.locked .col-paper { filter: brightness(0.5) saturate(0.6); }
.col-grid.locked .col-get { visibility: hidden; }
.col-grid:not(.locked) .col-card:hover { transform: translateY(-10px) rotate(-1.2deg); }
.col-grid:not(.locked) .col-card:nth-child(even):hover { transform: translateY(-10px) rotate(1.2deg); }
.col-grid:not(.locked) .col-card:hover .col-paper { box-shadow: 0 0 40px rgba(245,200,66,0.55), 0 22px 44px rgba(0,0,0,0.6), 0 0 0 2px rgba(245,200,66,0.9); }
.col-all { text-align: center; margin-top: 2.6rem; }
.col-all .gallery-note { margin-top: 1rem; }
.btn.locked { filter: grayscale(0.9) brightness(0.7); animation: none; }
@media (max-width: 1000px) { .col-grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 760px) { .col-gate { grid-template-columns: 1fr; } }
@media (max-width: 520px) { .col-grid { grid-template-columns: repeat(2, 1fr); gap: 0.9rem; } .col-name { font-size: 1.05rem; } }
/* v70 · one step: the Oak Promise */
.col-gate.col-gate-one { grid-template-columns: 1fr; max-width: 560px; }

/* ============================================================
   v71 · the passage, the Oak's clock, countdown
   ============================================================ */
/* hero: the real oak by night, or asleep by day */
.hero-cine .hero-bg { background-image: url("../img/realm/hero-oak-poster.jpg"); }
.hero-day { position: absolute; inset: 0; opacity: 0; transition: opacity 2.4s ease; overflow: hidden; background: #0b1424; }
.hero-day::before { content: ""; position: absolute; inset: -6%; background: url("../img/realm/day-oak.jpg") center / cover no-repeat; filter: blur(26px) brightness(0.9) saturate(1.1); }
.hero-day::after { content: ""; position: absolute; inset: 0; background: url("../img/realm/day-oak.jpg") center / contain no-repeat;
  -webkit-mask-image: linear-gradient(90deg, transparent 0%, #000 12%, #000 88%, transparent 100%); mask-image: linear-gradient(90deg, transparent 0%, #000 12%, #000 88%, transparent 100%); }
body.oak-day .hero-day { opacity: 1; }
body.oak-day .hero-cine .hero-video { opacity: 0; }
.hero-cine .hero-video { transition: opacity 2.4s ease; }
body.oak-day .hero-cine .hero-veil {
  background:
    radial-gradient(ellipse at 50% 46%, rgba(7,12,24,0.5) 0%, rgba(7,12,24,0.28) 45%, rgba(7,12,24,0.55) 100%),
    linear-gradient(rgba(7,12,24,0.45) 0%, rgba(7,12,24,0.1) 30%, rgba(7,12,24,0.3) 60%, rgba(7,12,24,0.95) 90%, var(--ink) 100%);
}
body.oak-day #fireflies { opacity: 0.25; }
.hero-daynote { margin-top: 1.3rem; font-family: var(--serif-display); font-style: italic; font-size: clamp(1rem, 2vw, 1.25rem); color: #fff6cf; text-shadow: 0 2px 14px rgba(0,0,0,0.95); }
.hero-daynote b { color: var(--gold); font-style: normal; }
.hero-daynote .linklike { font-size: 1em; color: var(--gold); margin-left: 0.4rem; }
.hero-inner .hero-daynote.fade-seq { animation-delay: 1.6s; }
.hero-count { margin-top: 1.6rem; }
.hero-inner .hero-count.fade-seq { animation-delay: 1.2s; }
.hc-cells { display: inline-flex; gap: 0.9rem; }
.hc-cells span { min-width: 84px; padding: 0.7rem 0.6rem 0.55rem; border-radius: 14px; border: 1px solid rgba(245,200,66,0.55); background: rgba(7,12,24,0.6); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
  font-family: var(--caps); font-size: 0.58rem; letter-spacing: 0.22em; text-transform: uppercase; color: var(--moon); display: flex; flex-direction: column; gap: 0.2rem; box-shadow: 0 0 24px rgba(245,200,66,0.14); }
.hc-cells b { font-family: var(--serif-display); font-size: 2.3rem; line-height: 1; letter-spacing: 0; color: #ffe9a8; font-variant-numeric: tabular-nums; }
.hc-label { margin-top: 0.7rem; font-family: var(--caps); font-size: 0.68rem; letter-spacing: 0.34em; text-transform: uppercase; color: var(--gold); }
.join-count { font-family: var(--serif-display); font-style: italic; font-size: 1.3rem; color: #ffe9a8; margin: 0.4rem 0 1rem; }
.join-thanks { font-family: var(--serif-display); font-style: italic; font-size: 1.3rem; color: #ffe9a8; margin-top: 1rem; }
.join-buy { margin-top: 1.4rem; }

/* the passage */
#passage { padding: 0; height: 520vh; background: var(--ink); isolation: auto; }
.ps-stage { position: sticky; top: 0; height: 100vh; overflow: hidden; background: var(--ink); --out: 0; }
#psCanvas { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; transform-origin: 52% 52%; will-change: transform, opacity; }
.ps-veil { position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(ellipse at 50% 50%, rgba(7,12,24,0) 40%, rgba(7,12,24,0.6) 100%), linear-gradient(var(--ink) 0%, rgba(7,12,24,0) 14%, rgba(7,12,24,0) 78%, rgba(7,12,24,0.9) 100%); }
.ps-stage::after { content: ""; position: absolute; inset: 0; background: var(--ink); opacity: var(--out); pointer-events: none; }
.ps-flash { position: absolute; inset: 0; opacity: 0; pointer-events: none; background: radial-gradient(ellipse at 52% 52%, #fffbe6 0%, #ffe9a8 30%, #f5c842 62%, rgba(245,200,66,0.85) 100%); }
.ps-cap { position: absolute; left: 50%; bottom: 13vh; width: min(900px, 90vw); margin: 0; opacity: 0; transform: translate(-50%, 18px); text-align: center; pointer-events: none; z-index: 2;
  font-family: var(--serif-display); font-style: italic; font-size: clamp(1.5rem, 3.6vw, 2.7rem); line-height: 1.3; color: #fffcea; text-shadow: 0 2px 22px rgba(0,0,0,0.95), 0 0 50px rgba(0,0,0,0.8); }
.ps-cap-big { bottom: 42vh; font-style: normal; font-weight: 600; font-size: clamp(2.6rem, 8vw, 6.4rem); line-height: 1;
  background: var(--gilt); -webkit-background-clip: text; background-clip: text; color: transparent; text-shadow: none; filter: drop-shadow(0 6px 30px rgba(0,0,0,0.9)); }
.ps-progress { position: absolute; left: 50%; bottom: 5vh; width: min(260px, 50vw); height: 2px; translate: -50% 0; background: rgba(255,252,234,0.18); z-index: 2; }
.ps-progress i { display: block; height: 100%; background: var(--gilt); transform-origin: 0 50%; transform: scaleX(0); box-shadow: 0 0 10px rgba(245,200,66,0.8); }
body.lights-down #passage { visibility: hidden; }

/* the Christmas tale, asleep until December */
.tale-card.xmas-asleep .tale-thumb img { filter: grayscale(0.7) brightness(0.55) blur(1.5px); }
.tale-card.xmas-asleep .tale-open { opacity: 1; translate: -50% 0; }
.poi.poi-tale.xmas-asleep { background: radial-gradient(circle at 35% 30%, #ffffff 0%, #cfe3f5 45%, #8fb0d0 100%); border-color: #fff; }

@media (max-width: 640px) {
  #passage { height: 420vh; }
  .hc-cells { gap: 0.4rem; } .hc-cells span { min-width: 64px; padding: 0.5rem 0.3rem; font-size: 0.5rem; letter-spacing: 0.14em; } .hc-cells b { font-size: 1.7rem; }
  .ps-cap { bottom: 16vh; }
}
@media (prefers-reduced-motion: reduce) { #passage { height: 100vh; } #psCanvas { opacity: 1 !important; transform: none !important; } }

/* ============================================================
   v71 · Keeper's Journey, the wish, grown ups
   ============================================================ */
/* passport chip */
.jr-chip { position: fixed; left: 18px; bottom: 20px; z-index: 120; display: flex; align-items: center; gap: 0.55rem; padding: 0.45rem 1rem 0.45rem 0.55rem; border-radius: 999px;
  border: 1px solid rgba(245,200,66,0.6); background: rgba(7,12,24,0.88); box-shadow: 0 6px 24px rgba(0,0,0,0.5), 0 0 20px rgba(245,200,66,0.18);
  opacity: 0; translate: 0 20px; pointer-events: none; transition: opacity 0.5s, translate 0.5s, box-shadow 0.4s; }
.jr-chip.show { opacity: 1; translate: 0 0; pointer-events: auto; }
.jr-chip span { width: 34px; height: 34px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 1.05rem; background: radial-gradient(circle at 35% 30%, #34467c, #141d3a); border: 1px solid rgba(245,200,66,0.7); }
.jr-chip b { font-family: var(--caps); font-weight: 400; font-size: 0.64rem; letter-spacing: 0.2em; text-transform: uppercase; color: #ffe9a8; }
.jr-chip:hover { box-shadow: 0 6px 24px rgba(0,0,0,0.5), 0 0 34px rgba(245,200,66,0.55); }
.jr-chip.rise { animation: chipRise 1.4s ease; }
@keyframes chipRise { 0% { scale: 1; } 30% { scale: 1.35; box-shadow: 0 0 60px rgba(245,200,66,0.9); } 100% { scale: 1; } }
body.lights-down .jr-chip { opacity: 0; }

#journey { background: radial-gradient(ellipse at 20% 30%, rgba(245,200,66,0.09), transparent 55%), var(--ink); }
.jr-grid { display: grid; grid-template-columns: 0.8fr 1.2fr; gap: 2.4rem; max-width: 1080px; margin: 0 auto; align-items: stretch; }
.jr-pass { position: relative; text-align: center; padding: 2.2rem 1.6rem 1.8rem; border-radius: 22px; border: 1px solid rgba(245,200,66,0.6);
  background: radial-gradient(ellipse at 50% 0%, rgba(245,200,66,0.16), transparent 60%), linear-gradient(165deg, #1b2a52, #0b1326);
  box-shadow: 0 0 0 6px rgba(7,12,24,0.9), 0 0 0 7px rgba(245,200,66,0.35), 0 30px 80px rgba(0,0,0,0.6); }
.jr-pass-top { font-family: var(--caps); font-size: 0.68rem; letter-spacing: 0.34em; text-transform: uppercase; color: var(--gold); }
.jr-emblem { width: 132px; height: 132px; margin: 1.3rem auto 1rem; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 3.6rem;
  background: radial-gradient(circle at 35% 30%, #3b4f8c, #141d3a 75%); border: 3px solid #f5c842; box-shadow: 0 0 40px rgba(245,200,66,0.5), inset 0 0 24px rgba(0,0,0,0.5); animation: archGlow 4.5s ease-in-out infinite; }
.jr-rank { font-family: var(--serif-display); font-weight: 600; font-size: clamp(1.8rem, 3.4vw, 2.5rem); line-height: 1.1;
  background: var(--gilt); -webkit-background-clip: text; background-clip: text; color: transparent; }
.jr-name { margin-top: 0.4rem; font-style: italic; color: var(--cream-dim); font-size: 1.02rem; }
.jr-ladder { display: flex; justify-content: center; gap: 0.35rem; margin: 1.4rem 0 0.9rem; flex-wrap: wrap; }
.jr-ladder span { padding: 0.28rem 0.7rem; border-radius: 999px; border: 1px solid rgba(176,196,216,0.3); font-family: var(--caps); font-size: 0.56rem; letter-spacing: 0.16em; text-transform: uppercase; color: rgba(176,196,216,0.6); }
.jr-ladder span.on { border-color: rgba(245,200,66,0.7); color: #ffe9a8; }
.jr-ladder span.now { background: var(--gilt); color: #241703; border-color: #fff0b8; font-weight: 600; }
.jr-next { font-size: 0.95rem; color: var(--moon); font-style: italic; }
.jr-quests { display: flex; flex-direction: column; gap: 0.9rem; justify-content: center; }
.jr-quest { display: flex; align-items: center; gap: 1.1rem; padding: 1.05rem 1.3rem; border-radius: 16px; border: 1px solid rgba(245,200,66,0.3); color: inherit;
  background: linear-gradient(160deg, rgba(22,34,60,0.85), rgba(9,15,29,0.92)); transition: transform 0.3s, border-color 0.3s, box-shadow 0.3s; }
.jr-quest:hover { transform: translateX(6px); border-color: rgba(245,200,66,0.85); box-shadow: 0 0 30px rgba(245,200,66,0.2); }
.jr-stamp { flex: none; width: 50px; height: 50px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 1.3rem; color: rgba(245,200,66,0.45);
  border: 2px dashed rgba(245,200,66,0.45); transition: all 0.6s; }
.jr-quest.done .jr-stamp { border: 2px solid #fff0b8; background: var(--gilt); color: #241703; box-shadow: 0 0 20px rgba(245,200,66,0.6); rotate: -10deg; }
.jr-q-body { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.jr-q-body b { font-family: var(--serif-display); font-size: 1.3rem; color: var(--cream); font-weight: 600; line-height: 1.2; }
.jr-q-body i { font-size: 0.9rem; color: var(--cream-dim); margin: 0.1rem 0 0.5rem; }
.jr-bar { display: block; height: 5px; border-radius: 999px; background: rgba(255,252,234,0.12); overflow: hidden; }
.jr-bar u { display: block; height: 100%; width: 0; border-radius: 999px; background: var(--gilt); transition: width 0.9s cubic-bezier(.2,.8,.2,1); text-decoration: none; }
.jr-q-count { flex: none; min-width: 3.6rem; text-align: right; font-family: var(--caps); font-size: 0.68rem; letter-spacing: 0.14em; color: var(--gold); }
.jr-quest.done .jr-q-count { font-size: 1.3rem; color: #8fe3a2; }
.jr-vault { max-width: 1080px; margin: 2.6rem auto 0; padding: 2.4rem 2rem; text-align: center; border-radius: 22px; border: 1px solid rgba(245,200,66,0.45);
  background: radial-gradient(ellipse at 50% 0%, rgba(245,200,66,0.12), transparent 65%), linear-gradient(160deg, rgba(22,38,63,0.95), rgba(11,20,36,0.95)); }
.jr-vault h3 { font-size: clamp(1.6rem, 3.2vw, 2.3rem); color: var(--cream); margin: 0.4rem 0 0.6rem; }
.jr-vault p { color: var(--cream-dim); max-width: 620px; margin: 0 auto; }
.jr-vault-lock { display: inline-flex; width: 70px; height: 70px; border-radius: 50%; align-items: center; justify-content: center; font-size: 1.7rem; border: 1px solid rgba(245,200,66,0.7); background: rgba(7,12,24,0.8); box-shadow: 0 0 26px rgba(245,200,66,0.3); }
.jr-verse { font-family: var(--serif-display); font-style: italic; font-size: 1.25rem; line-height: 1.6; color: #ffe9a8 !important; margin: 0.6rem auto 1.6rem !important; }
#jrCanvas { width: min(760px, 100%); height: auto; border-radius: 10px; box-shadow: 0 0 60px rgba(245,200,66,0.35), 0 20px 60px rgba(0,0,0,0.6); }
.jr-vault-open { animation: ttIn 1.4s ease; }

/* the wish */
#wish { background: radial-gradient(ellipse at 80% 30%, rgba(80,110,190,0.16), transparent 55%), radial-gradient(ellipse at 20% 80%, rgba(245,200,66,0.09), transparent 55%), #080f22; }
.wish-box { max-width: 760px; margin: 0 auto; padding: 2.4rem 2rem; border-radius: 22px; border: 1px solid rgba(245,200,66,0.45); text-align: center;
  background: linear-gradient(160deg, rgba(22,38,63,0.92), rgba(11,20,36,0.94)); box-shadow: 0 0 60px rgba(245,200,66,0.12), 0 24px 70px rgba(0,0,0,0.55); }
.wish-label { display: block; font-family: var(--serif-display); font-style: italic; font-size: 1.7rem; color: #ffe9a8; margin-bottom: 0.7rem; }
.wish-form textarea, .wish-form input, .wish-form select { font-family: var(--serif-body); font-size: 1.1rem; color: var(--cream); background: rgba(7,12,24,0.7); border: 1px solid rgba(245,200,66,0.45); outline: none; }
.wish-form textarea { width: 100%; border-radius: 16px; padding: 1rem 1.2rem; resize: none; line-height: 1.5; font-style: italic; }
.wish-form textarea:focus, .wish-form input:focus, .wish-form select:focus { border-color: var(--gold); box-shadow: 0 0 18px rgba(245,200,66,0.25); }
.wish-row { display: flex; gap: 0.7rem; margin: 0.9rem 0 1.4rem; flex-wrap: wrap; }
.wish-row input, .wish-row select { flex: 1; min-width: 200px; border-radius: 999px; padding: 0.8rem 1.2rem; }
.wish-row select option { background: #101d33; }
.wish-form.sent textarea { animation: wishFly 1.4s ease forwards; }
@keyframes wishFly { 40% { box-shadow: 0 0 60px rgba(245,200,66,0.8); border-color: #fff0b8; } 100% { opacity: 0; transform: translateY(-60px) scale(0.9); filter: blur(4px); } }
.wish-arrived { font-family: var(--caps); font-size: 0.74rem; letter-spacing: 0.34em; text-transform: uppercase; color: var(--gold); margin-bottom: 1.2rem; }
#wishCanvas { width: min(520px, 100%); height: auto; border-radius: 8px; box-shadow: 0 0 60px rgba(245,200,66,0.3), 0 20px 60px rgba(0,0,0,0.6); animation: letterIn 1.4s cubic-bezier(.2,.9,.3,1); }
@keyframes letterIn { from { opacity: 0; transform: translateY(-50px) rotate(-5deg) scale(0.8); } to { opacity: 1; transform: none; } }

/* for grown ups */
#grownups { background: linear-gradient(var(--ink), #0d1528 50%, var(--ink)); }
#grownups .wrap { max-width: 1240px; }
.gu-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.6rem; }
.gu-card { display: flex; flex-direction: column; padding: 2rem 1.7rem; border-radius: 20px; border: 1px solid rgba(245,200,66,0.35);
  background: linear-gradient(165deg, rgba(22,34,60,0.9), rgba(9,15,29,0.95)); box-shadow: 0 18px 50px rgba(0,0,0,0.5); }
.gu-kicker { font-family: var(--caps); font-size: 0.66rem; letter-spacing: 0.3em; text-transform: uppercase; color: var(--gold); }
.gu-card h3 { font-size: 1.7rem; line-height: 1.15; color: var(--cream); margin: 0.5rem 0 0.8rem; }
.gu-card p { color: var(--cream-dim); font-size: 1rem; line-height: 1.55; }
.gu-list { list-style: none; margin: 1rem 0 1.4rem; }
.gu-list li { position: relative; padding: 0.3rem 0 0.3rem 1.5rem; font-size: 0.96rem; color: var(--cream-dim); }
.gu-list li::before { content: "✦"; position: absolute; left: 0; color: var(--gold); font-size: 0.8rem; top: 0.45rem; }
.gu-facts { display: grid; grid-template-columns: auto 1fr; gap: 0.35rem 1rem; margin: 1rem 0 1.4rem; font-size: 0.94rem; }
.gu-facts dt { font-family: var(--caps); font-size: 0.6rem; letter-spacing: 0.18em; text-transform: uppercase; color: var(--gold); padding-top: 0.25rem; }
.gu-facts dd { color: var(--cream-dim); }
.gu-card > .btn, .gu-btns { margin-top: auto; }
.gu-btns { display: flex; gap: 0.7rem; flex-wrap: wrap; }
.gu-card .btn { padding: 0.8rem 1.4rem; font-size: 0.7rem; justify-content: center; }

@media (max-width: 1000px) { .gu-grid { grid-template-columns: 1fr; max-width: 640px; margin: 0 auto; } }
@media (max-width: 860px) { .jr-grid { grid-template-columns: 1fr; } }
@media (max-width: 640px) {
  .jr-chip { left: 10px; bottom: 14px; padding: 0.35rem 0.8rem 0.35rem 0.4rem; } .jr-chip b { font-size: 0.56rem; }
  .jr-quest { padding: 0.9rem 0.9rem; gap: 0.8rem; } .jr-stamp { width: 40px; height: 40px; } .jr-q-body b { font-size: 1.12rem; } .jr-q-count { min-width: 2.8rem; }
  .wish-box, .jr-vault { padding: 1.8rem 1.1rem; }
}
/* v72 · home screen film restored to the golden door and the Realm */
.hero-cine .hero-bg { background-image: url("../img/realm/trailer-poster.jpg"); }

/* ============================================================
   v75 · Quizzes of the Realm
   ============================================================ */
#quizzes { background: radial-gradient(ellipse at 80% 10%, rgba(245,200,66,0.10), transparent 50%), radial-gradient(ellipse at 10% 90%, rgba(80,110,190,0.14), transparent 55%), var(--ink); }
#quizzes .wrap { max-width: 1240px; }
.qz-filters { display: flex; gap: 0.6rem; justify-content: center; flex-wrap: wrap; margin-bottom: 2.2rem; }
.qz-filters button { padding: 0.5rem 1.2rem; border-radius: 999px; cursor: pointer; border: 1px solid rgba(245,200,66,0.45); background: rgba(7,12,24,0.6);
  font-family: var(--caps); font-size: 0.66rem; letter-spacing: 0.2em; text-transform: uppercase; color: var(--cream-dim); transition: all 0.25s; }
.qz-filters button:hover { color: #ffe9a8; border-color: rgba(245,200,66,0.9); }
.qz-filters button.on { background: var(--gilt); color: #241703; border-color: #fff0b8; font-weight: 600; }
.qz-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.5rem; }
.qz-card { display: flex; flex-direction: column; text-align: left; padding: 0; cursor: pointer; color: inherit; font: inherit; border-radius: 18px; overflow: hidden;
  border: 1px solid rgba(245,200,66,0.35); background: linear-gradient(170deg, rgba(22,34,60,0.92), rgba(9,15,29,0.96)); box-shadow: 0 18px 50px rgba(0,0,0,0.5);
  transition: transform 0.4s cubic-bezier(.2,.8,.2,1), box-shadow 0.4s, border-color 0.4s; }
.qz-card:hover { transform: translateY(-9px) rotate(-0.5deg); border-color: rgba(245,200,66,0.95); box-shadow: 0 0 40px rgba(245,200,66,0.35), 0 28px 60px rgba(0,0,0,0.65); }
.qz-card.hide { display: none; }
.qz-art { position: relative; display: block; aspect-ratio: 16 / 10; overflow: hidden; }
.qz-art img { width: 100%; height: 100%; object-fit: cover; object-position: center 22%; transition: transform 4s ease; }
.qz-card:hover .qz-art img { transform: scale(1.12); }
.qz-art::after { content: ""; position: absolute; inset: 0; background: linear-gradient(rgba(7,12,24,0) 45%, rgba(9,15,29,0.9)); }
.qz-chip { position: absolute; left: 12px; top: 12px; z-index: 2; padding: 0.22rem 0.8rem; border-radius: 999px; background: var(--gilt); color: #241703;
  font-family: var(--caps); font-weight: 600; font-size: 0.56rem; letter-spacing: 0.16em; text-transform: uppercase; box-shadow: 0 0 14px rgba(245,200,66,0.5); }
.qz-best { position: absolute; right: 12px; bottom: 10px; z-index: 2; padding: 0.2rem 0.7rem; border-radius: 999px; background: rgba(7,12,24,0.85); border: 1px solid rgba(245,200,66,0.7);
  font-family: var(--caps); font-size: 0.56rem; letter-spacing: 0.12em; text-transform: uppercase; color: #ffe9a8; }
.qz-body { display: flex; flex-direction: column; flex: 1; padding: 1.1rem 1.3rem 1.3rem; }
.qz-body b { font-family: var(--serif-display); font-weight: 600; font-size: 1.4rem; line-height: 1.15; color: var(--cream); }
.qz-body i { font-style: normal; font-size: 0.95rem; color: var(--cream-dim); line-height: 1.45; margin: 0.5rem 0 0.9rem; }
.qz-go { margin-top: auto; font-family: var(--caps); font-size: 0.64rem; letter-spacing: 0.22em; text-transform: uppercase; color: var(--gold); }

.qz-modal { position: fixed; inset: 0; z-index: 235; display: none; align-items: center; justify-content: center; padding: 1.2rem; background: rgba(4,7,14,0.94); }
.qz-modal.open { display: flex; animation: ttIn 0.4s ease; }
.qz-modal .lb-close { position: absolute; top: 14px; right: 18px; z-index: 3; }
.qz-box { position: relative; width: min(760px, 100%); max-height: 94vh; overflow-y: auto; padding: 2rem 2.2rem 2.2rem; border-radius: 24px; text-align: center;
  border: 1px solid rgba(245,200,66,0.75); background: radial-gradient(ellipse at 50% 0%, rgba(245,200,66,0.14), transparent 60%), linear-gradient(165deg, #1b2a52, #0b1326);
  box-shadow: 0 0 0 6px rgba(7,12,24,0.9), 0 0 0 7px rgba(245,200,66,0.4), 0 0 80px rgba(245,200,66,0.22), 0 40px 110px rgba(0,0,0,0.8); }
.qz-kicker { font-family: var(--caps); font-size: 0.68rem; letter-spacing: 0.3em; text-transform: uppercase; color: var(--gold); }
.qz-progress { height: 4px; border-radius: 999px; background: rgba(255,252,234,0.14); margin: 0.9rem auto 1.6rem; overflow: hidden; max-width: 420px; }
.qz-progress i { display: block; height: 100%; background: var(--gilt); transform-origin: 0 50%; transform: scaleX(0); transition: transform 0.6s cubic-bezier(.2,.8,.2,1); }
.qz-stage { transition: opacity 0.24s ease, transform 0.24s ease; }
.qz-stage.out { opacity: 0; transform: translateY(14px); }
.qz-pic { width: min(240px, 60%); aspect-ratio: 1; object-fit: cover; object-position: center 20%; border-radius: 50%; margin: 0 auto 1.1rem; border: 3px solid #f5c842; box-shadow: 0 0 40px rgba(245,200,66,0.45); }
.qz-verse { margin-bottom: 1rem; }
.qz-verse p { font-family: var(--serif-display); font-style: italic; font-size: clamp(1.25rem, 3vw, 1.75rem); line-height: 1.45; color: #ffe9a8; }
.qz-q { font-size: clamp(1.4rem, 3.4vw, 2.1rem); line-height: 1.2; color: var(--cream); margin-bottom: 1.4rem; }
.qz-opts { display: grid; gap: 0.7rem; max-width: 540px; margin: 0 auto; }
.qz-opt { padding: 0.95rem 1.3rem; border-radius: 16px; cursor: pointer; border: 1px solid rgba(245,200,66,0.4); background: rgba(7,12,24,0.6);
  font-family: var(--serif-body); font-size: 1.15rem; color: var(--cream); transition: transform 0.2s, border-color 0.2s, background 0.3s, box-shadow 0.3s; }
.qz-opt:hover { transform: translateY(-2px); border-color: rgba(245,200,66,0.95); box-shadow: 0 0 22px rgba(245,200,66,0.2); }
.qz-opt.right { background: linear-gradient(160deg, #a7efb8, #58c47a); color: #0b2414; border-color: #c6f7d2; font-weight: 600; box-shadow: 0 0 26px rgba(143,227,162,0.55); }
.qz-opt.wrong { animation: riddleShake 0.45s ease; background: rgba(160,50,50,0.35); border-color: rgba(230,110,110,0.9); }
.qz-opt.picked { background: var(--gilt); color: #241703; border-color: #fff0b8; font-weight: 600; }
.qz-hint { font-style: italic; color: #ffe9a8; font-size: 1.15rem; margin: -0.6rem 0 1.4rem; }
.qz-slots, .qz-tiles { display: flex; gap: 0.45rem; justify-content: center; flex-wrap: wrap; }
.qz-slots { margin-bottom: 1.4rem; min-height: 58px; }
.qz-slot { width: 50px; height: 58px; border-radius: 10px; border: 2px dashed rgba(245,200,66,0.5); display: flex; align-items: center; justify-content: center; cursor: pointer;
  font-family: var(--serif-display); font-weight: 600; font-size: 1.9rem; color: #ffe9a8; }
.qz-slots.right .qz-slot { border: 2px solid #c6f7d2; background: linear-gradient(160deg, #a7efb8, #58c47a); color: #0b2414; }
.qz-slots.shown .qz-slot { border-style: solid; color: var(--moon); }
.qz-slots.shake { animation: riddleShake 0.45s ease; }
.qz-tile { width: 50px; height: 58px; border-radius: 10px; cursor: pointer; border: 2px solid #fff0b8; background: var(--gilt); color: #241703;
  font-family: var(--serif-display); font-weight: 600; font-size: 1.9rem; box-shadow: 0 6px 14px rgba(0,0,0,0.45); transition: transform 0.2s, opacity 0.25s; }
.qz-tile:hover { transform: translateY(-4px) rotate(-3deg); }
.qz-tile.used { opacity: 0.18; pointer-events: none; }
.qz-skip { display: inline-block; margin-top: 1.4rem; font-size: 0.95rem; }
.qz-res-img { width: min(230px, 60%); aspect-ratio: 1; object-fit: cover; object-position: center 20%; border-radius: 50%; margin: 0 auto 1rem; border: 3px solid #f5c842; box-shadow: 0 0 60px rgba(245,200,66,0.6); animation: elfinIn 1.2s cubic-bezier(.2,.9,.3,1); }
.qz-res-lead { font-style: italic; color: var(--moon); font-size: 1.1rem; }
.qz-res-title, .qz-res-score { font-family: var(--serif-display); font-weight: 600; line-height: 1.1; background: var(--gilt); -webkit-background-clip: text; background-clip: text; color: transparent;
  filter: drop-shadow(0 0 22px rgba(245,200,66,0.45)); animation: elfinIn 1.3s cubic-bezier(.2,.9,.3,1); }
.qz-res-title { font-size: clamp(2.2rem, 6vw, 3.6rem); }
.qz-res-score { font-size: clamp(3rem, 9vw, 5rem); }
.qz-res-tier { font-size: clamp(1.5rem, 4vw, 2.2rem); margin-top: 0.2rem; }
.qz-res-text { color: var(--cream-dim); max-width: 520px; margin: 0.9rem auto 1.6rem; font-size: 1.1rem; }
.qz-res-btns { display: flex; gap: 1.4rem; justify-content: center; align-items: center; flex-wrap: wrap; }
@media (max-width: 1100px) { .qz-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) {
  .qz-grid { grid-template-columns: 1fr; }
  .qz-box { padding: 1.6rem 1.1rem 1.6rem; }
  .qz-slot, .qz-tile { width: 36px; height: 44px; font-size: 1.4rem; border-radius: 8px; } .qz-slots, .qz-tiles { gap: 0.3rem; }
  .qz-opt { font-size: 1.05rem; padding: 0.85rem 1rem; }
}

/* v75 · things to make and do, and a roomier menu */
nav ul { gap: 1.05rem; }
#activities { background: radial-gradient(ellipse at 15% 15%, rgba(245,200,66,0.09), transparent 50%), var(--ink); }
#activities .wrap { max-width: 1240px; }
.ac-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.5rem; }
.ac-card { display: flex; flex-direction: column; color: inherit; border-radius: 18px; overflow: hidden; border: 1px solid rgba(245,200,66,0.35);
  background: linear-gradient(170deg, rgba(22,34,60,0.92), rgba(9,15,29,0.96)); box-shadow: 0 18px 50px rgba(0,0,0,0.5);
  transition: transform 0.4s cubic-bezier(.2,.8,.2,1), box-shadow 0.4s, border-color 0.4s; }
.ac-card:hover { transform: translateY(-9px) rotate(0.5deg); border-color: rgba(245,200,66,0.95); box-shadow: 0 0 40px rgba(245,200,66,0.35), 0 28px 60px rgba(0,0,0,0.65); }
.ac-paper { position: relative; display: block; padding: 1.2rem 1.6rem 0; background: radial-gradient(ellipse at 50% 100%, rgba(245,200,66,0.18), transparent 70%); overflow: hidden; height: 250px; }
.ac-paper img { width: 100%; display: block; border-radius: 4px 4px 0 0; box-shadow: 0 10px 30px rgba(0,0,0,0.6); transform: rotate(-2deg) translateY(4px); transform-origin: 50% 0; transition: transform 0.6s cubic-bezier(.2,.8,.2,1); }
.ac-card:nth-child(even) .ac-paper img { transform: rotate(2deg) translateY(4px); }
.ac-card:hover .ac-paper img { transform: rotate(0deg) translateY(-6px) scale(1.04); }
.ac-body { display: flex; flex-direction: column; flex: 1; padding: 1.1rem 1.3rem 1.3rem; border-top: 1px solid rgba(245,200,66,0.25); }
.ac-body b { font-family: var(--serif-display); font-weight: 600; font-size: 1.35rem; line-height: 1.15; color: var(--cream); }
.ac-body i { font-style: normal; font-size: 0.95rem; color: var(--cream-dim); line-height: 1.45; margin: 0.5rem 0 0.9rem; }
@media (max-width: 1100px) { .ac-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .ac-grid { grid-template-columns: 1fr; } .ac-paper { height: 220px; } }
@media (max-width: 1340px) {
  nav ul {
    position: fixed; top: 58px; right: 0; flex-direction: column; align-items: flex-start;
    background: rgba(7, 12, 24, 0.97); padding: 1.6rem 2.2rem; gap: 1.1rem;
    border-left: 1px solid rgba(245,200,66,0.2); border-bottom: 1px solid rgba(245,200,66,0.2);
    border-radius: 0 0 0 14px; transform: translateX(110%); transition: transform 0.3s;
  }
  nav ul.open { transform: none; }
  nav ul a { font-size: 0.78rem; }
  .nav-toggle { display: block; }
}

/* v76 · reserve room for late-loading pictures, so menu jumps land in the right place */
.col-paper img { aspect-ratio: 744 / 1052; }
.secret-door img { aspect-ratio: 1100 / 1478; }
.author-art img { aspect-ratio: 1800 / 1209; width: 100%; }
/* v77 · the book opens only when pressed */
.book3d-stage:not(.opened) .book3d .bk-face { cursor: pointer; }
.ac-card.hide { display: none; }

/* ============================================================
   v79 · the Fairy Revels
   ============================================================ */
#revels { background: radial-gradient(ellipse at 80% 10%, rgba(245,200,66,0.10), transparent 50%), radial-gradient(ellipse at 10% 90%, rgba(80,110,190,0.14), transparent 55%), var(--ink); }
#revels .wrap { max-width: 1240px; }
.rv-choices { display: grid; grid-template-columns: 1fr 1fr; gap: 1.8rem; max-width: 1120px; margin: 0 auto; }
.rv-choice { position: relative; display: flex; align-items: flex-end; min-height: 400px; padding: 0; text-align: left; cursor: pointer; color: inherit; font: inherit; border-radius: 24px; overflow: hidden;
  border: 1px solid rgba(245,200,66,0.55); background: #0a1122;
  box-shadow: 0 0 0 5px rgba(7,12,24,0.9), 0 0 0 6px rgba(245,200,66,0.3), 0 30px 80px rgba(0,0,0,0.6);
  transition: transform 0.45s cubic-bezier(.2,.8,.2,1), box-shadow 0.45s, border-color 0.45s, min-height 0.6s cubic-bezier(.3,.8,.2,1); }
.rv-choice::before { content: ""; position: absolute; inset: 0; background: var(--art) center / cover no-repeat; transition: transform 5s ease; transform: scale(1.04); }
.rv-choice:hover::before { transform: scale(1.14); }
.rv-veil { position: absolute; inset: 0; background: linear-gradient(rgba(7,12,24,0.05) 20%, rgba(7,12,24,0.55) 52%, rgba(7,12,24,0.95) 100%); }
.rv-choice:hover { transform: translateY(-10px); border-color: #f5c842; box-shadow: 0 0 0 5px rgba(7,12,24,0.9), 0 0 0 6px rgba(245,200,66,0.7), 0 0 70px rgba(245,200,66,0.4), 0 36px 90px rgba(0,0,0,0.7); }
.rv-choice.on { border-color: #fff0b8; box-shadow: 0 0 0 5px rgba(7,12,24,0.9), 0 0 0 7px #f5c842, 0 0 80px rgba(245,200,66,0.5), 0 30px 80px rgba(0,0,0,0.6); }
.rv-body { position: relative; display: flex; flex-direction: column; align-items: flex-start; padding: 1.8rem 1.9rem 1.9rem; width: 100%; }
.rv-chip { padding: 0.26rem 0.9rem; border-radius: 999px; background: var(--gilt); color: #241703; font-family: var(--caps); font-weight: 600; font-size: 0.6rem; letter-spacing: 0.18em; text-transform: uppercase; box-shadow: 0 0 16px rgba(245,200,66,0.5); }
.rv-body b { margin-top: 0.8rem; font-family: var(--serif-display); font-weight: 600; font-size: clamp(2rem, 3.6vw, 3rem); line-height: 1.05;
  background: linear-gradient(180deg, #fffcea 20%, #f3d98a 80%, #c99a35 100%); -webkit-background-clip: text; background-clip: text; color: transparent; filter: drop-shadow(0 3px 12px rgba(0,0,0,0.8)); }
.rv-body i { font-style: normal; margin-top: 0.6rem; font-size: 1.08rem; line-height: 1.5; color: var(--cream-dim); max-width: 30rem; text-shadow: 0 2px 10px rgba(0,0,0,0.9); }
.rv-go { margin-top: 1.1rem; font-family: var(--caps); font-size: 0.7rem; letter-spacing: 0.24em; text-transform: uppercase; color: var(--gold); }
.rv-choices.chosen .rv-choice { min-height: 230px; }
.rv-choices.chosen .rv-choice:not(.on) { opacity: 0.72; }
.rv-choices.chosen .rv-choice:not(.on):hover { opacity: 1; }
.rv-panel { margin-top: 3.4rem; }
.rv-panel.in { animation: rvIn 0.8s cubic-bezier(.2,.8,.2,1); }
@keyframes rvIn { from { opacity: 0; transform: translateY(40px); } to { opacity: 1; transform: none; } }
.rv-panel-head { text-align: center; margin-bottom: 2rem; }
.rv-panel-head .kicker { font-family: var(--caps); font-size: 0.72rem; letter-spacing: 0.36em; text-transform: uppercase; color: var(--gold); }
.rv-panel-head h3 { font-size: clamp(2rem, 4.4vw, 3.2rem); line-height: 1.1; margin: 0.4rem 0 0.5rem;
  background: linear-gradient(180deg, #fffcea 20%, #f3d98a 78%, #c99a35 100%); -webkit-background-clip: text; background-clip: text; color: transparent; }
.rv-panel-head p { font-style: italic; color: var(--moon); font-size: 1.1rem; max-width: 640px; margin: 0 auto; }
@media (max-width: 800px) { .rv-choices { grid-template-columns: 1fr; } .rv-choice { min-height: 300px; } .rv-choices.chosen .rv-choice { min-height: 180px; } }

/* ============================================================
   v81 · information pages, footer legal links, privacy notice
   ============================================================ */
footer .f-legal { display: flex; gap: 0.5rem 1.6rem; justify-content: center; flex-wrap: wrap; margin: 0.4rem 0 1.4rem; padding-top: 1.2rem; border-top: 1px solid rgba(245,200,66,0.18); }
footer .f-legal a { font-family: var(--caps); font-size: 0.64rem; letter-spacing: 0.2em; text-transform: uppercase; color: var(--gold); }
footer .f-legal a:hover { color: #ffe9a8; }

.privacy-note { position: fixed; left: 50%; bottom: 18px; z-index: 330; width: min(680px, calc(100vw - 24px)); translate: -50% 30px; opacity: 0;
  display: flex; align-items: center; gap: 1.1rem; padding: 0.9rem 1.2rem 0.9rem 1.4rem; border-radius: 18px;
  border: 1px solid rgba(245,200,66,0.6); background: rgba(7,12,24,0.96); box-shadow: 0 14px 50px rgba(0,0,0,0.7), 0 0 30px rgba(245,200,66,0.18);
  transition: opacity 0.5s ease, translate 0.5s ease; }
.privacy-note.show { opacity: 1; translate: -50% 0; }
.privacy-note p { flex: 1; font-size: 0.95rem; line-height: 1.45; color: var(--cream-dim); margin: 0; }
.privacy-note a { white-space: nowrap; border-bottom: 1px dotted rgba(245,200,66,0.6); }
.privacy-note .btn { flex: none; padding: 0.6rem 1.3rem; font-size: 0.68rem; }
@media (max-width: 560px) { .privacy-note { flex-direction: column; align-items: stretch; text-align: center; gap: 0.7rem; bottom: 10px; } }

body.doc-page { background: radial-gradient(ellipse at 50% 0%, rgba(245,200,66,0.09), transparent 45%), var(--ink); }
.doc-nav { position: sticky; top: 0; z-index: 100; display: flex; align-items: center; justify-content: space-between; padding: 0.6rem 1.6rem;
  background: linear-gradient(rgba(7,12,24,0.95), rgba(7,12,24,0.82)); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border-bottom: 1px solid rgba(245,200,66,0.22); }
.doc-nav .brand { display: flex; align-items: center; gap: 0.7rem; }
.doc-nav .brand img { height: 44px; width: auto; filter: drop-shadow(0 0 6px rgba(245,200,66,0.35)); }
.doc-nav .brand span { font-family: var(--caps); letter-spacing: 0.16em; font-size: 0.98rem; text-transform: uppercase; color: var(--cream); white-space: nowrap; }
.doc-back { font-family: var(--caps); font-size: 0.68rem; letter-spacing: 0.2em; text-transform: uppercase; color: var(--gold); white-space: nowrap; }
.doc-back:hover { color: #ffe9a8; }
.doc-wrap { max-width: 900px; margin: 0 auto; padding: 4.2rem 1.4rem 5rem; }
.doc-wrap .section-head { margin-bottom: 2rem; }
.doc-title { font-size: clamp(2.3rem, 5.4vw, 3.8rem); line-height: 1.06; font-weight: 600;
  background: linear-gradient(180deg, #fffcea 20%, #f3d98a 78%, #c99a35 100%); -webkit-background-clip: text; background-clip: text; color: transparent; filter: drop-shadow(0 4px 18px rgba(0,0,0,0.6)); }
.doc-tabs { display: flex; gap: 0.5rem; justify-content: center; flex-wrap: wrap; margin-bottom: 2.4rem; }
.doc-tabs a { padding: 0.5rem 1.1rem; border-radius: 999px; border: 1px solid rgba(245,200,66,0.45); background: rgba(7,12,24,0.6);
  font-family: var(--caps); font-size: 0.64rem; letter-spacing: 0.18em; text-transform: uppercase; color: var(--cream-dim); transition: all 0.25s; }
.doc-tabs a:hover { color: #ffe9a8; border-color: rgba(245,200,66,0.9); }
.doc-tabs a.on { background: var(--gilt); color: #241703; border-color: #fff0b8; font-weight: 600; }
.doc-body { padding: 2.6rem 2.6rem 2.8rem; border-radius: 22px; border: 1px solid rgba(245,200,66,0.3); background: linear-gradient(165deg, rgba(22,34,60,0.82), rgba(9,15,29,0.92)); box-shadow: 0 24px 70px rgba(0,0,0,0.5); }
.doc-body h2 { font-size: 1.65rem; line-height: 1.2; color: #ffe9a8; margin: 2.2rem 0 0.7rem; }
.doc-body > h2:first-child, .doc-body .doc-summary h2, .doc-body .enq-card h2, .doc-body .faq-cat:first-of-type h2 { margin-top: 0; }
.doc-body p { color: var(--cream-dim); margin-bottom: 0.95rem; font-size: 1.08rem; }
.doc-body p strong { color: var(--cream); font-weight: 500; }
.doc-body ul { margin: 0 0 1.1rem 0; list-style: none; }
.doc-body ul li { position: relative; padding: 0.22rem 0 0.22rem 1.5rem; color: var(--cream-dim); font-size: 1.08rem; }
.doc-body ul li::before { content: ""; position: absolute; left: 0.2rem; top: 0.95rem; width: 7px; height: 7px; rotate: 45deg; background: var(--gold); }
.doc-body a { border-bottom: 1px dotted rgba(245,200,66,0.6); }
.doc-body a.btn { border-bottom: 1px solid rgba(245,200,66,0.65); }
.doc-updated { font-family: var(--caps); font-size: 0.66rem !important; letter-spacing: 0.22em; text-transform: uppercase; color: var(--moon) !important; }
.doc-summary { margin: 0.6rem 0 2.2rem; padding: 1.5rem 1.7rem 0.9rem; border-radius: 16px; border: 1px solid rgba(245,200,66,0.55); background: radial-gradient(ellipse at 50% 0%, rgba(245,200,66,0.13), transparent 70%), rgba(7,12,24,0.55); }
.doc-summary h2 { font-size: 1.35rem; margin-bottom: 0.6rem; }
.doc-table-wrap { overflow-x: auto; margin-bottom: 1.2rem; border-radius: 12px; border: 1px solid rgba(245,200,66,0.3); }
.doc-table { width: 100%; border-collapse: collapse; font-size: 1rem; min-width: 520px; }
.doc-table th { text-align: left; padding: 0.7rem 1rem; font-family: var(--caps); font-weight: 400; font-size: 0.62rem; letter-spacing: 0.2em; text-transform: uppercase; color: var(--gold); background: rgba(7,12,24,0.7); }
.doc-table td { padding: 0.75rem 1rem; color: var(--cream-dim); border-top: 1px solid rgba(245,200,66,0.16); vertical-align: top; }
.doc-table td:first-child { color: var(--cream); white-space: nowrap; }
.doc-done { color: #8fe3a2; font-style: italic; margin-left: 0.6rem; }
.doc-after { margin-top: 2rem; text-align: center; font-style: italic; }
.faq-tools { margin-bottom: 1.8rem; }
.faq-tools input { width: 100%; font-family: var(--serif-body); font-size: 1.1rem; padding: 0.85rem 1.3rem; border-radius: 999px; border: 1px solid rgba(245,200,66,0.45); background: rgba(7,12,24,0.7); color: var(--cream); outline: none; margin-bottom: 1.1rem; }
.faq-tools input:focus { border-color: var(--gold); box-shadow: 0 0 18px rgba(245,200,66,0.25); }
.faq-tools .qz-filters { margin-bottom: 0; }
.faq-cat { margin-bottom: 2rem; }
.faq { border: 1px solid rgba(245,200,66,0.28); border-radius: 14px; margin-bottom: 0.6rem; background: rgba(7,12,24,0.5); transition: border-color 0.3s, box-shadow 0.3s; }
.faq[open] { border-color: rgba(245,200,66,0.8); box-shadow: 0 0 26px rgba(245,200,66,0.14); }
.faq summary { cursor: pointer; list-style: none; padding: 0.95rem 3rem 0.95rem 1.3rem; position: relative; font-family: var(--serif-display); font-weight: 600; font-size: 1.28rem; line-height: 1.25; color: var(--cream); }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: 1.2rem; top: 50%; translate: 0 -50%; font-size: 1.6rem; color: var(--gold); transition: rotate 0.3s; }
.faq[open] summary::after { rotate: 45deg; }
.faq-a { padding: 0 1.3rem 0.6rem; }
.enq-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1.2rem; }
.enq-card { display: flex; flex-direction: column; padding: 1.5rem 1.5rem 1.6rem; border-radius: 16px; border: 1px solid rgba(245,200,66,0.3); background: rgba(7,12,24,0.5); }
.enq-card h2 { font-size: 1.45rem; margin: 0.35rem 0 0.6rem; }
.enq-card p { font-size: 1rem; }
.enq-card > .btn, .enq-card .gu-btns { margin-top: auto; align-self: flex-start; }
.enq-card .btn { padding: 0.75rem 1.3rem; font-size: 0.68rem; }
.enq-safe { margin: 1.6rem 0 0; }
.doc-foot { text-align: center; padding: 3rem 1.4rem 3.4rem; border-top: 1px solid rgba(245,200,66,0.18); }
.doc-foot .f-title { font-family: var(--serif-display); font-size: 1.4rem; color: var(--cream); }
.doc-foot .f-links { margin: 1.1rem 0; display: flex; gap: 0.5rem 1.6rem; justify-content: center; flex-wrap: wrap; }
.doc-foot .f-links a { color: var(--cream-dim); font-size: 0.95rem; }
.doc-foot .f-links a.on, .doc-foot .f-links a:hover { color: var(--gold); }
.doc-foot .f-copy { font-size: 0.82rem; color: var(--moon); max-width: 760px; margin: 0 auto; }
@media (max-width: 700px) {
  .doc-body { padding: 1.6rem 1.15rem 1.8rem; } .doc-wrap { padding: 2.6rem 0.8rem 3.4rem; }
  .enq-grid { grid-template-columns: 1fr; }
  .doc-nav .brand span { display: none; }
}
.doc-body section.faq-cat { padding: 0; }

/* v82 · information reader on the main page; footer always on top of page effects */
footer { position: relative; z-index: 65; }
.author-link { margin-top: 1.4rem; }
.author-link .btn { padding: 0.8rem 1.6rem; font-size: 0.72rem; }
.doc-reader { position: fixed; inset: 0; z-index: 245; display: none; background: rgba(4,7,14,0.97); }
.doc-reader.open { display: block; animation: ttIn 0.35s ease; }
.doc-reader .lb-close { position: absolute; top: 14px; right: 22px; z-index: 3; }
.doc-reader-scroll { position: absolute; inset: 0; overflow-y: auto; -webkit-overflow-scrolling: touch; background: radial-gradient(ellipse at 50% 0%, rgba(245,200,66,0.09), transparent 45%); }
.doc-reader .doc-wrap { padding-top: 3.4rem; }
.doc-reader { background: #060a14; }

/* v83 · the storyteller's portrait */
.author-portrait { text-align: center; }
.author-portrait a { display: block; }
.author-portrait img { aspect-ratio: 1122 / 1402; width: min(420px, 100%); margin: 0 auto; border-radius: 18px; object-fit: cover;
  border: 1px solid rgba(245,200,66,0.75); box-shadow: 0 0 0 5px rgba(7,12,24,0.9), 0 0 0 6px rgba(245,200,66,0.4), 0 0 70px rgba(245,200,66,0.2), 0 30px 80px rgba(0,0,0,0.7);
  transition: transform 0.6s cubic-bezier(.2,.8,.2,1), box-shadow 0.6s; }
.author-portrait a:hover img { transform: translateY(-6px); box-shadow: 0 0 0 5px rgba(7,12,24,0.9), 0 0 0 6px rgba(245,200,66,0.8), 0 0 90px rgba(245,200,66,0.4), 0 36px 90px rgba(0,0,0,0.75); }
.author-portrait figcaption { margin-top: 1.2rem; font-family: var(--caps); font-size: 0.68rem; letter-spacing: 0.22em; text-transform: uppercase; color: var(--moon); }
.author-portrait figcaption a { display: inline; color: var(--gold); border-bottom: 1px dotted rgba(245,200,66,0.6); }

/* v84 · a gentle golden glow around the writer's portrait */
.author-portrait a { position: relative; width: min(420px, 100%); margin: 0 auto; }
.author-portrait a::before { content: ""; position: absolute; inset: -14%; z-index: -1; border-radius: 50%; pointer-events: none;
  background: radial-gradient(ellipse at 50% 50%, rgba(245,200,66,0.34) 0%, rgba(245,200,66,0.16) 38%, rgba(245,200,66,0) 68%);
  animation: portraitHalo 6s ease-in-out infinite; }
.author-portrait img { width: 100%; animation: portraitGlow 6s ease-in-out infinite; }
@keyframes portraitGlow {
  0%, 100% { box-shadow: 0 0 0 5px rgba(7,12,24,0.9), 0 0 0 6px rgba(245,200,66,0.45), 0 0 34px rgba(245,200,66,0.28), 0 0 90px rgba(245,200,66,0.16), 0 30px 80px rgba(0,0,0,0.7); }
  50% { box-shadow: 0 0 0 5px rgba(7,12,24,0.9), 0 0 0 6px rgba(245,200,66,0.75), 0 0 52px rgba(245,200,66,0.5), 0 0 130px rgba(245,200,66,0.3), 0 30px 80px rgba(0,0,0,0.7); }
}
@keyframes portraitHalo { 0%, 100% { opacity: 0.6; transform: scale(0.97); } 50% { opacity: 1; transform: scale(1.03); } }
.author-portrait a:hover img { animation-play-state: paused; }
#author .author-art { position: relative; z-index: 0; }
@media (prefers-reduced-motion: reduce) { .author-portrait img, .author-portrait a::before { animation: none; } }

/* v86 · the writer's opening quote sits on one line on wide screens */
@media (min-width: 901px) {
  #author .wrap { max-width: 1200px; }
  .author-copy .drop-quote { white-space: nowrap; font-size: clamp(1rem, 1.72vw, 1.36rem); }
}

/* v87 · every close button is a golden CLOSE pill, like the Be First button */
button.lb-close.lb-close, button.cm-close.cm-close, button.scene-close.scene-close {
  position: absolute; top: 16px; right: 20px; left: auto; z-index: 30;
  width: auto; height: auto; padding: 0.55rem 1.25rem; border-radius: 999px; border: 1px solid #fff0b8; cursor: pointer;
  font-family: var(--caps); font-weight: 600; font-size: 0.72rem; line-height: 1; letter-spacing: 0.2em; text-transform: uppercase; color: #241703;
  background: var(--gilt); background-size: 200% 100%; animation: giltSlide 5s linear infinite;
  box-shadow: 0 0 18px rgba(245,200,66,0.4), 0 6px 18px rgba(0,0,0,0.5);
  display: inline-flex; align-items: center; justify-content: center; opacity: 1; text-shadow: none;
  transition: transform 0.2s, box-shadow 0.25s;
}
button.lb-close.lb-close:hover, button.cm-close.cm-close:hover, button.scene-close.scene-close:hover {
  transform: translateY(-2px); background: var(--gilt); background-size: 200% 100%; color: #241703; box-shadow: 0 0 28px rgba(245,200,66,0.75), 0 8px 22px rgba(0,0,0,0.55);
}
.lightbox > button.lb-close.lb-close, .doc-reader > button.lb-close.lb-close, .tale-theatre > button.lb-close.lb-close, .qz-modal > button.lb-close.lb-close, .flyin-overlay > button.lb-close.lb-close, .char-modal > button.cm-close.cm-close { position: fixed; }
button.scene-close.scene-close { top: 8px; right: 8px; padding: 0.4rem 0.9rem; font-size: 0.6rem; }
@media (max-width: 640px) {
  button.lb-close.lb-close, button.cm-close.cm-close { top: 10px; right: 10px; padding: 0.5rem 1rem; font-size: 0.66rem; }
}
@media (prefers-reduced-motion: reduce) { button.lb-close.lb-close, button.cm-close.cm-close, button.scene-close.scene-close { animation: none; } }

/* ============================================================
   v88 · five revels under one roof
   ============================================================ */
#revels .rv-panel { background: none; padding: 0; }
#revels .rv-panel::before { display: none !important; }
.rv-choices { grid-template-columns: repeat(6, 1fr); gap: 1.5rem; max-width: 1240px; }
.rv-choice { grid-column: span 2; min-height: 330px; }
.rv-choice:nth-child(-n+2) { grid-column: span 3; min-height: 380px; }
.rv-choice:nth-child(n+3) .rv-body b { font-size: clamp(1.6rem, 2.5vw, 2.1rem); }
.rv-choice:nth-child(n+3) .rv-body i { font-size: 1rem; }
/* once a revel is chosen, the five doors fold into one row of tabs above it */
.rv-choices.chosen { grid-template-columns: repeat(5, 1fr); gap: 0.9rem; }
.rv-choices.chosen .rv-choice, .rv-choices.chosen .rv-choice:nth-child(-n+2) { grid-column: span 1; min-height: 132px; border-radius: 18px; }
.rv-choices.chosen .rv-body { padding: 0.9rem 1rem 1rem; }
.rv-choices.chosen .rv-body i, .rv-choices.chosen .rv-chip, .rv-choices.chosen .rv-go { display: none; }
.rv-choices.chosen .rv-body b, .rv-choices.chosen .rv-choice:nth-child(n+3) .rv-body b { font-size: clamp(1.05rem, 1.55vw, 1.45rem); margin-top: 0; }
.rv-choices.chosen .rv-choice:hover { transform: translateY(-4px); }
#revels .secret-grid, #revels .jr-grid, #revels .jr-vault, #revels .col-gate { margin-left: auto; margin-right: auto; }
@media (max-width: 1000px) {
  .rv-choices { grid-template-columns: repeat(2, 1fr); }
  .rv-choice, .rv-choice:nth-child(-n+2) { grid-column: span 1; min-height: 280px; }
  .rv-choices.chosen { grid-template-columns: repeat(5, 1fr); gap: 0.5rem; }
  .rv-choices.chosen .rv-choice, .rv-choices.chosen .rv-choice:nth-child(-n+2) { min-height: 100px; }
}
@media (max-width: 640px) {
  .rv-choices { grid-template-columns: 1fr; gap: 1rem; }
  .rv-choice, .rv-choice:nth-child(-n+2) { min-height: 230px; }
  .rv-choices.chosen { grid-template-columns: repeat(2, 1fr); }
  .rv-choices.chosen .rv-choice, .rv-choices.chosen .rv-choice:nth-child(-n+2) { min-height: 74px; border-radius: 14px; }
  .rv-choices.chosen .rv-choice:last-child { grid-column: span 2; }
  .rv-choices.chosen .rv-body { padding: 0.6rem 0.8rem; }
}

/* v88 · the folded menu fades in place instead of waiting off screen, so phones never get a sideways scroll */
@media (max-width: 1340px) {
  nav ul { transform: translateY(-10px); opacity: 0; visibility: hidden; pointer-events: none; transition: opacity 0.25s ease, transform 0.25s ease, visibility 0s linear 0.25s; max-height: calc(100vh - 70px); overflow-y: auto; }
  nav ul.open { transform: none; opacity: 1; visibility: visible; pointer-events: auto; transition-delay: 0s; }
}
/* the portrait's halo must never widen the page on phones */
#author { overflow-x: hidden; overflow-x: clip; }

/* v89 · door titles line up across each row, whatever the length of the description beneath */
.rv-choice .rv-body i { min-height: 3em; }
.rv-choice:nth-child(n+3) .rv-body i { min-height: 4.5em; }
.rv-choice .rv-body b { white-space: nowrap; }
@media (max-width: 1000px) { .rv-choice .rv-body i, .rv-choice:nth-child(n+3) .rv-body i { min-height: 4.5em; } .rv-choice .rv-body b { white-space: normal; } }
@media (max-width: 640px) { .rv-choice .rv-body i, .rv-choice:nth-child(n+3) .rv-body i { min-height: 0; } }
.rv-choices.chosen .rv-choice .rv-body b { white-space: normal; }

/* ============================================================
   v90 · embossed gold titles
   ============================================================ */
.section-head h2, .doc-title, .rv-panel-head h3, .join-title, .oath h3, .jr-vault h3, .ff-copy h3, #book .book-copy h3, .tt-info h3 {
  background: linear-gradient(180deg, #fffdf0 0%, #fbe9a6 20%, #f0c85a 43%, #b8862b 53%, #e9c360 66%, #fff3c4 84%, #c9993a 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent; -webkit-text-fill-color: transparent;
  text-shadow: none;
  filter:
    drop-shadow(0 -1px 0 rgba(255, 252, 232, 0.55))
    drop-shadow(0 1px 0 #8a5f14)
    drop-shadow(0 2px 0 #5c3d0a)
    drop-shadow(0 3px 1px rgba(40, 26, 4, 0.9))
    drop-shadow(0 10px 22px rgba(0, 0, 0, 0.65))
    drop-shadow(0 0 26px rgba(245, 200, 66, 0.16));
  padding-bottom: 0.08em;
}
.section-head h2, .doc-title { letter-spacing: 0.01em; }
/* a slow glint travels across the main section titles */
.section-head h2, .doc-title { position: relative; }
@supports (background-clip: text) or (-webkit-background-clip: text) {
  .section-head h2, .doc-title {
    background-image:
      linear-gradient(105deg, rgba(255,255,255,0) 42%, rgba(255,255,255,0.85) 50%, rgba(255,255,255,0) 58%),
      linear-gradient(180deg, #fffdf0 0%, #fbe9a6 20%, #f0c85a 43%, #b8862b 53%, #e9c360 66%, #fff3c4 84%, #c9993a 100%);
    background-size: 280% 100%, 100% 100%; background-position: 140% 0, 0 0; background-repeat: no-repeat;
    animation: titleGlint 9s ease-in-out infinite;
  }
}
@keyframes titleGlint { 0%, 62% { background-position: 140% 0, 0 0; } 100% { background-position: -140% 0, 0 0; } }
/* door titles on the Revels cards pick up the same metal, a little lighter so they read over the pictures */
.rv-body b {
  background: linear-gradient(180deg, #fffdf0 0%, #fdeeb4 30%, #f2cf6a 52%, #d9a93e 60%, #fbe6a0 82%, #e2b450 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent; -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 -1px 0 rgba(255,252,232,0.5)) drop-shadow(0 1px 0 #7a5410) drop-shadow(0 2px 0 #4a3008) drop-shadow(0 4px 10px rgba(0,0,0,0.85));
}
@media (prefers-reduced-motion: reduce) { .section-head h2, .doc-title { animation: none; } }

/* ============================================================
   v91 · The Enchantments: seven doors (three above, four below)
   ============================================================ */
.rv-choice::before { background-position: var(--pos, center); }
.rv-choices.rv-seven { grid-template-columns: repeat(12, 1fr); gap: 1.4rem; max-width: 1280px; }
.rv-choices.rv-seven .rv-choice, .rv-choices.rv-seven .rv-choice:nth-child(-n+2) { grid-column: span 3; min-height: 300px; }
.rv-choices.rv-seven .rv-choice:nth-child(-n+3) { grid-column: span 4; min-height: 360px; }
.rv-choices.rv-seven .rv-choice .rv-body b { font-size: clamp(1.45rem, 2.05vw, 1.9rem); white-space: nowrap; }
.rv-choices.rv-seven .rv-choice:nth-child(-n+3) .rv-body b { font-size: clamp(1.8rem, 2.7vw, 2.5rem); }
.rv-choices.rv-seven .rv-choice .rv-body i { font-size: 0.98rem; min-height: 4.5em; }
.rv-choices.rv-seven .rv-choice:nth-child(-n+3) .rv-body i { font-size: 1.05rem; min-height: 3.2em; }
.rv-choices.rv-seven .rv-body { padding: 1.5rem 1.5rem 1.6rem; }
.rv-choices.rv-seven.chosen { grid-template-columns: repeat(7, 1fr); gap: 0.7rem; }
.rv-choices.rv-seven.chosen .rv-choice, .rv-choices.rv-seven.chosen .rv-choice:nth-child(-n+3) { grid-column: span 1; min-height: 118px; border-radius: 16px; }
.rv-choices.rv-seven.chosen .rv-body { padding: 0.7rem 0.8rem 0.8rem; }
.rv-choices.rv-seven.chosen .rv-choice .rv-body b, .rv-choices.rv-seven.chosen .rv-choice:nth-child(-n+3) .rv-body b { font-size: clamp(0.92rem, 1.25vw, 1.2rem); white-space: normal; line-height: 1.12; }
#revels .rv-panel .oath { margin-top: 0; }
#revels .rv-panel .wish-box { margin-left: auto; margin-right: auto; }
@media (max-width: 1100px) {
  .rv-choices.rv-seven { grid-template-columns: repeat(2, 1fr); }
  .rv-choices.rv-seven .rv-choice, .rv-choices.rv-seven .rv-choice:nth-child(-n+3) { grid-column: span 1; min-height: 260px; }
  .rv-choices.rv-seven .rv-choice:first-child { grid-column: span 2; }
  .rv-choices.rv-seven .rv-choice .rv-body b, .rv-choices.rv-seven .rv-choice:nth-child(-n+3) .rv-body b { white-space: normal; font-size: clamp(1.5rem, 3.4vw, 2rem); }
  .rv-choices.rv-seven .rv-choice .rv-body i, .rv-choices.rv-seven .rv-choice:nth-child(-n+3) .rv-body i { min-height: 4.5em; }
  .rv-choices.rv-seven.chosen { grid-template-columns: repeat(4, 1fr); gap: 0.5rem; }
  .rv-choices.rv-seven.chosen .rv-choice, .rv-choices.rv-seven.chosen .rv-choice:nth-child(-n+3), .rv-choices.rv-seven.chosen .rv-choice:first-child { grid-column: span 1; min-height: 92px; }
}
@media (max-width: 640px) {
  .rv-choices.rv-seven { grid-template-columns: 1fr; gap: 1rem; }
  .rv-choices.rv-seven .rv-choice, .rv-choices.rv-seven .rv-choice:nth-child(-n+3), .rv-choices.rv-seven .rv-choice:first-child { grid-column: span 1; min-height: 210px; }
  .rv-choices.rv-seven .rv-choice .rv-body i, .rv-choices.rv-seven .rv-choice:nth-child(-n+3) .rv-body i { min-height: 0; }
  .rv-choices.rv-seven.chosen { grid-template-columns: repeat(2, 1fr); }
  .rv-choices.rv-seven.chosen .rv-choice, .rv-choices.rv-seven.chosen .rv-choice:nth-child(-n+3) { min-height: 70px; border-radius: 14px; }
  .rv-choices.rv-seven.chosen .rv-choice:last-child { grid-column: span 2; }
  .rv-choices.rv-seven.chosen .rv-choice:first-child { grid-column: span 1; }
}
.rv-choices.rv-seven .rv-choice:nth-child(-n+3) .rv-body b { font-size: clamp(1.6rem, 2.25vw, 2.15rem); }
.rv-choices.rv-seven .rv-choice:nth-child(n+4) .rv-body b { font-size: clamp(1.2rem, 1.72vw, 1.62rem); }
.rv-choices.rv-seven .rv-choice:nth-child(-n+3) .rv-body i { min-height: 4.8em; }
@media (max-width: 1100px) { .rv-choices.rv-seven .rv-choice:nth-child(n+4) .rv-body b { font-size: clamp(1.5rem, 3.4vw, 2rem); } }
/* v92 · the seven tabs all share one title size once a door is chosen */
.rv-choices.rv-seven.chosen .rv-choice:nth-child(n) .rv-body b { font-size: clamp(0.92rem, 1.25vw, 1.2rem); white-space: normal; line-height: 1.12; }

/* ============================================================
   v93 · fonts served by the site itself, landmarks for search engines and screen readers
   ============================================================ */
@font-face { font-family: "Cormorant Garamond"; font-style: normal; font-weight: 500; font-display: swap; src: url("../fonts/cormorant-garamond-latin-500-normal.woff2") format("woff2"); }
@font-face { font-family: "Cormorant Garamond"; font-style: normal; font-weight: 600; font-display: swap; src: url("../fonts/cormorant-garamond-latin-600-normal.woff2") format("woff2"); }
@font-face { font-family: "Cormorant Garamond"; font-style: italic; font-weight: 500; font-display: swap; src: url("../fonts/cormorant-garamond-latin-500-italic.woff2") format("woff2"); }
@font-face { font-family: "Cormorant Garamond"; font-style: italic; font-weight: 600; font-display: swap; src: url("../fonts/cormorant-garamond-latin-600-italic.woff2") format("woff2"); }
@font-face { font-family: "EB Garamond"; font-style: normal; font-weight: 400; font-display: swap; src: url("../fonts/eb-garamond-latin-400-normal.woff2") format("woff2"); }
@font-face { font-family: "EB Garamond"; font-style: normal; font-weight: 500; font-display: swap; src: url("../fonts/eb-garamond-latin-500-normal.woff2") format("woff2"); }
@font-face { font-family: "EB Garamond"; font-style: italic; font-weight: 400; font-display: swap; src: url("../fonts/eb-garamond-latin-400-italic.woff2") format("woff2"); }
@font-face { font-family: "Cinzel"; font-style: normal; font-weight: 400; font-display: swap; src: url("../fonts/cinzel-latin-400-normal.woff2") format("woff2"); }
@font-face { font-family: "Cinzel"; font-style: normal; font-weight: 600; font-display: swap; src: url("../fonts/cinzel-latin-600-normal.woff2") format("woff2"); }

.sr-only { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.skip-link { position: fixed; left: 12px; top: -80px; z-index: 600; padding: 0.7rem 1.2rem; border-radius: 999px; background: var(--gilt); color: #241703;
  font-family: var(--caps); font-size: 0.72rem; letter-spacing: 0.18em; text-transform: uppercase; font-weight: 600; transition: top 0.2s; }
.skip-link:focus { top: 12px; }
/* phones measure the screen without the address bar */
.ps-stage { height: 100vh; height: 100svh; }
/* nothing drifting near the edge (fireflies, glows) may widen the page; clip keeps the sticky door sequence working */
main { overflow-x: clip; }

/* v94 · phones and tablets: the cast orbs gather in the air above the open book, never across its pages */
@media (max-width: 640px) {
  #book .book3d-stage .bk-orb { width: min(19vw, 96px); }
  #book .bk-orb span { font-size: 0.44rem; letter-spacing: 0.1em; bottom: -1.1rem; }
  #book .book3d-stage.opened { height: 570px; }
  #book .book3d-stage.opened .book3d { top: 350px; }
  #book .book3d-stage.magic .bk-orb[data-i="2"] { left: 13%; top: 58px; }
  #book .book3d-stage.magic .bk-orb[data-i="3"] { left: 38%; top: 48px; }
  #book .book3d-stage.magic .bk-orb[data-i="4"] { left: 62%; top: 48px; }
  #book .book3d-stage.magic .bk-orb[data-i="5"] { left: 87%; top: 58px; }
  #book .book3d-stage.magic .bk-orb[data-i="0"] { left: 13%; top: 164px; }
  #book .book3d-stage.magic .bk-orb[data-i="1"] { left: 38%; top: 154px; }
  #book .book3d-stage.magic .bk-orb[data-i="6"] { left: 62%; top: 154px; }
  #book .book3d-stage.magic .bk-orb[data-i="7"] { left: 87%; top: 164px; }
}
@media (min-width: 641px) and (max-width: 1199px) {
  #book .book3d-stage .bk-orb { width: min(11vw, 116px); }
  #book .bk-orb span { font-size: 0.5rem; letter-spacing: 0.12em; bottom: -1.3rem; }
  #book .book3d-stage.opened { height: 800px; }
  #book .book3d-stage.opened .book3d { top: 493px; }
  #book .book3d-stage.magic .bk-orb[data-i="0"] { left: 8%;  top: 132px; }
  #book .book3d-stage.magic .bk-orb[data-i="1"] { left: 20%; top: 102px; }
  #book .book3d-stage.magic .bk-orb[data-i="2"] { left: 32%; top: 80px; }
  #book .book3d-stage.magic .bk-orb[data-i="3"] { left: 44%; top: 68px; }
  #book .book3d-stage.magic .bk-orb[data-i="4"] { left: 56%; top: 68px; }
  #book .book3d-stage.magic .bk-orb[data-i="5"] { left: 68%; top: 80px; }
  #book .book3d-stage.magic .bk-orb[data-i="6"] { left: 80%; top: 102px; }
  #book .book3d-stage.magic .bk-orb[data-i="7"] { left: 92%; top: 132px; }
}
/* v94 · phones held sideways: a smaller book so the whole spread fits on the screen */
@media (min-width: 641px) and (max-height: 500px) and (orientation: landscape) {
  #book .book3d-stage { --bw: 232px; --bh: 310px; --bd: 25px; }
  #book .book3d-stage .bk-orb { width: 84px; }
  #book .book3d-stage.opened { height: 560px; }
  #book .book3d-stage.opened .book3d { top: 372px; }
}
/* v95 · the book's headline stays on one line (it wraps evenly only on small phones) */
#book .book-copy h3 { text-wrap: balance; }
@media (min-width: 700px) { #book .book-copy h3 { white-space: nowrap; font-size: min(2.15rem, 3.5vw); } }
/* v96 · the book's headline: a lighter touch, only slightly embossed */
#book .book-copy h3 {
  background: linear-gradient(180deg, #fff8dc 0%, #f6dc8c 45%, #e6bf5e 60%, #f3d98e 100%);
  -webkit-background-clip: text; background-clip: text;
  filter:
    drop-shadow(0 -1px 0 rgba(255, 252, 232, 0.3))
    drop-shadow(0 1px 0 rgba(92, 61, 10, 0.85))
    drop-shadow(0 4px 12px rgba(0, 0, 0, 0.5));
}
/* v97 · "Welcome to the Realm" wears the same gilt as the homepage title */
.ps-cap-big {
  font-family: var(--serif-display); font-weight: 600; line-height: 0.92; letter-spacing: 0.01em;
  background: var(--gilt); background-size: 220% 100%; -webkit-background-clip: text; background-clip: text;
  color: transparent; -webkit-text-fill-color: transparent; text-shadow: none;
  filter: drop-shadow(0 6px 30px rgba(0,0,0,0.85)) drop-shadow(0 0 40px rgba(245,200,66,0.28));
  animation: giltSlide 9s linear infinite;
}
@media (prefers-reduced-motion: reduce) { .ps-cap-big { animation: none; } }
/* v98 · every title carries the homepage's slow sweep of light */
.section-head h2, .doc-title, .rv-panel-head h3, .join-title, .oath h3, .jr-vault h3, .ff-copy h3, .tt-info h3 {
  background-image:
    linear-gradient(100deg, rgba(255,250,224,0) 26%, rgba(255,251,230,0.92) 50%, rgba(255,250,224,0) 74%),
    linear-gradient(180deg, #fffdf0 0%, #fbe9a6 20%, #f0c85a 43%, #b8862b 53%, #e9c360 66%, #fff3c4 84%, #c9993a 100%);
  background-size: 200% 100%, 100% 100%; background-repeat: repeat-x, no-repeat; background-position: 0% 0, 0 0;
  -webkit-background-clip: text; background-clip: text;
  animation: titleSweep 9s linear infinite;
}
#book .book-copy h3 {
  background-image:
    linear-gradient(100deg, rgba(255,250,224,0) 26%, rgba(255,253,240,0.95) 50%, rgba(255,250,224,0) 74%),
    linear-gradient(180deg, #f6dc8c 0%, #e9c466 50%, #d9ae4c 62%, #ecd07e 100%);
  background-size: 200% 100%, 100% 100%; background-repeat: repeat-x, no-repeat; background-position: 0% 0, 0 0;
  -webkit-background-clip: text; background-clip: text;
  animation: titleSweep 9s linear infinite;
}
.rv-body b {
  background-image:
    linear-gradient(100deg, rgba(255,250,224,0) 26%, rgba(255,253,240,0.95) 50%, rgba(255,250,224,0) 74%),
    linear-gradient(180deg, #fbe9a6 0%, #f2cf6a 45%, #d9a93e 60%, #f0d283 82%, #e2b450 100%);
  background-size: 200% 100%, 100% 100%; background-repeat: repeat-x, no-repeat; background-position: 0% 0, 0 0;
  -webkit-background-clip: text; background-clip: text;
  animation: titleSweep 9s linear infinite;
}
@keyframes titleSweep { from { background-position: 0% 0, 0 0; } to { background-position: -200% 0, 0 0; } }
@media (prefers-reduced-motion: reduce) {
  .section-head h2, .doc-title, .rv-panel-head h3, .join-title, .oath h3, .jr-vault h3, .ff-copy h3, .tt-info h3, #book .book-copy h3, .rv-body b { animation: none; background-position: 100% 0, 0 0; }
}
/* v106 · the page's own scroll bars are invisible, sideways and up and down (the page still scrolls as normal).
   Safari needs care here: if the styled bar is switched off (display: none) or the standard scrollbar-width property is set on the page,
   Safari falls back to its own grey bars, most visibly when the page is magnified. So the styled bar is kept, at zero size and fully clear. */
html::-webkit-scrollbar, body::-webkit-scrollbar { width: 0 !important; height: 0 !important; background: transparent !important; }
html::-webkit-scrollbar-thumb, body::-webkit-scrollbar-thumb,
html::-webkit-scrollbar-track, body::-webkit-scrollbar-track,
html::-webkit-scrollbar-corner, body::-webkit-scrollbar-corner { background: transparent !important; border: 0 !important; box-shadow: none !important; }
@supports (-moz-appearance: none) { html { scrollbar-width: none; } }
/* v104 · the soft shade behind the homepage words now fades to nothing well before its edges, so no faint line shows above the ribbon */
.hero-cine .hero-inner::before { inset: -34% -26% -24%;
  background: radial-gradient(ellipse closest-side at 50% 47%, rgba(7,12,24,0.66) 0%, rgba(7,12,24,0.42) 48%, rgba(7,12,24,0.14) 78%, rgba(7,12,24,0) 100%); }
/* v105 · homepage: words and buttons a touch lower, and the little down arrow rests at the bottom of the screen */
header.hero.hero-cine { padding-top: 1.25rem; padding-bottom: 5.4rem; }
.hero-cine .scroll-hint { bottom: 0.45rem; }
@media (max-width: 640px) { header.hero.hero-cine { padding-top: 1.25rem; padding-bottom: 5.6rem; } }
/* v108 · Map of the Realm: on arrival the title, the lantern line and the whole map fit on one screen (the frame width is set by the script) */
@media (min-width: 900px) {
  #kingdom { padding-top: calc(63px + 0.9rem); }
  #kingdom .section-head { margin-bottom: 0.6rem; }
  #kingdom .section-head .kingdom-sub { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; border: 0; }
  #kingdom .map-hud { margin-bottom: 0.7rem; }
  #kingdom .map-hud-line { margin-bottom: 0.5rem; }
}
/* v109 · the trailer has a CLOSE button once it starts: it stops the film and takes you back to where you came from */
.trailer-stage > button.trailer-close.trailer-close { display: none; top: 14px; right: 16px; width: auto; height: auto; min-width: 0; max-width: none; aspect-ratio: auto; border-radius: 999px; padding: 0.55rem 1.25rem; font-size: 0.72rem; z-index: 6; }
.trailer-stage.playing > button.trailer-close.trailer-close { display: inline-flex; }
@media (max-width: 640px) { .trailer-stage > button.trailer-close.trailer-close { top: 8px; right: 8px; padding: 0.45rem 0.95rem; font-size: 0.64rem; } }
.map-img { aspect-ratio: 2400 / 1612; height: auto; }  /* room is kept for the map before it loads, so nothing below it jumps */

/* ============================================================
   v110 · A royal summons: the Queen's scroll waits in the dark, tied with ribbon and sealed in wax.
   Press the seal: it cracks in a burst of gold, the scroll unrolls and the Queen steps out of the light.
   ============================================================ */
#message { position: relative; }
.queen-dark { position: absolute; inset: 0; z-index: 1; pointer-events: none; opacity: 0; transition: opacity 2.2s ease;
  background: radial-gradient(ellipse 44% 40% at 50% 58%, rgba(3,6,14,0.3) 0%, rgba(3,6,14,0.82) 62%, rgba(3,6,14,0.95) 100%); }
#message.is-sealed .queen-dark { opacity: 1; }
#message .section-head { transition: opacity 1.8s ease, transform 0.9s ease; }
#message.is-sealed .section-head.reveal.visible { opacity: 0.5; }

/* the Queen: hidden in the light until the seal breaks */
.queen-scene .queen-portrait { transition: opacity 1.9s ease 0.95s, scale 2.6s cubic-bezier(.2,.7,.2,1) 0.6s, filter 2.4s ease 0.95s, transform 0.9s ease; }
.queen-scene.sealed .queen-portrait { opacity: 0 !important; scale: 0.88; filter: brightness(1.7) sepia(0.5) saturate(1.5) blur(9px); pointer-events: none; transition-delay: 0s; }
.queen-bloom { position: absolute; left: 50%; top: 46%; width: 120%; aspect-ratio: 1; translate: -50% -50%; z-index: 3; border-radius: 50%; pointer-events: none; opacity: 0;
  background: radial-gradient(circle, rgba(255,251,228,1) 0%, rgba(255,232,150,0.95) 24%, rgba(245,200,66,0.6) 46%, rgba(245,200,66,0) 70%); }
.queen-scene.opening .queen-bloom { animation: queenBloom 3s ease-out 0.25s both; }
@keyframes queenBloom { 0% { opacity: 0; scale: 0.15; } 30% { opacity: 1; scale: 1.1; } 55% { opacity: 0.85; scale: 1.5; } 100% { opacity: 0; scale: 2.3; } }

/* the scroll: rolled, tied and glowing in the middle of the dark */
.queen-scene .message-scroll { transition: transform 1.9s cubic-bezier(.3,.7,.2,1), filter 1.2s ease; z-index: 5; }
.queen-scene.sealed .message-scroll { transform: translate(var(--seal-dx, 0px), var(--seal-dy, 0px)); animation: sealGlow 3.4s ease-in-out infinite; }
@keyframes sealGlow {
  0%, 100% { filter: drop-shadow(0 20px 40px rgba(0,0,0,0.7)) drop-shadow(0 0 26px rgba(245,200,66,0.55)) drop-shadow(0 0 70px rgba(245,200,66,0.3)); }
  50% { filter: drop-shadow(0 20px 40px rgba(0,0,0,0.7)) drop-shadow(0 0 40px rgba(245,200,66,0.95)) drop-shadow(0 0 110px rgba(245,200,66,0.55)); }
}
.seal-ribbon { position: absolute; left: 50%; top: -9px; bottom: -9px; width: 46px; translate: -50% 0; z-index: 3; pointer-events: none; border-radius: 3px;
  background: linear-gradient(90deg, #6d120c 0%, #c23a2a 38%, #d9503c 50%, #a8261b 70%, #6d120c 100%); box-shadow: 0 3px 8px rgba(0,0,0,0.5), inset 0 0 0 1px rgba(255,200,170,0.18);
  opacity: 0; transition: opacity 0.6s ease, translate 0.9s cubic-bezier(.4,0,.8,.4); }
.seal-ribbon::before, .seal-ribbon::after { content: ""; position: absolute; top: calc(100% - 4px); width: 24px; height: 64px;
  background: linear-gradient(90deg, #7a140d, #c23a2a 55%, #8f1c12); clip-path: polygon(0 0, 100% 0, 100% 100%, 50% 78%, 0 100%); box-shadow: 0 3px 8px rgba(0,0,0,0.5); }
.seal-ribbon::before { left: -6px; rotate: 14deg; transform-origin: 50% 0; }
.seal-ribbon::after { right: -6px; rotate: -12deg; transform-origin: 50% 0; }
.queen-scene.sealed .seal-ribbon { opacity: 1; }
.queen-scene:not(.sealed) .seal-ribbon { translate: -50% 70px; }

/* the royal seal */
.royal-seal { position: absolute; left: 50%; top: 50%; width: 122px; height: 122px; translate: -50% -50%; z-index: 7; padding: 0; border: 0; background: none; border-radius: 50%; cursor: pointer;
  -webkit-tap-highlight-color: transparent; display: none; filter: drop-shadow(0 9px 14px rgba(0,0,0,0.6)) drop-shadow(0 0 20px rgba(245,200,66,0.5)); }
.queen-scene.sealed .royal-seal, .royal-seal.cracking { display: block; }
.queen-scene.sealed .royal-seal:not(.cracking) { animation: sealPulse 2.6s ease-in-out infinite; }
@keyframes sealPulse { 0%, 100% { scale: 1; } 50% { scale: 1.07; } }
.royal-seal:hover:not(.cracking) { animation-play-state: paused; scale: 1.1; }
.royal-seal:focus-visible { outline: 2px solid #fff3bf; outline-offset: 8px; }
.rs-half { position: absolute; inset: 0; border-radius: 48% 52% 50% 50% / 52% 47% 53% 48%;
  background: radial-gradient(circle at 35% 28%, #e56a50 0%, #b42a1d 48%, #7a140d 82%, #5c0d08 100%);
  box-shadow: inset 0 4px 7px rgba(255,255,255,0.35), inset 0 -8px 12px rgba(50,4,2,0.6); transition: transform 1s cubic-bezier(.25,.6,.35,1), opacity 0.8s ease 0.3s; }
.rs-half::before { content: ""; position: absolute; inset: 15px; border-radius: 50%; border: 2px solid rgba(248,220,140,0.6); box-shadow: inset 0 0 0 5px rgba(90,10,6,0.35), 0 0 0 1px rgba(60,5,2,0.4); }
.rs-half b { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; font-size: 3.3rem; font-weight: 400; line-height: 1; color: #f8dc8c; text-shadow: 0 2px 2px rgba(60,5,2,0.8), 0 -1px 0 rgba(255,240,200,0.5); }
.rs-l { clip-path: polygon(0 0, 54% 0, 46% 17%, 57% 33%, 44% 51%, 55% 68%, 46% 85%, 52% 100%, 0 100%); }
.rs-r { clip-path: polygon(54% 0, 100% 0, 100% 100%, 52% 100%, 46% 85%, 55% 68%, 44% 51%, 57% 33%, 46% 17%); }
.rs-flash { position: absolute; inset: -90%; border-radius: 50%; pointer-events: none; opacity: 0;
  background: radial-gradient(circle, rgba(255,253,240,1) 0%, rgba(255,236,170,0.9) 18%, rgba(245,200,66,0.5) 40%, rgba(245,200,66,0) 68%); mix-blend-mode: screen; }
.royal-seal.cracking { pointer-events: none; animation: sealShake 0.38s linear both; }
@keyframes sealShake { 0%, 100% { translate: -50% -50%; rotate: 0deg; } 15% { translate: calc(-50% - 4px) -50%; rotate: -5deg; } 35% { translate: calc(-50% + 5px) calc(-50% + 1px); rotate: 5deg; } 55% { translate: calc(-50% - 5px) -50%; rotate: -4deg; } 75% { translate: calc(-50% + 4px) calc(-50% - 1px); rotate: 3deg; } }
.royal-seal.cracked .rs-l { transform: translate(-64px, 58px) rotate(-38deg); opacity: 0; }
.royal-seal.cracked .rs-r { transform: translate(66px, 66px) rotate(32deg); opacity: 0; }
.royal-seal.cracked .rs-flash { animation: sealFlash 1.1s ease-out both; }
@keyframes sealFlash { 0% { opacity: 0; scale: 0.2; } 22% { opacity: 1; scale: 0.9; } 100% { opacity: 0; scale: 2.1; } }

/* the invitation beneath the seal, and the buttons that only appear once the scroll is open */
.queen-hint { position: absolute; left: 50%; top: calc(100% + 92px); translate: -50% 0; width: max-content; max-width: min(92vw, 560px); margin: 0; text-align: center; pointer-events: none;
  font-family: var(--serif-display); font-style: italic; font-size: clamp(1.1rem, 2.2vw, 1.5rem); line-height: 1.45; color: #ffe9a8; text-shadow: 0 2px 14px rgba(0,0,0,0.9), 0 0 24px rgba(245,200,66,0.35);
  opacity: 0; transition: opacity 0.7s ease; }
.queen-scene.sealed .queen-hint { opacity: 1; animation: hintBreath 3.4s ease-in-out infinite; }
@keyframes hintBreath { 0%, 100% { opacity: 0.72; } 50% { opacity: 1; } }
.queen-actions { transition: opacity 1.2s ease 2s, visibility 0s linear 0s; }
.queen-scene.sealed + .queen-actions { opacity: 0 !important; visibility: hidden; transition: opacity 0.4s ease, visibility 0s linear 0.4s; }
@media (max-width: 640px) {
  .royal-seal { width: 98px; height: 98px; } .rs-half b { font-size: 2.6rem; } .rs-half::before { inset: 12px; }
  .seal-ribbon { width: 38px; } .queen-hint { top: calc(100% + 80px); }
}
@media (prefers-reduced-motion: reduce) {
  .queen-scene .queen-portrait, .queen-scene .message-scroll, .rs-half, .queen-dark, .seal-ribbon { transition: none; }
  .queen-scene.sealed .message-scroll, .queen-scene.sealed .royal-seal, .queen-scene.sealed .queen-hint, .royal-seal.cracking, .queen-scene.opening .queen-bloom, .royal-seal.cracked .rs-flash { animation: none; }
  .queen-scene.sealed .message-scroll { filter: drop-shadow(0 0 34px rgba(245,200,66,0.8)); }
}
/* a sliver of parchment shows between the rods while the scroll is rolled and sealed */
.queen-scene.sealed .message-scroll .scroll-paper { max-height: 20px; }
/* v112 · the Queen's portrait is her living film: the still frame beneath no longer drifts, so the film sits exactly over it */
.queen-arch img { animation: none; transform: none; object-position: center; }
.queen-arch video { object-position: center; }

/* ============================================================
   v113 · Queen Titania's living page.
   Her own double page from the book, with the real scroll in her hand. It waits in shadow beneath the royal seal;
   break the seal and the page wakes, she reads her message, and each line glows on the scroll as she speaks.
   ============================================================ */
.queen-stage { position: relative; z-index: 3; max-width: 1180px; margin: 0 auto; }
.qs-frame { position: relative; aspect-ratio: 2848 / 1913; border-radius: 22px; overflow: hidden; isolation: isolate; background: #0a1230; container-type: inline-size;
  border: 2px solid #f5c842; transition: box-shadow 2.4s ease, border-color 2.4s ease;
  box-shadow: 0 0 0 8px rgba(7,12,24,0.85), 0 0 0 9px rgba(245,200,66,0.4), 0 0 80px rgba(245,200,66,0.4), 0 0 170px rgba(245,200,66,0.18), 0 34px 90px rgba(0,0,0,0.75); }
.queen-stage.sealed .qs-frame { border-color: rgba(245,200,66,0.45); box-shadow: 0 0 0 8px rgba(7,12,24,0.85), 0 0 0 9px rgba(245,200,66,0.18), 0 0 40px rgba(245,200,66,0.12), 0 34px 90px rgba(0,0,0,0.75); }
.qs-cam { position: absolute; inset: 0; transform-origin: 67% 48%; transition: transform 10s cubic-bezier(.3,.1,.3,1); will-change: transform; }
.queen-stage.reading .qs-cam { transform: scale(1.09); }
.queen-stage.done .qs-cam { transform: scale(1.035); transition-duration: 4.5s; }
.qs-breathe { position: absolute; inset: 0; transform-origin: 30% 62%; transition: filter 2.6s ease; animation: qsBreathe 11s ease-in-out infinite; }
@keyframes qsBreathe { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.016) translateY(-0.3%); } }
.queen-stage.sealed .qs-breathe { filter: brightness(0.3) saturate(0.55) contrast(1.06); animation-play-state: paused; }
.qs-art, .qs-film { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; }
.qs-film { opacity: 0; transition: opacity 1.6s ease; }
.queen-stage.alive .qs-film { opacity: 1; }
/* over the living film the scroll itself is laid back exactly as printed, so every word stays crisp */
.qs-scrollfix { position: absolute; inset: 0; opacity: 0; background: url("../img/realm/titania-message.jpg") center / 100% 100% no-repeat;
  -webkit-mask: url("../img/realm/titania-scroll-matte.png") center / 100% 100% no-repeat; mask: url("../img/realm/titania-scroll-matte.png") center / 100% 100% no-repeat; }
.queen-stage.alive .qs-scrollfix { opacity: 1; }
/* her wings and crown catch the light, and a soft beam crosses the page */
.qs-shimmer { position: absolute; inset: 0; pointer-events: none; mix-blend-mode: screen; opacity: 0; transition: opacity 2.6s ease 0.9s; overflow: hidden; }
.queen-stage:not(.sealed) .qs-shimmer { opacity: 1; }
.qs-shimmer i { position: absolute; aspect-ratio: 1; translate: -50% -50%; border-radius: 50%; animation: qsPulse 5.2s ease-in-out infinite;
  background: radial-gradient(circle, rgba(255,244,190,0.5) 0%, rgba(245,200,66,0.24) 38%, rgba(245,200,66,0) 70%); }
.qs-shimmer i:nth-child(1) { left: 15%; top: 42%; width: 31%; }
.qs-shimmer i:nth-child(2) { left: 46%; top: 34%; width: 25%; animation-delay: -1.8s; }
.qs-shimmer i:nth-child(3) { left: 33.5%; top: 12.5%; width: 13%; animation-duration: 3.4s; animation-delay: -0.8s; }
@keyframes qsPulse { 0%, 100% { opacity: 0.25; scale: 0.92; } 50% { opacity: 1; scale: 1.08; } }
.qs-shimmer b { position: absolute; inset: -20% -60%; background: linear-gradient(104deg, rgba(255,246,207,0) 45%, rgba(255,246,207,0.32) 50%, rgba(255,246,207,0) 55%); animation: qsSweep 9s ease-in-out infinite; }
@keyframes qsSweep { 0%, 35% { transform: translateX(-45%); } 100% { transform: translateX(45%); } }
/* the lines of the message, lit one at a time on the painted scroll */
.qs-lines { position: absolute; inset: 0; pointer-events: none; }
.qs-title, .qs-line span { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; border: 0; }
.qs-line { position: absolute; margin: 0; left: calc(var(--x) * 1%); top: calc(var(--y) * 1%); width: calc(var(--w) * 1% + 2.8%); height: 4.1%; translate: -50% -50%; rotate: calc(var(--a) * 1deg);
  border-radius: 999px; opacity: 0; mix-blend-mode: overlay; transition: opacity 0.9s ease;
  background: radial-gradient(ellipse 58% 75% at 50% 50%, rgba(255,250,214,1) 0%, rgba(255,226,120,0.85) 48%, rgba(245,200,66,0) 100%);
  box-shadow: 0 0 22px 8px rgba(255,226,130,0.75); box-shadow: 0 0 min(22px, 2cqw) min(8px, 0.72cqw) rgba(255,226,130,0.75); }
.qs-line::after { content: ""; position: absolute; left: 4%; right: 4%; bottom: 2%; height: max(2px, 7%); border-radius: 4px; transform-origin: 0 50%; transform: scaleX(0);
  background: linear-gradient(90deg, rgba(184,134,43,0.2), #f5c842 30%, #fff3bf 60%, #f5c842 100%); box-shadow: 0 0 10px 2px rgba(245,200,66,0.9); mix-blend-mode: normal; }
.qs-line.speaking { opacity: 1; animation: qsLineIn 2.2s cubic-bezier(.3,.2,.3,1) both; }
.qs-line.speaking::after { animation: qsUnderline 2.2s cubic-bezier(.3,.2,.3,1) both; }
@keyframes qsLineIn { from { clip-path: inset(-80% 100% -80% -6%); } to { clip-path: inset(-80% -6% -80% -6%); } }
@keyframes qsUnderline { from { transform: scaleX(0); } to { transform: scaleX(1); } }
.qs-line.lit { opacity: 0.5; }
.qs-line.lit::after { transform: scaleX(1); opacity: 0.55; }
.queen-stage.done .qs-line.lit { animation: qsLitPulse 3.6s ease-in-out infinite; }
@keyframes qsLitPulse { 0%, 100% { opacity: 0.42; } 50% { opacity: 0.8; } }
.qs-sparks { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
/* shadow while sealed, and the bloom of light when the seal breaks */
.qs-shade { position: absolute; inset: 0; pointer-events: none; opacity: 0; transition: opacity 2.4s ease;
  background: radial-gradient(ellipse 46% 62% at 74% 52%, rgba(3,6,14,0) 0%, rgba(3,6,14,0.5) 70%, rgba(3,6,14,0.82) 100%); }
.queen-stage.sealed .qs-shade { opacity: 1; }
.qs-bloom { position: absolute; left: 70%; top: 46%; width: 120%; aspect-ratio: 1; translate: -50% -50%; border-radius: 50%; pointer-events: none; opacity: 0; mix-blend-mode: screen;
  background: radial-gradient(circle, rgba(255,251,228,1) 0%, rgba(255,232,150,0.8) 20%, rgba(245,200,66,0.4) 44%, rgba(245,200,66,0) 70%); }
.queen-stage.opening .qs-bloom { animation: queenBloom 3.2s ease-out 0.15s both; }
/* the royal seal rests on the scroll in her hand */
.qs-frame .royal-seal { left: 74.6%; top: 51.5%; width: min(122px, 15%); height: auto; aspect-ratio: 1; }
.queen-stage.sealed .royal-seal, .qs-frame .royal-seal.cracking { display: block; }
.queen-stage.sealed .royal-seal:not(.cracking) { animation: sealPulse 2.6s ease-in-out infinite; }
.qs-frame .rs-half b { font-size: min(3.3rem, 6.4vw); }
.qs-frame .rs-half::before { inset: 12%; }
.qs-frame .queen-hint { left: 74.4%; top: calc(51.5% + min(61px, 7.5%) + 5.5%); width: 24%; max-width: none; font-size: clamp(0.72rem, 1.55vw, 1.2rem); line-height: 1.35; }
.queen-stage.sealed .queen-hint { opacity: 1; animation: hintBreath 3.4s ease-in-out infinite; }
.queen-stage.sealed + .queen-actions { opacity: 0 !important; visibility: hidden; transition: opacity 0.4s ease, visibility 0s linear 0.4s; }
/* the line being read: along the foot of the page on large screens, large beneath it on small ones */
.qs-caption { margin: 0; text-align: center; font-family: var(--serif-display); font-style: italic; font-weight: 600; color: #ffe9a8; pointer-events: none;
  text-shadow: 0 2px 14px rgba(0,0,0,0.95), 0 0 26px rgba(245,200,66,0.35); opacity: 0; transition: opacity 0.35s ease; }
.qs-caption.show { opacity: 1; }
.qs-caption-in { position: absolute; left: 0; right: 0; bottom: 0; z-index: 4; padding: 2.4em 5% 0.75em; font-size: clamp(1.15rem, 2.3vw, 1.85rem); line-height: 1.25;
  background: linear-gradient(to top, rgba(5,9,22,0.9) 0%, rgba(5,9,22,0.6) 50%, rgba(5,9,22,0) 100%); }
.qs-caption-under { display: none; margin: 1rem auto 0; min-height: 2.9em; padding: 0 0.4rem; font-size: clamp(1.25rem, 5.4vw, 1.7rem); line-height: 1.3; }
/* the whole page fits on the screen beneath its title */
.queen-stage { max-width: min(1180px, max(560px, calc((100svh - 262px) * 1.4888))); }
@media (max-width: 760px) {
  .qs-caption-in { display: none; } .qs-caption-under { display: block; }
  .qs-frame .queen-hint { display: none; }
  .queen-stage.done .qs-line.lit { animation: none; opacity: 0.42; }
  .queen-stage { max-width: none; }
}
#message .queen-actions { margin-top: 0.6rem; }
@media (max-width: 700px) {
  .qs-frame { border-radius: 14px; box-shadow: 0 0 0 4px rgba(7,12,24,0.85), 0 0 0 5px rgba(245,200,66,0.4), 0 0 40px rgba(245,200,66,0.35), 0 18px 50px rgba(0,0,0,0.7); }
  .qs-frame .royal-seal { width: 17%; }
  .qs-frame .queen-hint { width: 30%; font-size: 0.62rem; line-height: 1.25; }
}
@media (prefers-reduced-motion: reduce) {
  .qs-breathe, .qs-shimmer i, .qs-shimmer b, .queen-stage.sealed .royal-seal, .queen-stage.sealed .queen-hint, .queen-stage.done .qs-line.lit, .queen-stage.opening .qs-bloom { animation: none; }
  .qs-cam, .qs-breathe, .qs-shade { transition: none; }
  .queen-stage.reading .qs-cam, .queen-stage.done .qs-cam { transform: none; }
  .qs-line.speaking, .qs-line.speaking::after { animation: none; } .qs-line.speaking::after { transform: scaleX(1); }
}
/* v114 · the way in to The Games Room, beneath the seven doors and at the top of the Gnomes' Workshop */
.gm-banner { display: flex; align-items: center; gap: 1.3rem; max-width: 980px; margin: 2rem auto 0; padding: 1rem 1.5rem; border-radius: 999px; text-decoration: none; color: #fff6dc;
  border: 1px solid #f5c842; background: linear-gradient(100deg, rgba(60,44,10,0.55), rgba(16,26,52,0.92) 45%, rgba(60,44,10,0.55)); box-shadow: 0 0 40px rgba(245,200,66,0.22), 0 14px 34px rgba(0,0,0,0.5);
  transition: transform 0.3s cubic-bezier(.2,.8,.2,1), box-shadow 0.3s; }
.gm-banner:hover { transform: translateY(-3px); box-shadow: 0 0 60px rgba(245,200,66,0.45), 0 18px 40px rgba(0,0,0,0.55); }
.gm-banner-new { flex: none; font-family: var(--caps); font-size: 0.62rem; letter-spacing: 0.24em; text-transform: uppercase; color: #241703; padding: 0.45rem 0.85rem; border-radius: 999px; background: var(--gilt); background-size: 200% 100%; animation: giltSlide 5s linear infinite; }
.gm-banner-text { flex: 1; min-width: 0; }
.gm-banner-text b { display: block; font-family: var(--serif-display); font-weight: 600; font-size: 1.5rem; line-height: 1.15; color: #ffe9a8; }
.gm-banner-text i { display: block; font-style: italic; font-family: var(--serif-display); font-size: 1.08rem; color: var(--cream-dim); }
.gm-banner-go { flex: none; font-family: var(--caps); font-size: 0.72rem; letter-spacing: 0.26em; text-transform: uppercase; color: #f5c842; white-space: nowrap; }
.gm-banner-in { margin: 0 auto 1.8rem; }
.rv-choices.chosen ~ .gm-banner:not(.gm-banner-in) { display: none; }
@media (max-width: 700px) { .gm-banner { flex-wrap: wrap; border-radius: 22px; gap: 0.6rem 1rem; padding: 1rem 1.1rem; } .gm-banner-text { flex-basis: 100%; order: 3; } .gm-banner-go { margin-left: auto; } }
/* v115 · The Games Room banner: a living gold surround that shimmers to catch the eye */
.gm-banner { position: relative; isolation: isolate; border: 2px solid transparent; padding-left: 2rem; overflow: hidden;
  background:
    linear-gradient(100deg, #2a2110, #121c38 45%, #2a2110) padding-box,
    linear-gradient(100deg, #8a5d12 0%, #f5c842 18%, #fffbe0 30%, #f5c842 42%, #8a5d12 60%, #f5c842 78%, #fffbe0 90%, #8a5d12 100%) border-box;
  background-size: 100% 100%, 300% 100%; background-position: 0 0, 0% 0;
  animation: gmEdge 3.2s linear infinite, gmGlow 2.4s ease-in-out infinite; }
@keyframes gmEdge { to { background-position: 0 0, -300% 0; } }
@keyframes gmGlow {
  0%, 100% { box-shadow: 0 0 22px rgba(245,200,66,0.3), 0 0 60px rgba(245,200,66,0.12), 0 14px 34px rgba(0,0,0,0.5); }
  50% { box-shadow: 0 0 40px rgba(245,200,66,0.75), 0 0 110px rgba(245,200,66,0.35), 0 14px 34px rgba(0,0,0,0.5); }
}
.gm-banner::after { content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background: linear-gradient(105deg, rgba(255,246,207,0) 40%, rgba(255,246,207,0.28) 50%, rgba(255,246,207,0) 60%); background-size: 260% 100%; background-repeat: no-repeat; animation: gmSweep 3.6s ease-in-out infinite; }
@keyframes gmSweep { 0% { background-position: 130% 0; } 70%, 100% { background-position: -130% 0; } }
.gm-banner:hover { animation-duration: 1.6s, 1.2s; }
@media (max-width: 700px) { .gm-banner { padding-left: 1.1rem; } }
@media (prefers-reduced-motion: reduce) { .gm-banner, .gm-banner::after { animation: none; } .gm-banner { box-shadow: 0 0 40px rgba(245,200,66,0.6), 0 14px 34px rgba(0,0,0,0.5); } }

/* v116 · the Queen now speaks in her own film (16:9): the stage, seal, light and sparkle are re-set to its composition */
.qs-frame { aspect-ratio: 16 / 9; }
.queen-stage { max-width: min(1180px, max(600px, calc((100svh - 330px) * 1.7778))); }
.qs-cam { transform-origin: 70% 56%; }
.queen-stage.reading .qs-cam { transform: scale(1.06); }
.qs-breathe { transform-origin: 24% 70%; }
.queen-stage.alive .qs-breathe { animation-play-state: paused; }
.qs-film { transition: opacity 1.1s ease; }
.queen-stage.alive .qs-shimmer i { display: none; }
.qs-shimmer i:nth-child(1) { left: 8%; top: 44%; width: 24%; }
.qs-shimmer i:nth-child(2) { left: 34%; top: 36%; width: 20%; }
.qs-shimmer i:nth-child(3) { left: 23%; top: 13%; width: 11%; }
.qs-shade { background: radial-gradient(ellipse 40% 66% at 71% 56%, rgba(3,6,14,0) 0%, rgba(3,6,14,0.5) 70%, rgba(3,6,14,0.82) 100%); }
.qs-bloom { left: 66%; top: 52%; }
.qs-frame .royal-seal { left: 70.6%; top: 57%; width: min(118px, 13%); }
.qs-frame .queen-hint { left: 70.6%; top: calc(57% + min(59px, 6.5%) + 7%); width: 22%; }
.qs-line { height: 4.6%; }
@media (max-width: 760px) { .queen-stage { max-width: none; } .qs-frame .royal-seal { width: 15%; } }
/* v117 · the Queen's page shows only what is in her film: no added stars, sparkle or light sweep */
.qs-sparks, .qs-shimmer { display: none !important; }
/* v119 · the Queen's page: no dark strip behind the line being read, only the line now being spoken glows, and the glow is a soft feathered light */
.qs-caption-in { background: none; padding: 0 5% 0.7em; text-shadow: 0 1px 2px rgba(0,0,0,0.95), 0 0 6px rgba(0,0,0,0.9), 0 0 16px rgba(0,0,0,0.85), 0 0 30px rgba(0,0,0,0.6); }
.qs-line { mix-blend-mode: normal; box-shadow: none; border-radius: 50%; height: 6.4%; width: calc(var(--w) * 1% + 6%);
  background: radial-gradient(ellipse 50% 50% at 50% 50%, rgba(255,226,120,0.5) 0%, rgba(255,214,90,0.3) 45%, rgba(255,214,90,0.1) 75%, rgba(255,214,90,0) 100%); }
.qs-line::after { display: none; }
.qs-line.lit, .queen-stage.done .qs-line.lit { opacity: 0; animation: none; }
.qs-line.speaking { opacity: 1; animation: qsLineSoft 0.7s ease both; }
@keyframes qsLineSoft { from { opacity: 0; } to { opacity: 1; } }
/* v120 · tablets held upright: the Queen's invitation and the line being read sit beneath her picture, at a readable size */
@media (max-width: 900px) {
  .qs-caption-in { display: none; } .qs-caption-under { display: block; }
  .qs-frame .queen-hint { display: none; }
  .queen-stage { max-width: none; }
}
/* v120 · phones held sideways: the Queen's picture and the trailer are sized to the height of the screen, so the whole picture is in view */
@media (max-height: 520px) and (orientation: landscape) {
  .queen-stage { max-width: max(360px, calc((100svh - 96px) * 1.7778)); }
  .trailer-stage:not(.portrait) { max-width: max(360px, calc((100svh - 96px) * 1.7778)); }
  #message .section-head, #trailer .section-head { margin-bottom: 1.2rem; }
}
@media (max-height: 520px) and (orientation: landscape) {
  .map-frame { max-width: max(380px, calc((100svh - 84px) * 1.489)); }
}
/* v121 · phones: the place card no longer sits unseen over the lower half of the map, so every secret number can be tapped */
.poi-card { pointer-events: none !important; }
/* the card never takes a tap itself: on a touch screen it used to appear under the finger and swallow the tap meant for the number */
@media (max-width: 760px) {
  .map-frame .poi-card { position: absolute; left: 3% !important; right: 3%; width: auto; top: auto !important; bottom: 3%; transform: none !important; padding: 0.6rem 0.8rem; }
  .map-frame .poi-card h4 { font-size: 1rem; } .map-frame .poi-card p { font-size: 0.82rem; line-height: 1.4; }
}
/* v122 · Story Time reads the opening scene only: no scene buttons, and no device voice */
.reader-single #readerPrev, .reader-single #readerNext, .reader-single .r-dots, .reader-single .r-voice { display: none !important; }
.reader-single .reader-controls { justify-content: center; }

/* ============================================================
   v125 · The True Story theatre: two golden tabs (Watch the film, Listen and read) over one stage.
   The full story is opened from the Listen pane and read beside the narration.
   ============================================================ */
.story-theatre { max-width: 1040px; margin: 3.4rem auto 0; border-radius: 22px; overflow: hidden; border: 1px solid rgba(245,200,66,0.45);
  background: linear-gradient(160deg, rgba(20,31,62,0.92), rgba(8,13,28,0.96)); box-shadow: 0 0 70px rgba(245,200,66,0.14), 0 26px 70px rgba(0,0,0,0.6); }
.st-tabs { display: grid; grid-template-columns: 1fr 1fr; border-bottom: 1px solid rgba(245,200,66,0.3); }
.st-tab { display: flex; align-items: center; gap: 0.95rem; padding: 1.05rem 1.5rem; border: 0; cursor: pointer; text-align: left; font: inherit; color: var(--cream-dim);
  background: rgba(7,12,24,0.55); transition: background 0.3s, color 0.3s; position: relative; -webkit-tap-highlight-color: transparent; }
.st-tab + .st-tab { border-left: 1px solid rgba(245,200,66,0.3); }
.st-tab:hover { background: rgba(245,200,66,0.08); }
.st-tab:focus-visible { outline: 2px solid #f5c842; outline-offset: -3px; }
.st-ico { flex: none; width: 46px; height: 46px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 1.05rem; color: #f5c842; border: 1px solid rgba(245,200,66,0.55); transition: background 0.3s, color 0.3s, box-shadow 0.3s; }
.st-lab b { display: block; font-family: var(--serif-display); font-weight: 600; font-size: 1.45rem; line-height: 1.15; color: #fff6dc; }
.st-lab i { display: block; font-style: normal; font-family: var(--caps); font-size: 0.62rem; letter-spacing: 0.2em; text-transform: uppercase; color: rgba(255,233,168,0.7); margin-top: 0.3rem; }
.st-tab.on { background: linear-gradient(180deg, rgba(245,200,66,0.2), rgba(245,200,66,0.04)); color: #fff6dc; }
.st-tab.on::after { content: ""; position: absolute; left: 0; right: 0; bottom: -1px; height: 3px; background: var(--gilt); background-size: 200% 100%; animation: giltSlide 5s linear infinite; }
.st-tab.on .st-ico { background: var(--gilt); color: #241703; border-color: #fff0b8; box-shadow: 0 0 20px rgba(245,200,66,0.55); }
.st-tab.on .st-lab b { color: #ffe9a8; }
.st-pane[hidden] { display: none; }
.st-watch { margin: 0; padding: 1.1rem; }
.st-watch video { width: 100%; aspect-ratio: 16 / 9; border-radius: 14px; display: block; background: #000; box-shadow: 0 0 0 1px rgba(245,200,66,0.3), 0 14px 40px rgba(0,0,0,0.55); }
.st-listen { padding: 1.3rem; }
.st-listen-top { display: grid; grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr); gap: 1.5rem; align-items: center; }
.st-cover { position: relative; border-radius: 14px; overflow: hidden; aspect-ratio: 16 / 9; box-shadow: 0 0 0 1px rgba(245,200,66,0.35), 0 14px 36px rgba(0,0,0,0.55); }
.st-cover img { width: 100%; height: 100%; object-fit: cover; display: block; animation: stDrift 24s ease-in-out infinite alternate; }
@keyframes stDrift { from { transform: scale(1.02); } to { transform: scale(1.12) translate(-1.5%, -1%); } }
.st-cover::after { content: ""; position: absolute; inset: 0; background: radial-gradient(ellipse at 50% 50%, rgba(7,12,24,0) 45%, rgba(7,12,24,0.55) 100%); }
.st-listen-side .track { margin: 0 0 1.1rem; }
.st-read { display: inline-flex; align-items: center; gap: 0.5rem; }
.st-read .st-read-close { display: none; }
.st-read[aria-expanded="true"] .st-read-open { display: none; }
.st-read[aria-expanded="true"] .st-read-close { display: inline; }
.st-text { margin-top: 1.3rem; border-radius: 14px; border: 1px solid rgba(245,200,66,0.3); background: rgba(7,12,24,0.6); max-height: min(62vh, 560px); overflow-y: auto; scrollbar-color: rgba(245,200,66,0.45) rgba(255,252,234,0.06);
  animation: stUnfold 0.6s cubic-bezier(.2,.8,.2,1) both; }
.st-text[hidden] { display: none; }
@keyframes stUnfold { from { opacity: 0; transform: translateY(-10px); } to { opacity: 1; transform: none; } }
.st-text .full-story-body { max-width: 760px; margin: 0 auto; padding: 1.8rem 2rem 2.2rem; }
@media (max-width: 760px) {
  .story-theatre { margin-top: 2.4rem; border-radius: 16px; }
  .st-tab { padding: 0.8rem 0.8rem; gap: 0.6rem; }
  .st-ico { width: 36px; height: 36px; font-size: 0.9rem; }
  .st-lab b { font-size: 1.12rem; } .st-lab i { font-size: 0.52rem; letter-spacing: 0.12em; }
  .st-watch { padding: 0.6rem; } .st-listen { padding: 0.8rem; }
  .st-listen-top { grid-template-columns: 1fr; gap: 0.9rem; }
  .st-text .full-story-body { padding: 1.2rem 1.1rem 1.6rem; }
  .st-read { width: 100%; justify-content: center; }
}
@media (prefers-reduced-motion: reduce) { .st-cover img, .st-tab.on::after, .st-text { animation: none; } }
@media (max-width: 760px) { .st-more { display: none; } .st-lab b { white-space: nowrap; font-size: 1.05rem; } .st-tab { padding: 0.75rem 0.6rem; } }
@media (max-width: 380px) { .st-lab b { font-size: 0.95rem; } .st-ico { width: 32px; height: 32px; } }

/* v126 · the True Story theatre, dressed up: a living gold frame, a cinema screen with a golden play button,
   a storyteller's player whose light dances as he speaks, and the full story unrolled on parchment */
.story-theatre { position: relative; border: 2px solid transparent; overflow: hidden;
  background:
    linear-gradient(160deg, #141f3e, #080d1c) padding-box,
    linear-gradient(100deg, #8a5d12 0%, #f5c842 18%, #fffbe0 30%, #f5c842 42%, #8a5d12 60%, #f5c842 78%, #fffbe0 90%, #8a5d12 100%) border-box;
  background-size: 100% 100%, 300% 100%; animation: gmEdge 7s linear infinite;
  box-shadow: 0 0 60px rgba(245,200,66,0.22), 0 0 150px rgba(245,200,66,0.1), 0 30px 80px rgba(0,0,0,0.65); transition: box-shadow 1.2s ease; }
.story-theatre.film-on, .story-theatre.audio-on { box-shadow: 0 0 90px rgba(245,200,66,0.5), 0 0 220px rgba(245,200,66,0.22), 0 30px 80px rgba(0,0,0,0.65); }
.st-tabs { background: linear-gradient(180deg, rgba(7,12,24,0.85), rgba(7,12,24,0.55)); }
.st-tab.on .st-ico { animation: stIco 2.6s ease-in-out infinite; }
@keyframes stIco { 50% { box-shadow: 0 0 34px rgba(245,200,66,0.95); } }
/* the screen */
.st-watch { padding: 1.3rem; background: radial-gradient(ellipse at 50% 0%, rgba(245,200,66,0.12), transparent 60%); }
.st-screen { position: relative; border-radius: 16px; overflow: hidden; background: #000; box-shadow: 0 0 0 1px rgba(245,200,66,0.45), 0 0 0 7px rgba(7,12,24,0.9), 0 0 0 8px rgba(245,200,66,0.25), 0 18px 50px rgba(0,0,0,0.6); }
.st-screen video { border-radius: 0; box-shadow: none; }
.st-play { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 0.5rem; padding: 1rem; border: 0; cursor: pointer; color: #fff6dc; font: inherit; text-align: center;
  background: radial-gradient(ellipse at 50% 45%, rgba(7,12,24,0.15) 0%, rgba(7,12,24,0.55) 62%, rgba(7,12,24,0.88) 100%); transition: opacity 0.7s ease, visibility 0s linear 0s; -webkit-tap-highlight-color: transparent; }
.st-play[hidden] { display: none; }
.st-play.gone { opacity: 0; visibility: hidden; pointer-events: none; transition: opacity 0.7s ease, visibility 0s linear 0.7s; }
.st-play-btn { position: relative; width: clamp(74px, 11vw, 112px); aspect-ratio: 1; border-radius: 50%; display: flex; align-items: center; justify-content: center; padding-left: 0.12em; font-size: clamp(1.7rem, 3.4vw, 2.6rem); color: #241703;
  background: var(--gilt); background-size: 200% 100%; animation: giltSlide 5s linear infinite; box-shadow: 0 0 44px rgba(245,200,66,0.85), 0 10px 30px rgba(0,0,0,0.6); transition: transform 0.3s cubic-bezier(.2,1.4,.4,1); }
.st-play:hover .st-play-btn, .st-play:focus-visible .st-play-btn { transform: scale(1.1); }
.st-play:focus-visible { outline: 2px solid #f5c842; outline-offset: -6px; }
.st-play-btn i { position: absolute; inset: 0; border-radius: 50%; border: 2px solid rgba(245,200,66,0.8); animation: stRing 2.8s ease-out infinite; pointer-events: none; }
.st-play-btn i + i { animation-delay: 1.4s; }
@keyframes stRing { from { transform: scale(1); opacity: 0.9; } to { transform: scale(2.1); opacity: 0; } }
.st-play-title { margin-top: 0.9rem; font-family: var(--serif-display); font-weight: 600; font-size: clamp(1.25rem, 3.4vw, 2.5rem); line-height: 1.1;
  background: var(--gilt); background-size: 220% 100%; -webkit-background-clip: text; background-clip: text; color: transparent; -webkit-text-fill-color: transparent; animation: giltSlide 9s linear infinite; filter: drop-shadow(0 3px 14px rgba(0,0,0,0.95)); }
.st-play-sub { font-family: var(--caps); font-size: clamp(0.5rem, 1.1vw, 0.72rem); letter-spacing: 0.26em; text-transform: uppercase; color: #ffe9a8; text-shadow: 0 2px 10px rgba(0,0,0,0.95); }
/* the storyteller's player */
.st-listen { background: radial-gradient(ellipse at 20% 0%, rgba(245,200,66,0.12), transparent 55%); }
.st-cover { box-shadow: 0 0 0 1px rgba(245,200,66,0.45), 0 0 0 6px rgba(7,12,24,0.9), 0 0 0 7px rgba(245,200,66,0.25), 0 14px 36px rgba(0,0,0,0.55); }
.st-eq { position: absolute; left: 50%; bottom: 9%; translate: -50% 0; z-index: 2; display: flex; align-items: flex-end; gap: 5px; height: 34%; opacity: 0; transition: opacity 0.6s ease; }
.st-eq i { width: 6px; height: 100%; border-radius: 3px; transform-origin: 50% 100%; transform: scaleY(0.15); background: linear-gradient(#fff6cf, #f5c842 55%, #b8862b); box-shadow: 0 0 10px rgba(245,200,66,0.9); }
.story-theatre.audio-on .st-eq { opacity: 1; }
.story-theatre.audio-on .st-eq i { animation: stEq 1.1s ease-in-out infinite; }
.st-eq i:nth-child(1) { animation-delay: -0.9s !important; } .st-eq i:nth-child(2) { animation-delay: -0.3s !important; animation-duration: 0.8s !important; } .st-eq i:nth-child(3) { animation-delay: -0.6s !important; animation-duration: 1.3s !important; }
.st-eq i:nth-child(4) { animation-delay: -0.1s !important; animation-duration: 0.9s !important; } .st-eq i:nth-child(5) { animation-delay: -0.75s !important; animation-duration: 1.2s !important; } .st-eq i:nth-child(6) { animation-delay: -0.45s !important; animation-duration: 0.85s !important; } .st-eq i:nth-child(7) { animation-delay: -0.2s !important; }
@keyframes stEq { 0%, 100% { transform: scaleY(0.18); } 30% { transform: scaleY(1); } 60% { transform: scaleY(0.45); } 80% { transform: scaleY(0.8); } }
.st-listen-side .track { border-color: rgba(245,200,66,0.45); box-shadow: 0 10px 30px rgba(0,0,0,0.4); }
.st-read { border-color: #f5c842; color: #ffe9a8; box-shadow: 0 0 22px rgba(245,200,66,0.22); }
.st-read:hover { background: rgba(245,200,66,0.14); box-shadow: 0 0 34px rgba(245,200,66,0.45); }
/* the full story, unrolled on parchment */
.st-text { position: relative; border: 0; border-radius: 6px; max-height: min(66vh, 620px); color: #3a2a10; scrollbar-color: #b8862b #ecd9a4;
  background:
    radial-gradient(ellipse at 50% 0%, rgba(255,255,255,0.55), transparent 50%),
    radial-gradient(ellipse at 0% 50%, rgba(160,110,30,0.22), transparent 28%),
    radial-gradient(ellipse at 100% 50%, rgba(160,110,30,0.22), transparent 28%),
    repeating-linear-gradient(92deg, rgba(150,105,35,0.045) 0 2px, rgba(255,255,255,0) 2px 7px),
    linear-gradient(#fbefc9, #f3dfa8 55%, #ead08f);
  box-shadow: inset 0 0 0 1px rgba(138,93,18,0.5), inset 0 0 0 6px rgba(251,239,201,0.7), inset 0 0 0 7px rgba(138,93,18,0.3), inset 0 0 60px rgba(120,80,20,0.25), 0 18px 44px rgba(0,0,0,0.55);
  animation: stUnroll 0.9s cubic-bezier(.25,.8,.25,1) both; }
@keyframes stUnroll { from { clip-path: inset(0 0 100% 0); opacity: 0.4; } to { clip-path: inset(0 0 0 0); opacity: 1; } }
.st-text-head { margin: 0; padding: 1.7rem 1rem 0; text-align: center; font-family: var(--caps); font-size: 0.74rem; letter-spacing: 0.32em; text-transform: uppercase; color: #8a5d12; }
.st-text-head span { color: #b8862b; margin: 0 0.5em; }
.st-text .full-story-body { padding: 1.3rem 2.4rem 2.6rem; }
.st-text .full-story-body p { color: #3a2a10; font-size: 1.12rem; line-height: 1.75; margin-bottom: 1.1rem; }
.st-text .full-story-body p em { color: #5a3d10; }
.st-text .full-story-body p:first-child::first-letter { color: #a8761c; text-shadow: 0 1px 0 rgba(255,255,255,0.6); }
@media (max-width: 760px) {
  .st-watch { padding: 0.7rem; }
  .st-play-title { margin-top: 0.5rem; }
  .st-text .full-story-body { padding: 1rem 1.2rem 1.8rem; } .st-text .full-story-body p { font-size: 1.04rem; line-height: 1.65; }
  .st-text-head { font-size: 0.56rem; letter-spacing: 0.2em; padding-top: 1.3rem; }
}
@media (prefers-reduced-motion: reduce) { .story-theatre, .st-tab.on .st-ico, .st-play-btn, .st-play-btn i, .st-play-title, .story-theatre.audio-on .st-eq i, .st-text { animation: none; } .st-play-btn i { display: none; } .story-theatre.audio-on .st-eq i { transform: scaleY(0.6); } }
@media (max-width: 760px) { .st-play-sub { letter-spacing: 0.12em; font-size: 0.5rem; white-space: nowrap; } }

/* v127 · the True Story opening: the words and the day-and-night picture share one height, top and bottom level, and the theatre sits closer beneath */
@media (min-width: 901px) {
  #story .story-grid { grid-template-columns: 1.08fr 0.92fr; align-items: stretch; gap: 3rem; }
  #story .story-text { display: flex; flex-direction: column; justify-content: space-between; }
  #story .story-text p { margin-bottom: 1.15rem; font-size: 1.12rem; line-height: 1.7; }
  #story .story-text p:last-of-type { margin-bottom: 0; }
  #story .story-art { position: relative; margin: 0; display: flex; }
  #story .story-art .daynight { flex: 1; aspect-ratio: auto; min-height: 290px; }
  #story .dn-layer { background-size: 200% auto; }
  #story .dn-day { background-position: 0% 74%; }
  #story .dn-night { background-position: 100% 74%; }
  #story .story-art figcaption { position: absolute; left: 0; right: 0; bottom: 0; margin: 0; padding: 2.6em 5rem 0.85em 1.1rem; text-align: left; pointer-events: none; color: #fff6dc; font-size: 0.95rem;
    border-radius: 0 0 16px 16px; background: linear-gradient(to top, rgba(7,12,24,0.88), rgba(7,12,24,0)); text-shadow: 0 1px 6px rgba(0,0,0,0.9); }
  #story .story-theatre { margin-top: 2.6rem; }
}
#story .story-theatre { max-width: none; }  /* same width as the words and picture above, so the edges line up */
/* v128 · the storyteller's bars are driven by his voice (see main.js), not by a looping animation */
.story-theatre.audio-on .st-eq i, .st-eq i { animation: none !important; transform: scaleY(0.06); will-change: transform; }
.st-eq { transition: opacity 0.9s ease; }
/* v130 · the homepage ribbon announces the book is out; when the shop address is set it becomes a link */
.hero-ribbon-link { color: inherit; text-decoration: none; display: inline-block; }
.hero-ribbon.is-link { cursor: pointer; transition: box-shadow 0.3s, transform 0.3s; }
.hero-ribbon.is-link:hover { transform: translateY(-2px); box-shadow: 0 0 34px rgba(245,200,66,0.55); }

/* v131 · three shimmering doors under the Enchantments: Games Room, Advent Calendar, Make Your Own Elfin */
.rx-trio { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1.3rem; max-width: 1080px; margin: 2.2rem auto 0; }
.rv-choices.chosen ~ .rx-trio { display: none; }
.rx-card { position: relative; isolation: isolate; display: flex; flex-direction: column; border-radius: 20px; overflow: hidden; text-decoration: none; color: #fff6dc; border: 2px solid transparent;
  background: linear-gradient(180deg, #17244a, #0b1226) padding-box, linear-gradient(100deg, #8a5d12 0%, #f5c842 18%, #fffbe0 30%, #f5c842 42%, #8a5d12 60%, #f5c842 78%, #fffbe0 90%, #8a5d12 100%) border-box;
  background-size: 100% 100%, 300% 100%; animation: gmEdge 3.2s linear infinite, gmGlow 2.4s ease-in-out infinite; transition: transform 0.35s; }
.rx-card:nth-child(2) { animation-delay: -1.1s, -0.8s; }
.rx-card:nth-child(3) { animation-delay: -2.2s, -1.6s; }
.rx-card:hover { transform: translateY(-6px); animation-duration: 1.6s, 1.2s; }
.rx-card::after { content: ""; position: absolute; inset: 0; z-index: 2; pointer-events: none; background: linear-gradient(105deg, rgba(255,246,207,0) 40%, rgba(255,246,207,0.26) 50%, rgba(255,246,207,0) 60%); background-size: 260% 100%; background-repeat: no-repeat; animation: gmSweep 3.6s ease-in-out infinite; }
.rx-card:nth-child(2)::after { animation-delay: 0.6s; }
.rx-card:nth-child(3)::after { animation-delay: 1.2s; }
.rx-pic { display: block; aspect-ratio: 16 / 10; overflow: hidden; border-bottom: 2px solid #f5c842; }
.rx-pic img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 30%; display: block; transition: transform 0.8s; }
.rx-card:hover .rx-pic img { transform: scale(1.07); }
.rx-text { display: flex; flex-direction: column; flex: 1; padding: 0.95rem 1.1rem 1.1rem; text-align: center; }
.rx-text b { font-family: var(--serif-display); font-weight: 600; font-size: 1.5rem; line-height: 1.15; color: #ffe9a8; }
.rx-text i { font-family: var(--serif-display); font-style: italic; font-size: 1.08rem; line-height: 1.35; color: var(--cream-dim); margin: 0.3rem 0 0.7rem; flex: 1; }
.rx-text em { font-style: normal; font-family: var(--caps); font-size: 0.72rem; letter-spacing: 0.26em; text-transform: uppercase; color: #f5c842; }
@media (max-width: 760px) {
  .rx-trio { grid-template-columns: 1fr; gap: 0.9rem; max-width: 520px; }
  .rx-card { flex-direction: row; align-items: stretch; }
  .rx-pic { flex: none; width: 36%; aspect-ratio: auto; border-bottom: 0; border-right: 2px solid #f5c842; }
  .rx-text { text-align: left; padding: 0.8rem 0.9rem; }
  .rx-text b { font-size: 1.25rem; } .rx-text i { font-size: 1rem; margin-bottom: 0.4rem; }
}
@media (prefers-reduced-motion: reduce) { .rx-card, .rx-card::after { animation: none; } .rx-card { box-shadow: 0 0 34px rgba(245,200,66,0.5), 0 14px 34px rgba(0,0,0,0.5); } }
@media (max-width: 760px) { .rx-text em { letter-spacing: 0.16em; font-size: 0.68rem; white-space: nowrap; } }

/* v140 · passport rank title: room for the tails of g, p and y (the gilt fill was cutting them off) */
.jr-rank { line-height: 1.3; padding: 0.04em 0.1em 0.2em; margin-bottom: -0.12em; overflow: visible; -webkit-box-decoration-break: clone; box-decoration-break: clone; }

/* v145 · True Story film: the golden cover stays until the film is really running, and pulses while it loads */
.st-play.loading { cursor: progress; }
.st-play.loading .st-play-btn { animation: stLoading 0.9s ease-in-out infinite alternate; }
.st-play.loading .st-play-btn i { animation-duration: 1.1s; }
@keyframes stLoading { from { transform: scale(0.94); filter: brightness(0.95); } to { transform: scale(1.08); filter: brightness(1.25); } }
@media (prefers-reduced-motion: reduce) { .st-play.loading .st-play-btn { animation: none; opacity: 0.75; } }

/* v145 · Story Time on phones: the line being read stays in the middle of the panel, and lines fade in and out at its edges */
@media (max-width: 999px) {
  .reader-lines { position: relative; max-height: min(300px, 40vh); padding: 1.1rem 0.4rem 1.1rem 0; overscroll-behavior: contain;
    -webkit-mask-image: linear-gradient(180deg, transparent 0, #000 16%, #000 84%, transparent 100%); mask-image: linear-gradient(180deg, transparent 0, #000 16%, #000 84%, transparent 100%); }
}

/* v145 · buttons to the Glossary from the Tales and Book sections */
.gl-cta { text-align: center; margin: 2.4rem 0 0; }
.book-btns { display: flex; flex-wrap: wrap; gap: 0.8rem 1rem; align-items: center; justify-content: center; }
@media (max-width: 560px) { .gl-cta .btn, .book-btns .btn { padding: 0.9rem 1.4rem; font-size: 0.76rem; letter-spacing: 0.16em; } }

/* v148 · phones and tablets: no label smaller than is comfortable to read, and every control big enough for a finger */
@media (max-width: 1200px) {
  .char-card .char-label p { font-size: 0.66rem; letter-spacing: 0.12em; line-height: 1.35; }
  #book .bk-orb span { font-size: 0.66rem; letter-spacing: 0.06em; bottom: -1.55rem; }
  footer .f-legal a, .f-legal a { display: inline-flex; align-items: center; min-height: 40px; font-size: 0.72rem !important; }
  .doc-table th { font-size: 0.68rem; letter-spacing: 0.14em; }
  .st-lab i { font-size: 0.66rem; letter-spacing: 0.12em; }
  .jr-chip b { font-size: 0.68rem; }
  .rv-chip { font-size: 0.68rem; letter-spacing: 0.14em; }
  .gu-facts dt { font-size: 0.68rem; }
  .book-specs span { font-size: 0.7rem; }
  .hero-cine .scroll-hint span { font-size: 0.68rem; letter-spacing: 0.28em; }
  .doc-tabs a { font-size: 0.72rem; }
  .nav-toggle { min-width: 44px; min-height: 44px; padding: 0; line-height: 1; }
  .doc-back { display: inline-flex; align-items: center; min-height: 44px; padding: 0 0.2rem; font-size: 0.7rem; }
  .f-links a { display: inline-flex; align-items: center; min-height: 40px; }
  .track .t-lyrics-btn { min-height: 40px; padding-left: 0.5rem; padding-right: 0.5rem; }
  .hero-song-link .linklike, #replayDoor { display: inline-flex; align-items: center; min-height: 44px; }
  .hidden-fairy::after, .wild-fly::after { content: ""; position: absolute; inset: -10px; }
}
@media (max-width: 760px) {
  .st-tab { padding: 0.7rem 0.55rem; gap: 0.5rem; min-width: 0; }
  .st-lab { min-width: 0; }
  .st-lab b { font-size: 1rem; }
}

/* v151 · "Welcome to the Realm" is cut from the same gold as the section titles (such as Map of the Realm):
   the same top-to-bottom gilt and the same raised edge, with a deeper shadow because it sits on a moving picture */
.ps-cap-big {
  background: linear-gradient(180deg, #fffdf0 0%, #fbe9a6 20%, #f0c85a 43%, #b8862b 53%, #e9c360 66%, #fff3c4 84%, #c9993a 100%);
  background-size: 100% 100%; animation: none;
  -webkit-background-clip: text; background-clip: text; color: transparent; -webkit-text-fill-color: transparent; text-shadow: none;
  line-height: 1.04; letter-spacing: 0.01em; padding-bottom: 0.08em;
  filter:
    drop-shadow(0 -1px 0 rgba(255, 252, 232, 0.55))
    drop-shadow(0 1px 0 #8a5f14)
    drop-shadow(0 2px 0 #5c3d0a)
    drop-shadow(0 3px 1px rgba(40, 26, 4, 0.9))
    drop-shadow(0 10px 26px rgba(0, 0, 0, 0.8))
    drop-shadow(0 0 30px rgba(0, 0, 0, 0.55));
}

/* v152 · a sleeping Realm is completely dark: no lit patch and no numbers until the lantern is carried onto the map */
.map-frame.asleep.dark .map-night { -webkit-mask-image: none; mask-image: none; }
.map-frame.asleep.dark .map-lantern { opacity: 0; }
.map-frame.asleep.dark .poi, .map-frame.asleep.dark .poi.near, .map-frame.asleep.dark .poi.found { opacity: 0; pointer-events: none; animation: none; }

/* v153 · phones: show the opening film itself. It sits in its own window at the top of the screen, nearly the whole
   picture instead of a narrow slice, drifting slowly from side to side, with the title and buttons beneath it */
@media (max-width: 640px) {
  body:not(.oak-day) header.hero.hero-cine { justify-content: flex-start; padding-top: calc(min(75vw, 44svh) - 1.4rem); padding-bottom: 4.6rem; }
  body:not(.oak-day) .hero-cine .hero-video { inset: 0 0 auto 0; width: 100%; height: min(75vw, 44svh); object-fit: cover; object-position: 50% 50%;
    -webkit-mask-image: linear-gradient(180deg, #000 0, #000 72%, rgba(0,0,0,0) 100%); mask-image: linear-gradient(180deg, #000 0, #000 72%, rgba(0,0,0,0) 100%);
    animation: heroPan 30s ease-in-out infinite alternate; }
  body:not(.oak-day) .hero-cine .hero-bg { filter: blur(24px) brightness(0.45) saturate(1.15); transform: scale(1.3); }
  body:not(.oak-day) .hero-cine .hero-inner::before { opacity: 0.55; }
}
@keyframes heroPan { from { object-position: 10% 50%; } to { object-position: 90% 50%; } }
@media (prefers-reduced-motion: reduce) { .hero-cine .hero-video { animation: none !important; } }

/* v154 · the opening logo film melts into the homepage: the fade begins while the film is still moving into the light,
   and the homepage title rises in at the same moment, so there is no held frame and no pause */
html.show-intro .intro-splash { transition: opacity 1.5s ease-in-out; }
html.intro-playing .fade-seq { animation-play-state: paused; }

/* v155 · phones: the whole opening screen fits without scrolling. The film window takes whatever height is left over
   after the words and buttons, and the spacing between the lines is drawn in */
@media (max-width: 640px) {
  header.hero.hero-cine { padding-bottom: 3.1rem; }
  .hero-cine .scroll-hint { bottom: 0.7rem; }
  .hero-cine .hero-ribbon { margin-bottom: 0.75rem; padding: 0.32rem 0.95rem; line-height: 1.55; }
  .hero-cine .hero-inner h1 small { margin-bottom: 0.4em; }
  .hero-cine .hero-inner .subtitle { margin-top: 0.6rem; font-size: 1.02rem; line-height: 1.36; }
  .hero-cine .hero-inner .byline { margin-top: 0.5rem; font-size: 0.68rem; letter-spacing: 0.16em; }
  .hero-cine .hero-ctas { margin-top: 1.05rem; gap: 0.6rem; }
  .hero-cine .hero-ctas .btn { padding-top: 0.8rem; padding-bottom: 0.8rem; }
  .hero-cine .hero-daynote { margin-top: 0.7rem; font-size: 0.98rem; line-height: 1.35; }
  .hero-cine .hero-song-link { margin-top: 0.3rem; }
  .hero-cine .scroll-hint { gap: 0; line-height: 1.1; }
  .hero-cine .scroll-hint span { white-space: nowrap; letter-spacing: 0.12em; }
  body:not(.oak-day) header.hero.hero-cine { padding-top: 0; justify-content: flex-start; }
  body:not(.oak-day) .hero-cine .hero-video { position: relative; inset: auto; flex: 1 1 0px; align-self: flex-start; width: calc(100% + 2.2rem); max-width: none;
    height: auto; min-height: 6rem; max-height: 75vw; margin: 0 -1.1rem -1.4rem; }
  body:not(.oak-day) .hero-cine .hero-inner { margin-top: auto; margin-bottom: auto; }
}
@media (max-width: 389px) { .hero-cine .hero-inner .byline { letter-spacing: 0.06em; } }

/* v156 · phones: the film window shows the whole width of the film, so the Elfin folk who peep in from the sides are
   never cut off. No sideways drift, and a shorter fade at the foot of the window */
@media (max-width: 640px) {
  body:not(.oak-day) .hero-cine .hero-video { max-height: 56.25vw; margin-bottom: -0.9rem; animation: none; object-position: 50% 50%;
    -webkit-mask-image: linear-gradient(180deg, #000 0, #000 84%, rgba(0,0,0,0) 100%); mask-image: linear-gradient(180deg, #000 0, #000 84%, rgba(0,0,0,0) 100%); }
}

/* Legal navigation shares the book site's colours and type. */
footer nav.f-legal { position:static; z-index:auto; height:auto; background:none; backdrop-filter:none; -webkit-backdrop-filter:none; border-bottom:0; padding:1.2rem 0 0; display:flex; flex-direction:column; align-items:flex-start; width:fit-content; margin:1.5rem auto; gap:0; text-align:left; }
footer nav.f-legal h2 { font:600 1.75rem/1.3 "Cormorant Garamond", Georgia, serif; color:var(--cream); margin:0 0 .5rem; }
footer nav.f-legal a { display:flex; align-items:center; min-height:44px; font:inherit; font-size:1.1rem !important; letter-spacing:normal; text-transform:none; color:var(--cream-dim); }
footer nav.f-legal a:hover, footer nav.f-legal a:focus-visible, footer nav.f-legal a.on { color:var(--gold); text-decoration:underline; }

.story-sources { max-width:42rem; margin:1.4rem auto; padding:0 1rem; text-align:center; color:var(--cream-dim); line-height:1.55; }
.story-sources a { color:var(--gold); text-decoration:underline; text-underline-offset:.18em; }
.story-sources p { margin-bottom:.4rem; }

/* v163 · the site footer: brand above, link columns under small gold headings, and a quiet legal line beneath */
footer .f-cols { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 2.2rem 2.2rem; max-width: 1120px; margin: 2.4rem auto 0; padding-top: 2.3rem;
  border-top: 1px solid rgba(245,200,66,0.16); text-align: left; }
footer.doc-foot .f-cols { grid-template-columns: repeat(2, minmax(0, 1fr)); max-width: 540px; gap: 2rem 3rem; margin-top: 1.8rem; }
footer .f-cols .f-col, footer .f-cols nav.f-legal { position: static; display: flex; flex-direction: column; justify-content: flex-start; align-items: flex-start; align-self: start; inset: auto; transform: none; width: auto; height: auto; margin: 0; padding: 0; gap: 0;
  background: none; border: 0; text-align: left; }
footer .f-cols .f-col h2, footer .f-cols nav.f-legal h2 { align-self: stretch; margin: 0 0 0.7rem; padding: 0 0 0.65rem; border-bottom: 1px solid rgba(245,200,66,0.22);
  font: 400 0.7rem/1.5 var(--caps); letter-spacing: 0.22em; text-transform: uppercase; color: var(--gold); background: none; -webkit-text-fill-color: currentColor; }
footer .f-cols .f-col a, footer .f-cols nav.f-legal a { display: flex; align-items: center; min-height: 34px; font: inherit; font-size: 1rem !important; line-height: 1.3; letter-spacing: normal;
  text-transform: none; text-decoration: none; color: var(--cream-dim); transition: color 0.2s ease, transform 0.2s ease; }
footer .f-cols .f-col a:hover, footer .f-cols .f-col a:focus-visible, footer .f-cols nav.f-legal a:hover, footer .f-cols nav.f-legal a:focus-visible { color: var(--gold); text-decoration: none; transform: translateX(3px); }
footer .f-cols .f-col a.on, footer .f-cols nav.f-legal a.on { color: var(--gold); text-decoration: none; }
footer .f-copy, .doc-foot .f-copy { max-width: 1120px; margin: 2.4rem auto 0; padding-top: 1.3rem; border-top: 1px solid rgba(255,255,255,0.07); font-size: 0.8rem; line-height: 1.75; color: rgba(176,196,216,0.62); }
footer .f-copy a { color: var(--cream-dim); text-decoration: underline; text-underline-offset: 0.18em; }
footer .f-copy a:hover { color: var(--gold); }
footer.doc-foot .f-copy { max-width: 540px; }
@media (max-width: 1024px) {
  footer .f-cols { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 2.2rem 1.8rem; }
  footer .f-cols .f-col a, footer .f-cols nav.f-legal a { min-height: 44px; }
}
@media (pointer: coarse) { footer .f-cols .f-col a, footer .f-cols nav.f-legal a { min-height: 44px; } }
@media (max-width: 640px) {
  footer .f-cols, footer.doc-foot .f-cols { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 2rem 1.3rem; padding-top: 1.9rem; }
  footer .f-cols .f-col a, footer .f-cols nav.f-legal a { font-size: 0.98rem !important; }
  footer .f-copy { font-size: 0.78rem; }
}
@media print { footer .f-cols { display: none; } }

/* v164 · True Story film: the AI disclosure sits above the film at every screen width (it was hidden on phones) */
.st-ai-note { margin: 0; padding: 0.6rem 1rem; text-align: center; font-size: 0.93rem; line-height: 1.45; color: var(--cream-dim);
  background: rgba(7,12,24,0.72); border-bottom: 1px solid rgba(245,200,66,0.18); }
.story-theatre:has(#stTabListen.on) .st-ai-note { display: none; }

/* v165 · footer sections are now <details>. Wide screens: always open, laid out as before.
   Phones: a tidy folding list, each heading a full-width row with a chevron, links set in two columns */
footer .f-cols details.f-col, footer .f-cols nav.f-legal { display: block; }
footer .f-cols summary { display: block; list-style: none; cursor: default; outline-offset: 4px; }
footer .f-cols summary::-webkit-details-marker { display: none; }
footer .f-cols .f-list { display: flex; flex-direction: column; align-items: flex-start; }
@media (max-width: 640px) {
  footer:not(.doc-foot) { padding-bottom: 6.2rem; }                      /* room for the floating buttons */
  footer .f-cols, footer.doc-foot .f-cols { grid-template-columns: 1fr; gap: 0; padding-top: 0; margin-top: 1.6rem; }
  footer .f-cols details.f-col, footer .f-cols nav.f-legal { border-bottom: 1px solid rgba(245,200,66,0.16); }
  footer .f-cols .f-col h2, footer .f-cols nav.f-legal h2 { margin: 0; padding: 0; border: 0; font-size: 0.74rem; letter-spacing: 0.2em; align-self: auto; }
  footer .f-cols summary { display: flex; align-items: center; justify-content: space-between; min-height: 54px; padding: 0 0.15rem; }
  footer .f-cols.f-fold summary { cursor: pointer; }
  footer .f-cols.f-fold summary::after { content: ""; flex: none; width: 8px; height: 8px; margin-right: 0.35rem; border-right: 1.5px solid var(--gold); border-bottom: 1.5px solid var(--gold);
    transform: translateY(-2px) rotate(45deg); transition: transform 0.25s ease; }
  footer .f-cols.f-fold details[open] > summary::after { transform: translateY(2px) rotate(-135deg); }
  footer .f-cols .f-list { display: grid; grid-template-columns: 1fr 1fr; column-gap: 1.1rem; padding: 0 0.15rem 0.9rem; }
  footer .f-cols .f-col a, footer .f-cols nav.f-legal a { min-height: 44px; font-size: 1rem !important; }
  footer .f-copy, footer.doc-foot .f-copy, .doc-foot .f-copy { margin-top: 1.6rem; border-top: 0; padding-top: 0; }
}
@media (prefers-reduced-motion: reduce) { footer .f-cols summary::after { transition: none; } }

/* v166 · phones: close the empty stretch between the last section and the footer.
   The footer emblem now has a still picture, so it is never a blank square while its film waits to play */
@media (max-width: 640px) {
  #grownups { padding-bottom: 2.4rem; }
  footer:not(.doc-foot) { padding-top: 1.9rem; }
  footer .f-logo-video { width: 92px; height: 92px; margin-bottom: 0.55rem; }
  footer .f-cols { margin-top: 1.3rem; }
}

/* v167 · the longer True Story narration carries its own AI label, shown only on the Listen tab */
.st-ai-listen { display: none; }
.story-theatre:has(#stTabListen.on) .st-ai-listen { display: block; }
.story-theatre:has(#stTabListen.on) #stAiNote { display: none; }

/* v168 · the menu button says what it is: a gold pill with three lines and the word Menu. The first time the bar
   appears it glows and a small note points to it. Open, the lines cross and the word becomes Close */
@media (max-width: 1340px) {
  nav .nav-toggle { position: relative; display: inline-flex; align-items: center; gap: 0.6rem; min-height: 44px; padding: 0 1.05rem 0 0.9rem; line-height: 1;
    border: 1px solid rgba(245,200,66,0.7); border-radius: 999px; background: rgba(245,200,66,0.08); color: #fff0c2;
    box-shadow: 0 0 0 rgba(245,200,66,0); transition: background 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease; }
  nav .nav-toggle:hover, nav .nav-toggle:focus-visible { background: rgba(245,200,66,0.18); box-shadow: 0 0 22px rgba(245,200,66,0.45); border-color: #ffe9a8; outline: none; }
  .nt-icon { position: relative; flex: none; width: 20px; height: 14px; }
  .nt-icon i { position: absolute; left: 0; right: 0; height: 2px; border-radius: 2px; background: var(--gold); transition: transform 0.3s ease, opacity 0.2s ease, top 0.3s ease; }
  .nt-icon i:nth-child(1) { top: 0; } .nt-icon i:nth-child(2) { top: 6px; } .nt-icon i:nth-child(3) { top: 12px; }
  .nt-label { font-family: var(--caps); font-size: 0.72rem; letter-spacing: 0.22em; text-transform: uppercase; padding-left: 0.05em; }
  nav .nav-toggle.is-open { background: rgba(245,200,66,0.2); }
  nav .nav-toggle.is-open .nt-icon i:nth-child(1) { top: 6px; transform: rotate(45deg); }
  nav .nav-toggle.is-open .nt-icon i:nth-child(2) { opacity: 0; }
  nav .nav-toggle.is-open .nt-icon i:nth-child(3) { top: 6px; transform: rotate(-45deg); }
  /* the note that points to it */
  .nt-hint { position: absolute; top: calc(100% + 12px); right: 0; white-space: nowrap; padding: 0.5rem 0.85rem; border-radius: 10px;
    background: linear-gradient(160deg, #f8d565, #e0a52c); color: #241703; font-family: var(--serif-display); font-size: 0.98rem; font-weight: 600; letter-spacing: 0;
    text-transform: none; box-shadow: 0 10px 30px rgba(0,0,0,0.55); opacity: 0; transform: translateY(-6px); pointer-events: none; transition: opacity 0.4s ease, transform 0.4s ease; }
  .nt-hint::before { content: ""; position: absolute; top: -6px; right: 26px; width: 12px; height: 12px; background: #f6cf5c; transform: rotate(45deg); }
  nav .nav-toggle.beckon .nt-hint { opacity: 1; transform: none; }
  nav .nav-toggle.beckon { animation: ntGlow 1.6s ease-in-out 3; }
  nav .nav-toggle.beckon .nt-icon i { animation: ntWave 1.6s ease-in-out 3; }
  nav .nav-toggle.beckon .nt-icon i:nth-child(2) { animation-delay: 0.12s; } nav .nav-toggle.beckon .nt-icon i:nth-child(3) { animation-delay: 0.24s; }
  nav .nav-toggle.is-open .nt-hint { opacity: 0 !important; }
}
@keyframes ntGlow { 0%, 100% { box-shadow: 0 0 0 rgba(245,200,66,0); } 50% { box-shadow: 0 0 26px rgba(245,200,66,0.75); background: rgba(245,200,66,0.22); } }
@keyframes ntWave { 0%, 100% { transform: none; } 40% { transform: translateX(3px); } 70% { transform: translateX(-2px); } }
@media (max-width: 420px) { nav .nav-toggle { padding: 0 0.85rem 0 0.75rem; gap: 0.5rem; } .nt-label { letter-spacing: 0.16em; } nav .brand span { font-size: 0.84rem; letter-spacing: 0.1em; } }
@media (max-width: 345px) { nav .brand span { display: none; } }
@media (prefers-reduced-motion: reduce) { nav .nav-toggle.beckon, nav .nav-toggle.beckon .nt-icon i { animation: none; } }

/* v169 · phones: the Menu button a little smaller. Its touch area stays a full 44 px */
@media (max-width: 640px) {
  nav .nav-toggle { min-height: 34px; padding: 0 0.78rem 0 0.68rem; gap: 0.45rem; }
  nav .nav-toggle::after { content: ""; position: absolute; inset: -5px -4px; }
  .nt-icon { width: 16px; height: 12px; }
  .nt-icon i { height: 1.5px; }
  .nt-icon i:nth-child(2) { top: 5px; } .nt-icon i:nth-child(3) { top: 10px; }
  nav .nav-toggle.is-open .nt-icon i:nth-child(1), nav .nav-toggle.is-open .nt-icon i:nth-child(3) { top: 5px; }
  .nt-label { font-size: 0.62rem; letter-spacing: 0.18em; }
  .nt-hint { font-size: 0.92rem; padding: 0.42rem 0.75rem; top: calc(100% + 11px); }
  .nt-hint::before { right: 22px; }
}

/* v170 · the Menu button keeps its gentle glow and rippling lines after the note has gone, for as long as the menu is closed */
@media (max-width: 1340px) {
  nav .nav-toggle.beckon, nav .nav-toggle.beckon .nt-icon i { animation: none; }
  nav .nav-toggle.alive:not(.is-open) { animation: ntGlow 2.4s ease-in-out infinite; }
  nav .nav-toggle.alive:not(.is-open) .nt-icon i { animation: ntWave 2.4s ease-in-out infinite; }
  nav .nav-toggle.alive:not(.is-open) .nt-icon i:nth-child(2) { animation-delay: 0.14s; }
  nav .nav-toggle.alive:not(.is-open) .nt-icon i:nth-child(3) { animation-delay: 0.28s; }
}
@media (prefers-reduced-motion: reduce) { nav .nav-toggle.alive, nav .nav-toggle.alive .nt-icon i { animation: none !important; } }

/* v171 · the three Amazon shops, named for the grown-ups, beside the buy buttons */
.store-links { margin: 0.9rem 0 0; font-size: 0.98rem; line-height: 1.6; color: var(--cream-dim); }
.store-links a { color: var(--gold); text-decoration: underline; text-underline-offset: 0.18em; white-space: nowrap; }
.store-links a:hover, .store-links a:focus-visible { color: #ffe9a8; }
#join .store-links { text-align: center; }

/* v172 · Out Now: one screen. The book glows on the left, three matching gold buttons, one for each Amazon, on the right.
   Starlight twinkles round the card and slow golden rays turn behind it */
#join { padding-top: clamp(3rem, 7vh, 5rem); padding-bottom: clamp(3rem, 7vh, 5rem); }
.join-wrap { position: relative; max-width: 1000px; padding: clamp(1.2rem, 3vh, 2.4rem) clamp(1.2rem, 3vw, 2.6rem); overflow: hidden; }
.join-rays { position: absolute; left: 50%; top: 50%; width: 180%; aspect-ratio: 1; translate: -50% -50%; pointer-events: none; opacity: 0.5;
  background: repeating-conic-gradient(from 0deg, rgba(245,200,66,0.10) 0deg 6deg, rgba(245,200,66,0) 6deg 18deg);
  -webkit-mask-image: radial-gradient(circle, #000 0, rgba(0,0,0,0.5) 35%, rgba(0,0,0,0) 62%); mask-image: radial-gradient(circle, #000 0, rgba(0,0,0,0.5) 35%, rgba(0,0,0,0) 62%);
  animation: joinTurn 90s linear infinite; }
@keyframes joinTurn { to { rotate: 360deg; } }
.join-stars { position: absolute; inset: 0; pointer-events: none; }
.join-stars i { position: absolute; width: 10px; height: 10px; background: radial-gradient(circle, #fff6cf 0, #f5c842 38%, rgba(245,200,66,0) 70%); border-radius: 50%; opacity: 0; animation: joinTwinkle 3.6s ease-in-out infinite; }
.join-stars i::before { content: "✦"; position: absolute; inset: 0; display: grid; place-items: center; font-style: normal; font-size: 13px; color: #fff3c4; text-shadow: 0 0 8px rgba(245,200,66,0.9); }
.join-stars i:nth-child(1) { left: 4%; top: 12%; } .join-stars i:nth-child(2) { left: 14%; top: 82%; animation-delay: -0.7s; } .join-stars i:nth-child(3) { left: 31%; top: 6%; animation-delay: -1.5s; }
.join-stars i:nth-child(4) { left: 39%; top: 91%; animation-delay: -2.2s; } .join-stars i:nth-child(5) { left: 52%; top: 9%; animation-delay: -0.3s; } .join-stars i:nth-child(6) { left: 63%; top: 88%; animation-delay: -2.9s; }
.join-stars i:nth-child(7) { left: 76%; top: 5%; animation-delay: -1.1s; } .join-stars i:nth-child(8) { left: 88%; top: 79%; animation-delay: -1.9s; } .join-stars i:nth-child(9) { left: 95%; top: 22%; animation-delay: -2.6s; }
.join-stars i:nth-child(10) { left: 2%; top: 52%; animation-delay: -3.2s; } .join-stars i:nth-child(11) { left: 96%; top: 55%; animation-delay: -0.9s; } .join-stars i:nth-child(12) { left: 46%; top: 95%; animation-delay: -1.7s; }
@keyframes joinTwinkle { 0%, 100% { opacity: 0; transform: scale(0.4) rotate(0deg); } 50% { opacity: 1; transform: scale(1) rotate(90deg); } }
.join-grid { position: relative; display: grid; grid-template-columns: auto minmax(0, 1fr); gap: clamp(1.4rem, 3.5vw, 3rem); align-items: center; }
.join-cover { --jc: min(430px, calc(100svh - 250px)); position: relative; justify-self: center; flex: none; height: var(--jc); width: calc(var(--jc) * 0.7133); animation: joinFloat 6s ease-in-out infinite; }
.join-cover img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; border-radius: 6px 10px 10px 6px; box-shadow: 0 18px 50px rgba(0,0,0,0.7), 0 0 0 1px rgba(245,200,66,0.35); }
.join-cover::after { content: ""; position: absolute; inset: 0; border-radius: 6px 10px 10px 6px; pointer-events: none; overflow: hidden;
  background: linear-gradient(105deg, rgba(255,255,255,0) 40%, rgba(255,246,207,0.42) 50%, rgba(255,255,255,0) 60%); background-size: 260% 100%; animation: joinShine 5.5s ease-in-out infinite; }
.join-halo { position: absolute; inset: -22%; border-radius: 50%; background: radial-gradient(circle, rgba(245,200,66,0.55) 0, rgba(245,200,66,0.18) 38%, rgba(245,200,66,0) 68%); animation: joinHalo 4.5s ease-in-out infinite; }
@keyframes joinFloat { 0%, 100% { transform: translateY(0) rotate(-1.2deg); } 50% { transform: translateY(-9px) rotate(0.6deg); } }
@keyframes joinShine { 0%, 55% { background-position: 130% 0; } 100% { background-position: -130% 0; } }
@keyframes joinHalo { 0%, 100% { opacity: 0.65; transform: scale(0.95); } 50% { opacity: 1; transform: scale(1.06); } }
.join-copy { text-align: center; min-width: 0; }
#join .join-title { font-size: clamp(1.9rem, 3.7vw, 3rem); line-height: 1.08; margin: 0.35rem 0 0; }
#join .join-sub { margin: 0.7rem auto 0; font-size: clamp(1rem, 1.5vw, 1.2rem); }
.join-for { margin: clamp(0.9rem, 2.2vh, 1.5rem) 0 0.7rem; font-family: var(--caps); font-size: 0.7rem; letter-spacing: 0.26em; text-transform: uppercase; color: var(--gold); }
.join-shops { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0.8rem; }
.join-shop { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 0.2rem; min-height: 62px; padding: 0.55rem 0.6rem; text-align: center; white-space: nowrap;
  box-shadow: 0 0 22px rgba(245,200,66,0.35), 0 8px 22px rgba(0,0,0,0.45); transition: transform 0.25s ease, box-shadow 0.25s ease; }
.join-shop small { font-size: 0.56rem; letter-spacing: 0.24em; opacity: 0.85; font-weight: 400; }
.join-shop b { font-size: 0.82rem; letter-spacing: 0.14em; font-weight: 700; }
.join-shop:hover, .join-shop:focus-visible { transform: translateY(-3px) scale(1.03); box-shadow: 0 0 38px rgba(245,200,66,0.75), 0 12px 26px rgba(0,0,0,0.5); }
.join-shop:nth-child(2) { animation-delay: -2s; } .join-shop:nth-child(3) { animation-delay: -4s; }
#join .join-schools { margin-top: clamp(0.9rem, 2.2vh, 1.5rem); font-size: 0.92rem; }
#join .join-schools a { color: var(--gold); text-decoration: underline; text-underline-offset: 0.18em; }
@media (max-width: 820px) {
  .join-grid { grid-template-columns: 1fr; gap: 0.9rem; }
  .join-cover { --jc: clamp(96px, 17svh, 170px); }
  .join-halo { inset: -30%; }
}
@media (max-width: 560px) {
  #join { padding-left: 0.9rem; padding-right: 0.9rem; }
  .join-wrap { padding: 1.1rem 1rem 1.2rem; }
  #join .join-title { font-size: clamp(1.6rem, 7.4vw, 2rem); }
  .join-shops { grid-template-columns: 1fr; gap: 0.55rem; }
  .join-shop { flex-direction: row; gap: 0.5rem; min-height: 48px; }
  .join-shop small { font-size: 0.6rem; } .join-shop b { font-size: 0.8rem; }
  #join .join-schools { font-size: 0.88rem; }
}
@media (prefers-reduced-motion: reduce) { .join-rays, .join-stars i, .join-cover, .join-cover::after, .join-halo { animation: none; } .join-stars i { opacity: 0.8; } }

/* v172b · Out Now on tablets and phones. Tablets: a larger book and title, three buttons in a row.
   Phones: the three buttons stacked, and the schools line left to the menu so the card clears the floating buttons */
@media (min-width: 561px) and (max-width: 1024px) {
  .join-grid { grid-template-columns: 1fr; gap: 1.2rem; }
  .join-cover { --jc: min(340px, 30svh); }
  #join .join-title { font-size: clamp(2.2rem, 5.6vw, 3rem); }
  #join .join-sub { font-size: 1.2rem; }
  .join-wrap { padding: 2rem 2rem 2.2rem; }
  .join-shop { min-height: 66px; }
  .join-shop b { font-size: 0.88rem; }
}
@media (min-width: 1025px) and (max-height: 760px) { .join-cover { --jc: min(380px, calc(100svh - 270px)); } }
@media (max-width: 560px) {
  #join .join-schools { display: none; }
  .join-cover { --jc: clamp(88px, 15svh, 150px); }
  .join-for { letter-spacing: 0.2em; font-size: 0.66rem; }
}

/* v173 · Out Now takes the whole screen. Nothing of the sections before or after shows when you arrive,
   and the card, the book and the three buttons are all larger */
#join { min-height: 100vh; min-height: 100lvh; display: flex; align-items: center; justify-content: center; padding: 84px clamp(1rem, 3vw, 2.4rem) 2.2rem; }
#join > .join-wrap { width: 100%; max-width: 1180px; margin: 0 auto; padding: clamp(1.6rem, 4.2vh, 3.4rem) clamp(1.6rem, 4vw, 3.8rem); }
.join-grid { gap: clamp(1.6rem, 4.5vw, 4rem); }
.join-cover { --jc: min(600px, calc(100svh - 230px)); }
#join .join-title { font-size: clamp(2.4rem, 4.6vw, 4rem); }
#join .join-sub { font-size: clamp(1.1rem, 1.7vw, 1.4rem); margin-top: 0.9rem; }
#join .oath-kicker { font-size: 0.8rem; }
.join-for { font-size: 0.76rem; margin: clamp(1.1rem, 3vh, 2rem) 0 0.9rem; }
.join-shops { gap: 1rem; }
.join-shop { min-height: 74px; padding: 0.7rem 0.8rem; }
.join-shop small { font-size: 0.6rem; } .join-shop b { font-size: 0.95rem; }
#join .join-schools { font-size: 1rem; margin-top: clamp(1.1rem, 3vh, 2rem); }
@media (min-width: 561px) and (max-width: 1024px) {
  #join { padding: 84px 1.6rem 2.4rem; }
  #join > .join-wrap { max-width: 780px; padding: clamp(1.8rem, 3.6vh, 3rem) 2.2rem; }
  .join-grid { gap: clamp(1.2rem, 2.6vh, 2.2rem); }
  .join-cover { --jc: min(460px, 36svh); }
  #join .join-title { font-size: clamp(2.6rem, 6.4vw, 3.6rem); }
  #join .join-sub { font-size: 1.35rem; }
  .join-shop { min-height: 76px; } .join-shop b { font-size: 0.95rem; }
}
@media (max-width: 560px) {
  #join { padding: 76px 0.8rem 5.4rem; }
  #join > .join-wrap { padding: clamp(1rem, 2.6vh, 1.6rem) 1rem clamp(1.1rem, 2.8vh, 1.7rem); }
  .join-grid { gap: clamp(0.7rem, 2vh, 1.2rem); }
  .join-cover { --jc: clamp(76px, calc(100svh - 548px), 230px); }   /* the book takes whatever height is left, so the card always clears the floating buttons */
  #join .join-title { font-size: clamp(1.75rem, 8vw, 2.3rem); }
  #join .join-sub { font-size: 1.08rem; margin-top: 0.6rem; }
  .join-for { font-size: 0.66rem; margin: clamp(0.8rem, 2.2vh, 1.3rem) 0 0.7rem; }
  .join-shops { gap: clamp(0.5rem, 1.4vh, 0.75rem); }
  .join-shop { min-height: clamp(48px, 7.4svh, 58px); }
  .join-shop b { font-size: 0.86rem; }
}
@media (min-width: 1025px) and (max-height: 760px) { .join-cover { --jc: min(520px, calc(100svh - 210px)); } #join .join-title { font-size: clamp(2.2rem, 4vw, 3.2rem); } .join-shop { min-height: 64px; } }

/* v173b · the words on the three shop buttons are darker and heavier, so they read clearly on the gold, above all on phones.
   Short phones drop the one line of small print so the last button stays clear of the floating buttons */
.join-shop { color: #1b1002; }
.join-shop small { opacity: 1; font-weight: 600; color: #3a2606; }
.join-shop b { font-weight: 600; color: #1b1002; text-shadow: 0 1px 0 rgba(255,246,207,0.55); }
@media (max-width: 560px) {
  .join-shop { gap: 0.55rem; }
  .join-shop small { font-size: 0.7rem; letter-spacing: 0.16em; }
  .join-shop b { font-size: 1.02rem; letter-spacing: 0.1em; }
  #join .oath-kicker { letter-spacing: 0.24em; font-size: 0.7rem; white-space: nowrap; }
  .join-for { letter-spacing: 0.14em; white-space: nowrap; }
}
@media (max-width: 560px) and (max-height: 700px) {
  #join .join-sub { display: none; }
  .join-for { margin-top: 0.7rem; }
}


/* v174 · phones: the book is the star. It takes all the height that the title and the three buttons leave,
   so it is as large as the screen allows while everything still fits on one screen above the floating buttons */
@media (max-width: 560px) {
  #join { padding: 74px 0.8rem 5.5rem; }
  #join > .join-wrap { padding: 0.95rem 0.95rem 1.05rem; }
  .join-grid { gap: 0.7rem; }
  #join .join-sub { display: none; }
  .join-cover { --jc: clamp(120px, calc(100svh - 488px), 330px); }
  .join-halo { inset: -20%; }
  #join .join-title { font-size: clamp(1.6rem, 7.2vw, 2.05rem); margin-top: 0.2rem; }
  .join-for { margin: 0.6rem 0 0.55rem; }
  .join-shops { gap: 0.5rem; }
  .join-shop { min-height: 48px; }
}

/* v175 · Out Now on tablets, upright and on their side.
   Upright: the book above, then the title and the three buttons.
   On its side: the book on the left and the words on the right, as on a desktop, with everything sized to the height of the screen */
@media (min-width: 561px) and (max-width: 1024px) and (orientation: portrait) {
  #join { padding: 84px 1.6rem 2.6rem; }
  #join > .join-wrap { max-width: 760px; padding: clamp(1.6rem, 3vh, 2.8rem) clamp(1.4rem, 4vw, 2.4rem); }
  .join-grid { grid-template-columns: 1fr; gap: clamp(1rem, 2.4vh, 2rem); }
  .join-cover { --jc: max(200px, min(520px, calc(100svh - 560px))); }
  #join .join-title { font-size: clamp(2.3rem, 6vw, 3.4rem); }
  #join .join-sub { font-size: 1.3rem; }
  .join-shops { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0.8rem; }
  .join-shop { flex-direction: column; gap: 0.2rem; min-height: 74px; }
  .join-shop b { font-size: 0.9rem; letter-spacing: 0.1em; }
}
@media (min-width: 561px) and (max-width: 699px) and (orientation: portrait) {
  .join-shops { grid-template-columns: 1fr; gap: 0.6rem; }
  .join-shop { flex-direction: row; gap: 0.6rem; min-height: 56px; }
  .join-cover { --jc: min(420px, calc(100svh - 640px)); }
}
@media (min-width: 561px) and (max-width: 1366px) and (orientation: landscape) {
  #join { padding: 80px clamp(1rem, 2.4vw, 2rem) 1.6rem; }
  #join > .join-wrap { max-width: 1180px; padding: clamp(1rem, 3vh, 2.4rem) clamp(1.2rem, 3vw, 3rem); }
  .join-grid { grid-template-columns: auto minmax(0, 1fr); gap: clamp(1.2rem, 3.2vw, 3rem); }
  .join-cover { --jc: min(560px, calc(100svh - 190px)); }
  #join .join-title { font-size: clamp(1.9rem, 3.8vw, 3.2rem); }
  #join .join-sub { font-size: clamp(1.05rem, 1.6vw, 1.3rem); }
  .join-for { margin: clamp(0.7rem, 2.4vh, 1.6rem) 0 0.7rem; }
  #join .join-schools { margin-top: clamp(0.7rem, 2.4vh, 1.6rem); }
}
@media (min-width: 561px) and (max-width: 1100px) and (orientation: landscape) {
  .join-shops { grid-template-columns: 1fr; gap: 0.6rem; max-width: 440px; margin-left: auto; margin-right: auto; }
  .join-shop { flex-direction: row; gap: 0.6rem; min-height: clamp(46px, 8.4svh, 60px); }
  .join-shop small { font-size: 0.66rem; } .join-shop b { font-size: 0.98rem; }
}
@media (orientation: landscape) and (max-height: 560px) {
  #join { padding: 70px 1rem 1rem; }
  #join > .join-wrap { padding: 0.8rem 1.2rem; }
  .join-grid { grid-template-columns: auto minmax(0, 1fr); gap: 1.2rem; }
  .join-cover { --jc: calc(100svh - 110px); }
  #join .join-sub, #join .join-schools, #join .oath-kicker { display: none; }
  #join .join-title { font-size: clamp(1.5rem, 3.4vw, 2.1rem); }
  .join-for { margin: 0.5rem 0; }
  .join-shops { grid-template-columns: 1fr; gap: 0.4rem; max-width: 420px; margin: 0 auto; }
  .join-shop { flex-direction: row; gap: 0.5rem; min-height: 40px; padding: 0.3rem 0.8rem; }
}

/* v176 · the book's width is now set outright from its height. Safari on iPad was reading the picture's own
   full width for the left-hand column, which squeezed the words into a sliver on the right */
@supports not (height: 100svh) { .join-cover { --jc: 300px !important; } }

/* v177 · phones and tablets: on the Out Now screen the floating Acorn badge and the moon fade away, and the three
   buttons sit a little higher, clear of the browser's own bar at the foot of the screen */
@media (max-width: 1024px) {
  body.at-join .jr-chip, body.at-join #bedtimeToggle { opacity: 0 !important; pointer-events: none !important; transition: opacity 0.3s ease; }
}
@media (max-width: 560px) {
  #join { padding-bottom: calc(6.4rem + env(safe-area-inset-bottom, 0px)); }
  .join-cover { --jc: clamp(110px, calc(100svh - 510px), 330px); }
  .join-shop { position: relative; z-index: 2; }
}

/* v178 · Out Now: no pale shading. The sheen that swept across the book and the striped rays behind it are gone.
   In their place, a soft golden glow that breathes behind the card. The stars, the halo and the floating book stay.
   Nothing that flies about the page can sit on top of the three shop buttons */
.join-cover::after { display: none; }
.join-rays { width: 130%; opacity: 1; background: radial-gradient(circle, rgba(245,200,66,0.17) 0, rgba(245,200,66,0.07) 30%, rgba(245,200,66,0) 58%);
  -webkit-mask-image: none; mask-image: none; animation: joinGlow 7s ease-in-out infinite; }
@keyframes joinGlow { 0%, 100% { opacity: 0.55; scale: 0.94; } 50% { opacity: 1; scale: 1.06; } }
body.at-join .wild-fly, body.at-join .hidden-fairy { pointer-events: none !important; }
@media (prefers-reduced-motion: reduce) { .join-rays { animation: none; } }


/* v179: the song and story bar is a slider you can press and drag, with a gold bead to hold */
.track .t-progress { height: 6px; margin-top: 0.7rem; touch-action: pan-y; -webkit-tap-highlight-color: transparent; user-select: none; -webkit-user-select: none; outline: none; }
.track .t-progress::before { content: ""; position: absolute; left: -6px; right: -6px; top: -15px; bottom: -15px; }
.track .t-progress .t-fill { position: relative; min-width: 0; }
.track .t-progress .t-fill::after {
  content: ""; position: absolute; right: -8px; top: 50%; width: 16px; height: 16px; margin-top: -8px; border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #fff3c4, #f5c842 55%, #c98a12);
  box-shadow: 0 0 0 1px rgba(36, 23, 3, 0.55), 0 0 10px rgba(245, 200, 66, 0.55);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.track .t-progress:hover .t-fill::after, .track.seeking .t-progress .t-fill::after { transform: scale(1.25); box-shadow: 0 0 0 1px rgba(36, 23, 3, 0.55), 0 0 16px rgba(245, 200, 66, 0.9); }
.track .t-progress:focus-visible { box-shadow: 0 0 0 2px #0d0a05, 0 0 0 4px var(--gold); }
@media (hover: none), (pointer: coarse) {
  .track .t-progress { height: 8px; margin-top: 0.85rem; margin-bottom: 0.2rem; }
  .track .t-progress .t-fill::after { width: 20px; height: 20px; margin-top: -10px; right: -10px; }
  .track .t-progress::before { top: -18px; bottom: -18px; }
}


/* v180 · Out Now: the hardback is a real three-dimensional book that turns slowly, as it does in The Book, and can be dragged round */
.join-book { --bh: calc(var(--jc) * 0.9); --bw: calc(var(--bh) * 0.7133); --bd: max(14px, calc(var(--bh) * 0.075));
  position: absolute; inset: 0; perspective: calc(var(--bh) * 4.2); perspective-origin: 50% 46%;
  touch-action: pan-y; cursor: grab; user-select: none; -webkit-user-select: none; -webkit-tap-highlight-color: transparent; }
.join-book.dragging { cursor: grabbing; }
.join-book3d { position: absolute; left: 50%; top: 50%; width: 0; height: 0; transform-style: preserve-3d;
  transform: rotateX(var(--rx, -6deg)) rotateY(var(--ry, -24deg)); will-change: transform; }
.join-book3d::after { content: ""; position: absolute; width: calc(var(--bw) * 1.4); height: calc(var(--bh) * 0.09); left: calc(var(--bw) * -0.7); top: calc(var(--bh) / 2 + var(--bh) * 0.03);
  background: radial-gradient(ellipse, rgba(0,0,0,0.6), rgba(0,0,0,0) 70%); transform: rotateX(90deg); filter: blur(6px); pointer-events: none; }
.join-cover .join-book img { border-radius: 0; box-shadow: none; }
.join-book .bk-cover { transition: none; }
.join-book .cv-out::after { display: none; }
.join-book .bk-base { box-shadow: none; }


/* v181 · Out Now buttons: calmer, bookish lettering. A small engraved label above the shop's name set in the book's own serif,
   no glow behind the letters, and the three buttons shimmer together so they always match */
#join .join-shop { text-transform: none; letter-spacing: 0; padding-left: 0.9rem; padding-right: 0.9rem; }
#join .join-shop:nth-child(2), #join .join-shop:nth-child(3) { animation-delay: 0s; }
#join .join-shop small { font-family: var(--caps); font-size: 0.58rem; font-weight: 600; letter-spacing: 0.24em; margin-right: -0.24em; text-transform: uppercase; line-height: 1; color: rgba(43, 28, 4, 0.74); text-shadow: none; }
#join .join-shop b { font-family: var(--serif-display); font-size: clamp(1.18rem, 0.95rem + 0.5vw, 1.42rem); font-weight: 600; letter-spacing: 0.015em; line-height: 1.05; color: #1a1003; text-shadow: none;
  -webkit-font-smoothing: antialiased; }
#join .join-shop small { margin-bottom: 0.14rem; }


/* v182 · Enter the Realm is the great golden button of the opening screen: it glows, breathes, sends out rings of light
   and is ringed with twinkling stars. Watch the Trailer steps back to a quiet outline beside it */
.btn-realm { position: relative; z-index: 1; overflow: visible; font-weight: 700; color: #1b1002; border-color: #fff6cf;
  box-shadow: 0 0 0 1px rgba(255,246,207,0.9), 0 0 24px rgba(245,200,66,0.8), 0 0 64px rgba(245,200,66,0.4), 0 8px 26px rgba(0,0,0,0.5);
  animation: giltSlide 4.5s linear infinite, realmPulse 2.6s ease-in-out infinite; }
.btn-realm:hover, .btn-realm:focus-visible { transform: translateY(-2px) scale(1.04); }
@keyframes realmPulse {
  0%, 100% { box-shadow: 0 0 0 1px rgba(255,246,207,0.9), 0 0 20px rgba(245,200,66,0.7), 0 0 50px rgba(245,200,66,0.3), 0 8px 26px rgba(0,0,0,0.5); }
  50% { box-shadow: 0 0 0 1px rgba(255,246,207,1), 0 0 36px rgba(255,214,102,1), 0 0 96px rgba(245,200,66,0.6), 0 8px 26px rgba(0,0,0,0.5); }
}
.btn-realm::before, .btn-realm::after { content: ""; position: absolute; inset: -3px; border-radius: 999px; border: 1.5px solid rgba(255,236,170,0.9); pointer-events: none; opacity: 0;
  animation: realmRing 2.6s ease-out infinite; }
.btn-realm::after { animation-delay: 1.3s; }
@keyframes realmRing { 0% { inset: -3px; opacity: 0.9; } 100% { inset: -26px; opacity: 0; } }
.br-sparks { position: absolute; inset: -38px -34px; pointer-events: none; }
.br-sparks i { position: absolute; left: var(--x); top: var(--y); width: var(--s, 12px); height: var(--s, 12px); translate: -50% -50%; opacity: 0;
  filter: drop-shadow(0 0 5px rgba(255,214,102,0.95)) drop-shadow(0 0 1px #fff);
  animation: realmSpark var(--d, 2.4s) ease-in-out var(--w, 0s) infinite; }
.br-sparks i::before { content: ""; position: absolute; inset: 0; background: radial-gradient(circle, #fff 0 24%, #fff0b8 46%, #f5c842 100%);
  clip-path: polygon(50% 0, 59% 41%, 100% 50%, 59% 59%, 50% 100%, 41% 59%, 0 50%, 41% 41%); }
@keyframes realmSpark { 0%, 100% { opacity: 0; transform: scale(0.15) rotate(0deg); } 45%, 60% { opacity: 1; transform: scale(1) rotate(45deg); } }
.br-sparks i:nth-child(1)  { --x: 3%;  --y: 30%; --s: 15px; --d: 2.6s; --w: -0.2s; }
.br-sparks i:nth-child(2)  { --x: 10%; --y: 92%; --s: 10px; --d: 2.1s; --w: -1.1s; }
.br-sparks i:nth-child(3)  { --x: 21%; --y: 6%;  --s: 12px; --d: 2.9s; --w: -1.7s; }
.br-sparks i:nth-child(4)  { --x: 34%; --y: 97%; --s: 14px; --d: 2.4s; --w: -0.6s; }
.br-sparks i:nth-child(5)  { --x: 47%; --y: 2%;  --s: 17px; --d: 2.2s; --w: -1.3s; }
.br-sparks i:nth-child(6)  { --x: 60%; --y: 99%; --s: 10px; --d: 3.1s; --w: -2.2s; }
.br-sparks i:nth-child(7)  { --x: 73%; --y: 5%;  --s: 11px; --d: 2.5s; --w: -0.9s; }
.br-sparks i:nth-child(8)  { --x: 86%; --y: 94%; --s: 15px; --d: 2.3s; --w: -1.9s; }
.br-sparks i:nth-child(9)  { --x: 97%; --y: 62%; --s: 13px; --d: 2.8s; --w: -0.4s; }
.br-sparks i:nth-child(10) { --x: 93%; --y: 14%; --s: 9px;  --d: 2s;   --w: -1.5s; }
.br-sparks i:nth-child(11) { --x: 1%;  --y: 74%; --s: 9px;  --d: 2.7s; --w: -2.4s; }
.br-sparks i:nth-child(12) { --x: 52%; --y: 80%; --s: 8px;  --d: 3.3s; --w: -0.8s; }
@media (min-width: 641px) { .hero-cine .hero-ctas .btn-realm { padding: 1.12rem 2.9rem; font-size: 0.92rem; } .hero-cine .hero-ctas { align-items: center; gap: 1.6rem; } }
@media (max-width: 640px) { .br-sparks { inset: -20px -16px; } .br-sparks i { scale: 0.8; } .hero-cine .hero-ctas { gap: 1.15rem; } .hero-cine .hero-ctas .btn-realm { min-width: 272px; justify-content: center; font-size: 0.8rem; }
  @keyframes realmRing { 0% { inset: -3px; opacity: 0.9; } 100% { inset: -15px; opacity: 0; } } }
@media (prefers-reduced-motion: reduce) {
  .btn-realm { animation: none; } .btn-realm::before, .btn-realm::after { animation: none; opacity: 0; }
  .br-sparks i { animation: none; opacity: 0.9; }
}


/* v183 · Enter the Realm glows smoothly. The glow now breathes by fading a soft light in and out (which phones draw smoothly)
   instead of redrawing the shadow, and the rings of light fade in gently and are kept for desktop only */
.btn-realm { animation: giltSlide 4.5s linear infinite;
  box-shadow: 0 0 0 1px rgba(255,246,207,0.9), 0 0 18px rgba(245,200,66,0.55), 0 8px 26px rgba(0,0,0,0.5); }
.btn-realm::before { inset: 0; border: 0; opacity: 0.3; z-index: -1; will-change: opacity;
  box-shadow: 0 0 30px 5px rgba(255,214,102,0.9), 0 0 84px 16px rgba(245,200,66,0.5);
  animation: realmGlow 2.8s ease-in-out infinite alternate; }
@keyframes realmGlow { from { opacity: 0.25; } to { opacity: 1; } }
.btn-realm::after { animation: realmRing2 3.2s ease-out infinite; animation-delay: 0s; }
@keyframes realmRing2 { 0% { inset: -2px; opacity: 0; } 18% { opacity: 0.7; } 100% { inset: -24px; opacity: 0; } }
.br-sparks i { will-change: transform, opacity; }
@media (max-width: 1024px), (hover: none), (pointer: coarse) {
  .btn-realm::after { display: none; }
  .btn-realm::before { box-shadow: 0 0 22px 3px rgba(255,214,102,0.85), 0 0 54px 10px rgba(245,200,66,0.45); }
  .br-sparks i { filter: drop-shadow(0 0 3px rgba(255,214,102,0.9)); }
}
@media (prefers-reduced-motion: reduce) { .btn-realm::before { animation: none; opacity: 0.7; } .btn-realm::after { display: none; } }


/* v184 · lighter first load. The pictures that sit far behind a dark veil in each section are now smaller copies
   (the veil hides the difference), and the daytime Oak picture is only fetched if the Oak is actually asleep */
.hero-day::before, .hero-day::after { background-image: none; }
body.oak-day .hero-day::before, body.oak-day .hero-day::after { background-image: url("../img/realm/day-oak.jpg"); }
