:root {
  color-scheme: dark;
  --ink: #fffaf0;
  --muted: #c9d5c8;
  --forest-0: #071a17;
  --forest-1: #0f3025;
  --forest-2: #174735;
  --leaf: #77d69c;
  --mint: #81e5bd;
  --gold: #ffd36d;
  --amber: #d9903d;
  --violet: #9e8bf2;
  --rose: #ff9bb7;
  --line: rgba(255,255,255,.14);
  font-family: Nunito, ui-rounded, "Segoe UI", system-ui, sans-serif;
}

* { box-sizing: border-box; }
html, body { min-height: 100%; }
body { margin: 0; min-width: 320px; color: var(--ink); background: radial-gradient(circle at 50% -20%, #214837, #07120f 58%); }
button { font: inherit; }
button:focus-visible, summary:focus-visible { outline: 4px solid var(--gold); outline-offset: 4px; }
[hidden] { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }

.app-shell { width: min(1450px, 100%); min-height: 100vh; margin: 0 auto; padding: 14px; }
.topbar { min-height: 78px; display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 5px 8px 13px; }
.brand-kicker, .intro-kicker, .finale-kicker { display: block; color: var(--gold); font-size: .72rem; font-weight: 950; letter-spacing: .14em; text-transform: uppercase; }
h1, h2, h3, p { margin-top: 0; }
h1 { margin-bottom: 0; font-family: Georgia, serif; font-size: clamp(1.75rem,4vw,2.6rem); letter-spacing: -.04em; }
.topbar-actions { display: flex; align-items: center; gap: 9px; }
.spark-counter, .icon-button, .text-button, .game-park-link { min-height: 44px; border: 1px solid var(--line); border-radius: 999px; color: var(--ink); background: rgba(255,255,255,.08); }
.spark-counter { display: flex; align-items: center; gap: 4px; padding: 0 15px; }
.spark-counter > span:first-child { color: var(--gold); }
.icon-button { width: 46px; cursor: pointer; font-size: 1.2rem; }
.text-button { padding: 0 17px; cursor: pointer; font-weight: 900; }
.music-button { width: auto; display: flex; align-items: center; gap: 5px; padding: 0 13px; }.music-button b { font-size: .72rem; }
.game-park-link { display: flex; align-items: center; gap: 6px; padding: 0 13px; text-decoration: none; font-size: .75rem; }.game-park-link span { font-size: 1.1rem; }
.icon-button:hover, .text-button:hover, .game-park-link:hover { background: rgba(255,255,255,.15); }
.text-button.is-armed { color: #2e2216; border-color: #ffe7a0; background: var(--gold); }

.game-shell { --hand-x: 50%; --hand-y: 50%; position: relative; isolation: isolate; overflow: hidden; border: 1px solid rgba(255,255,255,.12); border-radius: 32px; background: #0c211b; box-shadow: 0 30px 80px rgba(0,0,0,.34), inset 0 1px rgba(255,255,255,.1); }
.loading-state { position: absolute; inset: 0; z-index: 100; min-height: 760px; display: grid; place-content: center; justify-items: center; gap: 15px; background: #0b211b; }
.loading-leaf { width: 58px; height: 58px; display: grid; place-items: center; border-radius: 55% 20% 55% 20%; color: #193c2c; background: var(--mint); transform: rotate(45deg); animation: leaf-breathe 1.2s ease-in-out infinite; }
.loading-state.is-error { color: #ffe5e8; }

.journey-hud { position: relative; z-index: 25; min-height: 78px; display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 13px 24px; border-bottom: 1px solid rgba(255,255,255,.1); background: rgba(6,19,16,.86); backdrop-filter: blur(12px); }
.journey-hud > div:first-child { display: grid; gap: 5px; }
.case-label { width: max-content; padding: 4px 10px; border: 1px solid rgba(129,229,189,.35); border-radius: 999px; color: var(--mint); font-size: .68rem; font-weight: 950; letter-spacing: .1em; text-transform: uppercase; }
#round-label { font-size: .9rem; }
.step-track { display: flex; align-items: center; }
.step-track > span { position: relative; min-width: 74px; display: grid; justify-items: center; gap: 3px; color: #7d9389; }
.step-track > span:not(:last-child)::after { content: ""; position: absolute; z-index: -1; left: 58%; top: 16px; width: 84%; height: 3px; background: #375047; }
.step-track b { width: 34px; height: 34px; display: grid; place-items: center; border: 2px solid #49645a; border-radius: 50%; background: #142b24; }
.step-track em { font-size: .66rem; font-style: normal; font-weight: 900; }
.step-track .is-active { color: var(--gold); }
.step-track .is-active b { color: #2f2514; border-color: #fff0a3; background: var(--gold); box-shadow: 0 0 24px rgba(255,211,109,.45); }
.step-track .is-complete { color: var(--mint); }
.step-track .is-complete b { border-color: var(--mint); background: #245e49; }
.step-track .is-complete::after { background: var(--mint) !important; }

.forest-stage { position: relative; min-height: 610px; overflow: hidden; background: linear-gradient(#163d35 0%, #184438 42%, #102d26 76%, #091c18 100%); }
.forest-sky { position: absolute; inset: 0; background: radial-gradient(circle at 50% 26%, rgba(135,200,167,.24), transparent 28%), linear-gradient(#0e2928, transparent 60%); }
.moon { position: absolute; right: 10%; top: 10%; width: 72px; height: 72px; border-radius: 50%; background: #fff2bf; box-shadow: 0 0 42px rgba(255,239,176,.32); opacity: .8; }
.moon::after { content: ""; position: absolute; width: 72px; height: 72px; left: -20px; top: -9px; border-radius: 50%; background: #163d35; }
.star { position: absolute; width: 5px; height: 5px; border-radius: 50%; background: var(--gold); box-shadow: 0 0 10px var(--gold); animation: twinkle 2s ease-in-out infinite alternate; }
.s1 { left: 20%; top: 13%; }.s2 { left: 70%; top: 24%; animation-delay: -.7s; }.s3 { left: 45%; top: 9%; animation-delay: -1.3s; }
.forest-depth { position: absolute; inset: 0; pointer-events: none; transition: transform .8s ease, opacity .8s ease; }
.forest-depth::before, .forest-depth::after { content: ""; position: absolute; bottom: 0; width: 36%; height: 100%; background-repeat: repeat-x; }
.forest-depth-far { opacity: .48; background: repeating-linear-gradient(88deg, transparent 0 7%, rgba(10,39,30,.65) 7.5% 10%, transparent 10.5% 17%); }
.forest-depth-mid::before, .forest-depth-mid::after { width: 44%; background: radial-gradient(ellipse at 50% 110%, #174c35 0 46%, transparent 47%), repeating-linear-gradient(84deg, transparent 0 17%, #153f2f 18% 22%, transparent 23% 32%); }
.forest-depth-mid::before { left: -5%; }.forest-depth-mid::after { right: -5%; transform: scaleX(-1); }
.forest-depth-near::before, .forest-depth-near::after { width: 30%; background: radial-gradient(ellipse at 40% 100%, #0b281f 0 52%, transparent 53%), linear-gradient(84deg, transparent 0 30%, #0a251c 31% 43%, transparent 44%); }
.forest-depth-near::before { left: -3%; }.forest-depth-near::after { right: -3%; transform: scaleX(-1); }
.forest-road { position: absolute; left: 50%; bottom: -2px; width: min(760px,72%); height: 76%; transform: translateX(-50%); clip-path: polygon(43% 0,57% 0,93% 100%,7% 100%); background: linear-gradient(90deg,#18392b,#31553c 46%,#416447 52%,#18382b); box-shadow: inset 0 0 70px rgba(7,24,18,.75); }
.forest-road::after { content: ""; position: absolute; inset: 0; background: repeating-linear-gradient(166deg,transparent 0 34px,rgba(255,255,255,.025) 35px 37px); }
.trail-light { position: absolute; width: 7px; height: 7px; border-radius: 50%; background: var(--gold); box-shadow: 0 0 14px var(--gold); }
.t1 { left: 31%; top: 40%; }.t2 { right: 32%; top: 61%; }.t3 { left: 23%; top: 78%; }
.trail-steps { position: absolute; z-index: 7; inset: 0; pointer-events: none; }.trail-steps span { position: absolute; left: calc(50% - 10px); width: 20px; height: 11px; border: 3px solid rgba(255,230,164,.25); border-radius: 55% 55% 45% 45%; opacity: .18; transform: rotate(-12deg); transition: opacity .8s ease, transform .8s ease; }.trail-steps span:nth-child(1) { bottom: 23%; }.trail-steps span:nth-child(2) { bottom: 37%; transform: translateX(22px) rotate(12deg); }.trail-steps span:nth-child(3) { bottom: 51%; }
.forest-stage[data-round="2"] .trail-steps span:nth-child(-n+2),.forest-stage[data-round="3"] .trail-steps span,.forest-stage[data-round="4"] .trail-steps span { opacity: .8; border-color: rgba(255,230,164,.72); box-shadow: 0 0 14px rgba(255,211,109,.25); }
.forest-friend { position: absolute; z-index: 18; left: 64%; top: 43%; min-width: 50px; min-height: 50px; display: grid; place-items: center; gap: 1px; padding: 5px; border: 1px solid rgba(255,239,159,.48); border-radius: 50%; color: var(--gold); background: rgba(17,55,42,.72); box-shadow: 0 0 24px rgba(255,211,109,.28); cursor: pointer; animation: glow-friend 1.8s ease-in-out infinite; }.forest-friend span { font-size: 1.2rem; }.forest-friend small { color: #fff4bf; font-size: .45rem; font-weight: 900; }.forest-friend.is-playing { animation: glow-hop .65s ease; }

.secret-chest { position: absolute; z-index: 8; left: 50%; top: 10%; width: 240px; height: 190px; border: 0; color: var(--ink); background: transparent; cursor: pointer; transform: translateX(-50%) scale(.27); transform-origin: center center; transition: top 1.05s cubic-bezier(.2,.8,.2,1), transform 1.05s cubic-bezier(.2,.8,.2,1), filter .3s ease; }
.secret-chest:hover { filter: brightness(1.13); }
.forest-stage[data-round="2"] .secret-chest { top: 19%; transform: translateX(-50%) scale(.5); }
.forest-stage[data-round="3"] .secret-chest { top: 28%; transform: translateX(-50%) scale(.78); }
.forest-stage[data-round="4"] .secret-chest { top: 30%; transform: translateX(-50%) scale(.86); filter: brightness(1.16); animation: chest-ready 1.1s ease-in-out infinite alternate; }
.chest-body { position: absolute; left: 50%; top: 52px; width: 150px; height: 92px; border: 6px solid #5e351e; border-radius: 12px 12px 20px 20px; background: linear-gradient(90deg,#9d562c,#d69241 48%,#9d562c); box-shadow: 0 14px 0 #4b2e20, inset 0 0 0 8px rgba(255,212,111,.14), 0 0 30px rgba(255,202,92,.34); transform: translateX(-50%); }
.chest-lid { position: absolute; left: -6px; top: -45px; width: 150px; height: 58px; border: 6px solid #5e351e; border-bottom-width: 9px; border-radius: 70px 70px 10px 10px; background: linear-gradient(#dc9949,#955027); }
.chest-lock { position: absolute; left: 50%; top: 22px; width: 26px; height: 32px; border-radius: 5px; background: var(--gold); box-shadow: inset 0 0 0 5px #a76428; transform: translateX(-50%); }
.secret-smudge { position: absolute; inset: -16px 25px 8px; overflow: hidden; opacity: .12; filter: grayscale(1) brightness(0) invert(1) blur(24px); transition: opacity .8s ease, filter .8s ease, transform .8s ease; }
.secret-smudge svg { width: 100%; height: 100%; }
.forest-stage[data-round="2"] .secret-smudge { opacity: .24; filter: grayscale(1) brightness(0) invert(1) blur(16px); transform: scale(1.04); }
.forest-stage[data-round="3"] .secret-smudge { opacity: .42; filter: grayscale(1) brightness(0) invert(1) blur(9px); transform: scale(1.1); }
.forest-stage[data-round="4"] .secret-smudge { opacity: 0; }
.chest-fog { position: absolute; z-index: 5; border-radius: 50%; background: rgba(222,232,222,.86); filter: blur(11px); box-shadow: 0 0 36px rgba(226,235,220,.68); transition: opacity .8s ease, transform .8s ease; pointer-events: none; }
.fog-a { left: 8px; top: 35px; width: 150px; height: 90px; }.fog-b { right: -3px; top: 64px; width: 165px; height: 86px; }.fog-c { left: 48px; bottom: 0; width: 145px; height: 74px; }
.forest-stage[data-round="2"] .chest-fog { opacity: .72; transform: scale(.92); }
.forest-stage[data-round="3"] .chest-fog { opacity: .43; transform: scale(.78); }
.forest-stage[data-round="4"] .chest-fog { opacity: .18; transform: scale(.62); }
.inspect-label { position: absolute; left: 50%; bottom: -2px; min-width: 118px; padding: 7px 10px; border-radius: 999px; color: #26321f; background: var(--gold); transform: translateX(-50%); font-size: .72rem; font-weight: 950; box-shadow: 0 8px 18px rgba(0,0,0,.25); }

.walker-group { position: absolute; z-index: 12; left: 50%; bottom: 0; display: flex; align-items: end; gap: clamp(20px,5vw,72px); transform: translateX(-50%); transition: bottom 1.05s cubic-bezier(.2,.8,.2,1), transform 1.05s cubic-bezier(.2,.8,.2,1); }
.forest-stage[data-round="2"] .walker-group { bottom: 96px; transform: translateX(-50%) scale(.94); }
.forest-stage[data-round="3"] .walker-group { bottom: 152px; transform: translateX(-50%) scale(.88); }
.forest-stage[data-round="4"] .walker-group { bottom: 152px; transform: translateX(-50%) scale(.88); }
.walker { width: 112px; display: grid; justify-items: center; gap: 5px; padding: 0; border: 0; color: #fff8df; background: transparent; text-shadow: 0 2px 5px rgba(0,0,0,.6); }
.walker-avatar { width: 90px; height: 90px; overflow: hidden; border: 4px solid rgba(255,255,255,.84); border-radius: 50%; background: #fff; box-shadow: 0 10px 25px rgba(0,0,0,.32); }
.walker-avatar img { width: 100%; height: 100%; display: block; object-fit: cover; }
.walker strong { display: grid; justify-items: center; padding: 3px 9px; border-radius: 12px; background: rgba(5,24,17,.78); font-size: .78rem; }
.walker strong small { color: var(--mint); font-size: .53rem; letter-spacing: .05em; }
.walker-child { cursor: pointer; }
.walker-child:hover .child-explorer, .walker-child:focus-visible .child-explorer { transform: translateY(-5px) rotate(-2deg); }
.child-explorer { --explorer-main:#df783d; --explorer-mid:#ffc95c; --explorer-accent:#65d6bc; position: relative; width: 88px; height: 108px; display: block; filter: drop-shadow(0 10px 12px rgba(0,0,0,.32)); transition: transform .2s ease; }
.child-explorer[data-theme="mint"] { --explorer-main:#278d79; --explorer-mid:#8be4bf; --explorer-accent:#ffcf61; }
.child-explorer[data-theme="sky"] { --explorer-main:#3979aa; --explorer-mid:#8fd4ee; --explorer-accent:#ff9bb7; }
.child-face { position: absolute; z-index: 4; left: 50%; top: 10px; width: 54px; height: 55px; border: 3px solid rgba(255,244,214,.72); border-radius: 48% 48% 44% 44%; background: linear-gradient(145deg,#efb986,#c97c55); transform: translateX(-50%); }
.child-hair { position: absolute; z-index: 6; left: 50%; top: 3px; width: 62px; height: 33px; border-radius: 50% 50% 34% 38%; background: radial-gradient(circle at 32% 28%,#6f4632 0 17%,transparent 18%),#35231f; transform: translateX(-50%); }
.child-eye { position: absolute; top: 23px; width: 6px; height: 8px; border-radius: 50%; background: #272229; box-shadow: inset 0 2px rgba(255,255,255,.45); }.eye-left { left: 13px; }.eye-right { right: 13px; }
.child-smile { position: absolute; left: 50%; bottom: 9px; width: 16px; height: 8px; border-bottom: 3px solid #713c3a; border-radius: 50%; transform: translateX(-50%); }
.child-body { position: absolute; z-index: 3; left: 50%; bottom: 3px; width: 62px; height: 59px; border: 3px solid #fff0b7; border-radius: 22px 22px 12px 12px; background: linear-gradient(90deg,var(--explorer-main),var(--explorer-mid) 52%,var(--explorer-main)); transform: translateX(-50%); }
.child-body::before, .child-body::after { content: ""; position: absolute; bottom: -4px; width: 16px; height: 40px; border-radius: 10px; background: #335c70; }
.child-body::before { left: 9px; }.child-body::after { right: 9px; }
.child-pack { position: absolute; z-index: 1; right: 1px; top: 52px; width: 34px; height: 47px; border: 3px solid #ffd1d8; border-radius: 13px; background: #9d4967; }
.child-scarf { position: absolute; z-index: 7; left: 50%; top: 59px; width: 43px; height: 10px; border-radius: 999px; background: var(--explorer-accent); transform: translateX(-50%) rotate(-4deg); }
.child-arm { position: absolute; z-index: 5; top: 70px; width: 15px; height: 39px; border-radius: 999px; background: #eaa775; transform-origin: top; transition: transform .28s ease; }.arm-left { left: 4px; transform: rotate(20deg); }.arm-right { right: 4px; transform: rotate(-20deg); }
.clue-badge { position: absolute; z-index: 8; right: -4px; top: 0; width: 28px; height: 28px; display: grid; place-items: center; border: 3px solid #fff6cf; border-radius: 50%; color: #2f2b1f; background: var(--gold); font-size: .72rem; font-weight: 950; box-shadow: 0 5px 12px rgba(0,0,0,.3); }
.walker-group[data-mood="wrong"] .child-smile { border-bottom: 0; border-top: 3px solid #713c3a; bottom: 5px; }
.walker-group[data-mood="success"] .arm-left { transform: rotate(145deg); }.walker-group[data-mood="success"] .arm-right { transform: rotate(-145deg); }
.child-explorer.is-scouting { transform: translateY(-7px) rotate(4deg) scale(1.05); }.child-explorer.is-scouting .arm-right { transform: rotate(-118deg); }
.child-explorer.is-cheering .arm-left { transform: rotate(145deg); }.child-explorer.is-cheering .arm-right { transform: rotate(-145deg); }
.forest-stage.is-walking .walker { animation: walker-step .28s ease-in-out 4 alternate; }
.forest-stage.is-walking .forest-depth-mid { transform: scale(1.08) translateY(8px); }
.forest-stage.is-walking .forest-depth-near { transform: scale(1.12) translateY(15px); }

.dialogue-card { position: absolute; z-index: 15; left: 18px; top: 12px; width: min(230px,24%); min-height: 76px; padding: 10px 13px; border: 1px solid rgba(255,255,255,.22); border-radius: 20px; color: #22372d; background: rgba(255,252,237,.96); box-shadow: 0 14px 30px rgba(0,0,0,.26); transition: left .25s ease,right .25s ease,transform .25s ease; }
.dialogue-card[data-speaker="lumi"] { left: auto; right: 18px; }
.dialogue-card[data-mode="story"] { top: auto; bottom: 20px; width: min(310px,28%); min-height: 84px; }
.dialogue-card[data-mode="clue"] { width: min(190px,22%); min-height: 70px; text-align: center; }
.dialogue-card.is-speaking { animation: dialogue-pop .38s cubic-bezier(.2,.9,.3,1.15); }
.dialogue-speaker { color: #3d7a57; font-size: .7rem; font-weight: 950; letter-spacing: .1em; text-transform: uppercase; }
.dialogue-card p { margin: 5px 0 0; font-size: .78rem; font-weight: 850; line-height: 1.28; }
.dialogue-keyword { display: block; margin-top: 2px; color: #8c3f2e; font-family: Georgia,serif; font-size: clamp(1.35rem,2.4vw,1.85rem); font-weight: 950; line-height: 1; letter-spacing: .025em; text-transform: uppercase; }
.child-thought { position: relative; z-index: 16; width: 100%; min-height: 58px; display: flex; align-items: center; justify-content: center; gap: 13px; padding: 9px 18px; border-block: 1px solid rgba(255,211,109,.28); color: #2f3428; background: linear-gradient(90deg,#fff1b3,#fff8d8,#fff1b3); box-shadow: 0 10px 24px rgba(0,0,0,.2); text-align: center; }
.child-thought::after { display: none; }
.child-thought span { color: #8b5b24; font-size: .68rem; font-weight: 950; letter-spacing: .1em; text-transform: uppercase; }
.child-thought p { margin: 0; font-size: .78rem; font-weight: 850; line-height: 1.3; }

.intro-panel { position: relative; z-index: 30; width: min(1080px,calc(100% - 36px)); display: grid; grid-template-columns: minmax(300px,1.15fr) minmax(330px,.95fr) auto; grid-template-areas: "kicker picker action" "title picker action" "copy picker action"; align-items: center; column-gap: 24px; margin: 18px auto 22px; padding: 18px 24px 20px; border: 1px solid rgba(255,255,255,.2); border-radius: 25px; background: rgba(8,30,23,.96); box-shadow: 0 20px 48px rgba(0,0,0,.3), inset 0 1px rgba(255,255,255,.12); text-align: left; }
.intro-panel .intro-kicker { grid-area: kicker; }.intro-panel h2 { grid-area: title; margin: 4px 0 5px; font-family: Georgia,serif; font-size: clamp(1.45rem,3vw,2rem); }.intro-panel > p { grid-area: copy; margin: 0; color: var(--muted); font-size: .84rem; }.intro-panel .explorer-picker { grid-area: picker; }.intro-panel > .primary-button { grid-area: action; white-space: nowrap; }
.explorer-picker { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 8px; margin: 14px 0 17px; }.explorer-picker > span { width: 100%; color: #dcebe0; font-size: .72rem; font-weight: 900; }.explorer-picker button { min-height: 46px; display: flex; align-items: center; gap: 9px; padding: 0 14px; border: 2px solid rgba(255,255,255,.13); border-radius: 999px; color: var(--ink); background: rgba(255,255,255,.06); cursor: pointer; font-weight: 850; }.explorer-picker button[aria-pressed="true"] { color: #2c2a1d; border-color: #fff0aa; background: var(--gold); box-shadow: 0 0 0 3px rgba(255,211,109,.18); }.explorer-picker i { position: relative; width: 22px; height: 20px; display: block; border: 2px solid rgba(255,255,255,.68); border-radius: 6px 6px 9px 9px; background: linear-gradient(135deg,#df783d,#ffc95c); box-shadow: inset 0 2px rgba(255,255,255,.24); }.explorer-picker i::before,.explorer-picker i::after { content:""; position:absolute; top:2px; width:7px; height:10px; border-radius:4px; background:inherit; }.explorer-picker i::before { left:-6px; transform:rotate(28deg); }.explorer-picker i::after { right:-6px; transform:rotate(-28deg); }.explorer-picker [data-explorer-theme="mint"] i { background: linear-gradient(135deg,#278d79,#8be4bf); }.explorer-picker [data-explorer-theme="sky"] i { background: linear-gradient(135deg,#3979aa,#8fd4ee); }
.primary-button { min-height: 50px; padding: 0 22px; border: 0; border-radius: 16px; color: #29301f; background: var(--gold); box-shadow: 0 10px 22px rgba(0,0,0,.24); cursor: pointer; font-weight: 950; }
.primary-button:hover { filter: brightness(1.08); transform: translateY(-1px); }

.round-panel { position: relative; z-index: 20; padding: 16px clamp(16px,3vw,30px) 22px; border-top: 1px solid rgba(255,255,255,.12); background: linear-gradient(#112c23,#0a211a); }
.round-heading-row { display: grid; grid-template-columns: minmax(280px,1fr) minmax(280px,.85fr); gap: 14px; margin-bottom: 13px; }
.clue-callout, .known-clues, .card-table-header, .card-table-wrap { border: 1px solid var(--line); border-radius: 24px; background: rgba(255,255,255,.055); box-shadow: inset 0 1px rgba(255,255,255,.07); }
.clue-callout { padding: 13px 18px; }
.clue-giver, .presenter-label { color: var(--mint); font-size: .7rem; font-weight: 950; letter-spacing: .1em; text-transform: uppercase; }
.clue-callout > div { display: flex; align-items: center; gap: 12px; margin-top: 8px; }
.clue-callout h2 { margin: 0; color: var(--gold); font-family: Georgia,serif; font-size: clamp(1.45rem,3vw,2.2rem); }
.clue-icon { width: 44px; height: 44px; display: grid; place-items: center; border-radius: 14px; color: #304022; background: var(--gold); font-size: 1.3rem; }
.clue-callout p { margin: 6px 0 0; color: var(--muted); font-weight: 800; }
.known-clues { display: grid; align-content: center; gap: 8px; padding: 13px 18px; }
.known-clues > span { color: #9db0a6; font-size: .7rem; font-weight: 950; letter-spacing: .1em; text-transform: uppercase; }
#known-clues-list { display: flex; flex-wrap: wrap; gap: 8px; }
.known-clue-chip { display: inline-flex; align-items: center; gap: 7px; padding: 8px 11px; border: 1px solid rgba(255,255,255,.13); border-radius: 999px; background: rgba(255,255,255,.07); font-weight: 900; }
.known-clue-chip.is-new { color: #2c3723; background: var(--gold); animation: clue-arrive .42s cubic-bezier(.2,.9,.3,1.15); }
#known-clues-list.is-reminding .known-clue-chip { animation: clue-remind .8s ease; }
.card-launcher { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 18px; padding: 13px 17px; border: 1px solid var(--line); border-radius: 22px; background: rgba(255,255,255,.055); }
.card-launcher h3 { margin: 3px 0 2px; font-family: Georgia,serif; font-size: clamp(1.15rem,2.4vw,1.7rem); }.card-launcher p { margin: 0; color: var(--muted); font-size: .8rem; }
.mini-card-stack { position: relative; width: 77px; height: 58px; }.mini-card-stack i { position: absolute; left: 22px; top: 4px; width: 42px; height: 54px; border: 3px solid #f5ecd8; border-radius: 8px; background: repeating-linear-gradient(45deg,#59478f 0 6px,#8069b8 6px 12px); box-shadow: 0 5px 11px rgba(0,0,0,.28); }.mini-card-stack i:first-child { left: 3px; transform: rotate(-14deg); }.mini-card-stack i:last-child { left: 40px; transform: rotate(14deg); }
.open-cards-button { min-width: 190px; }
.card-legend { display: flex; flex-wrap: wrap; justify-content: end; gap: 9px; }
.card-legend span { display: flex; align-items: center; gap: 5px; font-size: .7rem; font-weight: 850; }
.card-legend i { width: 22px; height: 28px; display: inline-block; border: 2px solid rgba(255,255,255,.5); border-radius: 5px; background: #f6f0db; }
.card-legend .legend-back { background: repeating-linear-gradient(45deg,#644e9c 0 5px,#8069b8 5px 10px); }
.card-legend .legend-cover { transform: rotate(-10deg); box-shadow: 8px 6px 0 #59488a; }
.card-table-wrap { overflow: hidden; padding: 20px 18px 25px; background: radial-gradient(circle at 50% 20%,rgba(255,219,126,.08),transparent 45%), #17372b; }
.card-table { display: grid; grid-template-columns: repeat(5,minmax(0,1fr)); grid-auto-rows: 154px; align-items: center; min-height: 616px; padding: 6px 2%; }
.mystery-card { --dx: 0px; --dy: 0px; --rot: 0deg; --z: 2; position: relative; z-index: var(--z); width: min(126px,90%); height: 146px; justify-self: center; padding: 0; border: 0; border-radius: 16px; background: transparent; cursor: pointer; perspective: 900px; transform: translate(var(--dx),var(--dy)) rotate(var(--rot)); transition: transform .22s ease, filter .2s ease, z-index 0s; }
.mystery-card:hover { z-index: 30; transform: translate(var(--dx),calc(var(--dy) - 8px)) rotate(0) scale(1.03); }
.mystery-card.is-covered:not(.is-raised) { --z: 1; filter: brightness(.8); }
.mystery-card.is-covering { --z: 5; }
.mystery-card.is-raised { z-index: 40; filter: none; transform: translate(0,-13px) rotate(0) scale(1.06); }
.card-inner { position: absolute; inset: 0; border-radius: 16px; transform-style: preserve-3d; transition: transform .42s cubic-bezier(.2,.8,.2,1); box-shadow: 0 10px 20px rgba(0,0,0,.3); }
.mystery-card.is-face-down .card-inner { transform: rotateY(180deg); }
.card-front, .card-back { position: absolute; inset: 0; display: grid; place-items: center; overflow: hidden; border: 4px solid #f8f0dc; border-radius: 16px; backface-visibility: hidden; }
.card-front { grid-template-rows: 1fr auto; padding: 4px 5px 8px; color: #3d342e; background: linear-gradient(#fffdf5,#eee6d7); }
.card-back { transform: rotateY(180deg); background: radial-gradient(circle at center,#b09be8 0 13%,transparent 14%), repeating-linear-gradient(45deg,#59478f 0 9px,#755fac 9px 18px); box-shadow: inset 0 0 0 7px rgba(255,255,255,.12); }
.card-back::after { content: "?"; width: 52px; height: 52px; display: grid; place-items: center; border: 3px solid rgba(255,255,255,.72); border-radius: 50%; color: #fff; font-family: Georgia,serif; font-size: 2rem; }
.card-picture { width: 100%; height: 102px; display: grid; place-items: center; }
.card-picture svg { width: 100%; height: 100%; display: block; }
.card-front strong { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: .78rem; }
.card-state-badge { position: absolute; z-index: 7; right: -7px; top: -7px; min-width: 27px; height: 27px; display: grid; place-items: center; border: 2px solid #fff; border-radius: 50%; color: #342941; background: var(--gold); font-size: .66rem; font-weight: 950; box-shadow: 0 5px 12px rgba(0,0,0,.25); }
.mystery-card.is-wrong { animation: card-wrong .42s ease 2; }
.mystery-card.is-wrong .card-inner { box-shadow: 0 0 0 5px rgba(255,155,183,.3),0 12px 25px rgba(0,0,0,.3); }
.mystery-card.is-correct { animation: card-correct .65s ease; }
.mystery-card.is-correct .card-inner { box-shadow: 0 0 0 5px rgba(129,229,189,.35),0 0 35px rgba(129,229,189,.45); }

.card-drawer { position: fixed; inset: 0; z-index: 75; display: grid; place-items: center; padding: 12px; background: rgba(3,15,12,.94); backdrop-filter: blur(14px); }
.card-drawer-panel { position: relative; width: min(1050px,100%); max-height: calc(100vh - 24px); display: grid; grid-template-rows: auto auto minmax(0,1fr) auto; overflow: hidden; border: 1px solid rgba(255,255,255,.18); border-radius: 28px; background: #102b22; box-shadow: 0 30px 80px rgba(0,0,0,.5); }
.card-drawer-header { position: relative; padding: 17px 68px 10px 20px; }.card-drawer-header h2 { margin: 4px 0 3px; font-family: Georgia,serif; font-size: clamp(1.55rem,4vw,2.5rem); }.card-drawer-header p { margin: 0; color: var(--muted); }
.card-drawer .card-legend { justify-content: start; padding: 0 20px 10px; }
.card-drawer .card-table-wrap { min-height: 0; overflow: auto; border-inline: 0; border-radius: 0; padding-block: 13px 20px; }
.card-drawer .card-table { min-height: 0; grid-auto-rows: 137px; padding-block: 3px 18px; }
.card-drawer .mystery-card { height: 128px; }
.card-drawer .card-picture { height: 86px; }
.card-drawer-footer { min-height: 60px; display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 9px 18px; border-top: 1px solid var(--line); background: rgba(3,17,13,.55); }.card-drawer-footer span { color: var(--muted); font-weight: 850; }
.secondary-button { min-height: 44px; padding: 0 17px; border: 1px solid var(--line); border-radius: 13px; color: var(--ink); background: rgba(255,255,255,.08); cursor: pointer; font-weight: 900; }

.reveal-ready-panel { position: relative; z-index: 25; padding: 15px clamp(15px,3vw,30px) 22px; border-top: 1px solid rgba(255,255,255,.12); background: linear-gradient(#173d2e,#0a211a); }
.solved-theory { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 18px; padding: 18px 20px; border: 1px solid rgba(129,229,189,.35); border-radius: 24px; background: rgba(129,229,189,.08); }.theory-check { width: 52px; height: 52px; display: grid; place-items: center; border-radius: 50%; color: #173528; background: var(--mint); font-size: 1.7rem; font-weight: 950; }.solved-theory h2 { margin: 4px 0 3px; font-family: Georgia,serif; }.solved-theory p { margin: 0; color: var(--muted); }

.inspection-overlay, .walk-overlay, .finale { position: fixed; inset: 0; z-index: 70; display: grid; place-items: center; padding: 22px; overflow: auto; background: rgba(4,16,13,.9); backdrop-filter: blur(12px); }
.inspection-card { position: relative; width: min(620px,100%); padding: 27px; border: 1px solid rgba(255,255,255,.19); border-radius: 28px; background: #122f27; box-shadow: 0 28px 70px rgba(0,0,0,.42); text-align: center; }
.inspection-card h2 { margin: 7px 0 14px; font-family: Georgia,serif; font-size: clamp(1.8rem,5vw,3rem); }
.close-button { position: absolute; right: 15px; top: 13px; width: 44px; height: 44px; border: 1px solid var(--line); border-radius: 50%; color: var(--ink); background: rgba(255,255,255,.08); cursor: pointer; font-size: 1.4rem; }
.inspection-fog-view { position: relative; height: 300px; display: grid; place-items: center; overflow: hidden; margin-bottom: 15px; border: 1px solid rgba(255,255,255,.13); border-radius: 24px; background: radial-gradient(circle at center,rgba(255,218,126,.18),transparent 38%),#1a3c31; }
.inspection-secret { position: relative; z-index: 2; width: 34%; opacity: .12; filter: grayscale(1) brightness(0) invert(1) blur(24px); transition: width .3s ease,opacity .3s ease,filter .3s ease; }
.inspection-secret svg { width: 100%; display: block; }
.inspection-card[data-round="2"] .inspection-secret { width: 51%; opacity: .24; filter: grayscale(1) brightness(0) invert(1) blur(16px); }
.inspection-card[data-round="3"] .inspection-secret { width: 68%; opacity: .42; filter: grayscale(1) brightness(0) invert(1) blur(9px); }
.inspection-cloud { position: absolute; z-index: 4; border-radius: 50%; background: rgba(222,233,224,.82); filter: blur(18px); box-shadow: 0 0 55px rgba(226,235,220,.6); }
.cloud-a { left: 4%; top: 14%; width: 65%; height: 48%; }.cloud-b { right: 0; top: 30%; width: 70%; height: 45%; }.cloud-c { left: 20%; bottom: 1%; width: 65%; height: 42%; }
.inspection-card[data-round="2"] .inspection-cloud { opacity: .7; transform: scale(.92); }
.inspection-card[data-round="3"] .inspection-cloud { opacity: .4; transform: scale(.8); }
.inspection-chest-frame { position: absolute; z-index: 5; left: 50%; bottom: 10px; width: 62%; height: 38%; border: 9px solid rgba(96,55,32,.8); border-top: 0; border-radius: 0 0 24px 24px; transform: translateX(-50%); opacity: .65; }
.inspection-card > p { color: var(--muted); }
.walk-overlay { z-index: 80; align-items: start; padding-top: 116px; overflow: hidden; background: linear-gradient(rgba(4,16,13,.72),transparent 32%); backdrop-filter: none; pointer-events: none; }
.walk-message { display: grid; justify-items: center; gap: 4px; max-width: min(560px,calc(100% - 24px)); padding: 12px 22px; border: 1px solid rgba(255,255,255,.18); border-radius: 22px; background: rgba(5,31,23,.9); box-shadow: 0 14px 34px rgba(0,0,0,.32); text-align: center; }
.walk-message > span { font-size: 2rem; animation: footstep-hop .55s ease-in-out infinite alternate; }
.walk-message strong { font-family: Georgia,serif; font-size: clamp(1.2rem,3.5vw,2rem); }
.walk-message small { color: var(--muted); font-size: .78rem; }

.finale { z-index: 90; background: radial-gradient(circle at 50% 38%,rgba(255,211,109,.27),rgba(7,24,18,.97) 62%); }
.finale-card { position: relative; width: min(590px,100%); display: grid; justify-items: center; overflow: hidden; padding: 25px clamp(18px,4vw,40px) 29px; border: 1px solid rgba(255,255,255,.2); border-radius: 30px; background: rgba(19,52,40,.92); box-shadow: 0 30px 75px rgba(0,0,0,.4); text-align: center; }
.open-chest { position: relative; width: 190px; height: 90px; margin-top: 5px; border: 7px solid #5e351e; border-radius: 10px 10px 20px 20px; background: linear-gradient(90deg,#9d562c,#d69241,#9d562c); box-shadow: 0 0 45px rgba(255,211,109,.55); }
.open-chest::before { content: ""; position: absolute; left: -7px; top: -51px; width: 190px; height: 58px; border: 7px solid #5e351e; border-radius: 70px 70px 8px 8px; background: #d89446; transform: rotateX(52deg); transform-origin: bottom; }
.open-chest span { position: absolute; left: 50%; top: -18px; width: 90px; height: 54px; border-radius: 50%; background: var(--gold); filter: blur(22px); transform: translateX(-50%); }
.finale-visual { width: min(290px,62vw); margin-top: -18px; animation: reveal-pop .75s cubic-bezier(.2,.9,.25,1.2); }
.finale-visual svg { width: 100%; display: block; }
.finale h2 { margin: -5px 0 5px; color: var(--gold); font-family: Georgia,serif; font-size: clamp(2rem,6vw,3.5rem); }
.finale p { margin-bottom: 16px; color: #e2eee5; font-weight: 750; }
.surprise-faces { min-height: 34px; display: flex; align-items: center; justify-content: center; gap: 17px; margin-top: 5px; font-size: 1.55rem; }.surprise-faces strong { color: var(--gold); font-size: 1.8rem; }.finale.is-revealed .surprise-faces span:first-child { animation: surprise-left .7s cubic-bezier(.2,.9,.3,1.3); }.finale.is-revealed .surprise-faces span:last-child { animation: surprise-right .7s cubic-bezier(.2,.9,.3,1.3); }.finale.is-revealed .surprise-faces strong { animation: question-pop .7s ease both; }
.theory-recap { max-width: 470px; margin: 0 0 7px !important; padding: 8px 13px; border-radius: 999px; color: #342d20 !important; background: var(--gold); font-size: .82rem; font-weight: 950 !important; }
.panda-reaction { margin: 0 0 4px !important; color: var(--mint) !important; font-size: .82rem; font-weight: 900 !important; }
.finale.is-drumroll .finale-visual,.finale.is-drumroll .theory-recap,.finale.is-drumroll #twist-line,.finale.is-drumroll .high-five-zone,.finale.is-drumroll .reward-message,.finale.is-drumroll #next-case-button { opacity: 0; transform: scale(.72); pointer-events: none; }
.finale-visual,.theory-recap,#twist-line,.high-five-zone,.reward-message,#next-case-button { transition: opacity .35s ease,transform .45s cubic-bezier(.2,.9,.3,1.15); }
.celebration-burst { position: absolute; inset: 0; overflow: hidden; pointer-events: none; }.celebration-burst i { position: absolute; top: 44%; left: 50%; width: 13px; height: 7px; border-radius: 8px; opacity: 0; background: var(--gold); }.celebration-burst i:nth-child(2n) { background: var(--mint); }.celebration-burst i:nth-child(3n) { background: #ff8aa4; }.finale.is-revealed .celebration-burst i { animation: confetti-pop 1.15s ease-out both; }.celebration-burst i:nth-child(1) { --burst-x:-225px;--burst-y:-135px;transform:rotate(18deg); }.celebration-burst i:nth-child(2) { --burst-x:-150px;--burst-y:170px;transform:rotate(-22deg); }.celebration-burst i:nth-child(3) { --burst-x:-72px;--burst-y:-185px;transform:rotate(48deg); }.celebration-burst i:nth-child(4) { --burst-x:82px;--burst-y:-180px;transform:rotate(-38deg); }.celebration-burst i:nth-child(5) { --burst-x:165px;--burst-y:160px;transform:rotate(31deg); }.celebration-burst i:nth-child(6) { --burst-x:226px;--burst-y:-120px;transform:rotate(-18deg); }
.high-five-zone { position: relative; width: min(360px,90vw); height: 108px; display: grid; place-items: center; }
.high-five-hand { position: relative; z-index: 2; min-width: 145px; min-height: 88px; display: grid; place-items: center; border: 0; border-radius: 28px; color: #352d20; background: var(--gold); cursor: pointer; box-shadow: 0 12px 30px rgba(0,0,0,.27); animation: hand-invite 1.2s ease-in-out infinite; }
.high-five-hand span { font-size: 2.4rem; line-height: 1; }.high-five-hand strong { font-size: .85rem; }
.panda-paw { position: absolute; top: 25px; width: 58px; height: 58px; display: grid; place-items: center; border: 7px solid #f7f3e9; border-radius: 50%; color: #33313c; background: #25242d; box-shadow: 0 -12px 0 -7px #25242d,-13px -5px 0 -8px #25242d,13px -5px 0 -8px #25242d; transition: transform .5s cubic-bezier(.2,.9,.3,1.2); }
.paw-left { left: 12px; transform: rotate(22deg); }.paw-right { right: 12px; transform: rotate(-22deg); }
.high-five-zone.is-complete .paw-left { transform: translateX(93px) rotate(22deg); }.high-five-zone.is-complete .paw-right { transform: translateX(-93px) rotate(-22deg); }
.high-five-zone.is-complete .high-five-hand { animation: high-five-contact .65s ease both; }

.status-toast { position: absolute; z-index: 95; left: 50%; bottom: 12px; max-width: min(760px,calc(100% - 24px)); min-height: 38px; display: grid; place-items: center; padding: 7px 16px; border: 1px solid rgba(255,255,255,.13); border-radius: 999px; background: rgba(3,13,10,.84); transform: translateX(-50%); text-align: center; font-size: .8rem; font-weight: 850; box-shadow: 0 8px 22px rgba(0,0,0,.28); pointer-events: none; }
html[data-game-phase="forest_intro"] .status-toast { display: none; }
.card-drawer:not([hidden]) ~ .status-toast { display: none; }
.finale:not([hidden]) ~ .status-toast { opacity: 0; visibility: hidden; }
.child-hand { position: absolute; z-index: 99; left: 0; top: 0; display: grid; justify-items: center; opacity: 0; pointer-events: none; transform: translate(calc(var(--hand-x) - 18px),calc(var(--hand-y) - 10px)) rotate(-12deg); filter: drop-shadow(0 7px 8px rgba(0,0,0,.35)); transition: opacity .15s ease; }
.child-hand > span { font-size: 2.8rem; line-height: 1; }.child-hand small { padding: 2px 6px; border-radius: 999px; background: rgba(7,24,18,.86); font-size: .58rem; font-weight: 950; }
.child-hand.is-visible { opacity: 1; }.child-hand.is-tapping { transform: translate(calc(var(--hand-x) - 18px),calc(var(--hand-y) - 10px)) rotate(-12deg) scale(.82); }
.bug-hunter { margin-top: 18px; padding: 22px clamp(17px,4vw,34px); border: 1px solid rgba(255,255,255,.13); border-radius: 26px; background: rgba(12,33,27,.93); box-shadow: 0 18px 45px rgba(0,0,0,.23); }.bug-hunter h2 { margin: 5px 0 7px; font-family: Georgia,serif; }.bug-hunter > p { margin-bottom: 13px; color: var(--muted); }.bug-badge { color: var(--gold); font-size: .68rem; font-weight: 950; letter-spacing: .1em; }.feedback-panel summary { width: max-content; min-height: 44px; display: flex; align-items: center; padding: 0 15px; border: 1px solid var(--line); border-radius: 13px; background: rgba(255,255,255,.07); cursor: pointer; font-weight: 900; }.feedback-panel[open] summary { margin-bottom: 14px; }.feedback-form { display: grid; grid-template-columns: 1fr 1fr; gap: 13px; }.feedback-form label { display: grid; gap: 6px; color: #e9f1e9; font-size: .78rem; font-weight: 850; }.feedback-form textarea,.feedback-form input,.feedback-form select { width: 100%; min-height: 44px; padding: 9px 11px; border: 1px solid rgba(255,255,255,.18); border-radius: 12px; color: var(--ink); background: #0a2019; font: inherit; }.feedback-form textarea { resize: vertical; }.feedback-consent,.feedback-auto,.feedback-actions,.feedback-email-link,.privacy-note { grid-column: 1 / -1; }.feedback-consent { grid-template-columns: auto 1fr !important; align-items: start; }.feedback-consent input { width: 22px; min-height: 22px; }.feedback-auto { display: grid; gap: 4px; padding: 11px 13px; border-radius: 13px; color: #d8eee0; background: rgba(129,229,189,.08); font-size: .75rem; }.feedback-auto small { color: var(--muted); }.feedback-trap { position: absolute; left: -9999px; }.feedback-actions { display: flex; align-items: center; gap: 14px; }.feedback-actions p { margin: 0; font-size: .78rem; font-weight: 850; }.feedback-actions p[data-state="success"] { color: var(--mint); }.feedback-actions p[data-state="error"] { color: #ffb3c1; }.feedback-actions p[data-state="info"] { color: var(--gold); }.feedback-email-link { width: max-content; color: var(--mint); font-size: .78rem; }.privacy-note { margin: 0; color: #aabbb1; font-size: .7rem; }
.book-reward { display: flex; align-items: center; gap: 11px; margin: 15px 0; padding: 11px 13px; border: 1px solid rgba(255,211,109,.24); border-radius: 15px; color: #f6edcf; background: rgba(255,211,109,.08); }.book-reward span { font-size: 1.65rem; }.book-reward small { line-height: 1.45; }
.book-showcase { padding-top: 15px; border-top: 1px solid rgba(255,255,255,.1); }.book-showcase-heading { display: flex; align-items: end; justify-content: space-between; gap: 15px; margin-bottom: 11px; }.book-showcase-heading h3,.book-showcase-heading p { margin: 0; }.book-showcase-heading h3 { font-family: Georgia,serif; font-size: 1.15rem; }.book-showcase-heading p { color: var(--muted); font-size: .75rem; }.book-shelf { width: 100%; display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: clamp(10px,1.4vw,20px); }.book-shelf a { min-width: 0; display: grid; align-content: start; gap: 9px; padding: clamp(7px,1vw,12px); border: 1px solid rgba(255,255,255,.11); border-radius: 18px; color: var(--ink); background: rgba(255,255,255,.055); text-decoration: none; transition: transform .2s ease,border-color .2s ease; }.book-shelf a:hover,.book-shelf a:focus-visible { border-color: var(--gold); transform: translateY(-4px); }.book-shelf img { width: 100%; aspect-ratio: 4 / 5; display: block; object-fit: cover; border-radius: 12px; background: #fff; }.book-shelf strong { overflow: hidden; font-size: clamp(.7rem,1.05vw,.92rem); line-height: 1.25; text-align: center; text-overflow: ellipsis; white-space: nowrap; }.book-cta { min-height: 44px; width: max-content; display: inline-flex; align-items: center; margin-top: 12px; padding: 0 14px; border-radius: 12px; color: #263626; background: var(--gold); font-size: .78rem; font-weight: 950; text-decoration: none; }
.diagnostics { margin: 13px 4px 0; color: #9eafa5; font-size: .78rem; }.diagnostics summary { width: max-content; cursor: pointer; }.diagnostics pre { max-height: 260px; overflow: auto; padding: 14px; border-radius: 14px; background: #07120f; white-space: pre-wrap; }

@keyframes leaf-breathe { 50% { transform: rotate(45deg) scale(1.12); filter: brightness(1.1); } }
@keyframes twinkle { to { opacity: .3; transform: scale(.65); } }
@keyframes walker-step { to { transform: translateY(-8px) rotate(2deg); } }
@keyframes clue-arrive { from { opacity: 0; transform: translateY(9px) scale(.92); } }
@keyframes clue-remind { 0%,100% { transform: none; } 40% { transform: translateY(-4px); background: rgba(255,211,109,.2); } }
@keyframes dialogue-pop { from { opacity: .35; transform: translateY(8px) scale(.9); } }
@keyframes card-wrong { 0%,100% { transform: translate(var(--dx),var(--dy)) rotate(var(--rot)); } 35% { transform: translate(calc(var(--dx) - 7px),var(--dy)) rotate(-2deg); } 70% { transform: translate(calc(var(--dx) + 7px),var(--dy)) rotate(2deg); } }
@keyframes card-correct { 50% { transform: translate(0,-18px) scale(1.08); } }
@keyframes leaf-spin { 50% { transform: translateY(-12px) rotate(18deg); } }
@keyframes footstep-hop { to { transform: translateY(-5px) rotate(8deg); } }
@keyframes glow-friend { 50% { transform: translateY(-6px); filter: brightness(1.3); box-shadow: 0 0 36px rgba(255,211,109,.48); } }
@keyframes glow-hop { 45% { transform: translateY(-20px) scale(1.3) rotate(20deg); } }
@keyframes reveal-pop { from { opacity: 0; transform: scale(.6) rotate(-4deg); } 70% { transform: scale(1.08) rotate(2deg); } }
@keyframes surprise-left { 35% { transform: translateX(-13px) rotate(-18deg) scale(1.4); } }
@keyframes surprise-right { 35% { transform: translateX(13px) rotate(18deg) scale(1.4); } }
@keyframes question-pop { 35% { opacity: 0; transform: scale(1.8) rotate(18deg); } 100% { opacity: 0; transform: scale(.2); } }
@keyframes confetti-pop { 0% { opacity: 0; translate: 0 0; } 18% { opacity: 1; } 100% { opacity: 0; translate: var(--burst-x) var(--burst-y); rotate: 360deg; } }
@keyframes hand-invite { 50% { transform: translateY(-5px); box-shadow: 0 17px 34px rgba(0,0,0,.28),0 0 0 9px rgba(255,211,109,.09); } }
@keyframes high-five-contact { 45% { transform: scale(.88); } 75% { transform: scale(1.08); box-shadow: 0 0 45px rgba(255,211,109,.75); } }
@keyframes chest-ready { to { filter: brightness(1.28) drop-shadow(0 0 24px rgba(255,211,109,.7)); } }

@media (max-width: 900px) {
  .journey-hud { padding-inline: 14px; }
  .step-track > span { min-width: 58px; }
  .forest-stage { min-height: 570px; }
  .dialogue-card { left: 15px; top: 12px; bottom: auto; width: 210px; }
  .walker-group { gap: 24px; }
  .round-heading-row { grid-template-columns: 1fr; }
  .card-launcher { grid-template-columns: auto 1fr; }.open-cards-button { grid-column: 1 / -1; width: 100%; }
  .card-table { grid-auto-rows: 140px; min-height: 560px; }
  .mystery-card { height: 132px; }
  .card-picture { height: 90px; }
}

@media (max-width: 620px) {
  .app-shell { padding: 7px; }
  .topbar { min-height: 67px; padding-inline: 3px; }
  .brand-kicker { display: none; }
  h1 { font-size: 1.48rem; }
  .topbar-actions { gap: 5px; }
  .spark-counter { padding: 0 7px; font-size: .72rem; }.icon-button,.text-button,.game-park-link { width: 44px; min-height: 44px; padding: 0; justify-content: center; }
  .game-park-link b,.music-button b { display: none; }
  .text-button { position: relative; overflow: hidden; color: transparent; }.text-button::after { content: "↻"; position: absolute; inset: 0; display: grid; place-items: center; color: var(--ink); font-size: 1.2rem; }
  .game-shell { border-radius: 23px; }
  .journey-hud { min-height: 94px; display: grid; justify-items: center; gap: 8px; padding: 8px 6px; text-align: center; }
  .journey-hud > div:first-child { justify-items: center; }
  .step-track > span { min-width: 51px; }.step-track em { font-size: .59rem; }
  .forest-stage { min-height: 520px; }
  .moon { width: 54px; height: 54px; right: 6%; }.moon::after { width: 54px; height: 54px; }
  .secret-chest { top: 9%; transform: translateX(-50%) scale(.29); }
  .forest-stage[data-round="2"] .secret-chest { top: 19%; transform: translateX(-50%) scale(.47); }
  .forest-stage[data-round="3"] .secret-chest { top: 28%; transform: translateX(-50%) scale(.72); }
  .forest-stage[data-round="4"] .secret-chest { top: 30%; transform: translateX(-50%) scale(.78); }
  .forest-road { width: 92%; }
  .walker-group { bottom: 0; gap: 8px; width: 100%; justify-content: center; }
  .forest-stage[data-round="2"] .walker-group { bottom: 88px; }.forest-stage[data-round="3"] .walker-group,.forest-stage[data-round="4"] .walker-group { bottom: 136px; }
  .walker { width: 88px; }.walker-avatar { width: 62px; height: 62px; border-width: 3px; }.walker strong { font-size: .66rem; }
  .walker strong small { font-size: .44rem; }
  .child-explorer { width: 88px; height: 108px; margin: -18px -13px -17px; transform: scale(.7); transform-origin: center bottom; }
  .walker-child:hover .child-explorer, .walker-child:focus-visible .child-explorer { transform: scale(.7) translateY(-5px) rotate(-2deg); }
  .child-explorer.is-scouting { transform: scale(.73) translateY(-7px) rotate(4deg); }
  .forest-friend { left: 72%; top: 39%; min-width: 46px; min-height: 46px; }.forest-friend small { display: none; }
  .dialogue-card { left: 7px; right: auto; top: 7px; bottom: auto; width: 142px; min-height: 68px; padding: 7px 9px; transform: none; text-align: center; }
  .dialogue-card[data-speaker="lumi"] { left: auto; right: 7px; }
  .dialogue-card[data-mode="story"] { left: 7px; right: auto; top: auto; bottom: 7px; width: 148px; min-height: 74px; padding: 8px 9px; text-align: left; }
  .dialogue-card[data-mode="reaction"] { width: min(210px,56vw); }
  .dialogue-card p { margin-top: 3px; font-size: .66rem; line-height: 1.22; }.dialogue-keyword { font-size: 1.35rem; }
  .child-thought { min-height: 54px; gap: 8px; padding: 7px 10px; }.child-thought span { font-size: .57rem; }.child-thought p { font-size: .68rem; line-height: 1.23; }
  .intro-panel { width: calc(100% - 18px); display: block; margin: 10px auto 14px; padding: 12px 11px 13px; text-align: center; }
  .intro-panel .intro-kicker,.intro-panel > p { display: none; }
  .intro-panel h2 { margin: 0 0 5px; font-size: 1.3rem; }
  .intro-panel .explorer-picker { gap: 5px; margin: 4px 0 7px; }
  .intro-panel .explorer-picker > span { font-size: .62rem; }
  .explorer-picker button { min-height: 44px; padding-inline: 8px; font-size: .69rem; }
  .intro-panel .primary-button { min-height: 45px; }
  .round-panel { padding: 10px 8px 58px; }
  .round-heading-row { grid-template-columns: 1fr 1fr; gap: 7px; margin-bottom: 8px; }
  .clue-callout,.known-clues { padding: 9px 8px; border-radius: 16px; }
  .clue-callout > div { justify-content: center; }.clue-callout,.known-clues { text-align: center; }.known-clues { justify-items: center; }
  .clue-callout h2 { font-size: 1.2rem; }.clue-callout p { margin-top: 3px; font-size: .68rem; }.clue-icon { width: 31px; height: 31px; border-radius: 10px; font-size: .9rem; }
  #known-clues-list { justify-content: center; }
  .known-clue-chip { padding: 6px 8px; font-size: .73rem; }
  .card-launcher { grid-template-columns: 1fr auto; gap: 8px; padding: 9px 10px; border-radius: 16px; }.mini-card-stack { display: none; }.card-launcher p { display: none; }.card-launcher h3 { font-size: 1rem; }.open-cards-button { grid-column: auto; min-width: 154px; min-height: 45px; padding-inline: 12px; }
  .card-table-header { display: grid; padding: 13px 14px; border-radius: 18px; text-align: center; }
  .card-legend { justify-content: center; }
  .card-table-wrap { padding: 14px 6px 24px; border-radius: 18px; }
  .card-table { grid-template-columns: repeat(4,minmax(0,1fr)); grid-auto-rows: 112px; min-height: 560px; padding-inline: 0; }
  .card-drawer { padding: 5px; }.card-drawer-panel { max-height: calc(100vh - 10px); border-radius: 19px; }.card-drawer-header { padding: 13px 55px 7px 13px; }.card-drawer-header h2 { font-size: 1.35rem; }.card-drawer-header p { font-size: .72rem; }.card-drawer .card-legend { padding: 0 12px 7px; }.card-drawer .card-table-wrap { border-radius: 0; padding-block: 9px 14px; }.card-drawer .card-table { grid-auto-rows: 107px; min-height: 0; }.card-drawer .mystery-card { height: 99px; }.card-drawer .card-picture { height: 67px; }.card-drawer-footer { min-height: 51px; padding: 6px 11px; font-size: .72rem; }
  .mystery-card { width: 88%; height: 105px; border-radius: 12px; }
  .card-inner,.card-front,.card-back { border-radius: 12px; }.card-front,.card-back { border-width: 3px; }
  .card-picture { height: 73px; }.card-front strong { font-size: .62rem; }.card-state-badge { width: 24px; min-width: 24px; height: 24px; font-size: .58rem; }
  .inspection-overlay,.finale { padding: 12px; }.inspection-card,.finale-card { border-radius: 23px; padding-inline: 15px; }
  .inspection-fog-view { height: 235px; }.inspection-chest-frame { width: 82%; }
  .finale-visual { width: min(200px,55vw); }.open-chest { transform: scale(.76); margin-block: -7px; }.surprise-faces { min-height: 28px; margin-top: 2px; font-size: 1.3rem; }.theory-recap { padding: 7px 10px; border-radius: 14px; font-size: .72rem; }.panda-reaction { font-size: .72rem !important; }
  .high-five-zone { transform: scale(.88); margin-block: -6px; }
  .reveal-ready-panel { padding: 9px 8px 15px; }.solved-theory { grid-template-columns: auto 1fr; gap: 10px; padding: 12px; text-align: left; }.theory-check { width: 39px; height: 39px; font-size: 1.25rem; }.solved-theory h2 { font-size: 1.18rem; }.solved-theory p { font-size: .76rem; }.open-chest-button { grid-column: 1 / -1; width: 100%; }
  .status-toast { bottom: 7px; font-size: .68rem; min-height: 34px; }
  .child-hand { display: none; }
  .walk-overlay { padding-top: 104px; }.walk-message { padding: 9px 14px; }.walk-message small { font-size: .67rem; }
  .bug-hunter { padding: 18px 14px; border-radius: 20px; }.feedback-form { grid-template-columns: 1fr; }.feedback-form > * { grid-column: 1 !important; }.feedback-actions { display: grid; }.feedback-actions .primary-button { width: 100%; }.feedback-email-link { width: auto; overflow-wrap: anywhere; }.book-showcase-heading { display: grid; gap: 3px; }.book-shelf { gap: 6px; }.book-shelf a { padding: 4px; border-radius: 10px; }.book-shelf img { border-radius: 7px; }.book-shelf strong { font-size: .56rem; }.book-cta { width: 100%; justify-content: center; }
}

@media (max-width: 380px) {
  .step-track > span { min-width: 47px; }
  .card-table { grid-auto-rows: 105px; min-height: 525px; }
  .card-drawer .card-table { min-height: 0; }
  .mystery-card { height: 99px; }.card-picture { height: 68px; }
}

@media (prefers-reduced-motion: reduce) {
  *,*::before,*::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
  .child-hand { display: none; }
}
