/* Kiki's Jungle Journey — styles. Loads after gamekit.css.
   Palette: deep emerald + ruin-stone grey-green + orchid magenta + firefly-gold
   dusk. Distinct from every other game in the suite. */

:root {
    --jj-deep: #0A281C;
    --jj-emerald: #0F3A28;
    --jj-leaf: #175538;
    --jj-stone: #6A8571;
    --jj-stone-l: #8FA995;
    --jj-orchid: #C93D93;
    --jj-orchid-l: #E96CB8;
    --jj-gold: #FFC94A;
    --jj-gold-hi: #FFE9A8;
    --jj-cream: #FFF7E2;
    --jj-ink: #1C3A2E;
    --jj-font: 'Comic Sans MS', 'Chalkboard SE', 'Baloo 2', 'Segoe UI', Arial, sans-serif;
}

body { font-family: var(--jj-font); background: var(--jj-deep); overflow: hidden; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

#app { position: fixed; inset: 0; overflow: hidden; }
#app > section { position: absolute; inset: 0; overflow: hidden; z-index: 5; }
.gk-hidden { display: none !important; }

.scene-svg { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }

/* ── shared art animation classes (referenced from art.js) ── */
.jj-sway { animation: jj-sway 4.5s ease-in-out infinite; }
.jj-sway-slow { animation: jj-sway 7s ease-in-out infinite; }
@keyframes jj-sway { 0%, 100% { transform: rotate(-2deg); } 50% { transform: rotate(2.4deg); } }
.jj-twinkle { animation: jj-twinkle 2.6s ease-in-out infinite; }
@keyframes jj-twinkle { 0%, 100% { opacity: 1; } 50% { opacity: 0.15; } }
.jj-drift { animation: jj-drift 11s ease-in-out infinite; }
.jj-drift-slow { animation: jj-drift 17s ease-in-out infinite; }
@keyframes jj-drift { 0%, 100% { transform: translateX(-14px); } 50% { transform: translateX(16px); } }
.jj-shimmer { animation: jj-shimmer 3.2s ease-in-out infinite; }
@keyframes jj-shimmer { 0%, 100% { opacity: 0.25; transform: translateX(0); } 50% { opacity: 0.7; transform: translateX(9px); } }
.jj-fall { animation: jj-fall 1.1s linear infinite; }
@keyframes jj-fall { from { stroke-dashoffset: 0; } to { stroke-dashoffset: -66; } }
.jj-shaft { animation: jj-shaft 7s ease-in-out infinite; opacity: 0.16; }
@keyframes jj-shaft { 0%, 100% { opacity: 0.08; } 50% { opacity: 0.24; } }
.jj-moth { animation: jj-moth 5.5s ease-in-out infinite; }
@keyframes jj-moth {
    0%, 100% { transform: translate(0, 0); }
    25% { transform: translate(9px, -12px); }
    50% { transform: translate(-6px, -18px); }
    75% { transform: translate(-11px, -6px); }
}
.jj-bob-slow { animation: jj-bob 4.2s ease-in-out infinite; }
@keyframes jj-bob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-7px); } }
.jj-boing-slow { animation: jj-boing 3.4s ease-in-out infinite; }
@keyframes jj-boing { 0%, 100% { transform: scaleY(1); } 50% { transform: scaleY(0.965) translateY(4px); } }
.jj-breathe { animation: jj-breathe 3.6s ease-in-out infinite; }
@keyframes jj-breathe { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.035); } }
.jj-zz { animation: jj-zz 2.6s ease-in-out infinite; opacity: 0; }
@keyframes jj-zz { 0% { opacity: 0; transform: translateY(0); } 30% { opacity: 0.9; } 100% { opacity: 0; transform: translateY(-13px); } }
.jj-ring { animation: jj-ring 2.8s ease-in-out infinite; opacity: 0; transform-origin: center; }
@keyframes jj-ring { 0% { opacity: 0; transform: scale(0.7); } 35% { opacity: 0.9; } 100% { opacity: 0; transform: scale(1.35); } }
.jj-glow-pulse { animation: jj-glowp 2.6s ease-in-out infinite; }
@keyframes jj-glowp { 0%, 100% { opacity: 1; } 50% { opacity: 0.45; } }
.jj-feather { animation: jj-feather 6s ease-in-out infinite; }
@keyframes jj-feather { 0%, 100% { transform: translateY(0) rotate(0); } 50% { transform: translateY(26px) rotate(14deg); } }
.jj-fount { animation: jj-fount 2.4s ease-in-out infinite; transform-origin: center bottom; }
@keyframes jj-fount { 0%, 100% { transform: scaleY(0.9); } 50% { transform: scaleY(1.08); } }

/* ── character rigs ── */
.jj-char-in { animation: jj-char-in 0.55s cubic-bezier(0.2, 1.3, 0.4, 1) both; }
@keyframes jj-char-in { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: translateY(0); } }
.jj-k-eye { animation: jj-blink 4.4s infinite; transform-origin: center; }
@keyframes jj-blink { 0%, 93%, 100% { transform: scaleY(1); } 95.5%, 97% { transform: scaleY(0.1); } }
.jj-k-tail { animation: jj-tail 3.2s ease-in-out infinite; }
@keyframes jj-tail { 0%, 100% { transform: rotate(-4deg); } 50% { transform: rotate(5deg); } }
.jj-k-arm { animation: jj-armp 1.7s ease-in-out infinite; }
@keyframes jj-armp { 0%, 100% { transform: rotate(0); } 50% { transform: rotate(-7deg); } }
.jj-r-wing { animation: jj-wing 1.5s ease-in-out infinite; }
@keyframes jj-wing { 0%, 100% { transform: rotate(0); } 50% { transform: rotate(-9deg); } }
.jj-g-eyes { animation: jj-geyes 3.2s ease-in-out infinite; }
@keyframes jj-geyes { 0%, 100% { opacity: 1; } 50% { opacity: 0.55; } }
.jj-purr-line { animation: jj-purrl 1.2s ease-in-out infinite; }
@keyframes jj-purrl { 0%, 100% { opacity: 0.25; } 50% { opacity: 1; } }

/* the talking character wiggles while its line plays */
.char-slot.talking svg { animation: jj-talk 0.62s ease-in-out infinite; }
@keyframes jj-talk { 0%, 100% { transform: rotate(-1.6deg); } 50% { transform: rotate(1.8deg) translateY(-3px); } }
/* tap reaction */
.char-slot.reacting svg { animation: jj-react 0.55s cubic-bezier(0.2, 1.6, 0.4, 1); }
@keyframes jj-react { 0% { transform: scale(1); } 40% { transform: scale(1.14) rotate(-3deg); } 100% { transform: scale(1); } }

/* ══════════════════════════════════════════════════════════════
   TITLE
   ══════════════════════════════════════════════════════════════ */
#screen-title { display: flex; flex-direction: column; align-items: center; }
#title-bg { position: absolute; inset: 0; pointer-events: none; }
#title-head { margin-top: max(clamp(64px, 9vh, 92px), calc(var(--gk-hud-clear-top) + 8px)); text-align: center; z-index: 6; pointer-events: none; max-width: 94vw; }
#title-word {
    font-size: clamp(2rem, 7.4vw, 4.2rem); font-weight: 800; color: var(--jj-gold-hi); line-height: 1.04;
    text-shadow: 0 0 22px rgba(255, 201, 74, 0.45), 0 4px 0 #8A5E1E, 0 7px 16px rgba(0, 0, 0, 0.5);
    animation: jj-title-bob 5.5s ease-in-out infinite;
}
#title-sub { font-size: clamp(1rem, 3.6vw, 1.6rem); color: var(--jj-orchid-l); margin-top: 6px; font-weight: 700; text-shadow: 0 2px 8px rgba(0, 0, 0, 0.55); }
@keyframes jj-title-bob { 0%, 100% { transform: translateY(0) rotate(-0.6deg); } 50% { transform: translateY(-7px) rotate(0.6deg); } }

#title-cast { position: absolute; inset: 0; z-index: 5; pointer-events: none; }
#title-cast > div { pointer-events: auto; cursor: pointer; }
#title-guardian { position: absolute; left: 50%; bottom: 30%; transform: translateX(-50%); width: clamp(190px, 34vw, 320px); }
#title-guardian svg { width: 100%; height: auto; display: block; overflow: visible; }
#title-kiki { position: absolute; left: 10%; bottom: 27%; width: clamp(104px, 17vw, 168px); }
#title-kiki svg { width: 100%; height: auto; }
#title-rojo { position: absolute; right: 9%; bottom: 30%; width: clamp(86px, 14vw, 140px); }
#title-rojo svg { width: 100%; height: auto; }
#title-paz { position: absolute; right: 2%; top: 30%; width: clamp(84px, 13vw, 130px); }
#title-paz svg { width: 100%; height: auto; }
/* golden-bonus state: the stone jaguar stretches like a cat and purrs */
#title-guardian.golden { filter: drop-shadow(0 0 22px rgba(255, 201, 74, 0.75)); }
#title-guardian.golden .jj-char-in { animation: none; }
#title-guardian.stretching svg { animation: jj-stretch 2.6s ease-in-out; transform-origin: 50% 90%; }
@keyframes jj-stretch {
    0% { transform: scale(1, 1); }
    30% { transform: scale(1.1, 0.86) translateY(4%); }
    60% { transform: scale(0.94, 1.1) translateY(-3%); }
    80% { transform: scale(1.04, 0.97); }
    100% { transform: scale(1, 1); }
}

#btn-begin {
    position: absolute; left: 50%; bottom: clamp(88px, 16vh, 132px); transform: translateX(-50%); z-index: 8;
    min-height: 76px; padding: 16px 44px; border: 4px solid #7A4E14; border-radius: 50px; white-space: nowrap;
    background: linear-gradient(180deg, var(--jj-gold-hi), var(--jj-gold)); color: #4E3008;
    font-family: inherit; font-size: clamp(1.3rem, 5vw, 1.8rem); font-weight: 800; cursor: pointer;
    box-shadow: 0 10px 26px rgba(0, 0, 0, 0.45), 0 0 30px rgba(255, 201, 74, 0.35);
    animation: jj-begin-pulse 1.7s ease-in-out infinite;
}
@keyframes jj-begin-pulse { 0%, 100% { transform: translateX(-50%) scale(1); } 50% { transform: translateX(-50%) scale(1.06); } }
#btn-begin:active { transform: translateX(-50%) scale(0.95); }

/* bottom strip: room reserved on the left for the round ℹ️ button */
#title-stickers {
    position: absolute; left: var(--gk-corner-clear); right: 12px; bottom: 16px; z-index: 7;
    display: flex; justify-content: center; pointer-events: none;
}
#sticker-pill {
    display: flex; gap: 7px; align-items: center; padding: 7px 12px; border-radius: 18px;
    background: rgba(8, 30, 22, 0.62); backdrop-filter: blur(3px);
}
.mini-sticker { width: clamp(30px, 7vw, 44px); }
.mini-sticker svg { width: 100%; height: auto; display: block; }
.mini-sticker.unowned { opacity: 0.6; }
.mini-q {
    width: clamp(30px, 7vw, 44px); aspect-ratio: 100 / 84; border-radius: 8px;
    display: flex; align-items: center; justify-content: center;
    background: rgba(255, 247, 226, 0.14); border: 2px dashed rgba(255, 233, 168, 0.4);
    color: var(--jj-gold-hi); font-weight: 800; font-size: clamp(0.85rem, 2.6vw, 1.15rem);
}

#btn-book {
    position: absolute; left: 14px; top: 14px; width: 64px; height: 64px; border: none; border-radius: 20px;
    background: rgba(255, 247, 226, 0.94); font-size: 1.9rem; cursor: pointer; z-index: 8;
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.4); transition: transform 0.15s;
}
#btn-book:active { transform: scale(0.92); }

#info-btn {
    position: absolute; left: var(--gk-corner-inset); bottom: var(--gk-corner-inset); z-index: 8;
    width: var(--gk-corner-btn); height: var(--gk-corner-btn); border: none; border-radius: 50%;
    background: rgba(255, 247, 226, 0.92); font-size: 1.5rem;
    cursor: pointer; box-shadow: 0 6px 16px rgba(0, 0, 0, 0.4);
}
#info-btn:active { transform: scale(0.92); }

/* ══════════════════════════════════════════════════════════════
   STORY STAGE
   ══════════════════════════════════════════════════════════════ */
#scene-bg { position: absolute; inset: 0; z-index: 1; pointer-events: none; }
#scene-cast { position: absolute; inset: 0; z-index: 3; pointer-events: none; }
#beat-layer { position: absolute; inset: 0; z-index: 8; pointer-events: none; }
#beat-layer > * { pointer-events: auto; }

.char-slot {
    position: absolute; transform: translate(-50%, -50%) scale(var(--s, 1));
    transform-origin: center bottom; will-change: transform; pointer-events: auto; cursor: pointer;
    border: none; background: none; padding: 0;
}
.char-slot svg { width: 100%; height: auto; display: block; overflow: visible; }
.char-kiki { width: clamp(108px, 17vw, 172px); animation: jj-slot-bob 3.4s ease-in-out infinite; }
.char-rojo { width: clamp(88px, 14vw, 140px); animation: jj-slot-bob 2.9s ease-in-out infinite; }
.char-paz { width: clamp(96px, 15vw, 150px); animation: jj-slot-bob 5s ease-in-out infinite; }
.char-guardian { width: clamp(150px, 25vw, 250px); animation: jj-slot-bob 6s ease-in-out infinite; }
@keyframes jj-slot-bob { 0%, 100% { transform: translate(-50%, -50%) scale(var(--s, 1)); } 50% { transform: translate(-50%, calc(-50% - 7px)) scale(var(--s, 1)); } }

/* Paz peeking in from the edge — always one scene behind */
#paz-peek {
    position: absolute; left: 0; bottom: 24%; z-index: 4; width: clamp(52px, 9vw, 76px);
    border: none; background: none; padding: 0; cursor: pointer;
    animation: jj-peek-in 1.2s ease-out 2s both;
}
#paz-peek svg { width: 100%; height: auto; display: block; }
@keyframes jj-peek-in { from { transform: translateX(-9px); opacity: 0; } to { transform: translateX(0); opacity: 1; } }

#chapter-badge {
    position: absolute; left: 12px; top: var(--gk-hud-inset-top); z-index: 9;
    background: rgba(8, 30, 22, 0.68); color: var(--jj-gold-hi); font-weight: 800;
    font-size: clamp(0.8rem, 2.6vw, 1rem); padding: 8px 14px; border-radius: 999px;
    border: 2px solid rgba(255, 201, 74, 0.4); pointer-events: none;
}

/* leaf page-wipe */
#leaf-wipe { position: absolute; inset: 0; z-index: 20; pointer-events: none; opacity: 0; }
#leaf-wipe.go { animation: jj-wipe-fade 0.62s ease-out; }
#leaf-wipe.go::before {
    content: ''; position: absolute; inset: -4%;
    background:
        radial-gradient(ellipse 24% 34% at 12% 22%, #237048 96%, transparent),
        radial-gradient(ellipse 26% 36% at 34% 66%, #175538 96%, transparent),
        radial-gradient(ellipse 24% 34% at 56% 28%, #2E7D4C 96%, transparent),
        radial-gradient(ellipse 26% 38% at 78% 62%, #1C5A3C 96%, transparent),
        radial-gradient(ellipse 24% 34% at 94% 24%, #237048 96%, transparent),
        radial-gradient(ellipse 30% 40% at 24% 90%, #123D2C 96%, transparent),
        radial-gradient(ellipse 30% 40% at 70% 94%, #123D2C 96%, transparent),
        linear-gradient(100deg, #0F3A28 30%, #175538 70%);
    animation: jj-wipe-move 0.62s ease-in-out;
}
@keyframes jj-wipe-fade { 0% { opacity: 1; } 70% { opacity: 1; } 100% { opacity: 0; } }
@keyframes jj-wipe-move { from { transform: translateX(-112%) rotate(2deg); } to { transform: translateX(112%) rotate(-2deg); } }

/* ── narration panel ── */
#narration {
    position: absolute; left: 50%; bottom: clamp(10px, 3vh, 30px); transform: translateX(-50%);
    width: min(90vw, 700px); background: linear-gradient(180deg, #FFFDF4, #F5EBD0);
    border: 3px solid var(--jj-ink); border-radius: 24px; padding: 12px 16px 14px;
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.4); z-index: 10;
    animation: jj-narr-in 0.4s cubic-bezier(0.2, 1.3, 0.4, 1);
}
@keyframes jj-narr-in { from { transform: translateX(-50%) translateY(20px); opacity: 0; } to { transform: translateX(-50%) translateY(0); opacity: 1; } }
#narr-top { display: flex; align-items: center; gap: 10px; margin-bottom: 4px; }
#speaker-chip {
    flex: none; color: #fff; font-weight: 800; font-size: clamp(0.8rem, 2.6vw, 0.95rem);
    padding: 4px 13px; border-radius: 999px; background: var(--jj-leaf);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.25);
}
#ear-btn {
    flex: none; margin-left: auto; width: 48px; height: 48px; border: none; border-radius: 50%;
    background: var(--jj-orchid-l); font-size: 1.4rem; cursor: pointer;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.25); animation: jj-ear 2.4s ease-in-out infinite;
}
@keyframes jj-ear { 0%, 100% { transform: scale(1) rotate(-4deg); } 50% { transform: scale(1.07) rotate(4deg); } }
#narr-text { font-size: clamp(1.02rem, 3vw, 1.32rem); color: var(--jj-ink); font-weight: 700; line-height: 1.42; }
/* compact mode while choices are on stage: two-line recap, choices own the screen */
#narration.compact #narr-text {
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
    overflow: hidden; font-size: clamp(0.88rem, 2.6vw, 1.05rem); line-height: 1.35;
}
.wg { transition: color 0.2s, transform 0.2s; display: inline-block; margin-right: 0.34em; transform-origin: center bottom; }
.wg.on { color: var(--jj-orchid); transform: scale(1.06); }

/* ── the big ▶ page-turn button ── */
#btn-next {
    position: absolute; right: clamp(12px, 3.4vw, 40px); bottom: clamp(118px, 22vh, 190px);
    width: 88px; height: 88px; border: 3px solid var(--jj-ink); border-radius: 50%;
    background: radial-gradient(circle at 40% 35%, var(--jj-gold-hi), var(--jj-gold)); cursor: pointer;
    box-shadow: 0 8px 20px rgba(255, 201, 74, 0.45); z-index: 11;
    animation: jj-next-pulse 1.3s ease-in-out infinite;
    display: flex; align-items: center; justify-content: center;
}
#btn-next svg { width: 56%; height: 56%; }
@keyframes jj-next-pulse { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.1); box-shadow: 0 8px 30px rgba(255, 201, 74, 0.75); } }
#btn-next:active { transform: scale(0.92); }

/* ── choices ── */
#choose-banner {
    position: absolute; left: 50%; top: max(clamp(10px, 3.4vh, 34px), var(--gk-hud-clear-top)); transform: translateX(-50%);
    background: linear-gradient(180deg, var(--jj-gold-hi), var(--jj-gold)); color: #4E3008;
    font-size: clamp(1.15rem, 4.4vw, 1.8rem); font-weight: 800; padding: 10px 30px;
    border: 3px solid var(--jj-ink); border-radius: 22px; box-shadow: 0 8px 20px rgba(0, 0, 0, 0.35);
    animation: jj-boing-in 0.6s cubic-bezier(0.2, 1.7, 0.4, 1); white-space: nowrap; z-index: 9;
}
@keyframes jj-boing-in { 0% { transform: translateX(-50%) translateY(-70px) scale(0.6); } 60% { transform: translateX(-50%) translateY(6px) scale(1.08); } 100% { transform: translateX(-50%) translateY(0) scale(1); } }

#choice-col {
    position: absolute; left: 50%; transform: translateX(-50%);
    top: calc(max(clamp(10px, 3.4vh, 34px), var(--gk-hud-clear-top)) + clamp(52px, 8vh, 66px));
    bottom: clamp(104px, 20vh, 170px);
    width: min(92vw, 560px); z-index: 9;
    display: flex; flex-direction: column; gap: clamp(8px, 1.8vh, 16px);
    justify-content: center; justify-content: safe center;
    overflow-y: auto; overscroll-behavior: contain;
}
.choice-btn {
    min-height: 88px; width: 100%; flex: none;
    display: flex; align-items: center; gap: 14px; padding: 10px 18px 10px 12px;
    background: linear-gradient(180deg, #FFFDF4, #EFE4C6); border: 4px solid var(--jj-ink);
    border-radius: 26px; cursor: pointer; text-align: left;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.35); transition: transform 0.25s, opacity 0.35s;
    animation: jj-choice-in 0.5s cubic-bezier(0.2, 1.4, 0.4, 1) both;
}
@keyframes jj-choice-in { from { opacity: 0; transform: translateY(24px) scale(0.92); } to { opacity: 1; transform: translateY(0) scale(1); } }
.choice-art { flex: none; width: clamp(56px, 9vw, 72px); }
.choice-art svg { width: 100%; height: auto; display: block; }
.choice-label { font-size: clamp(1.05rem, 3.6vw, 1.4rem); font-weight: 800; color: var(--jj-ink); line-height: 1.2; }
.choice-btn.wiggle { animation: jj-cardwig 0.6s ease-in-out; }
@keyframes jj-cardwig { 0%, 100% { transform: rotate(0); } 25% { transform: rotate(-1.6deg) scale(1.02); } 75% { transform: rotate(1.6deg) scale(1.02); } }
.choice-btn.faded { opacity: 0.15; transform: scale(0.9); pointer-events: none; }
.choice-btn.picked { border-color: var(--jj-gold); box-shadow: 0 10px 26px rgba(255, 201, 74, 0.55); transform: scale(1.04); }
.choice-btn:active { transform: scale(0.97); }

/* ── how-to coach (first run only) ── */
#howto-layer {
    position: absolute; inset: 0; z-index: 30; background: rgba(8, 30, 22, 0.55);
    border: none; padding: 0; cursor: pointer; font-family: inherit;
    display: flex; align-items: flex-end; justify-content: flex-end;
}
#howto-card {
    margin: 0 clamp(110px, 20vw, 170px) clamp(120px, 24vh, 200px) 16px;
    max-width: 320px; background: var(--jj-cream); color: var(--jj-ink);
    border: 3px solid var(--jj-ink); border-radius: 22px; padding: 14px 18px;
    font-size: clamp(1rem, 3.2vw, 1.2rem); font-weight: 700; line-height: 1.4; text-align: left;
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.45);
    animation: jj-narr-in 0.4s cubic-bezier(0.2, 1.3, 0.4, 1);
}
#howto-hand {
    position: absolute; right: clamp(20px, 4.4vw, 52px); bottom: clamp(96px, 19vh, 168px);
    font-size: 2.6rem; pointer-events: none; animation: jj-hand 1.1s ease-in-out infinite;
}
@keyframes jj-hand { 0%, 100% { transform: translate(0, 0); } 50% { transform: translate(-8px, -10px); } }

/* ── whole-map moment ── */
#map-moment {
    position: absolute; inset: 0; z-index: 26; display: flex; align-items: center; justify-content: center;
    background: rgba(8, 30, 22, 0.6); animation: gk-fade-in 0.35s ease-out;
}
#map-moment .map-card {
    background: var(--jj-cream); border: 4px solid var(--jj-ink); border-radius: 26px;
    padding: 18px 22px; text-align: center; max-width: min(90vw, 420px);
    box-shadow: 0 18px 44px rgba(0, 0, 0, 0.5);
    animation: jj-boing-in2 0.6s cubic-bezier(0.2, 1.6, 0.4, 1);
}
@keyframes jj-boing-in2 { 0% { transform: scale(0.5); opacity: 0; } 60% { transform: scale(1.07); opacity: 1; } 100% { transform: scale(1); } }
#map-moment h3 { color: var(--jj-orchid); font-size: clamp(1.2rem, 4.4vw, 1.6rem); margin-bottom: 6px; }
#map-moment .map-art { width: min(58vw, 240px); margin: 0 auto 6px; }
#map-moment .map-art svg { width: 100%; height: auto; }

/* ══════════════════════════════════════════════════════════════
   STICKER BOOK
   ══════════════════════════════════════════════════════════════ */
#screen-book { display: flex; align-items: center; justify-content: center; }
#book-card {
    width: min(94vw, 680px); max-height: calc(100vh - var(--gk-hud-clear-top) - 12px);
    margin-top: var(--gk-hud-clear-top);
    overflow-y: auto; overscroll-behavior: contain;
    background: linear-gradient(180deg, #14402E, #0C2A1E);
    border: 5px solid #2E6B4C; border-radius: 30px; padding: clamp(14px, 3vw, 26px);
    text-align: center; box-shadow: 0 20px 50px rgba(0, 0, 0, 0.55);
}
#book-card h2 { color: var(--jj-gold-hi); font-size: clamp(1.3rem, 4.8vw, 1.9rem); margin-bottom: 4px; text-shadow: 0 0 14px rgba(255, 201, 74, 0.35); }
#book-sub { color: #BFD8C4; font-size: clamp(0.9rem, 2.8vw, 1.05rem); margin-bottom: 12px; }
#book-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(8px, 2vw, 16px); margin-bottom: 14px; }
@media (max-width: 460px) { #book-grid { grid-template-columns: repeat(2, 1fr); } }
.book-slot { background: rgba(8, 30, 22, 0.7); border: 3px solid #2E5A42; border-radius: 20px; padding: 8px; }
.book-slot.owned { border-color: var(--jj-gold); box-shadow: inset 0 0 20px rgba(255, 201, 74, 0.18); }
.book-slot .slot-art { width: 100%; }
.book-slot .slot-art svg { width: 100%; height: auto; display: block; }
.slot-name { margin-top: 6px; color: var(--jj-cream); font-weight: 700; font-size: clamp(0.82rem, 2.5vw, 1.02rem); }
.book-slot.unowned .slot-name { color: #7FA189; }
.book-slot.stamp { animation: jj-stamp 0.7s cubic-bezier(0.2, 1.8, 0.4, 1); }
@keyframes jj-stamp { 0% { transform: scale(2) rotate(-7deg); opacity: 0; } 55% { transform: scale(0.92) rotate(3deg); opacity: 1; } 100% { transform: scale(1) rotate(0); } }
#book-golden {
    margin: 2px auto 12px; padding: 9px 16px; border-radius: 16px; max-width: 480px;
    background: rgba(255, 201, 74, 0.14); border: 2px solid rgba(255, 201, 74, 0.5);
    color: var(--jj-gold-hi); font-weight: 700; font-size: clamp(0.9rem, 2.8vw, 1.05rem);
}
#book-actions { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }

/* ══════════════════════════════════════════════════════════════
   GROWN-UPS
   ══════════════════════════════════════════════════════════════ */
#info-overlay { position: fixed; inset: 0; z-index: 930; background: rgba(8, 24, 18, 0.65); display: flex; align-items: center; justify-content: center; animation: gk-fade-in 0.25s; }
#info-card { position: relative; width: min(92vw, 520px); max-height: 90vh; overflow-y: auto; text-align: left; background: #FFFDF4; }
#info-card h2 { color: var(--jj-leaf); margin-bottom: 8px; padding-right: 54px; }
#info-card p { color: var(--jj-ink); line-height: 1.5; margin-bottom: 6px; }
.info-block { margin-top: 14px; padding-top: 12px; border-top: 2px dashed #D8E4CE; }
.info-block h3 { color: var(--jj-orchid); font-size: 1.05rem; margin-bottom: 4px; }
#info-close { position: absolute; right: 12px; top: 12px; width: 50px; height: 50px; border: none; border-radius: 50%; background: #E8F0DC; font-size: 1.2rem; cursor: pointer; }

/* ══════════════════════════════════════════════════════════════
   REDUCED MOTION — everything settles to its rest pose at once
   ══════════════════════════════════════════════════════════════ */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        animation-delay: 0s !important;
        transition-duration: 0.01ms !important;
    }
}

/* small phones: tuck the panel + next button a little tighter */
@media (max-height: 620px) {
    #narration { bottom: 8px; padding: 9px 12px 11px; }
    #btn-next { width: 74px; height: 74px; bottom: 108px; }
    #choice-col { bottom: 96px; }
    #howto-card { margin-bottom: 104px; }
}
