/* Crowns & Jewels — CLEAR GLASS over candlelit art (owner's glass rule):
   strongly see-through, palette-tinted (deep navy / steel / gold),
   backdrop blur, light and luminous — never frosted or opaque. */
:root {
  --burgundy: #14304d;
  --burgundy-deep: #0a1826;
  --gold: #d8b25a;
  --gold-bright: #f0d089;
  --parchment: #e9eff7;
  --ink: #0d1a29;
  --glass-bright: rgba(219, 233, 248, 0.22);
  --glass-tint: rgba(41, 90, 146, 0.14);
  --glass-border: rgba(216, 178, 90, 0.55);
  --text: #eef4fb;
  --muted: #b7c8dc;
  --danger: #e88;
}
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 19px;
  color: var(--text);
  background: var(--burgundy-deep);
  min-height: 100vh;
}
.bg {
  position: fixed; inset: 0; z-index: -1;
  background:
    radial-gradient(120% 90% at 50% 0%, rgba(8,22,40,0.10), rgba(8,22,40,0.72)),
    url('/assets/situation.jpg') center / cover no-repeat fixed,
    var(--burgundy-deep);
  filter: brightness(1.32) saturate(1.06);
  transition: filter 1.1s ease;
}
/* When a decision lands, the candlelight in the room itself answers. */
body.shift .bg { filter: brightness(1.46) saturate(1.14); }
h1, h2, h3, .cinzel { font-family: "Cinzel", serif; letter-spacing: 0.04em; }
button { font-family: inherit; cursor: pointer; }
img { max-width: 100%; display: block; }

/* ---------- clear glass ---------- */
.glass {
  background: linear-gradient(155deg, var(--glass-bright), var(--glass-tint));
  -webkit-backdrop-filter: blur(16px) saturate(1.5);
  backdrop-filter: blur(16px) saturate(1.5);
  border: 1px solid var(--glass-border);
  border-radius: 16px;
  box-shadow: inset 0 1px 0 rgba(255, 244, 214, 0.35), inset 0 -1px 0 rgba(0,0,0,0.15), 0 12px 32px rgba(0,0,0,0.35);
}
.glass-soft {
  background: linear-gradient(155deg, rgba(219,233,248,0.18), rgba(41,90,146,0.09));
  -webkit-backdrop-filter: blur(12px) saturate(1.4);
  backdrop-filter: blur(12px) saturate(1.4);
  border: 1px solid rgba(216,178,90,0.38);
  border-radius: 14px;
  box-shadow: inset 0 1px 0 rgba(255,244,214,0.25), 0 8px 22px rgba(0,0,0,0.28);
}

/* ---------- chrome ---------- */
.topbar {
  position: sticky; top: 10px; z-index: 40;
  margin: 10px auto 0; max-width: 1080px; width: calc(100% - 20px);
  display: flex; align-items: center; gap: 14px; padding: 10px 16px;
}
.brand { background: none; border: 0; color: var(--text); text-align: left; line-height: 1; padding: 0; }
.brand-crown { color: var(--gold); font-size: 26px; margin-right: 6px; text-shadow: 0 0 14px rgba(216,178,90,.8); }
.brand-text { font-family: "Cinzel", serif; font-weight: 900; font-size: 21px; }
.brand-text .amp { color: var(--gold); }
.brand-sub { display: block; font-family: "Cinzel", serif; font-size: 10.5px; letter-spacing: .34em; color: var(--muted); margin-top: 3px; text-transform: uppercase; }
.topnav { display: flex; gap: 4px; margin-left: auto; }
.topnav button, .ghost-btn {
  background: rgba(219,233,248,0.08); color: var(--text);
  border: 1px solid rgba(216,178,90,0.35); border-radius: 999px;
  padding: 7px 14px; font-size: 15.5px;
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
}
.topnav button:hover, .ghost-btn:hover { border-color: var(--gold); color: var(--gold-bright); }
.topmeta { display: flex; align-items: center; gap: 8px; }
.coin-chip { padding: 6px 12px; border-radius: 999px; font-size: 16px; position: relative; }
.coin-chip b { color: var(--gold-bright); }
.coin-chip.coin-pulse { animation: coinPulse .6s ease; }
@keyframes coinPulse { 0% { transform: scale(1); } 40% { transform: scale(1.13); } 100% { transform: scale(1); } }
.coin-float { position: absolute; right: 4px; top: -8px; color: var(--gold-bright); font-family: "Cinzel", serif; font-weight: 700; font-size: 15px; pointer-events: none; text-shadow: 0 2px 8px rgba(0,0,0,.65); animation: coinFloat 1.25s ease-out both; }
@keyframes coinFloat { from { opacity: 0; transform: translateY(6px); } 25% { opacity: 1; } to { opacity: 0; transform: translateY(-18px); } }
.adult-badge { border: 1.5px solid #c0392b; color: #ff9d8f; border-radius: 6px; padding: 2px 7px; font-family: "Cinzel", serif; font-weight: 700; font-size: 13px; }
.app { max-width: 1080px; margin: 0 auto; padding: 18px 14px 40px; }
.footer { max-width: 1080px; margin: 0 auto 16px; width: calc(100% - 20px); padding: 16px 20px; text-align: center; }
.footer p { margin: 4px 0; }
.fine { font-size: 15px; color: var(--muted); }
.link-btn { background: none; border: 0; color: var(--gold-bright); font-size: 15px; text-decoration: underline; padding: 0; }

/* ---------- hero & library ---------- */
.hero { position: relative; border-radius: 20px; overflow: hidden; border: 1px solid var(--glass-border); box-shadow: 0 18px 44px rgba(0,0,0,.5); }
.hero img { width: 100%; height: min(46vh, 420px); object-fit: cover; filter: brightness(1.16) saturate(1.06); animation: kenburns 26s ease-in-out infinite alternate; will-change: transform; }
@keyframes kenburns { from { transform: scale(1) translate(0, 0); } to { transform: scale(1.09) translate(-1.6%, -2%); } }
.hero-veil { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(8,22,40,.10) 30%, rgba(8,22,40,.64)); display: flex; flex-direction: column; justify-content: flex-end; padding: 26px; }
.hero h1 { margin: 0; font-size: clamp(30px, 5.4vw, 52px); font-weight: 900; text-shadow: 0 3px 18px rgba(0,0,0,.7); }
.hero h1 .amp { color: var(--gold); }
.hero .kicker { font-family: "Cinzel", serif; letter-spacing: .3em; font-size: 12px; color: var(--gold-bright); text-transform: uppercase; margin-bottom: 8px; }
.tagline { font-size: clamp(19px, 2.6vw, 24px); font-style: italic; color: #ffeec4; max-width: 760px; margin: 10px 0 0; text-shadow: 0 2px 10px rgba(0,0,0,.8); }
.twist { margin-top: 8px; color: var(--muted); font-size: 17.5px; }
.section-head { display: flex; align-items: baseline; gap: 12px; margin: 30px 4px 14px; }
.section-head h2 { margin: 0; font-size: 24px; color: var(--gold-bright); }
.section-head .rule { flex: 1; height: 1px; background: linear-gradient(90deg, var(--glass-border), transparent); }
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 16px; }
.ep-card { overflow: hidden; padding: 0; text-align: left; color: var(--text); width: 100%; }
.ep-card .thumb { height: 250px; overflow: hidden; position: relative; }
.ep-card .thumb img { width: 100%; height: 100%; object-fit: cover; object-position: top; filter: brightness(1.15) saturate(1.05); transition: transform .6s ease; }
.ep-card:hover .thumb img { transform: scale(1.045); }
.ep-card .thumb .ep-no { position: absolute; top: 10px; left: 10px; background: rgba(8,22,40,.55); border: 1px solid var(--glass-border); color: var(--gold-bright); border-radius: 999px; padding: 3px 11px; font-family: "Cinzel", serif; font-size: 12px; letter-spacing: .14em; -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); }
.ep-card .body { padding: 14px 16px 16px; }
.ep-card h3 { margin: 0 0 2px; font-size: 21px; }
.ep-card .sub { color: var(--gold-bright); font-style: italic; font-size: 17px; }
.ep-card .era { color: var(--muted); font-size: 14.5px; letter-spacing: .12em; text-transform: uppercase; font-family: "Cinzel", serif; margin: 6px 0; }
.ep-card p { margin: 6px 0 10px; font-size: 16.5px; line-height: 1.45; color: #efe3c8; }
.ep-card .foot { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.pill { border: 1px solid rgba(216,178,90,.45); border-radius: 999px; padding: 3px 11px; font-size: 14px; color: var(--gold-bright); background: rgba(219,233,248,.07); }
.pill.done { color: #b9e7b0; border-color: rgba(140,220,130,.5); }
.pill.lock { color: #ffb3a0; border-color: rgba(230,140,110,.5); }
.pill.soon { color: var(--muted); }
.medallion { height: 100%; display: flex; align-items: center; justify-content: center; background: radial-gradient(circle at 50% 38%, rgba(216,178,90,.30), rgba(16,42,72,.55) 70%); font-family: "Cinzel", serif; font-size: 92px; color: var(--gold-bright); text-shadow: 0 0 26px rgba(216,178,90,.6); }
.interlude { margin: 26px 0 4px; padding: 14px 18px; text-align: center; color: var(--muted); font-style: italic; }

/* ---------- play view ---------- */
.play-head { padding: 18px; display: grid; grid-template-columns: 168px 1fr; gap: 18px; align-items: center; }
.frame { position: relative; border-radius: 12px; padding: 7px; background: linear-gradient(150deg, #f4d98c, #9a742f 40%, #e9cd82 60%, #7c5c22); box-shadow: 0 10px 26px rgba(0,0,0,.5), inset 0 0 0 2px rgba(60,40,8,.55); animation: candleGlow 5.4s ease-in-out infinite; }
/* Candlelight breathes around the portrait — the glow never sits still. */
@keyframes candleGlow {
  0%, 100% { box-shadow: 0 10px 26px rgba(0,0,0,.5), 0 0 14px rgba(216,178,90,.16), inset 0 0 0 2px rgba(60,40,8,.55); }
  30% { box-shadow: 0 10px 26px rgba(0,0,0,.5), 0 0 27px rgba(230,190,100,.30), inset 0 0 0 2px rgba(60,40,8,.55); }
  55% { box-shadow: 0 10px 26px rgba(0,0,0,.5), 0 0 18px rgba(216,178,90,.20), inset 0 0 0 2px rgba(60,40,8,.55); }
  78% { box-shadow: 0 10px 26px rgba(0,0,0,.5), 0 0 31px rgba(240,208,137,.34), inset 0 0 0 2px rgba(60,40,8,.55); }
}
.frame.enter { animation: frameIn .7s cubic-bezier(.22,.8,.3,1) both, candleGlow 5.4s ease-in-out .7s infinite; }
@keyframes frameIn { from { opacity: 0; transform: translateX(-22px); } to { opacity: 1; transform: none; } }
.frame-clip { overflow: hidden; border-radius: 7px; }
.frame-clip img { animation: breathe 8s ease-in-out infinite; transform-origin: 50% 32%; will-change: transform; }
@keyframes breathe { 0%, 100% { transform: scale(1.02) translateY(0); } 50% { transform: scale(1.055) translateY(-4px); } }
.frame.react .frame-clip { animation: reactPulse .6s ease; }
@keyframes reactPulse { 0% { transform: scale(1); } 35% { transform: scale(1.045); } 100% { transform: scale(1); } }
.frame::after { content: '✦'; position: absolute; bottom: -11px; left: 50%; transform: translateX(-50%); background: var(--burgundy-deep); color: var(--gold); border: 1px solid var(--glass-border); border-radius: 999px; width: 24px; height: 24px; line-height: 22px; text-align: center; font-size: 13px; }
.frame img { border-radius: 7px; width: 100%; height: 218px; object-fit: cover; object-position: top; filter: brightness(1.12) saturate(1.05); }
.play-head .kicker { font-family: "Cinzel", serif; letter-spacing: .26em; font-size: 11.5px; color: var(--gold-bright); text-transform: uppercase; }
.play-head h2 { margin: 4px 0 2px; font-size: clamp(24px, 4vw, 34px); }
.play-head .sub { font-style: italic; color: var(--gold-bright); font-size: 19px; }
.play-head .era { color: var(--muted); letter-spacing: .16em; font-size: 13.5px; text-transform: uppercase; font-family: "Cinzel", serif; margin-top: 5px; }
.playas { margin-top: 8px; font-size: 17.5px; color: #ffeec4; }
.head-actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 12px; }
.btn {
  background: linear-gradient(155deg, rgba(219,233,248,.16), rgba(30,70,120,.20));
  -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
  color: var(--text); border: 1px solid var(--glass-border); border-radius: 999px;
  padding: 9px 18px; font-size: 16.5px; font-family: "Cinzel", serif; letter-spacing: .03em;
}
.btn { transition: transform .12s ease, border-color .15s ease, color .15s ease, filter .15s ease; }
.btn:active { transform: scale(.96); }
.btn:hover { border-color: var(--gold-bright); color: var(--gold-bright); }
.btn.gold { background: linear-gradient(155deg, #e9cd82, #b98f3e); color: #33160a; font-weight: 700; border-color: #f4d98c; }
.btn.gold:hover { color: #1d0c04; filter: brightness(1.06); }
.btn.small { padding: 6px 13px; font-size: 14.5px; }
.btn:disabled { opacity: .45; cursor: not-allowed; }
.stats-row { display: flex; gap: 8px; flex-wrap: wrap; margin: 14px 0 0; }
.stat-chip { display: inline-flex; align-items: center; gap: 7px; padding: 6px 13px; border-radius: 999px; font-size: 16px; }
.stat-chip .ic { color: var(--gold); }
.stat-chip b { color: var(--gold-bright); font-family: "Cinzel", serif; }
.stat-chip { transition: box-shadow .35s ease, border-color .35s ease; }
.stat-chip .bar { width: 54px; height: 6px; border-radius: 3px; background: rgba(219,233,248,.18); overflow: hidden; }
.stat-chip .bar i { display: block; height: 100%; background: linear-gradient(90deg, #b98f3e, var(--gold-bright)); transition: width .6s ease; }
.stat-chip.stat-up { border-color: rgba(140,220,130,.7); box-shadow: 0 0 16px rgba(150,230,140,.35); }
.stat-chip.stat-down { border-color: rgba(230,140,110,.7); box-shadow: 0 0 16px rgba(230,120,100,.35); }
.secret-line { margin-top: 10px; font-size: 16px; color: var(--muted); }
.secret-line b { color: var(--gold-bright); }
.section-card { margin-top: 16px; padding: 26px clamp(18px, 4vw, 38px); scroll-margin-top: 92px; }
.section-enter { animation: rise .55s ease both; }
.section-card.lit { animation: rise .55s ease both, cardGlow 1.15s ease .1s; }
@keyframes cardGlow { 0% { box-shadow: 0 0 0 rgba(216,178,90,0); } 35% { box-shadow: 0 0 46px rgba(216,178,90,.38); } 100% { box-shadow: 0 0 0 rgba(216,178,90,0); } }
.scene-leaving { opacity: 0; transform: translateY(12px); transition: opacity .3s ease, transform .3s ease; }
/* The consequence beat: the court answers your decision before the page turns. */
.beat { margin-top: 18px; padding: 13px 16px; text-align: center; }
.beat-head { font-family: "Cinzel", serif; font-size: 12.5px; letter-spacing: .22em; text-transform: uppercase; color: var(--gold-bright); margin-bottom: 6px; }
.beat-line { font-size: 17.5px; color: #ffe9b0; opacity: 0; transform: translateY(8px); transition: opacity .35s ease, transform .35s ease; padding: 2px 0; }
.beat.show .beat-line { opacity: 1; transform: none; }
@keyframes rise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
.section-card h3 { margin: 0 0 12px; font-size: 24px; color: var(--gold-bright); text-align: center; }
.section-card h3::before, .section-card h3::after { content: ' ✦ '; color: var(--gold); font-size: 15px; vertical-align: 3px; }
.section-text p { font-size: 20.5px; line-height: 1.62; margin: 0 0 14px; color: #f9f0da; }
.section-text p:first-of-type::first-letter { font-family: "Cinzel", serif; font-size: 44px; color: var(--gold-bright); line-height: 1; padding-right: 4px; }
.tidbit { margin: 18px 0 4px; padding: 13px 16px; display: flex; gap: 12px; align-items: flex-start; animation: tidbitIn .6s ease both; }
@keyframes tidbitIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
.tidbit .t-ic { font-size: 21px; animation: candleFlicker 2.8s ease-in-out infinite; }
@keyframes candleFlicker { 0%, 100% { filter: brightness(1); } 30% { filter: brightness(1.4); } 55% { filter: brightness(.88); } 75% { filter: brightness(1.28); } }
.tidbit .t-head { font-family: "Cinzel", serif; font-size: 12.5px; letter-spacing: .22em; text-transform: uppercase; color: var(--gold-bright); }
.tidbit p { margin: 3px 0 0; font-size: 16.5px; font-style: italic; color: #efe3c8; line-height: 1.45; }
.notes { margin: 12px 0 0; display: flex; gap: 8px; flex-wrap: wrap; }
.note { background: rgba(216,178,90,.16); border: 1px solid rgba(216,178,90,.5); color: #ffe9b0; border-radius: 999px; padding: 4px 12px; font-size: 15px; animation: tidbitIn .5s ease both; }
.choices { margin-top: 20px; display: grid; gap: 11px; }
.choice {
  display: flex; gap: 13px; align-items: flex-start; text-align: left; width: 100%;
  padding: 14px 16px; border-radius: 14px; color: var(--text); font-size: 18.5px; line-height: 1.4;
  background: linear-gradient(155deg, rgba(219,233,248,.13), rgba(30,70,120,.16));
  -webkit-backdrop-filter: blur(12px) saturate(1.4); backdrop-filter: blur(12px) saturate(1.4);
  border: 1px solid rgba(216,178,90,.42);
  box-shadow: inset 0 1px 0 rgba(255,244,214,.28);
  transition: transform .15s ease, border-color .15s ease, box-shadow .25s ease, opacity .25s ease, background .25s ease;
}
.choice:hover:not(:disabled) { transform: translateY(-1px); border-color: var(--gold-bright); box-shadow: inset 0 1px 0 rgba(255,244,214,.28), 0 6px 20px rgba(0,0,0,.30), 0 0 14px rgba(216,178,90,.18); }
.choice:active:not(:disabled) { transform: scale(.985); }
.choice.chosen { border-color: var(--gold-bright); background: linear-gradient(155deg, rgba(219,233,248,.26), rgba(52,110,180,.28)); box-shadow: inset 0 1px 0 rgba(255,244,214,.42), 0 0 24px rgba(216,178,90,.38); transform: scale(1.012); opacity: 1; }
.choice.chosen .letter { background: var(--gold); color: #33160a; }
.choice.dimmed { opacity: .35; }
.choice .letter { flex: none; width: 32px; height: 32px; border-radius: 999px; border: 1.5px solid var(--gold); color: var(--gold-bright); font-family: "Cinzel", serif; font-weight: 700; display: flex; align-items: center; justify-content: center; font-size: 16px; margin-top: 1px; }
.choice.premium { border-color: rgba(240,208,137,.85); box-shadow: inset 0 1px 0 rgba(255,244,214,.35), 0 0 16px rgba(216,178,90,.22); }
.choice:disabled { opacity: .55; cursor: not-allowed; }
.choice .hint { display: block; font-size: 14.5px; color: var(--muted); margin-top: 3px; font-style: italic; }
.choice .prem-tag { color: var(--gold-bright); font-family: "Cinzel", serif; font-size: 11px; letter-spacing: .18em; text-transform: uppercase; }

/* ---------- endings & epilogue ---------- */
.ending-banner { text-align: center; padding: 10px 0 2px; }
.ending-banner .crown { font-size: 40px; color: var(--gold); text-shadow: 0 0 22px rgba(216,178,90,.75); }
.ending-banner h3 { margin: 6px 0 2px; font-size: 27px; }
.ending-banner .best { color: var(--gold-bright); font-family: "Cinzel", serif; letter-spacing: .2em; font-size: 12.5px; text-transform: uppercase; }
.epilogue { margin-top: 20px; border-radius: 14px; overflow: hidden; border: 1px solid rgba(70,90,120,.65); color: var(--ink); background: #dfe7f1; box-shadow: 0 14px 30px rgba(0,0,0,.45); }
.epilogue .inner { background: rgba(242,246,251,.96); padding: 22px clamp(18px, 4vw, 32px); }
.epilogue h4 { font-family: "IBM Plex Mono", monospace; font-size: 23px; letter-spacing: .08em; text-transform: uppercase; margin: 0 0 6px; color: #14304d; font-weight: 700; }
.epilogue h5 { font-family: "Cinzel", serif; margin: 14px 0 5px; font-size: 14.5px; letter-spacing: .14em; text-transform: uppercase; color: #33506e; }
.epilogue p { margin: 0 0 7px; font-size: 17.5px; line-height: 1.5; }

/* ---------- panels, forms, modals ---------- */
.panel { padding: 22px clamp(16px, 3.5vw, 30px); margin-top: 16px; }
.panel h2 { margin-top: 0; color: var(--gold-bright); }
.field { margin-bottom: 13px; }
.field label { display: block; font-size: 15.5px; color: var(--muted); margin-bottom: 5px; font-family: "Cinzel", serif; letter-spacing: .05em; }
.field input[type="text"], .field input[type="email"], .field input[type="password"] {
  width: 100%; padding: 11px 14px; border-radius: 11px; font-size: 17px; font-family: inherit;
  background: rgba(219,233,248,.10); border: 1px solid rgba(216,178,90,.4); color: var(--text);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
}
.field input::placeholder { color: rgba(183,200,220,.6); }
.checkline { display: flex; gap: 10px; align-items: flex-start; font-size: 16.5px; margin: 12px 0; }
.checkline input { margin-top: 5px; transform: scale(1.25); }
.form-err { color: #ffb3a0; font-size: 16px; min-height: 20px; }
.modal-veil { position: fixed; inset: 0; z-index: 90; background: rgba(4,12,24,.42); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); display: flex; align-items: flex-start; justify-content: center; overflow-y: auto; padding: 22px 12px; }
.modal { max-width: 560px; width: 100%; padding: 24px; margin: auto 0; }
.modal.wide { max-width: 860px; }
.modal h2 { margin: 0 0 6px; color: var(--gold-bright); }
.modal .x { float: right; }
.grid-looks { display: grid; grid-template-columns: repeat(auto-fill, minmax(128px, 1fr)); gap: 12px; margin: 10px 0 4px; }
.look { padding: 0; overflow: hidden; text-align: left; color: var(--text); width: 100%; }
.look img { height: 158px; width: 100%; object-fit: cover; object-position: top; filter: brightness(1.14) saturate(1.05); }
.look .cap { padding: 8px 10px 10px; }
.look .cap b { display: block; font-size: 16px; font-family: "Cinzel", serif; font-weight: 700; }
.look .cap span { font-size: 13.5px; color: var(--muted); line-height: 1.3; display: block; }
.look.sel { outline: 2px solid var(--gold-bright); }
.look .price { color: var(--gold-bright); font-family: "Cinzel", serif; font-size: 14px; }
.acc-row { display: flex; flex-wrap: wrap; gap: 8px; margin: 8px 0; }
.acc-chip { border-radius: 999px; padding: 7px 13px; font-size: 15px; color: var(--text); background: rgba(219,233,248,.08); border: 1px solid rgba(216,178,90,.4); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); }
.acc-chip.on { background: rgba(216,178,90,.30); border-color: var(--gold-bright); color: #ffeec4; }
.acc-chip .p { color: var(--gold-bright); font-size: 13.5px; }
.store-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 16px; }
.pack { padding: 20px; display: flex; flex-direction: column; gap: 8px; }
.pack h3 { margin: 0; font-size: 19px; }
.pack .price { font-family: "Cinzel", serif; font-size: 26px; color: var(--gold-bright); }
.pack p { margin: 0; font-size: 16.5px; color: #efe3c8; line-height: 1.45; flex: 1; }
.toast { position: fixed; left: 50%; bottom: 22px; transform: translateX(-50%); z-index: 120; padding: 11px 20px; border-radius: 999px; font-size: 16.5px; max-width: min(92vw, 560px); text-align: center; }
.kv { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.kv .cell { padding: 12px 14px; }
.kv .cell b { display: block; font-size: 22px; color: var(--gold-bright); font-family: "Cinzel", serif; }
table.simple { width: 100%; border-collapse: collapse; font-size: 15.5px; }
table.simple td, table.simple th { padding: 6px 8px; border-bottom: 1px solid rgba(216,178,90,.25); text-align: left; }
.legal p, .legal li { font-size: 17px; line-height: 1.55; color: #efe3c8; }
/* ---------- Chapters staging: the painted scene is the stage ---------- */
.stage {
  position: relative; margin-top: 16px; border-radius: 20px; overflow: hidden;
  border: 1px solid var(--glass-border);
  box-shadow: 0 18px 44px rgba(0,0,0,.45), inset 0 1px 0 rgba(255,244,214,.3);
  min-height: min(84vh, 780px);
  scroll-margin-top: 92px;
  background: var(--burgundy-deep);
}
.stage.lit { animation: rise .55s ease both, cardGlow 1.15s ease .1s; }
.stage-img {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
  filter: brightness(1.19) saturate(1.07);
  animation: kenburns 30s ease-in-out infinite alternate; will-change: transform;
}
.stage-shade {
  position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(180deg, rgba(8,22,40,.18) 0%, rgba(8,22,40,0) 26%, rgba(8,22,40,0) 52%, rgba(8,22,40,.44) 100%);
}
.chapter-card {
  position: absolute; top: 16px; left: 16px; z-index: 6;
  padding: 12px 20px 13px; text-align: center; max-width: min(78%, 470px);
  border-radius: 14px;
}
.chapter-no {
  font-family: "Cinzel", serif; font-size: 12.5px; font-weight: 700;
  letter-spacing: .34em; text-transform: uppercase; color: var(--gold-bright);
  text-shadow: 0 1px 6px rgba(4,12,24,.5);
}
.chapter-title { margin: 3px 0 2px; font-size: clamp(21px, 3.6vw, 29px); color: #fff3d0; text-shadow: 0 2px 10px rgba(4,12,24,.55); }
.chapter-era { font-family: "Cinzel", serif; font-size: 11.5px; letter-spacing: .18em; text-transform: uppercase; color: var(--muted); }
.stage-figure {
  position: absolute; right: 16px; bottom: 16px; z-index: 4;
  width: min(26%, 196px); height: 57%;
}
.stage-figure .frame-clip { height: 100%; }
.stage-figure img { height: 100%; width: 100%; object-fit: cover; object-position: top; }
.beatbox {
  position: absolute; left: 50%; transform: translateX(-50%); bottom: 16px; z-index: 5;
  width: min(94%, 800px); padding: 18px 22px 11px; cursor: pointer;
  background: linear-gradient(155deg, rgba(219,233,248,.24), rgba(16,42,72,.36));
}
.beatbox[hidden] { display: none; }
.beat-text {
  margin: 0; font-size: 21.5px; line-height: 1.58; color: #fff8e6;
  text-shadow: 0 1px 4px rgba(4,12,24,.45); min-height: 2.6em;
}
.beat-text.beat-in { animation: beatIn .38s ease both; }
@keyframes beatIn { from { opacity: 0; transform: translateY(9px); } to { opacity: 1; transform: none; } }
.beat-foot { display: flex; justify-content: space-between; align-items: baseline; margin-top: 9px; }
.beat-count { font-family: "Cinzel", serif; font-size: 12px; letter-spacing: .2em; color: var(--muted); }
.beat-next {
  font-family: "Cinzel", serif; font-size: 12.5px; letter-spacing: .22em; text-transform: uppercase;
  color: var(--gold-bright); animation: beatPulse 1.9s ease-in-out infinite;
}
@keyframes beatPulse { 0%, 100% { opacity: .55; } 50% { opacity: 1; } }
.stage-choices {
  position: absolute; left: 50%; transform: translateX(-50%); bottom: 16px; z-index: 5;
  width: min(94%, 800px); max-height: 66%; overflow-y: auto;
  padding: 16px 18px;
  background: linear-gradient(155deg, rgba(219,233,248,.24), rgba(16,42,72,.36));
}
.stage-choices[hidden] { display: none; }
.stage-choices.show { animation: riseCentered .5s ease both; }
@keyframes riseCentered { from { opacity: 0; transform: translateX(-50%) translateY(14px); } to { opacity: 1; transform: translateX(-50%) translateY(0); } }
.stage-choices .choices { margin-top: 4px; }
.stage-choices .tidbit { margin: 0 0 12px; }
.stage-choices .ending-banner h3 { color: var(--gold-bright); font-size: 26px; margin: 4px 0 2px; }
.stage .beat {
  position: absolute; top: 88px; left: 50%; transform: translateX(-50%);
  width: min(92%, 560px); z-index: 7; margin-top: 0;
}
.epilogue { scroll-margin-top: 92px; }
@media (max-width: 640px) {
  .stage { min-height: 76vh; }
  .stage-figure { width: 33%; height: 44%; right: 10px; bottom: 10px; }
  .chapter-card { top: 10px; left: 10px; padding: 9px 14px 10px; }
  .chapter-title { font-size: 20px; }
  .beatbox { bottom: 10px; padding: 14px 16px 9px; }
  .beat-text { font-size: 19.5px; }
  .stage-choices { bottom: 10px; max-height: 72%; padding: 13px; }
  .play-head { grid-template-columns: 108px 1fr; }
  .frame img { height: 148px; }
  .topnav { display: none; }
  .brand-sub { display: none; }
  .section-text p { font-size: 19px; }
}
@media (prefers-reduced-motion: reduce) {
  .section-enter, .stage.lit, .tidbit, .note { animation: none; }
  .ep-card .thumb img { transition: none; }
  .hero img, .frame, .frame.enter, .frame-clip img, .frame.react .frame-clip,
  .tidbit .t-ic, .coin-chip.coin-pulse, .coin-float,
  .stage-img, .beat-text.beat-in, .stage-choices.show, .beat-next { animation: none; }
  .bg, .choice, .btn, .stat-chip, .stat-chip .bar i, .beat-line { transition: none; }
  .beat-line { opacity: 1; transform: none; }
}
