:root {
  color-scheme:light;
  --ink:#172443; --muted:#52617e; --paper:#f2f5ff; --line:#dce3f4;
  --blue:#4356dd; --blue-dark:#2c3eae; --coral:#ce402a; --gold:#f6c865;
  font-family:ui-rounded,'Avenir Next','Segoe UI',system-ui,sans-serif;
  font-size:17px; font-synthesis:none;
}
*{box-sizing:border-box}
body{margin:0;background:radial-gradient(ellipse at 85% 15%,#dce9ff 0,transparent 38%),radial-gradient(ellipse at 5% 55%,#e7e5ff 0,transparent 36%),var(--paper);color:var(--ink);padding:env(safe-area-inset-top) env(safe-area-inset-right) env(safe-area-inset-bottom) env(safe-area-inset-left)}
button,a,audio{-webkit-tap-highlight-color:transparent}button,a{touch-action:manipulation}button{font:inherit;cursor:pointer}a{color:inherit;text-underline-offset:5px}
button:focus-visible,a:focus-visible,canvas:focus-visible,input:focus-visible{outline:3px solid #b43a22;outline-offset:5px}
button:disabled{opacity:.55;cursor:default}[hidden]{display:none!important}
p{line-height:1.7}h1,h2{font-family:inherit;font-weight:850}h1{font-size:clamp(2.4rem,5vw,4.5rem);line-height:1.06;letter-spacing:-.055em;margin:22px 0}h1 em{font-style:normal;color:var(--blue)}h2{font-size:1.8rem;line-height:1.16;letter-spacing:-.035em}
.site-header{max-width:1280px;margin:auto;padding:26px 38px;display:flex;align-items:center;justify-content:space-between;gap:24px}
.brand{display:flex;align-items:center;gap:12px;text-decoration:none;font-size:1.45rem;font-weight:850;letter-spacing:-.045em;line-height:1.1}
.brand-star{display:grid;place-items:center;flex-shrink:0;width:48px;height:48px;border-radius:16px;background:linear-gradient(140deg,#586cef,#304bc0);color:white;font-size:2.2rem;box-shadow:0 8px 18px #3f53b92b;transform:rotate(-7deg)}
.brand small{display:block;font-size:.58rem;font-weight:750;letter-spacing:.13em;margin-top:7px;color:var(--muted)}
nav{display:flex;gap:7px;background:#ffffffa6;border:1px solid #fff;border-radius:999px;padding:5px;box-shadow:0 5px 18px #243d7210}
nav a{display:inline-flex;align-items:center;justify-content:center;min-height:44px;text-decoration:none;font-size:.9rem;font-weight:750;padding:10px 19px;border-radius:999px}
nav a:hover{background:#e7edff}nav a[aria-current]{background:var(--ink);color:white}
main{max-width:1280px;margin:auto;min-height:65vh}main:focus{outline:none}
.eyebrow{font-size:.75rem;font-weight:800;letter-spacing:.11em;line-height:1.5;color:var(--blue)}
.hero{display:grid;grid-template-columns:1.15fr .85fr;gap:34px;margin:16px 38px 0;align-items:stretch}
.hero-copy{padding:34px 10px 34px 0;align-self:center}.hero-copy .eyebrow{display:flex;align-items:center;gap:9px}.mini-star{color:#b54225;font-size:1.25rem}
.hero-copy h1{font-size:clamp(2.7rem,5.4vw,4.8rem);max-width:12ch;margin:24px 0}.hero-copy h1 em{display:inline;background:linear-gradient(transparent 78%,#ccd6ff 78%)}
.hero-copy .intro{font-size:1.35rem;font-weight:800;letter-spacing:-.025em;margin:24px 0 12px}
.hero-copy>p:not(.eyebrow):not(.intro):not(.byline){max-width:34em;color:var(--muted);font-size:1rem;margin-top:0}
.primary,.secondary{display:inline-flex;align-items:center;justify-content:center;min-height:52px;padding:14px 23px;border-radius:16px;text-decoration:none;font-weight:800;font-size:.96rem;border:1px solid transparent;text-align:center;transition:background .16s,transform .16s,box-shadow .16s}
.primary{background:var(--blue);color:white;box-shadow:0 8px 20px #4356dd28}.primary:hover{background:var(--blue-dark);transform:translateY(-2px);box-shadow:0 11px 24px #4356dd35}
.secondary{background:#fff;color:var(--ink);border-color:#ced8ef;box-shadow:0 4px 12px #263a6d08}.secondary:hover{background:#e8edff;transform:translateY(-2px)}
.byline{font-size:.8rem;color:var(--muted);margin-top:24px}
.hero-art{position:relative;isolation:isolate;min-height:650px;border-radius:38px 38px 100px 38px;background:#1c3354;box-shadow:0 24px 55px #243a7425;overflow:hidden;transform:rotate(1.5deg);border:7px solid #fff}
.cover-image{position:absolute;inset:0;width:100%;height:100%;object-fit:cover;object-position:center;display:block}
.hero-art:after{content:'';position:absolute;inset:35% 0 0;background:linear-gradient(transparent,#122347ed);z-index:0}
.art-label{position:absolute;bottom:48px;left:30px;right:30px;z-index:2;color:white;max-width:260px}.art-label strong{font-size:1.45rem;letter-spacing:-.035em;line-height:1.25;display:block}.art-label span{display:block;font-size:.875rem;margin-top:12px;color:#e1ebff}
.hero-door{position:absolute;z-index:1;width:155px;height:175px;object-fit:contain;right:-10px;bottom:92px;transform:rotate(-9deg);filter:drop-shadow(0 9px 16px #0b153d66)}
.art-spark{position:absolute;z-index:2;color:#fff0b3;font-size:3rem;text-shadow:0 0 22px #ffc75755}.spark-one{top:30px;right:25px}.spark-two{top:160px;left:20px;font-size:2rem}
.experience-grid{display:grid;grid-template-columns:1fr 1fr;gap:22px;margin:52px 38px 64px}
.experience-card{display:grid;grid-template-columns:58px 1fr;gap:18px;padding:28px;border:1px solid #fff;border-radius:26px;background:#fff;box-shadow:0 12px 35px #253d7610;text-decoration:none;transition:transform .18s,box-shadow .18s}
.experience-card:hover{transform:translateY(-4px);box-shadow:0 18px 40px #253d7620}.experience-icon{width:56px;height:56px;display:grid;place-items:center;border-radius:18px;background:#e8edff;color:#354aca;font-size:2rem;font-weight:800}
.experience-card .eyebrow{margin:0 0 10px;font-size:.7rem}.experience-card h2{margin:0;font-size:1.55rem;max-width:17ch}.experience-card p:not(.eyebrow){color:var(--muted);font-size:.94rem;margin:12px 0 0}.experience-tag{grid-column:2;font-size:.875rem;font-weight:800;color:var(--blue);margin-top:3px}
.flight-experience{background:#fff0e9;border-color:#fff6f0}.flight-experience .experience-icon{background:#ffdcd0;color:#b83a24}.flight-experience .eyebrow,.flight-experience .experience-tag{color:#ad3420}
footer{border-top:1px solid #d4ddef;display:flex;justify-content:space-between;align-items:center;gap:20px;max-width:1204px;margin:0 auto;padding:20px 0 30px;color:var(--muted);font-size:.8rem}footer a{min-height:44px;display:inline-flex;align-items:center;font-weight:650}
.demo{background:#e3e9ff;color:#2a3d8b;border-block:1px solid #d1dbfc;padding:7px 18px;text-align:center;font-size:.8rem}
.calendar-page{padding:26px 38px 60px;text-align:center}.section-heading{max-width:720px;margin:10px auto 42px}.section-heading h1{margin:16px 0 24px}.section-heading>p:not(.eyebrow){color:var(--muted);max-width:540px;margin:0 auto 18px}.today-link{margin-top:6px;background:var(--ink)}
.doors{list-style:none;display:grid;grid-template-columns:repeat(6,minmax(0,1fr));gap:18px;padding:0;margin:0}
.door{position:relative;width:100%;height:100%;display:flex;align-items:center;flex-direction:column;min-height:204px;background:#fff;border:1px solid #dce4f8;border-radius:22px;padding:12px 7px;color:var(--ink);box-shadow:0 6px 17px #233e7510;transition:transform .18s,box-shadow .18s}
.door:hover{transform:translateY(-4px);box-shadow:0 12px 25px #293d8123;border-color:#9bacf7}.door-picture{background:url('art/door.webp') center/contain no-repeat;height:142px;width:100%;display:block}
.door-number{position:absolute;top:57px;left:50%;transform:translateX(-50%);display:grid;place-items:center;font-size:1.45rem;font-weight:900;color:white;background:#3048b7;border:3px solid #e1e8ff;border-radius:50%;width:45px;height:45px;z-index:1;box-shadow:0 4px 12px #14215633}
.door-status{font-size:.875rem;line-height:1.35;display:block;padding-top:9px;min-height:30px}.door.locked{background:#edf1fa;box-shadow:none}.door.locked .door-picture{filter:saturate(.7)}
.door.ready,.door.missing{background:radial-gradient(ellipse at 50% 35%,#fff2c5,#fff 75%)}.door.today{border:3px solid #5367e3;padding:10px 5px;background:radial-gradient(ellipse at 50% 35%,#ffe9a8,#edf1ff 78%);box-shadow:0 9px 28px #4356dd23}.door.today .door-status{font-weight:850;color:#253a9b}.heard{font-size:.875rem;color:#435376}
.calendar-note{color:var(--muted);margin:36px 0 24px}
.chapter-page{max-width:850px;padding:30px 30px 65px;margin:auto}.chapter-page h1{font-size:clamp(2.2rem,4.6vw,3.8rem)}.back{display:inline-flex;align-items:center;min-height:44px;margin-bottom:16px;color:#364bab;font-weight:750;font-size:.9rem;text-decoration:none}.back:hover{text-decoration:underline}
.chapter-image{max-height:500px;max-width:100%;display:block;margin:28px auto;border-radius:24px;box-shadow:0 16px 35px #243b6a1c}
.audio-card{border:1px solid #dce4f6;background:#fff;padding:28px;border-radius:25px;margin:28px 0;box-shadow:0 14px 36px #243d7310}.audio-card h2{margin:0 0 16px}.audio-card p{margin:0 0 20px;color:var(--muted)}.audio-card audio{display:block;width:100%;min-height:54px;margin-top:24px}.audio-card #audio-status{font-size:.875rem;margin:18px 0 0}.audio-card #retry-audio{margin-top:16px}
.chapter-game{display:inline-flex;align-items:center;min-height:48px;margin-top:26px;font-weight:750;color:var(--blue)}.chapter-text{white-space:pre-wrap;line-height:1.85;margin:25px 0;padding:24px;background:#fff;border-radius:20px}.locked-illustration{height:200px;background:url('art/door.webp') center/contain no-repeat}
.toast{position:fixed;bottom:max(24px,env(safe-area-inset-bottom));left:50%;transform:translateX(-50%);background:var(--ink);color:white;box-shadow:0 10px 35px #111e4638;border:1px solid #ffffff24;border-radius:18px;max-width:calc(100% - 30px);width:max-content;padding:16px 23px;z-index:20;font-size:.95rem}
.skip{position:fixed;top:-100px;left:10px;z-index:30;padding:15px;background:white;border-radius:10px}.skip:focus{top:10px}.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}.loading{padding:70px 25px;text-align:center;font-weight:700;color:var(--muted)}
/* Game: the two counters are anchored to the canvas, not to the surrounding menus. */
.game-page{padding:12px 38px 42px;max-width:1120px;margin:auto}.game-page>.back{margin-bottom:5px}.game-heading h1{font-size:clamp(2rem,3.8vw,3.2rem);margin:10px 0}.game-heading .eyebrow{margin:0}.game-page #instructions{max-width:800px;color:var(--muted);font-size:.94rem;margin:14px 0 22px}
.game-stage{position:relative;border-radius:28px;overflow:hidden;border:5px solid #fff;background:#15264d;box-shadow:0 18px 50px #20376b23}
.game-viewport{position:relative;width:100%;aspect-ratio:3/2;overflow:hidden;isolation:isolate;background:#17284e}.game-viewport canvas{display:block;width:100%;height:100%;touch-action:none;outline-offset:-5px}
.screen-hud{position:absolute;inset:0;z-index:2;pointer-events:none;user-select:none}
.screen-score{position:absolute;right:16px;top:16px;display:flex;align-items:center;gap:13px;padding:9px 16px;background:#101e3cde;border:1px solid #ffffff50;border-radius:18px;color:#fff;box-shadow:0 5px 18px #07112625;min-height:58px}
.screen-score strong{font-size:2rem;font-weight:900;line-height:1;font-variant-numeric:tabular-nums}.score-label{font-size:.875rem;font-weight:700;color:#e1ecff}
.magnet-gauge{position:absolute;left:14px;top:12px;width:76px;height:76px;border-radius:50%;background:#101e3cde;border:1px solid #ffffff30;box-shadow:0 5px 18px #07112625;color:white}
.magnet-gauge svg{display:block;width:100%;height:100%}.gauge-track{fill:none;stroke:#ffffff28;stroke-width:5}.gauge-value{fill:none;stroke:#ffcc68;stroke-width:5;stroke-linecap:round}
.magnet-gauge img{position:absolute;left:50%;top:12px;transform:translateX(-50%);width:32px;height:32px;object-fit:contain}.magnet-gauge span{position:absolute;left:50%;bottom:9px;transform:translateX(-50%);font-weight:850;font-size:.875rem;font-variant-numeric:tabular-nums;line-height:1}
.game-overlay{position:absolute;inset:0;z-index:3;background:#0f1d4266;display:grid;place-items:center;padding:18px;text-align:center}.game-overlay>div{width:100%;max-width:450px;background:#f8fafff5;padding:26px;border:1px solid #fff;border-radius:26px;box-shadow:0 18px 55px #07132b40}.game-overlay h2{margin:10px 0;font-size:1.8rem}.game-overlay p{font-size:.9rem;line-height:1.6;color:var(--muted)}.game-overlay .eyebrow{color:var(--blue);margin:0}.game-overlay .primary{min-width:180px}.game-back{display:block;min-height:44px;padding-top:15px;font-size:.875rem;font-weight:750;color:var(--muted)}
#difficulty{margin:16px 0 10px;border:0;padding:0;text-align:left}#difficulty legend{font-weight:800;font-size:.9rem;margin-bottom:9px}#difficulty .difficulty-options{display:grid;grid-template-columns:1fr 1fr;gap:10px}
#difficulty label{display:flex;align-items:flex-start;gap:9px;border:2px solid #dce3f5;border-radius:16px;padding:13px 10px;min-height:84px;cursor:pointer;background:white}#difficulty label:has(input:checked){border-color:var(--blue);background:#eaf0ff;box-shadow:0 4px 12px #354bd212}#difficulty input{width:20px;height:20px;accent-color:var(--blue);flex-shrink:0;margin:2px 0 0}#difficulty strong{font-size:.94rem}#difficulty small{display:block;font-size:.875rem;line-height:1.35;color:var(--muted);margin-top:5px}.difficulty-hint{font-size:.875rem}
.game-toolbar{display:flex;align-items:center;gap:12px;min-height:60px;padding:12px 2px 0}.level-chip{font-size:.875rem;font-weight:800;color:#2f43b0;background:#e2e9ff;border:1px solid #ccd6fc;padding:8px 13px;border-radius:999px}.best-score{font-size:.875rem;color:var(--muted)}.best-score b{color:var(--ink);font-variant-numeric:tabular-nums}
.game-toolbar>button,.game-controls button{min-height:44px;min-width:82px;border:1px solid #cbd5ed;background:white;color:var(--ink);border-radius:14px;padding:9px 16px;font:inherit;font-weight:750}.game-toolbar>button{margin-left:auto}.game-toolbar>button:hover,.game-controls button:hover{background:#e4ebff}
.boost-button{display:block;width:100%;min-height:64px;margin-top:12px;background:var(--coral);color:white;border:1px solid #b12b1c;border-radius:18px;font-size:1.12rem;font-weight:850;touch-action:none;box-shadow:0 7px 0 #9f2d21,0 13px 22px #b9402522;transition:background .12s,transform .12s,box-shadow .12s}.boost-button:active:not(:disabled){background:#b6301d;transform:translateY(4px);box-shadow:0 3px 0 #9f2d21}.boost-button:disabled{box-shadow:0 4px 0 #9f2d2140;opacity:.45}
.game-controls{display:flex;gap:14px;align-items:center;flex-wrap:wrap;margin-top:18px}.game-controls>span,.game-note{font-size:.875rem;color:var(--muted)}.game-note{line-height:1.6;margin-top:18px}
@media(max-width:1050px){.hero{gap:24px}.hero-copy h1{font-size:3.5rem}.hero-art{min-height:610px}.hero-door{width:125px;right:-20px}.art-label{left:23px;bottom:40px}.art-label strong{font-size:1.25rem}.experience-card{padding:22px;gap:14px}.doors{grid-template-columns:repeat(4,minmax(0,1fr))}footer{margin-left:38px;margin-right:38px}}
@media(max-width:760px){.hero{grid-template-columns:1fr;margin:10px 24px 0;gap:14px}.hero-copy{padding:18px 0}.hero-copy h1{font-size:clamp(2.7rem,7vw,4rem);max-width:15ch}.hero-art{min-height:390px;transform:none;border-radius:30px 30px 70px 30px}.cover-image{object-position:center 60%}.hero-door{width:145px;right:15px;bottom:35px}.art-label{max-width:65%;bottom:30px}.experience-grid{grid-template-columns:1fr;margin:30px 24px 40px}.site-header{padding:20px 24px}.brand{font-size:1.25rem}nav a{padding:10px 14px}.calendar-page{padding:20px 24px 40px}.game-page{padding:12px 20px 30px}.game-overlay>div{padding:20px}.game-overlay h2{font-size:1.55rem}}
@media(max-width:650px){:root{font-size:16px}.hero-copy h1{font-size:2.85rem}.hero-copy .intro{font-size:1.25rem}.hero-copy .eyebrow{font-size:.7rem}.hero-art{min-height:330px}.hero-copy>p:not(.eyebrow):not(.intro):not(.byline){font-size:1rem}
.experience-card{grid-template-columns:46px 1fr;padding:20px;gap:13px;border-radius:22px}.experience-icon{width:44px;height:44px;border-radius:14px;font-size:1.6rem}.experience-card h2{font-size:1.5rem}.experience-card .eyebrow{font-size:.65rem}.experience-tag{grid-column:2}
footer{margin:0 24px;padding:18px 0 24px;flex-direction:column;align-items:flex-start;gap:0}.section-heading h1{font-size:2.55rem}.section-heading{margin-bottom:28px}.doors{grid-template-columns:repeat(3,minmax(0,1fr));gap:11px 8px}.door{min-height:162px;padding:9px 4px;border-radius:17px}.door-picture{height:108px}.door-number{top:44px;width:37px;height:37px;font-size:1.2rem;border-width:2px}.door-status{font-size:.875rem}.door.today{padding:7px 2px}.calendar-page{padding:18px 14px 36px}.chapter-page{padding:20px 20px 40px}.chapter-page h1{font-size:2.3rem}.audio-card{padding:20px}.chapter-text{padding:18px}
.game-page{padding:8px 12px 24px}.game-heading h1{font-size:1.8rem}.game-page #instructions{font-size:.94rem}.game-stage{border-width:3px;border-radius:22px}.game-overlay{position:relative;inset:auto;padding:12px;background:#e5ecfc}.game-overlay>div{max-width:none;padding:18px;border-radius:19px;box-shadow:none}.game-overlay .eyebrow{display:none}.game-overlay h2{font-size:1.55rem}.game-overlay p{font-size:.9rem}.game-overlay .primary{min-height:48px}.game-back{padding-top:12px}.screen-score{top:10px;right:10px;min-height:48px;padding:8px 12px;gap:10px;border-radius:15px}.screen-score strong{font-size:1.6rem}.score-label{font-size:.875rem}.magnet-gauge{left:10px;top:10px;width:64px;height:64px}.magnet-gauge img{width:27px;height:27px;top:10px}.magnet-gauge span{font-size:.875rem;bottom:7px}
.game-toolbar{gap:10px}.game-controls{margin-top:18px}.game-controls>span{font-size:.875rem}.game-note{font-size:.875rem}}
@media(max-width:480px){.site-header{padding:17px 18px;display:grid;grid-template-columns:1fr;gap:14px}.brand{justify-self:center}.brand-star{width:39px;height:39px;font-size:1.8rem;border-radius:13px}.brand small{font-size:.55rem}nav{justify-self:center;width:100%;max-width:330px}nav a{flex:1}.hero{margin-left:20px;margin-right:20px}.hero-copy h1{font-size:2.6rem;max-width:12ch}.experience-grid{margin-left:16px;margin-right:16px}.hero-art{min-height:300px}.hero-door{width:120px;right:0;bottom:45px}.art-label strong{font-size:1.25rem}.art-label span{font-size:.875rem}.experience-card{grid-template-columns:1fr}.experience-icon{width:44px;height:44px}.experience-tag{grid-column:1}}
@media(max-width:650px) and (orientation:portrait){.game-page{padding:6px 8px 20px}.game-page.is-playing .game-heading,.game-page.is-playing #instructions{display:none}.game-stage{display:flex;flex-direction:column}.game-overlay{order:-1}.game-viewport{aspect-ratio:9/10}.game-toolbar{min-height:56px}.game-controls>span{display:none}.boost-button{min-height:64px}.game-note{line-height:1.5}#difficulty label{min-height:94px;padding:11px 8px;gap:7px}#difficulty small{font-size:.875rem}#difficulty input{width:18px;height:18px}.game-overlay>div{padding:16px}.game-overlay h2{font-size:1.4rem}}
@media(prefers-reduced-motion:reduce){*,*:before,*:after{scroll-behavior:auto!important;animation:none!important;transition:none!important}.primary:hover,.secondary:hover,.experience-card:hover,.door:hover,.boost-button:active:not(:disabled){transform:none}}
.music-option{display:inline-flex;align-items:center;gap:9px;min-height:44px;padding:8px 12px;background:#ffffffb3;border:1px solid #ccd5ed;border-radius:14px;font-size:.9rem;font-weight:700;cursor:pointer}.music-option input{width:20px;height:20px;margin:0;accent-color:var(--blue)}
/* Advent calendar: clear day numbers, a little depth, and a real opening flap. */
html{scrollbar-gutter:stable}.chapter-open{overflow:hidden}
.calendar-intro{display:grid;grid-template-columns:minmax(0,1fr) 240px;gap:46px;align-items:center;margin:10px 0 40px;text-align:left}
.calendar-intro .section-heading{max-width:none;margin:0;text-align:left}.calendar-intro .section-heading h1{font-size:clamp(2.5rem,4.8vw,4rem)}.calendar-intro .section-heading>p:not(.eyebrow){margin-left:0;max-width:530px}
.calendar-summary{padding:25px;border-radius:28px;background:linear-gradient(145deg,#243977,#4356ba);color:#fff;box-shadow:0 14px 35px #263f7d22;position:relative;overflow:hidden}
.calendar-summary>span{position:absolute;right:20px;top:12px;font-size:4.5rem;color:#ffffff20;line-height:1}.calendar-summary strong{display:block;font-size:3.2rem;line-height:1;font-variant-numeric:tabular-nums;letter-spacing:-.05em}.calendar-summary small{display:block;font-size:.875rem;letter-spacing:0;line-height:1.5;margin-top:12px;font-weight:650;color:#e3ecff}.calendar-summary p{font-size:.9rem;color:#e3ecff;margin:15px 0 0;line-height:1.5}
.calendar-summary progress{display:block;width:100%;height:7px;border:0;border-radius:999px;overflow:hidden;margin-top:17px;background:#ffffff25;accent-color:#ffcf79}.calendar-summary progress::-webkit-progress-bar{background:#ffffff25}.calendar-summary progress::-webkit-progress-value{background:#ffcf79;border-radius:999px}.calendar-summary progress::-moz-progress-bar{background:#ffcf79}
.calendar-page .doors{gap:18px}.calendar-page .door{min-height:216px;padding:12px 7px;border-radius:24px;overflow:hidden;background:#fff;isolation:isolate}
.calendar-page .door.tone-0{background:linear-gradient(155deg,#f8faff,#e9edff)}.calendar-page .door.tone-1{background:linear-gradient(155deg,#fff9f5,#ffede0)}.calendar-page .door.tone-2{background:linear-gradient(155deg,#f6ffff,#e3f3f0)}.calendar-page .door.tone-3{background:linear-gradient(155deg,#fdfaff,#efe6f6)}
.calendar-page .door.locked{box-shadow:none;border-color:#dce3f0}.calendar-page .door.today{border-color:#5367e3;box-shadow:0 12px 30px #4356dd25}.calendar-page .door-number{top:13px;left:15px;transform:none;display:block;width:auto;height:auto;border:0;border-radius:0;background:none;color:#26365b;box-shadow:none;font-size:2rem;font-weight:900;line-height:1.1;letter-spacing:-.06em}
.door-today{position:absolute;top:17px;right:10px;padding:4px 7px;border-radius:999px;background:#fff0bd;color:#704715;font-size:.72rem;font-weight:800}
.door-scene{--door-w:104px;--door-h:110px;position:relative;display:block;width:100%;height:140px;margin-top:24px;perspective:550px}
.door-flap{position:absolute;left:0;right:0;bottom:0;margin:auto;width:var(--door-w);height:var(--door-h);background:url('art/door.webp') center bottom/contain no-repeat;transform-origin:12% 60%;backface-visibility:hidden;transition:transform .42s cubic-bezier(.2,.7,.15,1),filter .42s;filter:drop-shadow(0 4px 4px #68471825);z-index:1}
.door-light{display:grid;place-items:center;position:absolute;left:0;right:0;margin:auto;bottom:4px;width:80px;height:88px;border-radius:44px 44px 8px 8px;background:linear-gradient(#ffe6a5,#fff7d7);box-shadow:0 0 25px #efc57855;opacity:.35;transition:opacity .3s,box-shadow .3s}
.door-light svg{width:36px;height:36px;fill:none;stroke:#82521c;stroke-width:2;stroke-linejoin:round;stroke-linecap:round}.locked .door-light{opacity:0}.locked .door-flap{filter:saturate(.55) drop-shadow(0 3px 3px #38425c15)}
.door.is-opening .door-flap,.door.is-open .door-flap{transform:rotateY(-112deg);filter:drop-shadow(-5px 5px 6px #3a315033)}.door.is-opening .door-light,.door.is-open .door-light{opacity:1;box-shadow:0 0 34px #f4bd6770}.calendar-page .door-status{font-weight:750;font-size:.875rem;padding-top:7px;min-height:28px}.calendar-page .heard{font-size:.875rem}
/* Native dialog supplies focus containment and an inert background. */
.chapter-dialog{position:fixed;inset:0;margin:auto;padding:0;width:min(620px,calc(100vw - 32px));max-width:none;height:fit-content;max-height:calc(100dvh - 32px);border:1px solid #ffffffc9;border-radius:32px;background:#fff;color:var(--ink);box-shadow:0 30px 100px #09142d55;overflow:hidden;animation:chapter-enter .22s ease-out}
.chapter-dialog::backdrop{background:#101b3999;backdrop-filter:blur(8px);-webkit-backdrop-filter:blur(8px)}
.chapter-sheet{padding:24px;max-height:calc(100dvh - 32px);overflow:auto;overscroll-behavior:contain;text-align:center}
.chapter-top{display:flex;align-items:center;justify-content:space-between;gap:16px;position:sticky;top:-24px;z-index:2;margin:-24px -24px 18px;padding:16px 24px 10px;background:#fffffff2;backdrop-filter:blur(10px)}
.chapter-pill{display:inline-flex;align-items:center;min-height:34px;padding:7px 13px;border-radius:999px;background:#e9eeff;color:#3348ae;font-size:.875rem;font-weight:800}
.chapter-close{width:46px;height:46px;display:grid;place-items:center;border:1px solid #dce3f4;border-radius:50%;background:#f1f4fc;color:#344567;flex-shrink:0}.chapter-close:hover{background:#e1e8fb}.chapter-close svg{width:22px;height:22px;fill:none;stroke:currentColor;stroke-width:2;stroke-linecap:round}
.modal-illustration{display:block;width:100%;height:220px;object-fit:contain;background:#eff3ff;border-radius:22px;margin-bottom:20px}.modal-door{height:150px;background:url('art/door.webp') center/contain no-repeat;margin-bottom:20px}
.chapter-sound-art{height:130px;border-radius:22px;display:flex;align-items:center;justify-content:center;gap:9px;background:radial-gradient(circle at 30% 30%,#fbe5cf,transparent 65%),linear-gradient(130deg,#e5ebff,#eee8ff);color:#4e5ec9;margin-bottom:20px;position:relative;overflow:hidden}.chapter-sound-art>span{font-size:4rem;font-weight:800;margin-right:16px}.chapter-sound-art i{height:40px;width:7px;border-radius:9px;background:#6d7cdb}.chapter-sound-art i:nth-child(3){height:65px}.chapter-sound-art i:nth-child(4){height:82px}.chapter-sound-art i:nth-child(5){height:57px}
.chapter-sheet>.eyebrow{margin:14px 0 10px}.chapter-sheet h2{font-size:clamp(1.7rem,4vw,2.35rem);line-height:1.15;margin:0 auto 14px;max-width:20ch;overflow-wrap:anywhere}.chapter-sheet #chapter-description{font-size:.95rem;color:var(--muted);line-height:1.6;margin:0 auto 24px;max-width:40ch}
.chapter-player{padding:22px;border:1px solid #dce4f8;border-radius:25px;background:linear-gradient(145deg,#f3f6ff,#f9faff)}.chapter-player audio{display:none}
.player-buttons{display:flex;align-items:center;justify-content:center;gap:23px;margin:0 0 18px}.player-play{width:80px;height:80px;display:grid;place-items:center;border-radius:50%;border:0;background:var(--blue);color:#fff;box-shadow:0 10px 22px #4356dd33}.player-play:hover{background:var(--blue-dark)}.player-play svg{width:34px;height:34px;fill:currentColor}.player-skip{position:relative;display:flex;flex-direction:column;align-items:center;justify-content:center;width:52px;height:52px;flex-shrink:0;border-radius:50%;background:#fff;border:1px solid #d6def0;color:#3c4e7a;line-height:1}.player-skip span{font-size:1.55rem;line-height:.85}.player-skip b{font-size:.875rem;margin-top:3px}.player-skip:disabled{opacity:.4}
#chapter-seek{display:block;width:100%;height:44px;margin:0;accent-color:var(--blue);cursor:pointer}#chapter-seek:disabled{cursor:default;opacity:.5}.player-times{display:flex;justify-content:space-between;font-size:.875rem;color:#526384;font-variant-numeric:tabular-nums;font-weight:650}.chapter-player #audio-status{font-size:.875rem;line-height:1.5;margin:18px 0 0;color:var(--muted)}.chapter-player #retry-audio{margin-top:16px}
.chapter-empty{padding:20px;background:#f0f4ff;border:1px solid #dce4fa;border-radius:22px}.chapter-empty h3{font-size:1.3rem;margin:0 0 8px}.chapter-empty p{margin:0 0 18px;color:var(--muted)}.chapter-transcript{margin-top:18px;text-align:left;border:1px solid #dce4f6;border-radius:18px;background:#f9faff}.chapter-transcript summary{min-height:48px;padding:14px 17px;cursor:pointer;font-weight:750;font-size:.9rem}.chapter-transcript #chapter-text{white-space:pre-wrap;padding:0 18px 18px;line-height:1.8;font-size:.95rem}.chapter-sheet .chapter-game{font-size:.875rem;margin-top:18px}
@keyframes chapter-enter{from{opacity:0;transform:translateY(16px) scale(.98)}to{opacity:1;transform:translateY(0) scale(1)}}
@media(max-width:760px){.calendar-intro{grid-template-columns:1fr;gap:22px}.calendar-summary{display:grid;grid-template-columns:auto 1fr;gap:6px 22px;padding:20px 24px;border-radius:23px}.calendar-summary strong{font-size:2.4rem}.calendar-summary small{margin-top:7px}.calendar-summary p{grid-column:2;grid-row:1;align-self:center;margin:0}.calendar-summary progress{grid-column:1/-1;margin-top:10px}.calendar-summary>span{font-size:4rem}.calendar-intro .section-heading h1{font-size:2.7rem}}
@media(max-width:650px){.calendar-page .doors{gap:12px 8px}.calendar-page .door{min-height:186px;border-radius:19px;padding:10px 4px}.calendar-page .door-number{font-size:1.6rem;top:12px;left:11px}.door-today{font-size:.68rem;top:13px;right:6px;padding:4px 5px}.door-scene{--door-w:78px;--door-h:84px;height:111px;margin-top:24px}.door-light{width:60px;height:66px;border-radius:34px 34px 7px 7px}.door-light svg{width:28px;height:28px}.calendar-page .door-status{font-size:.875rem;min-height:35px;line-height:1.25}.calendar-page .heard{font-size:.8rem}.calendar-intro{margin-bottom:25px}.calendar-intro .section-heading h1{font-size:2.55rem}.calendar-summary p{font-size:.875rem}.calendar-summary small{font-size:.875rem}.chapter-dialog{width:calc(100vw - 16px);max-height:calc(100dvh - 16px);border-radius:28px}.chapter-sheet{padding:20px;max-height:calc(100dvh - 16px)}.chapter-top{top:-20px;margin:-20px -20px 15px;padding:12px 18px 9px}.modal-illustration{height:185px}.chapter-sound-art{height:110px}.chapter-sheet h2{font-size:1.8rem}.chapter-player{padding:19px 16px}.player-buttons{gap:20px}.player-play{width:76px;height:76px}.chapter-sheet #chapter-description{margin-bottom:20px}.chapter-sheet>.eyebrow{font-size:.75rem}}
@media(prefers-reduced-motion:reduce){.chapter-dialog{animation:none}.door-flap,.door-light{transition:none}}
/* School adventure uses its own lazy-loaded pixel graphics and progress. */
.experience-grid{grid-template-columns:repeat(3,minmax(0,1fr))}.experience-card{grid-template-columns:1fr}.experience-tag{grid-column:1}.school-experience{background:#e5f5ee;border-color:#f4fff9}.school-experience .experience-icon{background:#c6ebdb;color:#205f4a}.school-experience .eyebrow,.school-experience .experience-tag{color:#205f4a}
.school-page{padding:24px 30px 40px;max-width:1160px;margin:auto}.school-heading h1{font-size:clamp(2rem,4.5vw,3.7rem);margin:14px 0}
.school-levels{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:16px;list-style:none;padding:0;margin:0}.school-intro img,.school-found{image-rendering:pixelated;object-fit:contain}
.school-intro{text-align:center;max-width:640px;padding:36px 26px;margin:20px auto;background:#fff;border:1px solid #dbe4f5;border-radius:30px;box-shadow:0 12px 35px #243d7310}.school-intro h2{font-size:2rem;margin:16px 0}.school-intro>img{width:128px;height:128px}.school-intro-help{color:var(--muted);font-size:1rem;line-height:1.7;margin-bottom:24px}.school-intro button{margin:6px}
.school-arena{margin-top:16px;border-radius:24px;overflow:hidden;box-shadow:0 16px 42px #172b592b;border:4px solid #fff;background:#17294c}.school-hud{display:flex;align-items:center;gap:12px;justify-content:space-between;background:#17294c;color:#fff;min-height:65px;padding:9px 16px;font-size:.95rem}.school-hud>span{font-weight:750;line-height:1.35}.school-hud strong{color:#ffe3a0;white-space:nowrap;font-variant-numeric:tabular-nums}.school-hud .secondary{min-height:44px;padding:8px 16px;border-radius:12px;font-size:.875rem}
.school-viewport{position:relative;width:100%;aspect-ratio:16/9;overflow:hidden;background:#253953}.school-viewport canvas{display:block;width:100%;height:100%;image-rendering:pixelated;outline-offset:-5px;touch-action:none}.school-overlay{position:absolute;inset:0;background:#0e193caa;backdrop-filter:blur(3px);display:flex;align-items:center;justify-content:center;padding:16px;overflow:auto}.school-overlay>div{max-width:460px;width:100%;text-align:center;padding:25px;background:#f8faff;border-radius:25px;max-height:100%;overflow:auto}.school-overlay h2{font-size:1.7rem;margin:8px 0}.school-overlay p{font-size:1rem;color:var(--muted);line-height:1.5;margin:12px 0}.school-overlay button{margin:5px;min-height:48px}.school-found{width:64px;height:64px}.school-help{margin:0;padding:9px 16px 14px;background:#e4ebfc;color:#344b78;font-size:.875rem;line-height:1.5}.school-footer{display:flex;gap:20px;align-items:center;flex-wrap:wrap;margin:18px 0 0}.school-footer a{display:inline-flex;align-items:center;min-height:44px;font-weight:750;font-size:.9rem}.school-page>#school-status{font-size:.95rem;min-height:1.5em;color:var(--muted)}
body.school-playing>.site-header,body.school-playing>footer,body.school-playing>#demo,body.school-playing .school-heading{display:none}.school-playing .school-page{padding-top:8px}.school-playing main{min-height:0}.school-playing .school-arena{margin-top:0}
@media(max-width:980px){.experience-grid{grid-template-columns:1fr}.experience-card{grid-template-columns:58px 1fr}.experience-tag{grid-column:2}.school-levels{grid-template-columns:repeat(3,minmax(0,1fr))}.site-header{flex-wrap:wrap;gap:10px}.site-header nav{flex-wrap:wrap}}
@media(max-width:650px){.school-page{padding:18px 12px 30px}.school-heading h1{font-size:2.2rem}.school-levels{grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}.school-hud{padding:8px 10px;gap:8px;flex-wrap:wrap;font-size:.875rem}.school-hud>span{flex:1 1 120px}.school-hud strong{font-size:.875rem}.school-hud .secondary{padding:8px 10px}.school-arena{border-width:3px;border-radius:19px}.school-viewport{aspect-ratio:4/3}.school-overlay{padding:10px}.school-overlay>div{padding:15px}.school-overlay h2{font-size:1.4rem}.school-overlay button{font-size:.875rem;min-height:44px;padding:10px 13px}.school-overlay p{font-size:.875rem}.school-found{width:48px;height:48px}.school-footer{gap:12px}.school-help{font-size:.875rem}.school-intro{padding:25px 18px}.school-intro h2{font-size:1.8rem}.school-playing .school-page{padding-inline:6px}.school-playing .school-help{padding-block:7px}}
@media(orientation:landscape) and (max-height:600px){.school-playing .school-page{max-width:960px;padding:0 6px}.school-playing .school-viewport{aspect-ratio:auto;height:calc(100dvh - 160px)}.school-playing .school-hud{min-height:48px}.school-playing .school-help,.school-playing .school-footer,.school-playing #school-status{display:none}}

.school-target{display:flex;flex-direction:column;gap:3px}.school-target small{font-size:.875rem;font-weight:550;color:#d3dfff;line-height:1.35}.school-level-brief{padding:15px 18px;border-radius:16px;background:#edf2ff;text-align:left;color:#3e5278;font-size:1rem;line-height:1.65}

.school-feature {
  position: relative;
  isolation: isolate;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(88px, 27%);
  align-items: center;
  gap: clamp(10px, 3vw, 36px);
  padding: clamp(20px, 4vw, 48px);
  margin: 22px 0 32px;
  overflow: hidden;
  color: #fff;
  background: #17294c;
  border-radius: 28px;
  box-shadow: 0 16px 34px #17294c25;
}
.school-feature-room, .school-feature::before {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: -2;
}
.school-feature-room {object-fit: cover; object-position: right center; image-rendering: pixelated}
.school-feature::before {
  content: "";
  z-index: -1;
  background: linear-gradient(90deg,#142444 12%,#142444f7 42%,#182b4caa 78%,#182b4c66);
}
.school-feature-kicker {margin: 0; color: #fbe0a4; font-size: .9rem; font-weight: 700}
.school-feature h2 {margin: 8px 0 18px; font-size: clamp(1.55rem, 4vw, 3rem)}
.school-feature .primary {background: #ffe19c; color: #25314e; border-color: #ffe19c; box-shadow: none}
.school-feature .primary:hover {background: #ffefc5}
.school-feature-animal {
  width: 100%;
  height: auto;
  image-rendering: pixelated;
  filter: drop-shadow(0 8px 12px #091224aa);
}
.school-feature-progress {max-width: 320px; margin-bottom: 18px; font-size: .875rem; font-weight: 650}
.school-feature-progress progress {
  display: block;
  appearance: none;
  width: 100%;
  height: 8px;
  margin-top: 7px;
  border: 0;
  border-radius: 999px;
  background: #ffffff40;
  accent-color: #ffda8a;
}
.school-feature-progress progress::-webkit-progress-bar {background: #ffffff40; border-radius: 999px}
.school-feature-progress progress::-webkit-progress-value {background: #ffda8a; border-radius: 999px}
.school-feature-progress progress::-moz-progress-bar {background: #ffda8a; border-radius: 999px}
.school-picker-title {margin: 0 0 16px; font-size: 1.45rem}

.school-level {
  width: 100%;
  height: 100%;
  min-height: 168px;
  padding: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  text-align: left;
  border: 1px solid #d8e0f0;
  border-radius: 19px;
  background: #fff;
  color: var(--ink);
  box-shadow: 0 4px 14px #2439610e;
  transition: transform .15s, box-shadow .15s;
}
.school-level:not(:disabled):hover {transform: translateY(-2px); box-shadow: 0 8px 22px #24396125}
.school-level.current {border-color: #5268cf; box-shadow: 0 0 0 1px #5268cf}
.school-level-art {
  position: relative;
  display: grid;
  place-items: center;
  width: 100%;
  min-height: 78px;
  background: linear-gradient(145deg, #dce7ff, #f1e9fb);
}
.school-level.finished .school-level-art {background: linear-gradient(145deg,#cfefe2,#edf8ef)}
.school-level-number {
  position: absolute;
  inset: 10px auto auto 12px;
  color: #40557e;
  font-size: .95rem;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
}
.school-level img {image-rendering: pixelated; object-fit: contain}
.school-level-copy {display: grid; gap: 4px; padding: 10px 12px 12px; line-height: 1.3}
.school-level-copy strong {font-size: 1rem; overflow-wrap: anywhere}
.school-level-copy > span, .school-level-copy > small {font-size: .875rem; color: var(--muted)}
.school-level-copy > small {font-weight: 700}
.school-level.current small {color: #344db0}
.school-level.finished small {color: #23654e}
.school-level:disabled {opacity: 1; box-shadow: none; background: #f4f6fa}
.school-level:disabled .school-level-art {background: #e6ebf4}
.school-level:disabled img {opacity: .65; filter: saturate(.45)}

.school-controls {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
  padding: 9px max(13px, env(safe-area-inset-right)) 9px max(13px, env(safe-area-inset-left));
  background: #17294c;
  color: #fff;
}
.school-dpad {
  display: flex;
  gap: 3px;
  padding: 3px;
  border: 1px solid #546789;
  border-radius: 21px;
  background: #101e38;
  touch-action: none;
}
.school-controls button {
  display: grid;
  place-items: center;
  min-height: 56px;
  min-width: 60px;
  padding: 0;
  color: #f4f7ff;
  border: 0;
  border-radius: 16px;
  background: #354c77;
  touch-action: none;
  user-select: none;
  -webkit-user-select: none;
  transition: background .12s, color .12s;
}
.school-controls .school-jump {
  grid-auto-flow: column;
  justify-content: center;
  gap: 8px;
  padding-inline: 13px;
  min-width: 106px;
  background: #ffdc8e;
  color: #25314e;
  border-radius: 999px;
  font-size: .875rem;
  font-weight: 800;
}
.school-control-icon {
  width: 12px;
  height: 12px;
  border-top: 3px solid currentColor;
  border-right: 3px solid currentColor;
  transform: rotate(45deg);
}
[data-school-action="left"] .school-control-icon {transform: rotate(-135deg)}
.school-jump .school-control-icon {transform: translateY(3px) rotate(-45deg)}
.school-controls button[data-held] {background: #b8c9ff; color: #142444}
.school-controls .school-jump[data-held] {background: #fff2cb}
.school-controls button:focus-visible {outline-color: #ffedbe; outline-offset: 2px}

@media(max-width: 650px) {
  .school-feature {grid-template-columns: minmax(0, 1fr) 72px; border-radius: 22px}
  .school-level {border-radius: 15px}
}
@media(orientation: landscape) and (max-height: 600px) {
  .school-controls {padding-block: 4px}
  .school-controls button {min-height: 48px}
}

.experience-grid {grid-template-columns: repeat(2, minmax(0, 1fr))}
.experience-card {grid-template-columns: 56px minmax(0, 1fr)}
.experience-tag {grid-column: 2}
.lexicon-experience {background: #fff2d7; border-color: #fff9ed}
.lexicon-experience .experience-icon {object-fit: cover}
.lexicon-experience .eyebrow, .lexicon-experience .experience-tag {color: #815320}
.lexicon {padding: 22px 38px 64px}
.lexicon-intro p {max-width: 42rem; color: var(--muted); font-size: 1.1rem}
.lexicon-index {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-start;
  gap: 8px;
  margin: 24px 0;
  padding: 0;
  border: 0;
  background: none;
  box-shadow: none;
}
.lexicon-index a {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  min-height: 44px;
  padding: 6px 14px;
  border: 1px solid #d6dff1;
  border-radius: 999px;
  background: #fff;
  color: #2d4275;
  font-weight: 700;
  text-decoration: none;
}
.lexicon-index a:hover {background: #e6ecff}
.lexicon-index a[aria-current] {background: var(--ink); color: #fff; border-color: var(--ink)}
.lexicon-entry {
  max-width: 920px;
  display: grid;
  grid-template-columns: minmax(0, 40%) minmax(0, 1fr);
  align-items: center;
  border: 1px solid #dce4f6;
  border-radius: 23px;
  background: #fff;
  overflow: hidden;
}
.lexicon-entry img {width: 100%; height: auto; aspect-ratio: 1; object-fit: cover}
.lexicon-entry-copy {padding: clamp(18px, 4vw, 42px)}
.lexicon-entry h2 {font-size: clamp(1.25rem, 2.2vw, 1.65rem); margin: 0 0 8px; overflow-wrap: anywhere}
.lexicon-entry p {margin: 0; color: #35425d; line-height: 1.65}

@media(max-width: 880px) {
  .lexicon {padding-inline: 24px}
}
@media(max-width: 650px) {
  .experience-grid {grid-template-columns: 1fr}
  .experience-card {grid-template-columns: 44px minmax(0, 1fr)}
  .experience-icon {width: 44px; height: 44px}
  .lexicon {padding-inline: 16px}
  .lexicon-index {width: auto; max-width: none}
  .lexicon-entry {grid-template-columns: 1fr}
  .lexicon-entry img {max-height: 340px; object-fit: contain; background: #eef3ff}
}

.school-jump[data-trampoline]:not(:disabled) {outline: 3px solid #52eac0; outline-offset: 3px}
