:root{--ink:#224350;--teal:#087f89;--purple:#795fc4;--line:#dce6ed;--paper:#f2f6f9}*{box-sizing:border-box}[hidden]{display:none!important}body{margin:0;background:var(--paper);color:var(--ink);font-family:system-ui,'Segoe UI',sans-serif}button,input,textarea{font:inherit}button{cursor:pointer}a{color:inherit}button:focus-visible,a:focus-visible,input:focus-visible,textarea:focus-visible,[tabindex]:focus-visible{outline:3px solid #1596a6;outline-offset:4px}.skills-top{min-height:78px;background:#183e49;color:white;padding:15px 25px;display:flex;align-items:center;gap:18px}.skills-brand{background:white;border-radius:12px;padding:5px;display:flex}.skills-top small{font-size:9px;letter-spacing:1.8px;color:#a9c9d0;font-weight:700}.skills-top h1{font-size:21px;margin:3px 0 0;line-height:1.15}.skills-top nav{display:flex;justify-content:center;gap:8px;flex:1}.skills-top nav button{width:34px;height:34px;border-radius:50%;border:1px solid #597680;color:#c2d7dc;background:#ffffff0e;font-size:13px;font-weight:700}.skills-top nav button.current{background:#f6cf5d;color:#183e49;border-color:#f6cf5d;box-shadow:0 0 0 3px #f6cf5d26}.skills-top nav button.completed{background:#299780;color:white;border-color:#299780}.skills-top>button{color:white;border:1px solid #5c7a85;background:none;border-radius:8px;padding:10px 14px;font-size:12px}.skills-layout{max-width:1440px;display:grid;grid-template-columns:225px 1fr;gap:24px;margin:auto;padding:25px;min-height:calc(100dvh - 78px)}.skills-layout>aside{display:flex;flex-direction:column;gap:8px;padding-top:4px}.skills-layout>aside button{text-align:left;padding:14px 15px;background:none;border:1px solid transparent;border-radius:12px;display:grid;grid-template-columns:25px 1fr;gap:5px 8px;color:#516c78}.skills-layout>aside button>span{grid-row:span 2;align-self:center;border:1px solid #c6d7df;border-radius:50%;width:25px;height:25px;display:grid;place-items:center;font-size:11px}.skills-layout>aside button b{font-size:13px;font-weight:650}.skills-layout>aside button small{font-size:10px;color:#8295a0}.skills-layout>aside button.current{background:white;border-color:var(--line);box-shadow:0 3px 10px #183e4907}.skills-layout>aside button.completed>span{color:#21816b;border-color:#81bfad;background:#ebf7f1}.skills-main{min-width:0;display:flex;flex-direction:column;background:white;border:1px solid var(--line);border-radius:20px;overflow:hidden}.skill-heading{padding:22px 26px;display:flex;align-items:center;justify-content:space-between;gap:22px;border-bottom:1px solid var(--line)}.skill-heading span{font-size:10px;color:#8872b9;font-weight:750;letter-spacing:1.5px;text-transform:uppercase}.skill-heading h2{font-size:25px;margin:7px 0 8px;letter-spacing:-.7px}.skill-heading p{font-size:13px;line-height:1.65;margin:0;max-width:740px;color:#667f8b}.skill-play{position:relative;flex:1;min-height:345px;background:#edf5f9;overflow:hidden;display:flex;flex-direction:column;justify-content:center;align-items:center;padding:25px}.skill-bottom{min-height:78px;border-top:1px solid var(--line);padding:15px 24px;display:flex;align-items:center;gap:10px}.skill-bottom p{font-size:12px;color:#5f7d89;line-height:1.5;margin:0;flex:1}.skill-bottom button,dialog button{border:1px solid #ccdce4;color:#3d6575;background:white;border-radius:10px;padding:11px 15px;font-size:12px;font-weight:650}.skill-bottom .primary,.primary{border:0;background:#087f89;color:white;border-radius:10px;padding:12px 17px;font-weight:650}.garden{width:min(760px,100%);display:grid;grid-template-columns:repeat(3,1fr);gap:24px;align-items:center;justify-items:center}.firefly,.seed,.gift,.kite{border:0;position:relative;display:grid;place-items:center;width:110px;height:110px;border-radius:50%;background:#e1eedb;touch-action:manipulation}.firefly{background:#1e5360}.firefly:before{content:'';width:35px;height:35px;border-radius:50%;background:#fddd67;box-shadow:0 0 0 12px #fddd6720,0 0 35px #fddd6770}.firefly.found:before{background:#8fd6bf;box-shadow:0 0 0 12px #8fd6bf20}.firefly.found:after{content:'✓';position:absolute;right:9px;bottom:4px;font-size:22px;color:#baf4de}.seed svg,.gift svg,.kite svg{width:88px;height:88px;pointer-events:none}.gift{border-radius:20px;background:#e8def9}.gift.opened{background:#dff3e8}.kite{background:#e0edfc}.play-note{font-size:12px;line-height:1.6;color:#5e7a89;margin:20px 0 0;text-align:center}.touch-mode{border:1px solid #bdd3df;background:white;color:#487688;border-radius:8px;padding:9px 13px;font-size:11px;margin:15px}.context-colours{position:absolute;z-index:4;background:white;box-shadow:0 12px 30px #26404f30;border:1px solid #d5e2eb;border-radius:12px;padding:8px;display:flex;gap:6px}.context-colours button{width:40px;height:40px;border-radius:8px;border:2px solid white;background:var(--color)}.drag-layout{display:grid;grid-template-columns:1fr 1fr;gap:24px;width:100%;max-width:760px;align-items:center}.bag-items,.bag-pockets{display:grid;grid-template-columns:1fr 1fr;gap:15px}.bag-item{height:98px;border:1px solid #b8d6df;background:white;border-radius:14px;padding:10px;text-align:center;cursor:grab;touch-action:none;user-select:none}.bag-item svg{height:57px;width:57px;display:block;margin:auto;pointer-events:none}.bag-item span{font-size:11px;pointer-events:none}.bag-item.dragging{box-shadow:0 12px 20px #26435330;z-index:8;cursor:grabbing;position:relative}.bag-item.packed{opacity:.4}.pocket{height:125px;border:2px dashed #9cbcc8;background:#dfedf4;border-radius:17px;display:flex;align-items:center;justify-content:center;flex-direction:column;gap:6px;font-size:12px;color:#658291}.pocket svg{width:51px;height:51px;opacity:.45}.pocket.packed{border-style:solid;border-color:#6eb597;background:#e8f5ed;color:#28785f}.journal{height:300px;overflow:auto;overscroll-behavior:contain;width:min(600px,100%);background:#fffdf4;box-shadow:0 6px 20px #314f6610;border:1px solid #e4dfcf;border-radius:12px;padding:24px;scrollbar-width:auto}.journal article{min-height:180px;border-bottom:1px dashed #d3cebd;padding-bottom:24px;margin-bottom:24px}.journal h3{font-size:20px}.journal p{color:#84947d;font-size:14px;line-height:1.8}.journal-leaf{display:block;margin:18px auto;background:#e1f2dd;color:#277b56;border:1px solid #8bba91;border-radius:30px;padding:15px 23px;font-size:16px}.post-map{display:grid;grid-template-columns:repeat(5,1fr);gap:7px;width:310px;max-width:100%;padding:10px;background:#dbead9;border-radius:13px;outline:0}.post-cell{height:50px;display:grid;place-items:center;background:#edf5e7;border-radius:5px}.post-cell svg{width:37px;height:37px}.arrow-controls{display:flex;gap:7px;margin-top:12px}.arrow-controls button{border:1px solid #b6ced9;border-radius:8px;background:white;padding:12px;color:#355e71}.message-card{background:white;border:1px solid #dce4e8;border-radius:18px;padding:25px;width:min(560px,100%)}.message-card label{font-size:13px;display:block;line-height:1.8}.message-card input{padding:14px;width:100%;border:1px solid #bdd1de;border-radius:9px;margin:15px 0;font-size:19px}.message-card kbd{background:#edf2f6;border:1px solid #cedce5;border-radius:5px;padding:3px 6px}.typing-play{background:linear-gradient(130deg,#edf5fb,#f2effa);gap:20px}.typing-card{width:min(830px,100%);text-align:center}.typing-line{font-family:ui-monospace,Consolas,monospace;letter-spacing:.5px;font-size:clamp(20px,2.5vw,30px);line-height:1.8;white-space:pre-wrap;overflow-wrap:anywhere;margin:5px 0 18px;display:block}.typing-line span.correct{color:#28835e}.typing-line span.wrong{background:#ffe5dd;color:#b24d36;border-radius:3px}.typing-line span.caret{border-bottom:3px solid #795fc4;background:#e0d8f5}.typing-input{width:100%;border:2px solid #b8cddd;background:white;border-radius:12px;padding:15px 18px;font-size:19px;line-height:1.7;color:#304d60;resize:none;min-height:65px}.typing-input:focus{border-color:#795fc4;outline:none;box-shadow:0 0 0 3px #795fc414}.typing-stats{display:flex;justify-content:center;gap:28px;color:#5a7380;font-size:12px;margin:15px 0 8px}.typing-stats strong{color:#35596a}.keyboard{width:min(720px,100%);padding:12px;background:#d6e0eb;border-radius:14px;border-bottom:5px solid #afc2d3;user-select:none}.keyboard-row{display:flex;justify-content:center;gap:5px;margin:5px 0}.keyboard kbd{display:grid;place-items:center;flex:1;max-width:55px;min-height:38px;background:#fbfdff;border:1px solid #bccada;border-bottom:3px solid #b2c4d3;border-radius:6px;font-size:12px;color:#4b6373}.keyboard kbd.next{background:#8064cb;border-color:#8064cb;color:white;box-shadow:0 0 0 3px #8064cb26}.keyboard kbd.home-key{border-bottom-color:#846ccd}.keyboard kbd.wide{max-width:none;flex:2}.keyboard kbd.space{max-width:270px;flex:5}.line-pips{display:flex;justify-content:center;gap:7px;margin-bottom:13px}.line-pips i{height:6px;width:30px;border-radius:5px;background:#cedce5}.line-pips i.done{background:#48a18a}.line-pips i.current{background:#8064cb}.quest-complete{width:100%;height:100%;min-height:320px;display:flex;align-items:center;justify-content:center;flex-direction:column;gap:9px;text-align:center}.quest-complete img{width:86px;height:86px}.quest-complete h3{font-size:28px;margin:8px 0}.quest-complete p{font-size:14px;line-height:1.7;max-width:450px;color:#617c8b}.quest-complete a{color:#087f89;font-size:14px}dialog{border:1px solid #d7e2e9;border-radius:18px;background:white;color:#294b59;padding:28px;max-width:520px;max-height:calc(100dvh - 36px);overflow:auto}dialog::backdrop{background:#173e4960}dialog p{font-size:14px;line-height:1.8;color:#68838e}
@media(max-width:1050px){.skills-layout{grid-template-columns:180px 1fr;gap:17px;padding:18px}.skill-heading{padding:18px}.skill-heading h2{font-size:22px}.garden{gap:18px}.skills-top nav{gap:5px}.skills-top nav button{width:29px;height:29px}.skills-top h1{font-size:18px}.skill-play{padding:20px}.keyboard kbd{min-height:32px}.skills-layout>aside button{padding:13px 8px}}
@media(max-width:760px){.skills-top{padding:12px 14px;gap:12px;flex-wrap:wrap}.skills-top h1{font-size:17px}.skills-top>button{margin-left:auto;font-size:10px;padding:8px}.skills-top nav{order:4;flex-basis:100%;padding-top:5px}.skills-layout{display:block;padding:13px;min-height:0}.skills-layout>aside{display:none}.skill-heading{padding:18px;align-items:flex-start;gap:12px}.skill-heading p{font-size:12px}.skill-heading h2{font-size:22px}.skill-heading img{width:46px;height:46px}.skill-play{min-height:355px;padding:20px 15px}.garden{gap:16px}.firefly,.seed,.gift,.kite{width:82px;height:82px}.seed svg,.gift svg,.kite svg{width:65px;height:65px}.skill-bottom{padding:13px;flex-wrap:wrap}.skill-bottom p{flex-basis:100%;font-size:12px}.drag-layout{gap:16px}.bag-items,.bag-pockets{gap:9px}.bag-item{height:80px;padding:6px}.bag-item svg{height:42px;width:42px}.pocket{height:93px;font-size:10px}.pocket svg{width:39px;height:39px}.keyboard{padding:5px}.keyboard-row{gap:3px}.keyboard kbd{font-size:10px;min-height:28px}.typing-input{font-size:16px}.typing-stats{gap:15px}.message-card{padding:16px}}
@media(prefers-reduced-motion:reduce){*{transition:none!important;animation: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}

/* Keep the lesson header, activity and controls together on classroom screens. */
@media(min-width:761px){body{overflow:hidden}.skills-top{height:82px}.skills-layout{height:calc(100dvh - 82px);min-height:0;padding:20px 25px}.skills-layout>aside{min-height:0;overflow:auto}.skills-layout>aside button{padding:12px 15px}.skills-layout>aside button small{font-size:12px}.skills-main{min-height:0}.skill-heading{padding:16px 23px;flex-shrink:0}.skill-heading h2{font-size:24px;margin:5px 0}.skill-play{min-height:0;overflow:auto;padding:18px 24px}.skill-bottom{min-height:66px;padding:11px 20px;flex-shrink:0}.typing-play{gap:10px}.typing-line{font-size:26px;line-height:1.5;margin:0 0 10px}.typing-input{min-height:50px;line-height:1.4;padding:10px 15px}.typing-stats{margin:10px 0 2px}.keyboard{padding:7px 10px}.keyboard-row{margin:4px 0}.keyboard kbd{min-height:30px}.typing-play .play-note{margin:0}}
.message-card>svg{width:88px;height:88px;display:block;margin:0 auto 15px}.journal article>svg{width:110px;height:110px;display:block;margin:auto}.firefly:before{position:absolute;width:24px;height:24px;top:58%;left:40%;opacity:.65}.firefly>svg{width:86px;height:86px;position:relative}.firefly.found>svg{opacity:.65}

/* Ten-puzzle skill chapters: the activity owns the available screen space. */
.chapter-picker{display:none}.chapter-picker select{max-width:200px;background:#28515c;color:white;border:1px solid #66818a;padding:9px;border-radius:9px}
.garden{grid-template-columns:repeat(var(--cols,3),1fr);gap:clamp(12px,2.5vh,25px);max-width:820px}
.garden button{width:clamp(58px,7.4vw,106px);height:clamp(58px,7.4vw,106px);transition:background .18s,box-shadow .18s}
.garden button svg{width:82%;height:82%}.garden button.found,.garden button.opened{box-shadow:0 0 0 3px #7ac5a3}
.garden:has([data-target="12"]) button{width:clamp(56px,6.3vw,84px);height:clamp(56px,6.3vw,84px)}
.drag-layout:has([data-item="star"]){max-width:900px;gap:25px}.drag-layout:has([data-item="star"]) .bag-items,.drag-layout:has([data-item="star"]) .bag-pockets{grid-template-columns:repeat(3,1fr);gap:10px}
.drag-layout:has([data-item="star"]) .pocket,.drag-layout:has([data-item="star"]) .bag-item{height:86px}.drag-layout:has([data-item="star"]) svg{width:45px;height:45px}
.journal article small{color:#6a897a;font-size:11px;font-weight:700;letter-spacing:1px}.journal article:last-child{margin:0;border:0}
@media(max-width:1000px){.skills-top{gap:10px;padding:12px 16px}.skills-top h1{font-size:18px}.skills-top nav{gap:5px}.skills-top nav button{width:30px;height:30px}.skills-layout{grid-template-columns:190px 1fr}.garden{gap:12px}}
@media(max-width:760px){.chapter-picker{display:block}.skills-top>button{margin-left:0}.garden{gap:9px;grid-template-columns:repeat(4,1fr)}.garden button,.garden:has([data-target="12"]) button{width:clamp(55px,16vw,83px);height:clamp(55px,16vw,83px)}.drag-layout{gap:10px!important}.drag-layout:has([data-item="star"]) .bag-items,.drag-layout:has([data-item="star"]) .bag-pockets{grid-template-columns:repeat(2,1fr)}.skill-play:has(.bag-item){overflow:auto;justify-content:flex-start}.journal{height:325px}}

@media(min-width:761px){.typing-play{padding-top:14px;padding-bottom:14px}}
