@font-face { font-family: Fell; src: url(/fonts/im-fell-double-pica-latin-400-normal.woff2) format("woff2"); font-display: swap; }
@font-face { font-family: Fell; font-style: italic; src: url(/fonts/im-fell-double-pica-latin-400-italic.woff2) format("woff2"); font-display: swap; }
@font-face { font-family: FellSC; src: url(/fonts/im-fell-double-pica-sc-latin-400-normal.woff2) format("woff2"); font-display: swap; }
@font-face { font-family: Garamond; src: url(/fonts/eb-garamond-latin-400-normal.woff2) format("woff2"); font-display: swap; }
@font-face { font-family: Garamond; font-style: italic; src: url(/fonts/eb-garamond-latin-400-italic.woff2) format("woff2"); font-display: swap; }
@font-face { font-family: Garamond; font-weight: 500; src: url(/fonts/eb-garamond-latin-500-normal.woff2) format("woff2"); font-display: swap; }
@font-face { font-family: Script; src: url(/fonts/pinyon-script-latin-400-normal.woff2) format("woff2"); font-display: swap; }
/* Fell's old-style 0 and 1 look like letters, so digits come from Garamond. */
@font-face { font-family: Fell; src: url(/fonts/eb-garamond-latin-500-normal.woff2) format("woff2"); unicode-range: U+30-39; font-display: swap; }
@font-face { font-family: Fell; font-style: italic; src: url(/fonts/eb-garamond-latin-400-italic.woff2) format("woff2"); unicode-range: U+30-39; font-display: swap; }
@font-face { font-family: FellSC; src: url(/fonts/eb-garamond-latin-500-normal.woff2) format("woff2"); unicode-range: U+30-39; font-display: swap; }

:root {
  --night: #070a08; --forest: #0d1a14; --coal: #12130f;
  --gold: #c9a35c; --gold-hi: #f0d9a0; --gold-lo: #7d6133;
  --parchment: #e6d3a8; --ink: #2a1a0d; --wine: #6d1420; --candle: #ffb765;
  --st: env(safe-area-inset-top, 0px); --sb: env(safe-area-inset-bottom, 0px);
}
* { box-sizing: border-box; margin: 0; -webkit-tap-highlight-color: transparent; }
[hidden] { display: none !important; }
html, body { height: 100%; background: var(--night); overflow: hidden; overscroll-behavior: none; }
body { font: 19px/1.5 Garamond, Georgia, serif; color: var(--parchment); -webkit-font-smoothing: antialiased; -webkit-text-size-adjust: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; touch-action: manipulation; }
img { display: block; }
:focus-visible { outline: 1px solid var(--gold-hi); outline-offset: 4px; }
h1, h2 { font-weight: 400; font-family: Fell, serif; line-height: 1.12; text-wrap: balance; }
small { font-size: inherit; }

/* ---------- stage ---------- */
#stage { position: fixed; inset: 0; max-width: 540px; margin: auto; overflow: hidden; overflow: clip; background: var(--night); font-variant-numeric: lining-nums; isolation: isolate; }
@media (min-width: 541px) {
  body { background: radial-gradient(ellipse at 50% 40%, #14231b, #050706 75%); }
  #stage { box-shadow: 0 0 120px 30px #000; }
}
.desk { position: absolute; left: 50%; top: 50%; width: max(100%, 56.25dvh); aspect-ratio: 9/16; translate: -50% -50%; transition: opacity 1.2s, filter 1.2s; z-index: -3; }
.desk img { width: 100%; height: 100%; object-fit: cover; }
.glow { position: absolute; inset: 0; background: radial-gradient(circle at 20.3% 33%, rgb(255 176 84 / .5), rgb(255 140 50 / .16) 22%, transparent 55%); mix-blend-mode: screen; animation: flicker 3.7s infinite; }
.flame { position: absolute; left: 20.4%; top: 35.9%; width: 3.6%; height: 7.4%; translate: -50% -100%; transform-origin: 50% 96%; animation: sway 2.9s ease-in-out infinite; }
.flame::before { content: ""; position: absolute; inset: -110% -330%; background: radial-gradient(closest-side, rgb(255 190 100 / .5), rgb(255 140 50 / .14) 45%, transparent); }
.flame i { position: absolute; inset: 0; border-radius: 50% 50% 50% 50% / 76% 76% 24% 24%; background: radial-gradient(ellipse 60% 62% at 50% 74%, #fffbe6 0 22%, #ffe49a 48%, #ffae45 78%, rgb(255 120 30 / .25)); box-shadow: 0 0 14px 3px rgb(255 180 80 / .6); filter: blur(.7px); clip-path: none; }
.flame i::after { content: ""; position: absolute; left: 18%; right: 18%; bottom: 0; height: 24%; border-radius: 50%; background: rgb(60 90 190 / .4); filter: blur(2px); }
@keyframes flicker { 0%, 100% { opacity: .75 } 12% { opacity: .95 } 23% { opacity: .68 } 41% { opacity: 1 } 55% { opacity: .8 } 68% { opacity: .92 } 81% { opacity: .7 } }
@keyframes sway { 0%, 100% { transform: rotate(-1.5deg) scaleY(1) } 25% { transform: rotate(1.5deg) scaleY(1.06) scaleX(.95) } 50% { transform: rotate(-.6deg) scaleY(.95) scaleX(1.05) } 75% { transform: rotate(2deg) scaleY(1.04) } }
.leather { position: absolute; inset: 0; z-index: -2; opacity: 0; transition: opacity 1s; background:
  radial-gradient(ellipse 90% 55% at 50% 18%, rgb(255 178 90 / .26), transparent 70%), radial-gradient(ellipse at 50% 40%, transparent 40%, #030504 105%), url(/img/leather.webp) 0 0/420px; }
#air { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 5; }
[data-scene="dark"] .desk { opacity: 0; }
[data-scene="archive"] .desk { opacity: 0; } [data-scene="archive"] .leather { opacity: 1; }
[data-scene="case"] .desk { filter: blur(9px) brightness(.5); }
[data-scene="archive"] :is(.glow, .flame), [data-scene="dark"] :is(.glow, .flame) { animation-play-state: paused; }
#view { position: absolute; inset: 0; overflow: hidden auto; overscroll-behavior: contain; -webkit-overflow-scrolling: touch; scrollbar-width: none; }
#view::-webkit-scrollbar { display: none; }
.center { min-height: 60%; display: grid; place-content: center; justify-items: center; text-align: center; gap: 18px; padding: 24px; }
#toast { position: absolute; left: 24px; right: 24px; bottom: calc(94px + var(--sb)); text-align: center; font-style: italic; color: var(--gold-hi); text-shadow: 0 1px 12px #000; padding: 12px; opacity: 0; transform: translateY(8px); transition: .4s; pointer-events: none; z-index: 20; background: radial-gradient(closest-side, rgb(0 0 0 / .92), rgb(0 0 0 / .78) 60%, transparent); }
#toast.on { opacity: 1; transform: none; }

/* ---------- ornaments and buttons ---------- */
.star { width: 44px; color: var(--gold); }
.rule { display: flex; align-items: center; gap: 10px; width: min(240px, 70%); margin: 12px auto; color: var(--gold); }
.rule i { flex: 1; height: 1px; background: linear-gradient(90deg, transparent, currentColor); } .rule i:last-child { scale: -1 1; }
.rule .star { width: 20px; color: inherit; }
.plate { display: inline-block; position: relative; overflow: hidden; padding: 5px; color: #231505; font: 20px/1 FellSC, serif; letter-spacing: .05em; cursor: pointer;
  background: linear-gradient(170deg, #f3dca0, #b98d45 28%, #8a6428 52%, #c69c52 78%, #6f4f1f); box-shadow: 0 8px 24px rgb(0 0 0 / .65), 0 0 34px rgb(255 170 80 / .16), inset 0 1px 0 rgb(255 245 210 / .6);
  clip-path: polygon(9px 0, calc(100% - 9px) 0, 100% 9px, 100% calc(100% - 9px), calc(100% - 9px) 100%, 9px 100%, 0 calc(100% - 9px), 0 9px); }
.plate span { display: block; padding: 15px 30px 16px; border: 1px solid rgb(60 35 8 / .55); text-shadow: 0 1px 0 rgb(255 235 180 / .5);
  clip-path: polygon(7px 0, calc(100% - 7px) 0, 100% 7px, 100% calc(100% - 7px), calc(100% - 7px) 100%, 7px 100%, 0 calc(100% - 7px), 0 7px); background: linear-gradient(175deg, #dcb76f, #b48a44 55%, #c9a055); }
.plate::after { content: ""; position: absolute; inset: 0; background: linear-gradient(105deg, transparent 35%, rgb(255 250 225 / .5) 50%, transparent 65%); translate: -110% 0; animation: gleam 5.5s 2.5s infinite; pointer-events: none; }
@keyframes gleam { 0% { translate: -110% 0 } 22%, 100% { translate: 110% 0 } }
.plate:active { filter: brightness(.85); transform: translateY(1px); }
.plate:disabled, .wax-btn:disabled { pointer-events: none; }
.wax-btn { font: 20px/1 FellSC, serif; letter-spacing: .04em; color: #f7dcc2; padding: 15px 28px 16px; border-radius: 22px 18px 24px 17px / 19px 24px 18px 23px; text-shadow: 0 1px 2px #2b0307;
  background: radial-gradient(ellipse at 32% 18%, #a82a33, #74121c 55%, #520a13); box-shadow: inset 0 2px 3px rgb(255 160 140 / .4), inset 0 -4px 7px rgb(30 0 4 / .55), 0 4px 10px rgb(40 15 5 / .5); }
.wax-btn:active { filter: brightness(.85); transform: translateY(1px) scale(.99); }
.quiet { font-style: italic; padding: 12px 18px; min-height: 44px; border-bottom: 0; text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 5px; text-decoration-color: rgb(120 80 30 / .5); }
.feedback { min-height: 1.5em; font-style: italic; }
.over, .case-no { font: 16px/1.2 FellSC, serif; letter-spacing: .09em; color: var(--gold); }
.note { font-style: italic; color: #b9a67d; text-wrap: balance; }
.count { font: 30px/1.2 Fell, serif; color: var(--gold-hi); font-variant-numeric: tabular-nums; letter-spacing: .03em; text-shadow: 0 0 24px rgb(255 180 90 / .4); }
.ink { width: 100%; font: 24px/1.2 Fell, serif; color: var(--ink); background: none; border: 0; border-bottom: 1.5px solid rgb(60 35 12 / .6); border-radius: 0; padding: 8px 2px; text-align: center; outline: none; -webkit-appearance: none; }
.ink:focus { border-color: var(--wine); box-shadow: 0 1px 0 var(--wine); }
.ink::placeholder { color: rgb(60 35 12 / .5); font-style: italic; }
.ink.light { color: var(--gold-hi); border-color: var(--gold-lo); } .ink.light:focus { border-color: var(--gold-hi); box-shadow: 0 1px 0 var(--gold); }

/* ---------- intro and gate ---------- */
.intro { height: 100%; min-height: 520px; display: flex; flex-direction: column; justify-content: space-between; align-items: center; text-align: center; padding: calc(28px + var(--st)) 20px calc(38px + var(--sb)); }
.intro-top { width: 100%; padding: 2dvh 0 30px; background: radial-gradient(ellipse 80% 60% at 50% 45%, rgb(3 5 4 / .62), transparent 75%); }
.logo { line-height: .92; color: transparent; }
.logo span { display: block; background: linear-gradient(178deg, #fff0c4 12%, #e0b964 42%, #8f6a2d 62%, #efd392 88%); -webkit-background-clip: text; background-clip: text; color: transparent; padding: 0 .06em .1em; filter: drop-shadow(0 2px 8px #000); }
.logo .the { font: italic 30px/1 Fell, serif; }
.logo .big { font: clamp(58px, 18.4vw, 92px)/.86 FellSC, serif; letter-spacing: -.015em; }
@media (min-width: 541px) { .logo .big { font-size: 88px; } }
.tagline { font: italic 21px/1.45 Fell, serif; color: #eeddb4; text-shadow: 0 1px 10px #000, 0 0 3px #000; }
.tagline span { display: block; }
.gate { min-height: 100%; display: grid; place-items: center; padding: 24px 34px; background: radial-gradient(ellipse at 50% 50%, rgb(2 4 3 / .86), rgb(2 4 3 / .55)); text-align: center; }
.gate-in { width: 100%; max-width: 320px; display: grid; justify-items: center; gap: 14px; }
.gate .star { width: 92px; filter: drop-shadow(0 0 18px rgb(255 180 90 / .45)); }
.gate .lead { font: 30px/1.2 Fell, serif; color: var(--gold-hi); }
.gate form { display: grid; gap: 8px; justify-items: center; width: 100%; } .gate label { font: 17px FellSC, serif; color: var(--gold); letter-spacing: .08em; }

/* ---------- navigation ---------- */
#nav { position: absolute; left: 0; right: 0; bottom: 0; z-index: 6; display: flex; padding: 22px 8px calc(4px + var(--sb)); background: linear-gradient(transparent, rgb(4 7 5 / .9) 34%, #040705); }
#nav a { flex: 1; display: grid; justify-items: center; gap: 1px; padding: 5px 0 7px; font: 15px/1.1 FellSC, serif; letter-spacing: .04em; color: #94814f; transition: color .4s; }
#nav svg { width: 26px; }
#nav a[aria-current] { color: var(--gold-hi); text-shadow: 0 0 16px rgb(255 190 100 / .6); } #nav a[aria-current] svg { filter: drop-shadow(0 0 7px rgb(255 180 90 / .7)); }

/* ---------- archive ---------- */
.mast { text-align: center; padding: calc(26px + var(--st)) 20px 0; }
.mast h1 { font: 31px/1.1 FellSC, serif; color: var(--gold-hi); text-shadow: 0 2px 10px #000; } .mast h1 small { font: italic 21px Fell, serif; }
.mast .act { font: 17px/1.3 FellSC, serif; color: var(--gold); margin-top: 8px; } .mast .act em { font: italic 18px Fell, serif; color: #d8c79c; margin-left: 5px; }
.track { display: flex; justify-content: center; align-items: center; gap: 4px; height: 16px; margin-top: 8px; }
.track i { width: 7px; height: 7px; rotate: 45deg; border: 1px solid rgb(201 163 92 / .34); }
.track i.solved { background: var(--gold); border-color: var(--gold); }
.track i.today { border-color: var(--gold-hi); box-shadow: 0 0 10px 1px rgb(255 190 100 / .75); margin: 0 4px; width: 9px; height: 9px; }
.mast .day { font: 17px/1.2 Fell, serif; color: #d8c79c; margin-top: 2px; } .mast .day span { color: #94814f; }
.hero { overflow: clip; text-align: center; padding: 20px 22px 34px; display: grid; justify-items: center; gap: 8px; }
.hero h2 { font-size: 35px; color: #f4e6c2; text-shadow: 0 2px 12px #000; margin-bottom: 10px; }
.env-wrap { display: block; width: min(80%, 340px); margin: 14px 0 20px; position: relative; rotate: -2.5deg; }
.env-wrap.live { animation: breathe 4.5s ease-in-out infinite; }
.env-wrap.live::before { content: ""; position: absolute; inset: -34% -22%; background: radial-gradient(closest-side, rgb(255 180 86 / .38), transparent); animation: flicker 4s infinite; z-index: -1; }
.env-wrap.dim { filter: brightness(.48) saturate(.75); width: min(58%, 240px); }
@keyframes breathe { 50% { transform: translateY(-5px) rotate(.8deg) } }
.env { position: relative; aspect-ratio: 1.5; perspective: 900px; filter: drop-shadow(0 16px 18px rgb(0 0 0 / .65)); }
.env > div, .env-front i { position: absolute; inset: 0; }
.env-back { background: linear-gradient(rgb(40 22 8 / .62), rgb(60 35 14 / .5)), url(/img/parchment.webp) 50% 50%/130%; }
.env-sheet { inset: 5% 4% 4% !important; background: url(/img/parchment.webp) 50% 0/cover; box-shadow: 0 0 8px rgb(0 0 0 / .4); z-index: 1; visibility: hidden; }
.env-front { z-index: 2; filter: drop-shadow(0 -1px 2px rgb(40 20 5 / .45)); }
.env-front i { background: url(/img/parchment.webp) 50% 50%/130%; }
.env-front i:nth-child(1) { clip-path: polygon(0 0, 52% 56%, 0 100%); filter: brightness(.93); }
.env-front i:nth-child(2) { clip-path: polygon(100% 0, 48% 56%, 100% 100%); filter: brightness(.88); }
.env-front i:nth-child(3) { clip-path: polygon(0 100%, 47% 49%, 50% 47.5%, 53% 49%, 100% 100%); filter: brightness(.97); }
.env-flap { z-index: 3; transform-origin: 50% 0; filter: drop-shadow(0 3px 4px rgb(40 20 5 / .6)); }
.env-flap i { position: absolute; inset: 0; background: linear-gradient(180deg, rgb(255 240 200 / .12), rgb(80 45 15 / .18) 62%), url(/img/parchment.webp) 40% 30%/150%; clip-path: polygon(0 0, 100% 0, 54% 59%, 50% 62%, 46% 59%); }
.env > .seal { position: absolute; z-index: 4; left: 50%; top: 59%; width: 31%; translate: -50% -50%; filter: drop-shadow(0 4px 4px rgb(40 10 5 / .6)); }
.env.open .env-flap { z-index: 0; } .env.open .env-flap i { filter: brightness(.62); } .env.open .env-sheet { visibility: visible; }

.block { padding: 26px 20px 30px; text-align: center; }
.block .title { font: 27px/1.1 FellSC, serif; color: var(--gold-hi); text-shadow: 0 2px 10px #000; }
.cabinet { display: grid; grid-template-columns: repeat(4, 1fr); margin: 20px -8px 0; box-shadow: 0 22px 40px rgb(0 0 0 / .7), 0 0 0 5px #150b06, 0 0 0 6px #3a2413; background: #150b06; }
.drawer { position: relative; display: block; width: 100%; aspect-ratio: 1.27; }
.drawer img:first-child { width: 100%; height: 100%; object-fit: cover; filter: brightness(.66) saturate(.75); transition: filter .5s; }
.drawer b { position: absolute; left: 0; right: 0; top: 39.6%; translate: 0 -50%; font: 400 13.5px/1 Fell, serif; letter-spacing: -.045em; color: rgb(24 13 4 / .95); text-align: center; }
.drawer.solved img:first-child { filter: brightness(.95); }
.drawer:is(.new, .open) img:first-child { filter: brightness(1.25) saturate(1.1); } .drawer:is(.new, .open) { box-shadow: 0 0 26px 2px rgb(255 178 84 / .6); z-index: 1; }
.drawer .mini { position: absolute; width: 38%; right: 3%; bottom: 3%; rotate: 14deg; filter: drop-shadow(0 2px 3px #000); }
.evidence { display: flex; justify-content: center; align-items: center; min-height: 170px; margin-top: 10px; }
.evidence img { width: 44%; max-width: 190px; rotate: var(--r); filter: drop-shadow(0 12px 14px rgb(0 0 0 / .7)); margin: 0 -14px; }
.empty { font-style: italic; color: #b9a67d; } .empty .star { width: 60px; opacity: .35; margin-bottom: 8px; display: inline-block; }
.chest { padding-inline: 0; }
.chest-img { position: relative; margin: -6px 0 -14px; overflow: hidden; }
.chest-img img { width: 100%; -webkit-mask: radial-gradient(ellipse 54% 56% at 50% 54%, #000 62%, transparent 98%); mask: radial-gradient(ellipse 54% 56% at 50% 54%, #000 62%, transparent 98%); }
.chest-img i { position: absolute; inset: 0; background: radial-gradient(closest-side at 30% 45%, rgb(255 170 80 / .24), transparent); mix-blend-mode: screen; animation: flicker 4.2s infinite; }
.chest .note { padding: 0 34px; position: relative; }
.keys { list-style: none; padding: 0 20px; margin-top: 22px; display: grid; grid-template-columns: repeat(2, 1fr); gap: 22px 12px; }
.keys li { display: grid; justify-items: center; }
.keys img { width: 92%; filter: brightness(.16) drop-shadow(0 0 1px rgb(201 163 92 / .95)) drop-shadow(0 0 5px rgb(201 163 92 / .3)); }
.keys .won img { filter: drop-shadow(0 8px 8px #000) drop-shadow(0 0 16px rgb(255 190 100 / .5)); }
.keys span { font: 18px/1 FellSC, serif; color: var(--gold); } .keys em { font: italic 17px/1.3 Fell, serif; color: #b9a67d; }
.map { position: relative; margin: 18px 4px 0; }
.map img { width: 100%; filter: brightness(.62) sepia(.2) blur(1.6px); -webkit-mask: radial-gradient(circle at 24% 70%, #000 0, rgb(0 0 0 / .85) 10%, rgb(0 0 0 / .4) 34%, rgb(0 0 0 / .18) 70%); mask: radial-gradient(circle at 24% 70%, #000 0, rgb(0 0 0 / .85) 10%, rgb(0 0 0 / .4) 34%, rgb(0 0 0 / .18) 70%); }
.map p { position: absolute; inset: 0; display: grid; place-items: center; padding: 0 20%; font: italic 20px/1.3 Fell, serif; color: #d8c79c; text-shadow: 0 1px 10px #000; text-wrap: balance; }
.foot { padding: 18px 0 calc(110px + var(--sb)); text-align: center; } .foot .star { opacity: .5; display: inline-block; }

/* ---------- clues ---------- */
.board { display: grid; gap: 34px; padding: 22px 34px calc(120px + var(--sb)); }
.exhibit { rotate: var(--r); text-align: center; } .exhibit img { width: 88%; margin: auto; filter: drop-shadow(0 18px 18px rgb(0 0 0 / .7)); }
.tag { display: inline-grid; gap: 2px; margin-top: 2px; padding: 9px 26px 11px; color: var(--ink); font: 21px/1.15 Fell, serif; background: linear-gradient(rgb(255 235 190 / .1), rgb(70 40 10 / .2)), url(/img/parchment.webp) 50% 40%/300%; clip-path: polygon(10px 0, calc(100% - 10px) 0, 100% 10px, 100% calc(100% - 10px), calc(100% - 10px) 100%, 10px 100%, 0 calc(100% - 10px), 0 10px); }
.tag small { font: 15px/1.1 FellSC, serif; color: var(--wine); }
.viewer { width: 100%; max-width: 540px; height: 100%; max-height: none; border: 0; margin: auto; padding: 20px 28px; background: rgb(3 5 4 / .95); color: var(--parchment); text-align: center; }
.viewer[open] { display: grid; align-content: center; justify-items: center; gap: 8px; } .viewer::backdrop { background: rgb(0 0 0 / .8); }
.viewer img { width: 100%; max-height: 58dvh; object-fit: contain; } .viewer h2 { font-size: 33px; color: var(--gold-hi); }

/* ---------- case ---------- */
.back { position: sticky; top: calc(8px + var(--st)); left: 8px; width: 46px; height: 46px; margin: 8px 0 -54px 8px; display: grid; place-items: center; color: var(--gold-hi); z-index: 8; filter: drop-shadow(0 1px 5px #000) drop-shadow(0 0 2px #000); } .back svg { width: 25px; }
.case { min-height: 100%; }
.case-head { text-align: center; } .case-head h1 { font-size: 38px; color: #f4e6c2; text-shadow: 0 2px 14px #000; margin-top: 6px; }
.sealed { overflow: clip; min-height: 100dvh; display: grid; grid-template-rows: auto 1fr auto; padding: calc(62px + var(--st)) 18px calc(46px + var(--sb)); }
.env-big { align-self: center; width: 100%; max-width: 430px; margin: auto; }
.hold { text-align: center; font: italic 20px/1.3 Fell, serif; color: var(--gold-hi); text-shadow: 0 1px 8px #000; animation: flicker 4s infinite; }
.seal-btn { position: absolute; z-index: 4; left: 50%; top: 60%; width: 36%; aspect-ratio: 1; translate: -50% -50%; touch-action: none; -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; border-radius: 50%; }
.seal-btn .half { position: absolute; inset: 0; pointer-events: none; filter: drop-shadow(0 4px 4px rgb(40 10 5 / .6)); } .seal-btn img { width: 100%; }
.half.a img { clip-path: polygon(0 0, 55% 0, 49% 18%, 56% 33%, 46% 48%, 54% 62%, 45% 80%, 50% 100%, 0 100%); }
.half.b img { clip-path: polygon(55% 0, 100% 0, 100% 100%, 50% 100%, 45% 80%, 54% 62%, 46% 48%, 56% 33%, 49% 18%); }
.seal-btn svg { position: absolute; inset: -9%; rotate: -90deg; overflow: visible; pointer-events: none; transition: opacity .3s; }
.seal-btn circle { fill: none; stroke: #ffd98f; stroke-width: 1.6; stroke-dasharray: 1; stroke-dashoffset: 1; filter: drop-shadow(0 0 4px #ffb24f); }
.seal-btn::before { content: ""; position: absolute; inset: -25%; border-radius: 50%; background: radial-gradient(closest-side, rgb(255 190 90 / .5), transparent); animation: pulse 2.4s infinite; pointer-events: none; }
.seal-btn.broken::before, .seal-btn.broken svg { opacity: 0; animation: none; } .seal-btn.broken { pointer-events: none; }
@keyframes pulse { 50% { opacity: .25; scale: .9 } }

.sheet { position: relative; margin: calc(60px + var(--st)) 12px calc(34px + var(--sb)); padding: 50px 32px 46px; color: var(--ink); font: 21px/1.46 Fell, Georgia, serif; background: url(/img/parchment.webp) 50% 0/100% 100%; box-shadow: 0 24px 50px rgb(0 0 0 / .75), 0 0 70px rgb(255 170 80 / .13);
  clip-path: polygon(0 .4%, 7% 0, 16% .35%, 29% 0, 43% .3%, 58% 0, 71% .4%, 84% .05%, 94% .35%, 100% 0, 99.5% 14%, 100% 31%, 99.4% 47%, 100% 66%, 99.6% 83%, 100% 99.8%, 88% 99.6%, 76% 100%, 61% 99.7%, 47% 100%, 33% 99.65%, 18% 100%, 8% 99.7%, 0 100%, .5% 81%, 0 63%, .6% 44%, 0 27%, .4% 12%); }
.sheet p + p { margin-top: .72em; }
.sheet .heading { text-align: center; color: var(--wine); font: 22px/1.25 FellSC, serif; letter-spacing: .03em; border-block: 1.5px solid rgb(109 20 32 / .65); padding: 9px 0 11px; margin-bottom: 26px; rotate: -1.2deg; opacity: .95; }
.sheet .heading span { display: block; } .sheet .heading span + span { font-size: 18px; }
.sheet .sign { font: 38px/1.15 Script, cursive; text-align: right; margin-top: 22px !important; }
.sheet .greeting { font: 42px/1.1 Script, cursive; margin-bottom: 4px; }
.addressee { position: absolute; z-index: 4; left: 0; right: 0; top: 9%; text-align: center; font: 46px/1.1 Script, cursive; color: #2f1b0b; opacity: .85; pointer-events: none; }
.unwritten { visibility: hidden; }
.turn { text-align: center; margin-top: 34px; }
.sheet.small { padding: 40px 32px; margin: 0 12px; text-align: center; } .sheet.small .sign { text-align: center; }
.dossier { text-align: center; min-height: 70dvh; } .dossier.small { min-height: 0; }
.dossier .case-no { color: var(--wine); } .dossier h1 { font-size: 33px; margin-top: 4px; } .dossier h2 { font-size: 26px; margin-bottom: 14px; } .dossier .rule { color: #7a5524; }
.ch-intro { font-style: italic; color: #5b3c1c; } .question { font-size: 25px; line-height: 1.3; margin: 22px 0 18px !important; text-wrap: balance; overflow-wrap: anywhere; }
.dossier .feedback { color: var(--wine); margin: 12px 0 14px; font-size: 20px; line-height: 1.3; }
.hints { margin-top: 22px; } .hints p { border-left: 2px solid rgb(109 20 32 / .5); padding: 2px 0 2px 14px; text-align: left; font-style: italic; } .hints small { display: block; font: 16px/1.2 FellSC, serif; color: var(--wine); }
.dossier .quiet { display: block; margin: 8px auto 0; font-size: 19px; color: #54371a; }

.stamp-over { position: absolute; inset: 0; z-index: 4; display: grid; place-items: center; background: radial-gradient(circle, rgb(8 8 5 / .82), rgb(2 3 2 / .96)); text-align: center; }
.stamp-in { display: grid; justify-items: center; padding: 20px; } .slam { width: min(62vw, 270px); filter: brightness(.74) drop-shadow(0 18px 22px #000); }
.stamp { font: 44px/1.1 FellSC, serif; color: var(--gold-hi); text-shadow: 0 0 30px rgb(255 180 80 / .6); margin-top: 18px; } .stamp-text { font: italic 22px Fell, serif; }
.ink-stamp { display: inline-block; color: var(--wine); font-size: 29px; text-shadow: none; border: 2.5px solid; padding: 3px 18px 6px; rotate: -5deg; opacity: .85; }
.reward { position: relative; min-height: 100dvh; display: grid; align-content: center; justify-items: center; gap: 16px; text-align: center; padding: calc(54px + var(--st)) 28px calc(34px + var(--sb)); overflow: hidden; }
.rays { position: absolute; left: 50%; top: 40%; width: 210vmin; height: 210vmin; translate: -50% -50%; z-index: -1; background: radial-gradient(circle, rgb(255 190 100 / .36), rgb(255 160 60 / .07) 30%, transparent 48%), repeating-conic-gradient(rgb(255 190 100 / .1) 0 5deg, transparent 9deg 20deg); -webkit-mask: radial-gradient(circle, #000 8%, transparent 46%); mask: radial-gradient(circle, #000 8%, transparent 46%); animation: turn 70s linear infinite; }
@keyframes turn { to { rotate: 360deg } }
.prize { width: min(82vw, 380px); max-height: 48dvh; object-fit: contain; filter: drop-shadow(0 20px 24px #000); }
.reward h1 { font-size: 37px; color: var(--gold-hi); } .reward .info p { font: italic 21px/1.35 Fell, serif; text-wrap: balance; }
.ending { display: grid; gap: 26px; justify-items: center; padding: calc(64px + var(--st)) 0 calc(42px + var(--sb)); } .ending .sheet { width: calc(100% - 24px); margin: 0; }
.next { position: relative; width: 74%; max-width: 300px; text-align: center; } .next img { width: 62%; margin: 0 auto 12px; filter: brightness(.55) drop-shadow(0 10px 14px #000); }
.next p { font: italic 20px/1.3 Fell, serif; color: #d8c79c; text-shadow: 0 1px 8px #000; } .next small { display: block; font: 17px FellSC, serif; color: var(--gold); } .next .count { font: 30px/1.3 Fell, serif; color: var(--gold-hi); }
.found { display: flex; align-items: center; gap: 6px; padding: 0 20px; font: 24px/1.15 Fell, serif; color: #f4e6c2; text-shadow: 0 1px 10px #000; } .found img { width: 128px; filter: drop-shadow(0 8px 10px #000); } .found small { display: block; font: 16px FellSC, serif; color: var(--gold); }

@media (max-height: 640px) { .intro { padding-top: 10px; } .logo .big { font-size: 54px; } .tagline { font-size: 18px; } }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; } }
