/* Story templates: slides sized for a phone, five themes (body.th-*) */
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; height: 100%; overflow: hidden; overscroll-behavior: none; }
body { font-family: var(--sans); color: var(--ink); background: var(--bg); -webkit-font-smoothing: antialiased; }
button { font: inherit; color: inherit; border: 0; background: none; cursor: pointer; padding: 0; }
img { display: block; max-width: 100%; }
[hidden] { display: none !important; }

/* ---------- deck ---------- */
#deck { position: fixed; inset: 0; }
.slide { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center;
  padding: calc(70px + env(safe-area-inset-top)) 24px calc(64px + env(safe-area-inset-bottom)); overflow-y: auto; overflow-x: hidden;
  opacity: 0; visibility: hidden; transform: translateX(40px); transition: opacity .5s ease, transform .55s cubic-bezier(.2, .8, .2, 1), visibility 0s .55s; }
.slide.on { opacity: 1; visibility: visible; transform: none; transition: opacity .5s ease, transform .55s cubic-bezier(.2, .8, .2, 1), visibility 0s; }
.slide.past { transform: translateX(-40px); }
.slide > * { max-width: 460px; flex: none; }
/* centred when it fits, scrollable from the top when it does not */
.slide { justify-content: flex-start; } .slide > :first-child { margin-top: auto; } .slide > :last-child { margin-bottom: auto; }
.deco { position: fixed; inset: 0; pointer-events: none; overflow: hidden; }

/* ---------- hud ---------- */
.hud { position: fixed; left: 0; right: 0; top: 0; z-index: 20; display: flex; align-items: center; justify-content: space-between; padding: calc(14px + env(safe-area-inset-top)) 16px 10px; pointer-events: none; transition: opacity .4s; }
.hud > * { pointer-events: auto; }
body.at-start .hud .back, body.at-end .hud .next { visibility: hidden; }
body.at-start .hud, body.locked .hud, body.locked .dots { opacity: 0; pointer-events: none; }
body.at-start .hud > * { pointer-events: none; }
.nav { font: 700 11px var(--sans); letter-spacing: .14em; text-transform: uppercase; padding: 9px 16px; border-radius: 999px; min-height: 36px; display: inline-flex; align-items: center; gap: 6px; }
.nav .ab, .stage, .score, .quest { display: none; }
.dots { position: fixed; left: 0; right: 0; bottom: calc(18px + env(safe-area-inset-bottom)); z-index: 20; display: flex; justify-content: center; gap: 6px; transition: opacity .4s; }
.dots i { width: 6px; height: 6px; border-radius: 50%; background: var(--dot-off); transition: all .3s; }
.dots i.on { background: var(--accent); width: 18px; border-radius: 4px; }
body.at-start .dots { opacity: 0; }

/* ---------- shared pieces ---------- */
.eyebrow { font: 700 10.5px var(--sans); letter-spacing: .22em; text-transform: uppercase; color: var(--accent); margin: 0 0 10px; }
h1, h2 { margin: 0; font-weight: 400; }
.o-title { font-family: var(--script); font-size: clamp(2.6rem, 13vw, 3.6rem); line-height: 1.05; color: var(--title); }
.o-name { font-family: var(--script); font-size: clamp(2.6rem, 13vw, 3.6rem); line-height: 1.1; color: var(--title); margin: 0 0 12px; }
.o-sub { font-size: 13px; color: var(--muted); margin: 0 0 22px; line-height: 1.5; }
h2 { font-family: var(--script); font-size: clamp(2rem, 10vw, 2.7rem); line-height: 1.15; color: var(--title); margin-bottom: 8px; }
.hint, .w-hint { font-size: 12.5px; color: var(--muted); margin: 6px 0 16px; line-height: 1.5; }
.btn { font: 700 11.5px var(--sans); letter-spacing: .16em; text-transform: uppercase; padding: 14px 26px; border-radius: 999px; background: var(--btn); color: var(--btn-ink); box-shadow: 0 6px 0 var(--btn-shadow), 0 12px 24px rgba(0, 0, 0, .15); transition: transform .12s, box-shadow .12s; min-height: 46px; }
.btn:active { transform: translateY(4px); box-shadow: 0 2px 0 var(--btn-shadow), 0 6px 14px rgba(0, 0, 0, .15); }
.o-art { margin-bottom: 18px; position: relative; }
.tap-hint { display: block; font: 700 9.5px var(--sans); letter-spacing: .2em; text-transform: uppercase; color: var(--muted); margin-top: 6px; }
.o-lock { margin: 0 0 18px; padding: 14px 18px; border-radius: 16px; background: var(--card); color: var(--ink); font-size: 13.5px; }
.o-lock p { margin: 0; } .lock-cd { font: 700 1.25rem var(--sans); margin-top: 6px !important; letter-spacing: .04em; color: var(--accent); }
body.locked .o-btn, body.locked .tap-open { pointer-events: none; opacity: .5; }

/* gift (blossom) */
.gift-svg { width: 150px; filter: drop-shadow(0 14px 18px rgba(200, 60, 120, .25)); animation: bob 2.8s ease-in-out infinite; }
.o-art.opening .gift-svg { animation: pop .6s ease forwards; }
@keyframes bob { 50% { transform: translateY(-8px) rotate(-2deg); } }
@keyframes pop { 40% { transform: scale(1.15) rotate(6deg); } 100% { transform: scale(.2); opacity: 0; } }

/* voice */
.player { display: flex; align-items: center; gap: 12px; width: min(340px, 100%); padding: 14px 16px; border-radius: 22px; background: var(--card); box-shadow: 0 12px 30px rgba(0, 0, 0, .12); margin-top: 18px; }
.play { flex: none; width: 50px; height: 50px; border-radius: 50%; background: var(--accent); display: grid; place-items: center; box-shadow: 0 6px 14px rgba(0, 0, 0, .18); }
.i-play { width: 0; height: 0; border-left: 14px solid var(--play-ink, #fff); border-top: 9px solid transparent; border-bottom: 9px solid transparent; margin-left: 4px; }
.playing .i-play { width: 14px; height: 16px; border: 0; margin: 0; background: linear-gradient(90deg, var(--play-ink, #fff) 0 35%, transparent 35% 65%, var(--play-ink, #fff) 65%); }
.wave { flex: 1; height: 40px; display: flex; align-items: center; gap: 2px; }
.wave i { flex: 1; background: var(--wave-off); border-radius: 2px; transition: background .2s; }
.wave i.on { background: var(--accent); }
.playing .wave i { animation: wv 1s ease-in-out infinite; } .playing .wave i:nth-child(3n) { animation-delay: -.3s; } .playing .wave i:nth-child(3n+1) { animation-delay: -.6s; }
@keyframes wv { 50% { transform: scaleY(.6); } }
.vt { flex: none; font: 600 11px var(--sans); color: var(--muted); min-width: 32px; }

/* gallery */
.s-gallery > :first-child { margin-top: 0; }
.grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; width: min(380px, 100%); }
.ph { margin: 0; background: #fff; padding: 7px 7px 0; border-radius: 4px; box-shadow: 0 8px 18px rgba(0, 0, 0, .16); cursor: zoom-in; transition: transform .2s; }
.ph img, .ph-empty { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 2px; background: #e9e3df; }
.ph-empty { display: grid; place-items: center; color: #aaa; font-size: 12px; }
.ph figcaption { font-family: var(--script); font-size: 1.25rem; color: var(--cap-ink, #8b2f55); padding: 4px 2px 6px; min-height: 2rem; line-height: 1.2; }
.ph:active { transform: scale(.97); }

/* wish */
.cake { margin: 14px 0 4px; }
.cake-svg { width: min(230px, 62vw); overflow: visible; filter: drop-shadow(0 14px 20px rgba(0, 0, 0, .18)); }
.flame { transform-box: fill-box; transform-origin: 50% 100%; animation: flick .5s ease-in-out infinite alternate; transition: opacity .3s, transform .3s; }
@keyframes flick { to { transform: scale(.9, 1.08) rotate(3deg); } }
.smoke { fill: rgba(180, 170, 170, .55); opacity: 0; }
.blown .flame { opacity: 0; animation: none; transform: scale(.2); }
.blown .smoke { animation: smoke 1.6s ease-out forwards; }
@keyframes smoke { 0% { opacity: .8; transform: translateY(0); } 100% { opacity: 0; transform: translateY(-26px); } }
.w-done { font-family: var(--script); font-size: 1.7rem; color: var(--title); margin: 4px 0 0; opacity: 0; transform: translateY(8px); transition: .6s .5s; }
.s-wish.done .w-done { opacity: 1; transform: none; }
.s-wish.done .w-hint { opacity: 0; }
.confetti { position: fixed; inset: 0; pointer-events: none; z-index: 30; overflow: hidden; }
.confetti i { position: absolute; top: -12px; width: 8px; height: 12px; border-radius: 2px; animation: fall linear forwards; }
@keyframes fall { to { transform: translate3d(var(--dx), 110vh, 0) rotate(var(--rot)); } }

/* love */
.l-sub { font: 700 10px var(--sans); letter-spacing: .24em; text-transform: uppercase; color: var(--accent); margin: 0 0 18px; }
.l-wrap { display: flex; flex-direction: column; align-items: center; gap: 18px; width: min(380px, 100%); }
.letter-card { width: 100%; text-align: left; background: var(--card); color: var(--ink); padding: 18px 20px; border-radius: 18px; box-shadow: 0 12px 30px rgba(0, 0, 0, .12); font-size: 14px; line-height: 1.65; cursor: pointer; position: relative; }
.letter-card:not(.open) .letter-body { max-height: 7.5em; overflow: hidden; -webkit-mask: linear-gradient(#000 60%, transparent); mask: linear-gradient(#000 60%, transparent); }
.letter-body p { margin: 0 0 .8em; } .letter-body p:last-child { margin: 0; }
.more { display: block; font: 700 9.5px var(--sans); letter-spacing: .2em; text-transform: uppercase; color: var(--accent); margin-top: 8px; }
.love-photos { position: relative; display: flex; justify-content: center; gap: 10px; }
.lp { width: 92px; height: 92px; object-fit: cover; border-radius: 50%; border: 4px solid #fff; box-shadow: 0 8px 18px rgba(0, 0, 0, .18); }
.again { margin-top: 22px; font-size: 10px; padding: 11px 18px; min-height: 40px; }

/* lightbox + letter modal */
.lightbox, .letter-modal { position: fixed; inset: 0; z-index: 40; background: rgba(10, 6, 14, .78); display: flex; align-items: center; justify-content: center; padding: 24px; animation: fade .25s; }
@keyframes fade { from { opacity: 0; } }
.lightbox figure { margin: 0; background: #fff; padding: 10px 10px 0; border-radius: 6px; max-width: min(92vw, 440px); transform: rotate(-1.5deg); }
.lightbox img { width: 100%; max-height: 70vh; object-fit: contain; }
.lightbox figcaption { font-family: var(--script); font-size: 1.5rem; text-align: center; padding: 8px; color: var(--cap-ink, #8b2f55); }
.lm-card { background: var(--card); color: var(--ink); border-radius: 22px; padding: 26px 22px 20px; width: min(440px, 100%); max-height: 84vh; overflow-y: auto; text-align: left; font-size: 15px; line-height: 1.7; }
.lm-card h3 { font-family: var(--script); font-weight: 400; font-size: 2.3rem; margin: 0 0 12px; color: var(--title-on-card, var(--title)); text-align: center; }
.lm-body p { margin: 0 0 1em; } .lm-sign { text-align: right; font-style: italic; color: var(--muted); }
.lm-close { display: block; margin: 16px auto 0; }

/* =================================================================== BLOSSOM */
.th-blossom { --bg: linear-gradient(180deg, #ffe4ee 0%, #ffd2e1 60%, #ffc4d8 100%); --ink: #5a2a3d; --muted: #a0607a; --title: #d2457c; --accent: #e8558c; --card: #fff; --btn: linear-gradient(180deg, #ff7aa8, #e2508a); --btn-ink: #fff; --btn-shadow: #b93a6c;
  --dot-off: rgba(226, 80, 138, .25); --wave-off: #f6c3d5; --petal: #ffb3cb; --gift: #ff8fb5; --gift2: #ff74a3; --ribbon: #fff; --cap-ink: #c0487a;
  --cake1: #ff7fab; --cake2: #ff99bd; --frost: #fff0f5; --dot: #ffffff; --candle: #fff; --candle2: #ff9cbf; --plate: rgba(214, 80, 130, .25);
  --script: 'Great Vibes', cursive; --sans: 'Quicksand', system-ui, sans-serif; }
.th-blossom body, body.th-blossom { background: linear-gradient(180deg, #ffe4ee 0%, #ffd2e1 60%, #ffc4d8 100%); }
.th-blossom .nav { background: #fff; color: #e2508a; border: 1.5px solid #f6b3cb; }
.th-blossom .nav.next { background: linear-gradient(180deg, #ff7aa8, #e2508a); color: #fff; border: 0; box-shadow: 0 4px 0 #b93a6c; }
.th-blossom .eyebrow { display: inline-block; background: #e8558c; color: #fff; padding: 5px 12px; border-radius: 999px; font-size: 9.5px; }
.th-blossom .fl { position: absolute; animation: sway 6s ease-in-out infinite; }
@keyframes sway { 50% { transform: translateY(-6px) rotate(8deg); } }
.th-blossom .petal { position: absolute; top: -20px; width: 12px; height: 9px; background: #ffb3cb; border-radius: 80% 0 80% 0; opacity: .8; animation: drift 11s linear infinite; }
.th-blossom .p1 { left: 15%; } .th-blossom .p2 { left: 45%; animation-delay: -4s; animation-duration: 13s; } .th-blossom .p3 { left: 72%; animation-delay: -8s; } .th-blossom .p4 { left: 90%; animation-delay: -2s; animation-duration: 15s; }
@keyframes drift { to { transform: translate(-40px, 110vh) rotate(540deg); } }
.th-blossom .lp1 { margin-top: 40px; } .th-blossom .lp-heart { position: absolute; left: 50%; top: 64px; transform: translateX(-50%); color: #e8558c; font-size: 22px; }

/* =================================================================== STARLIGHT */
.th-starlight { --ink: #f4f1ff; --muted: #b9b2e6; --title: #f4f1ff; --accent: #ffd56a; --card: rgba(255, 255, 255, .08); --btn: rgba(255, 255, 255, .1); --btn-ink: #fff; --btn-shadow: rgba(0, 0, 0, .3);
  --dot-off: rgba(255, 255, 255, .25); --wave-off: rgba(255, 255, 255, .22); --play-ink: #2a1f5c; --cap-ink: #e9e5ff;
  --cake1: #6f55d9; --cake2: #8a70ee; --frost: #d8ccff; --dot: #fff7cf; --candle: #f4efff; --candle2: #b6a3ff; --plate: rgba(255, 255, 255, .12);
  --script: 'Cormorant Garamond', Georgia, serif; --sans: 'Quicksand', system-ui, sans-serif; }
body.th-starlight { background: radial-gradient(120% 70% at 50% 110%, #5a3fb3 0%, #2d1f6e 45%, #140e36 100%); color: #f4f1ff;
  background-image: radial-gradient(1.5px 1.5px at 12% 20%, #fff, transparent), radial-gradient(1px 1px at 30% 70%, #fff9, transparent), radial-gradient(1.5px 1.5px at 70% 30%, #fffc, transparent), radial-gradient(1px 1px at 85% 75%, #fff8, transparent), radial-gradient(1px 1px at 55% 50%, #fff7, transparent), radial-gradient(1.2px 1.2px at 40% 12%, #fffa, transparent), radial-gradient(120% 70% at 50% 110%, #5a3fb3 0%, #2d1f6e 45%, #140e36 100%); }
.th-starlight h1, .th-starlight h2, .th-starlight .o-name { font-style: italic; font-weight: 500; }
.th-starlight .o-name { font-size: clamp(2rem, 10vw, 2.8rem); }
.th-starlight .nav { color: #e8e3ff; background: transparent; }
.th-starlight .btn { border: 1px solid rgba(255, 255, 255, .35); box-shadow: none; backdrop-filter: blur(6px); }
.th-starlight .moon-svg { width: 74px; filter: drop-shadow(0 0 22px rgba(255, 217, 138, .6)); animation: bob 5s ease-in-out infinite; }
.th-starlight .star-btn { display: block; margin: 0 auto 18px; }
.th-starlight .star-svg { width: 54px; filter: drop-shadow(0 0 14px rgba(255, 213, 106, .8)); animation: twk 1.8s ease-in-out infinite; }
@keyframes twk { 50% { transform: scale(1.15) rotate(10deg); } }
.th-starlight .o-btn { display: none; }
.th-starlight .player, .th-starlight .letter-card { border: 1px solid rgba(255, 255, 255, .18); backdrop-filter: blur(8px); color: #f4f1ff; }
.th-starlight .ph { background: rgba(255, 255, 255, .08); padding: 0; border-radius: 16px; overflow: hidden; border: 1px solid rgba(255, 255, 255, .25); }
.th-starlight .ph img, .th-starlight .ph-empty { border-radius: 0; }
.th-starlight .ph figcaption { font-family: var(--script); font-style: italic; font-size: 1.1rem; }
.th-starlight .lp { border-radius: 14px; border: 1px solid rgba(255, 255, 255, .3); width: 84px; height: 84px; }
.th-starlight .lm-card { background: #241a58; color: #f4f1ff; }
.th-starlight .planet { position: absolute; right: -30px; bottom: 16%; width: 110px; height: 110px; border-radius: 50%; background: radial-gradient(circle at 35% 30%, #e6d2ff, #a57af2 45%, #5a33b5 100%); box-shadow: 0 0 40px rgba(165, 122, 242, .5); }
.th-starlight .planet::after { content: ''; position: absolute; left: -38%; top: 38%; width: 176%; height: 26%; border-radius: 50%; border: 4px solid #e8c98a; transform: rotate(-18deg); border-top-color: transparent; }
.th-starlight .planet.small { right: auto; left: 8%; bottom: auto; top: 12%; width: 34px; height: 34px; }
.th-starlight .orb { position: absolute; width: 16px; height: 16px; border-radius: 50%; background: radial-gradient(circle at 35% 30%, #ffe9c4, #f0a35a); top: 18%; right: 18%; }
.th-starlight .orb.o2 { width: 22px; height: 22px; background: radial-gradient(circle at 35% 30%, #cfe3ff, #5a7bea); top: 70%; left: 6%; }
.th-starlight .spark, .th-vintage .spark { position: absolute; width: 14px; height: 14px; animation: twk 2.4s ease-in-out infinite; }
.th-starlight .spark::before, .th-vintage .spark::before { content: ''; position: absolute; inset: 0; background: #fff; clip-path: polygon(50% 0, 58% 42%, 100% 50%, 58% 58%, 50% 100%, 42% 58%, 0 50%, 42% 42%); }
.th-starlight .lm-card h3 { color: #fff; }

/* =================================================================== ELEGAN */
body.th-elegan { background: radial-gradient(120% 80% at 50% 0%, #fbf7f1, #efe6da); }
.th-elegan { --ink: #3b1d22; --muted: #8c6f68; --title: #3b1d22; --accent: #5a1f2a; --card: #fff; --btn: #4a1820; --btn-ink: #f6e9e4; --btn-shadow: #2a0c11;
  --dot-off: rgba(74, 24, 32, .2); --wave-off: rgba(255, 255, 255, .3); --play-ink: #4a1820; --cap-ink: #3b1d22;
  --cake1: #5a1f2a; --cake2: #6d2a35; --frost: #f4e7e0; --dot: #f4e7e0; --candle: #f4e7e0; --candle2: #c9a37a; --plate: rgba(74, 24, 32, .16);
  --script: 'Pinyon Script', cursive; --sans: 'Quicksand', system-ui, sans-serif; }
.th-elegan .nav { color: #5a1f2a; } .th-elegan .nav.next { background: #4a1820; color: #f6e9e4; }
.th-elegan .o-art .cake-svg { width: 170px; }
.th-elegan .eyebrow { font-family: 'Cormorant Garamond', serif; font-weight: 600; letter-spacing: .3em; }
.th-elegan .o-sub, .th-elegan .hint, .th-elegan .w-hint { font-family: 'Cormorant Garamond', serif; font-style: italic; font-size: 15px; }
.th-elegan .player { background: #4a1820; color: #f6e9e4; --muted: #e2c9c2; }
.th-elegan .play { background: #f6e9e4; }
.th-elegan .wave i.on { background: #f6e9e4; }
.th-elegan .ph { transform: rotate(var(--r)); }
.th-elegan .letter-card { background: #4a1820; color: #f6e9e4; font-family: 'Cormorant Garamond', serif; font-size: 16px; --accent: #e2c9c2; }
.th-elegan .love-photos { flex-direction: column; gap: 6px; padding: 8px; background: #1c1214; transform: rotate(-4deg); box-shadow: 0 12px 24px rgba(0, 0, 0, .25); }
.th-elegan .love-photos.n1, .th-elegan .love-photos.n2, .th-elegan .love-photos.n3 { flex-direction: row; }
.th-elegan .lp { border-radius: 0; border: 0; width: 84px; height: 84px; }
.th-elegan .hrt { position: absolute; color: #5a1f2a; opacity: .35; font-size: 12px; animation: bob 4s ease-in-out infinite; }
.th-elegan .lm-card { background: #fffaf6; font-family: 'Cormorant Garamond', serif; font-size: 17px; }

/* =================================================================== VINTAGE */
body.th-vintage { background: radial-gradient(110% 80% at 50% 30%, #9b1b26 0%, #6d0f18 55%, #3e070d 100%); }
.th-vintage { --ink: #3a0c12; --muted: #f0c9c0; --title: #fff3ea; --accent: #f3d38c; --card: #fff8ef; --btn: #6be08d; --btn-ink: #10391e; --btn-shadow: #3a9a57;
  --dot-off: rgba(255, 255, 255, .25); --wave-off: rgba(255, 255, 255, .25); --play-ink: #fff; --cap-ink: #3a0c12;
  --cake1: #8f1621; --cake2: #a31d2a; --frost: #fff3ea; --dot: #fff3ea; --candle: #fff3ea; --candle2: #f3a1a8; --plate: rgba(0, 0, 0, .3);
  --script: 'Pinyon Script', cursive; --sans: 'Quicksand', system-ui, sans-serif; }
.th-vintage .nav { background: #6be08d; color: #10391e; box-shadow: 0 4px 0 #3a9a57; padding: 7px 14px; }
.th-vintage .nav.back { visibility: visible; }
.th-vintage .eyebrow { color: #f3d38c; }
.th-vintage .o-title { font-size: clamp(2.4rem, 12vw, 3.3rem); }
.th-vintage .o-name { font-size: 1.6rem; font-family: 'Cormorant Garamond', serif; font-style: italic; }
.th-vintage .o-btn { background: none; box-shadow: none; color: #f6dfd6; font-family: 'Cormorant Garamond', serif; font-style: italic; text-transform: none; letter-spacing: 0; font-size: 18px; text-decoration: underline; }
.envelope { position: relative; width: 220px; height: 140px; margin: 0 auto; perspective: 600px; }
.env-back, .env-front, .env-flap, .env-letter { position: absolute; left: 0; right: 0; }
.env-back { inset: 0; background: #efe3cf; border-radius: 6px; box-shadow: 0 16px 30px rgba(0, 0, 0, .4); }
.env-letter { left: 12px; right: 12px; top: 10px; height: 110px; background: #fffdf8; border-radius: 4px; transition: transform .7s .35s ease; }
.env-front { inset: 0; border-radius: 6px; background: linear-gradient(to top right, #f6ecdb 50%, transparent 50%) left / 50% 100% no-repeat, linear-gradient(to top left, #f3e7d3 50%, transparent 50%) right / 50% 100% no-repeat; }
.env-flap { top: 0; height: 80px; background: #e8d9bf; clip-path: polygon(0 0, 100% 0, 50% 100%); transform-origin: 50% 0; transition: transform .5s ease; z-index: 2; }
.env-seal { position: absolute; left: 50%; top: 66px; transform: translate(-50%, -50%); width: 40px; height: 40px; border-radius: 50%; background: radial-gradient(circle at 35% 30%, #d23c4c, #8f1621 70%); color: #ffd9de; display: grid; place-items: center; font-size: 16px; z-index: 3; box-shadow: 0 3px 6px rgba(0, 0, 0, .3); transition: opacity .3s; }
.opening .env-flap { transform: rotateX(180deg); z-index: 0; } .opening .env-seal { opacity: 0; } .opening .env-letter { transform: translateY(-60px); }
.env-btn { display: block; margin-bottom: 26px; }
.th-vintage .vinyl { width: 200px; height: 200px; border-radius: 50%; margin-bottom: 18px; background: repeating-radial-gradient(circle, #151515 0 2px, #222 2px 4px); display: grid; place-items: center; box-shadow: 0 14px 30px rgba(0, 0, 0, .5); animation: spin 6s linear infinite; animation-play-state: paused; }
.th-vintage .vinyl .label { width: 76px; height: 76px; border-radius: 50%; overflow: hidden; background: #c6303e; border: 4px solid #e9c7a4; }
.th-vintage .vinyl .label img { width: 100%; height: 100%; object-fit: cover; }
.th-vintage .s-voice.playing .vinyl { animation-play-state: running; }
@keyframes spin { to { transform: rotate(360deg); } }
.th-vintage .v-title { font-family: var(--sans); font-weight: 700; font-size: 1.4rem; }
.v-for { margin: 0; color: var(--muted); font-size: 13px; }
.th-vintage .player { background: #1a1a1a; color: #fff; }
.th-vintage .play { background: #e33b4b; }
.th-vintage .grid { gap: 10px 16px; }
.th-vintage .ph { transform: rotate(var(--r)) translateY(calc(var(--r) * 1.5)); }
.th-vintage .letter-card { font-family: 'Cormorant Garamond', serif; font-size: 16px; }
.th-vintage .lp { border-radius: 0; border: 4px solid #d8b060; width: 86px; height: 86px; }
.th-vintage .lp1 { transform: rotate(5deg) translateY(10px); } .th-vintage .lp0 { transform: rotate(-6deg); } .th-vintage .lp2 { transform: rotate(-3deg) translateY(4px); }
.th-vintage .spark::before { background: #f3d38c; }
.th-vintage .bouquet { position: relative; width: 70px; height: 80px; margin-bottom: 8px; }
.th-vintage .bouquet i { position: absolute; width: 26px; height: 26px; border-radius: 50%; background: radial-gradient(circle at 40% 35%, #f04a5c, #a3121f); }
.th-vintage .bouquet i:nth-child(1) { left: 4px; top: 6px; } .th-vintage .bouquet i:nth-child(2) { left: 22px; top: 0; } .th-vintage .bouquet i:nth-child(3) { left: 40px; top: 6px; } .th-vintage .bouquet i:nth-child(4) { left: 13px; top: 22px; } .th-vintage .bouquet i:nth-child(5) { left: 31px; top: 22px; }
.th-vintage .bouquet b { position: absolute; left: 14px; top: 34px; width: 42px; height: 46px; background: #f5dbe0; clip-path: polygon(0 0, 100% 0, 55% 100%, 45% 100%); }
.th-vintage .lm-card { font-family: 'Cormorant Garamond', serif; font-size: 17px; }
.th-vintage .lm-card h3 { color: #8f1621; }

/* =================================================================== RETRO */
body.th-retro { background: #1a1240; background-image: linear-gradient(rgba(120, 90, 255, .12) 1px, transparent 1px), linear-gradient(90deg, rgba(120, 90, 255, .12) 1px, transparent 1px); background-size: 22px 22px; color: #fff; }
.th-retro { --ink: #fff; --muted: #a9a2d9; --title: #ffd84d; --accent: #ff5fa2; --card: #241a59; --btn: #ffd84d; --btn-ink: #2a1a00; --btn-shadow: #b38f00;
  --dot-off: rgba(255, 255, 255, .25); --wave-off: #3c3180; --play-ink: #2a1a00; --cap-ink: #fff;
  --script: 'Press Start 2P', monospace; --sans: 'VT323', monospace; }
.th-retro * { border-radius: 0 !important; }
.th-retro .slide { image-rendering: pixelated; }
.th-retro .o-title, .th-retro h2 { font-family: 'Press Start 2P', monospace; text-transform: uppercase; line-height: 1.4; text-shadow: 3px 3px 0 #b3366e; }
.th-retro .o-title { font-size: clamp(1.4rem, 7.4vw, 2rem); }
.th-retro h2 { font-size: clamp(.95rem, 4.6vw, 1.2rem); color: #ffd84d; text-shadow: 2px 2px 0 #b3366e; margin-bottom: 12px; }
.th-retro .o-name { font: 400 clamp(.8rem, 4vw, 1rem) 'Press Start 2P', monospace; color: #ff5fa2; text-transform: uppercase; margin: 14px 0 12px; }
.th-retro .quest { display: inline; }
.th-retro .eyebrow { font: 400 9px 'Press Start 2P', monospace; color: #6dffa8; letter-spacing: .08em; }
.th-retro .o-sub, .th-retro .hint, .th-retro .w-hint, .th-retro .letter-card, .th-retro .v-for { font-family: 'VT323', monospace; font-size: 20px; color: #cfc8ff; }
.th-retro .btn { font: 400 11px 'Press Start 2P', monospace; letter-spacing: 0; box-shadow: 4px 4px 0 #b38f00; padding: 14px 18px; }
.th-retro .btn:active { box-shadow: 1px 1px 0 #b38f00; transform: translate(3px, 3px); }
.th-retro .hrt-i { display: none; }
.th-retro .hearts { font: 22px 'Press Start 2P', monospace; color: #ff5fa2; display: flex; gap: 12px; }
.th-retro .hearts .st { color: #ffd84d; animation: twk 1.4s steps(2) infinite; }
.th-retro .hud { top: auto; bottom: 0; padding: 10px 14px calc(14px + env(safe-area-inset-bottom)); }
.th-retro .hud::before { content: ''; position: fixed; left: 0; right: 0; top: 0; height: calc(44px + env(safe-area-inset-top)); background: linear-gradient(#1a1240, transparent); pointer-events: none; }
.th-retro .stage, .th-retro .score { display: block; position: fixed; top: calc(16px + env(safe-area-inset-top)); font: 400 9px 'Press Start 2P', monospace; }
.th-retro .stage { left: 50%; transform: translateX(-50%); color: #ffd84d; }
.th-retro .score { right: 14px; color: #6dffa8; }
.th-retro .nav { font: 400 9px 'Press Start 2P', monospace; color: #cfc8ff; letter-spacing: 0; padding: 0; gap: 8px; }
.th-retro .nav .ab { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50% !important; font-size: 13px; color: #fff; }
.th-retro .nav.back .ab { background: #6b55d6; box-shadow: 0 4px 0 #3e2f8f; }
.th-retro .nav.next .ab { background: #ff5fa2; box-shadow: 0 4px 0 #b3366e; }
.th-retro .dots { bottom: auto; top: calc(36px + env(safe-area-inset-top)); }
.th-retro .dots i { background: #3c3180; } .th-retro .dots i.on { background: #ffd84d; width: 6px; }
.th-retro .slide { padding-bottom: calc(80px + env(safe-area-inset-bottom)); }
.th-retro .player { background: transparent; border: 3px solid #fff; box-shadow: none; padding: 12px; }
.th-retro .play { background: #ffd84d; box-shadow: 3px 3px 0 #b38f00; }
.th-retro .wave i { background: #3c3180; } .th-retro .wave i.on { background: #6dffa8; }
.th-retro .vt { font: 400 9px 'Press Start 2P', monospace; }
.th-retro .walkie { width: 54px; margin-bottom: 12px; }
.th-retro .ph { background: #fff; padding: 4px; box-shadow: 0 0 0 3px #6b55d6; position: relative; }
.th-retro .ph figcaption { position: absolute; left: 4px; right: 4px; bottom: 4px; background: rgba(26, 18, 64, .8); color: #fff; font: 400 8px 'Press Start 2P', monospace; text-transform: uppercase; padding: 5px 3px; min-height: 0; }
.th-retro .w-done { font: 400 12px 'Press Start 2P', monospace; color: #6dffa8; line-height: 1.6; }
.th-retro .scores { width: min(360px, 100%); border: 3px solid #fff; border-collapse: collapse; font: 400 20px 'VT323', monospace; margin: 0 0 14px; }
.th-retro .scores td { padding: 6px 8px; text-align: left; text-transform: uppercase; } .th-retro .scores td:last-child { text-align: right; color: #ffd84d; }
.th-retro .scores tr:first-child td { color: #ff5fa2; } .th-retro .scores tr:first-child td:last-child { color: #ffd84d; }
.th-retro .l-sub { font: 400 9px 'Press Start 2P', monospace; color: #6dffa8; letter-spacing: 0; }
.th-retro .letter-card { border: 3px solid #fff; background: transparent; box-shadow: none; }
.th-retro .lp { border: 3px solid #fff; width: 76px; height: 76px; }
.th-retro .px { position: absolute; width: 4px; height: 4px; background: #fff; box-shadow: 4px 0 #fff, -4px 0 #fff, 0 4px #fff, 0 -4px #fff; opacity: .5; animation: twk 1.6s steps(2) infinite; }
.th-retro .lm-card { background: #241a59; border: 3px solid #fff; font: 400 21px 'VT323', monospace; color: #fff; }
.th-retro .lm-card h3 { font: 400 1rem 'Press Start 2P', monospace; color: #ffd84d; }
.th-retro .lightbox figcaption { font: 400 10px 'Press Start 2P', monospace; color: #1a1240; }
.th-retro .confetti i { border-radius: 0; }

@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition-duration: .01ms !important; } }
