.lab{margin:2rem 0;padding:clamp(1rem,4vw,2rem);border:1px solid #626b9e;border-radius:20px;background:#171d39;color:#f1efff}.lab p{max-width:72ch}.lab button,.lab input,.lab select{font:inherit;padding:.65rem .8rem;border:1px solid #a9b5eb;border-radius:9px;background:#252e52;color:#fff;min-height:44px}.lab button{cursor:pointer}.lab button:focus-visible,.lab input:focus-visible,.lab select:focus-visible{outline:3px solid #f5d477;outline-offset:2px}.lab button[aria-pressed=true]{background:#e7d6ff;color:#171d39}.lab-buttons,.lab form{display:flex;flex-wrap:wrap;gap:.5rem;align-items:center;margin:1rem 0}.lab input{max-width:100%;width:12rem}.block-board,.prism-board{display:grid;gap:4px;width:min(100%,360px);margin:1rem 0}.block-board{grid-template-columns:repeat(6,minmax(0,1fr))}.prism-board{grid-template-columns:repeat(4,minmax(0,1fr))}.block-board button,.prism-board>*{aspect-ratio:1;min-width:0;min-height:0;padding:0;display:grid;place-items:center;border:1px solid #929bc5;border-radius:7px}.block-board button[data-filled=true]{background:#ad87ec;color:#16152b}.prism-board .lit{background:#f5d477;color:#171d39}.swatch{height:72px;border:2px solid #c7cbed;border-radius:12px;width:min(100%,260px)}.lab a{color:#d7c6ff}@media(max-width:380px){.lab{padding:.75rem}}
.lab button:disabled{opacity:.48;cursor:default}.lab #letters button{min-width:44px;font-size:1.25rem;font-weight:700}.lab #answer{font-size:1.25rem;letter-spacing:.12em}.block-board button[data-fit=true]:not([data-filled=true]){border-color:#93c7a9}.block-board button.suggested{outline:3px solid #ffdb71;outline-offset:-3px}.prism-board .lit{box-shadow:inset 0 0 0 2px #fff4b4}.prism-board button{font-size:1.8rem;font-weight:700}.lab [role=status]{min-height:1.5em}.lab #color-buttons button:nth-child(1){border-color:#ff7c7c}.lab #color-buttons button:nth-child(2){border-color:#81e09b}.lab #color-buttons button:nth-child(3){border-color:#8bb1ff}

/* Arcade: native links remain usable without scripting. */
.arcade-hub{margin:2rem 0}.arcade-cards{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:1.25rem}.arcade-card{display:block;overflow:hidden;border:1px solid #7770a4;border-radius:20px;background:#191e3b;color:#fff;text-decoration:none;box-shadow:0 14px 32px #0004}.arcade-card img{display:block;width:100%;aspect-ratio:16/10;object-fit:cover}.arcade-card>div{padding:1.2rem}.arcade-card h3{margin:0;color:#fff}.arcade-card p{color:#d6d7ef}.arcade-card span{display:inline-block;padding:.65rem 1rem;background:#e0c7ff;color:#231438;border-radius:999px;font-weight:700}.arcade-card:hover,.arcade-card:focus-visible{border-color:#e7c6ff;outline:2px solid #e7c6ff;outline-offset:3px}.arcade-settings{display:flex;gap:1.25rem;flex-wrap:wrap;margin-top:1.5rem}.game-screen{max-width:850px;margin:1rem auto 3rem;min-height:min(68vh,650px);background:radial-gradient(ellipse at top right,#45416b 0,transparent 48%),linear-gradient(160deg,#202748,#11172e);box-shadow:0 24px 65px #0005}.game-top{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap;margin-bottom:1rem}.game-kicker{font-size:.72rem;letter-spacing:.15em;color:#d2c4f6}.game-meter{border:1px solid #857caf;border-radius:999px;padding:.45rem 1rem;display:inline-block;color:#e9d6ff}.game-screen .block-board,.game-screen .prism-board{margin:1.5rem auto;width:min(100%,420px);gap:6px}.game-screen #letters{justify-content:center;min-height:75px}.game-screen #letters button{border-radius:14px;min-width:48px;min-height:52px;background:linear-gradient(145deg,#6b568e,#302849);box-shadow:0 3px 0 #181329}.game-screen #letters button:disabled{background:#22283e;box-shadow:none}.game-screen #word-form{justify-content:center}.game-screen #clue{font-size:1.2rem;text-align:center}.game-screen .block-board button[data-filled=true]{background:linear-gradient(145deg,#e1b8f8,#8662bf);box-shadow:inset 0 0 0 2px #d7b8f7}.game-screen .prism-board .lit{background:linear-gradient(145deg,#fff2b3,#eebd5d);box-shadow:0 0 12px #ffc76b55}.game-screen .swatch{height:90px;box-shadow:inset 0 0 16px #ffffff22}.game-screen [role=status]{padding:.7rem .9rem;border-radius:10px;background:#0e142a;color:#f5eaff}.game-screen.celebrate{animation:arcade-win .55s ease-out}@keyframes arcade-win{50%{box-shadow:0 0 42px #c6a2ff88; border-color:#f6da8b}}.arcade-reduced .game-screen,.arcade-reduced .arcade-card{animation:none!important;transition:none!important}[hidden]{display:none!important}@media(max-width:600px){.arcade-cards{grid-template-columns:1fr}.game-screen{padding:1rem}.game-screen .prism-board{gap:3px}.game-screen .prism-board button{font-size:1.3rem}}@media(prefers-reduced-motion:reduce){.game-screen{animation:none!important}}

/* Illustrated arcade: the WebP pack is distributed as real deployable assets. */
.game-screen{max-width:1100px;margin:clamp(.5rem,2vw,1.5rem) auto 3rem;padding:clamp(1rem,3vw,2rem);border-color:#7b86a7;background:linear-gradient(150deg,#222b48,#11182f 72%);box-shadow:0 28px 80px #0007}
.game-screen h2{margin:.3rem 0 .8rem;font-size:clamp(1.65rem,3vw,2.35rem)}
.game-screen>p:not([role=status]){color:#e0e4f5}
.game-top{display:flex;align-items:center;gap:.75rem;flex-wrap:wrap}.game-top .game-kicker{margin-left:auto}.game-expand{font-size:.8rem!important;min-height:36px!important}
.game-stage{position:relative;isolation:isolate;overflow:hidden;border:1px solid #b7b6e788;border-radius:24px;min-height:360px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:.7rem;padding:clamp(12px,3vw,24px);margin:1rem 0;background-color:#18233a;background-size:cover;background-position:center;box-shadow:inset 0 0 50px #08142655,0 12px 25px #0004}
.scene-word{background-image:linear-gradient(180deg,#06132c44,#08132699),url('/assets/arcade/word.webp')}
.scene-prism{background-image:linear-gradient(180deg,#0a233844,#07192c99),url('/assets/arcade/prism.webp')}
.scene-blocks{background-image:linear-gradient(180deg,#17293d22,#0c243c88),url('/assets/arcade/blocks.webp')}
.scene-colors{background-image:linear-gradient(180deg,#200e3644,#1b0d3299),url('/assets/arcade/colors.webp')}
.arcade-card{background-color:#141b32}.arcade-card[href="#word"]{--card-art:url('/assets/arcade/word.webp')}.arcade-card[href="#prism"]{--card-art:url('/assets/arcade/prism.webp')}.arcade-card[href="#blocks"]{--card-art:url('/assets/arcade/blocks.webp')}.arcade-card[href="#colors"]{--card-art:url('/assets/arcade/colors.webp')}
.arcade-card img{object-fit:cover}.arcade-card.has-art img{object-position:center}
.game-screen .scene-clue{width:min(100%,620px);margin:0 auto;padding:.75rem 1.05rem;background:#071327d9;box-shadow:0 4px 20px #0005;border:1px solid #a5d7ed66;border-radius:14px;color:#fff;line-height:1.5}
.answer-slots{display:flex;flex-wrap:wrap;gap:5px;justify-content:center;width:100%}.answer-slot{display:grid;place-items:center;min-width:27px;width:clamp(27px,5vw,40px);height:clamp(34px,5.5vw,46px);border:1px solid #c4d6f3bb;border-bottom:3px solid #c7d6fe;background:#0c1738de;border-radius:7px;font-weight:800;font-size:1.1rem;color:#fff;text-shadow:0 0 8px #c0deff}
.word-wheel{position:relative;width:min(100%,310px);aspect-ratio:1;border-radius:50%;border:1px solid #c3b8ff77;background:radial-gradient(circle,#1427499e,#0c16269e 63%,#6c57c066 64%,#15223eab 68%,#080f2366 70%,transparent 71%);box-shadow:0 0 40px #81b5ff44}
.word-wheel::before{content:'✦';position:absolute;inset:42%;display:grid;place-items:center;color:#f8e2ff;font-size:2rem;text-shadow:0 0 18px #ff8eff}
.word-path{position:absolute;inset:0;width:100%;height:100%;pointer-events:none;filter:drop-shadow(0 0 5px #ae8cff)}
.game-screen #letters{position:absolute;inset:0;margin:0;display:block;min-height:0;touch-action:none;user-select:none}
.game-screen #letters button{position:absolute;left:var(--wheel-x);top:var(--wheel-y);transform:translate(-50%,-50%);width:clamp(35px,12%,53px);height:auto;aspect-ratio:1;min-width:0;min-height:0;border:2px solid #e4ccffa6;border-radius:50%;padding:0;font-size:clamp(1rem,3.5vw,1.35rem);background:radial-gradient(circle at 35% 20%,#f9d9ff,#9764d4 30%,#3c3474 62%,#141b3c 95%);box-shadow:inset 0 0 8px #c6e1ff66,0 3px 8px #061327aa,0 0 12px #b59cff44;color:#fff;text-shadow:0 1px 3px #180d35}
.game-screen #letters button:disabled{opacity:1;background:radial-gradient(circle at 35% 20%,#fff7ce,#aabcf9 35%,#6656a7 70%);color:#172041;border-color:#ffe7a7;box-shadow:0 0 16px #b1e1ff;cursor:default;text-shadow:none}
.game-screen #letters button:not(:disabled):hover{filter:brightness(1.2)}
.game-screen .game-stage #word-form{margin:0;gap:.5rem;justify-content:center;padding:.6rem .8rem;border:1px solid #91a6c766;border-radius:12px;background:#0b1731d9;max-width:100%}
.game-screen #word-form label{display:flex;align-items:center;gap:.45rem;flex-wrap:wrap;font-size:.9rem}.game-screen #answer{width:min(34vw,9rem);letter-spacing:.1em}
.game-screen #word-form button{background:linear-gradient(155deg,#ae8cf7,#6952b3);color:#fff;font-weight:700}
.prism-frame{position:relative;width:min(100%,480px);padding:0;border:3px solid #91d8e3b3;border-radius:12px;overflow:hidden;background:#0a1d35d9;box-shadow:0 0 35px #7ee7f944,inset 0 0 22px #5da5ff33}
.game-screen .prism-board{width:100%;margin:0;gap:0}
.game-screen .prism-board>*{position:relative;background:#0b1c3b9e;border:1px solid #b4c7e43b;border-radius:0;color:#c6eaff;font-size:0;box-shadow:none}
.game-screen .prism-board .lit{background:#356b9277;box-shadow:inset 0 0 10px #84eaff44}
.prism-board [data-kind="empty"]::before{content:'';width:5%;height:5%;min-width:3px;min-height:3px;border-radius:50%;background:#9aefff88}
.game-screen .prism-board button[data-kind="mirror"]{border-color:#acdfff88;background:radial-gradient(circle,#4c688cb3,#182748d9 70%);font-size:0}
.prism-board [data-kind="mirror"]::before{content:'';position:absolute;left:11%;top:44%;width:78%;height:12%;border-radius:4px;background:linear-gradient(#fff 0%,#d9f9ff 20%,#4badc7 52%,#e6fcff 75%,#6a85be 100%);box-shadow:0 0 10px #95f5ffb3,0 2px 5px #081127;transform:rotate(-45deg)}
.prism-board [data-kind="mirror"][data-orientation="1"]::before{transform:rotate(45deg)}
.prism-board [data-kind="target"]::before,.prism-board [data-kind="emitter"]::before{content:'';width:47%;height:47%;border:1px solid #d0f8ff;transform:rotate(45deg);border-radius:12%;background:linear-gradient(135deg,#effbff,#43baf3 30%,#8870d8 60%,#212e77);box-shadow:0 0 18px #78dbff88,inset 0 0 10px #fff}
.prism-board [data-kind="target"]::before{background:linear-gradient(135deg,#fdf6ff,#d779f4 35%,#7136a8 65%,#38236b)}.prism-board [data-kind="target"].lit::before{background:linear-gradient(135deg,#fff,#e6ffc5,#ffdf78);box-shadow:0 0 26px #fcffb8}
.prism-beam{position:absolute;inset:0;pointer-events:none;width:100%;height:100%;overflow:visible}.beam-halo{stroke:#4ddcff;stroke-width:.15;opacity:.7;filter:blur(2px)}.beam-core{stroke:#e8fcff;stroke-width:.045;filter:drop-shadow(0 0 3px #6fe4ff)}.beam-won .beam-core{stroke:#ffffc2}.beam-won .beam-halo{stroke:#ffdf75}
.game-screen .block-board{margin:0 auto;width:min(100%,420px);gap:4px;border:5px solid #bf9e61;border-radius:16px;padding:5px;background:#332e44df;box-shadow:0 6px 0 #4f3d31,0 16px 30px #0006}
.game-screen .block-board button{border-radius:5px;border:1px solid #e0d7fa55;background:#121f35d9;color:transparent;font-size:0;box-shadow:inset 0 1px 6px #0006}
.game-screen .block-board button[data-filled=true]{border-color:#f3ddff;background:linear-gradient(135deg,#fdf1ff 0%,#cf89ff 15%,#8354cb 48%,#4e318f 79%,#9671e0 100%);box-shadow:inset 2px 2px 0 #f8ddffb3,inset -3px -3px 0 #46257999,0 2px 5px #060e28}
.game-screen .block-board button[data-filled=true]:nth-child(3n){background:linear-gradient(135deg,#e9fbff,#72d5f3 20%,#3483c4 55%,#1c527b);border-color:#a4e8ff}
.game-screen .block-board button[data-filled=true]:nth-child(3n+2){background:linear-gradient(135deg,#fff6d6,#f7b95e 20%,#d7785d 55%,#95405c);border-color:#ffe2a8}
.game-screen .block-board button[data-fit=true]:not([data-filled=true]){border-color:#6e9eaa77}
.game-screen .block-board button.placement-preview{background:#7bdcc6b3;border-color:#d1ffdd;outline:2px solid #d1ffdd;outline-offset:-3px}
.game-screen .block-board button.placement-invalid{outline:2px solid #ff847b;outline-offset:-3px}
.game-screen #pieces{gap:.75rem;justify-content:center;margin:0;padding:.6rem 1rem;background:#10213cde;border:1px solid #e6c78d99;border-radius:14px;width:min(100%,420px)}
.game-screen #pieces button{position:relative;display:flex;align-items:flex-end;justify-content:center;min-width:78px;min-height:78px;padding:.35rem;border:1px solid #d5bdf766;color:#fff;font-size:.7rem;background:#1b3156;touch-action:none;user-select:none}
.game-screen #pieces button[aria-pressed=true]{background:#4b417e;border:2px solid #ffe4a6;box-shadow:0 0 14px #fde3a655}
.game-screen #pieces button::before{content:'';position:absolute;top:10px;left:50%;transform:translateX(-50%);width:26px;height:26px;border-radius:5px;border:1px solid #fce1ff;background:linear-gradient(135deg,#f7ddff,#a565ed 25%,#6338a2 90%);box-shadow:inset 1px 1px 0 #fff8,0 2px 5px #1119}
.game-screen #pieces button[data-shape="1"]::before{width:52px;background:linear-gradient(90deg,transparent 47%,#4c2764 48%,#4c2764 51%,transparent 52%),linear-gradient(135deg,#f7ddff,#a565ed 25%,#6338a2 90%)}
.game-screen #pieces button[data-shape="2"]::before{height:42px;width:22px;background:linear-gradient(0deg,transparent 47%,#4c2764 48%,#4c2764 51%,transparent 52%),linear-gradient(135deg,#f7ddff,#a565ed 25%,#6338a2 90%)}
.game-screen #pieces button.dragging{filter:brightness(1.35);cursor:grabbing}
.scene-caption{margin:0;padding:.35rem .65rem;border-radius:8px;background:#08172bd9;color:#fff;font-size:.82rem;text-align:center}
.line-cleared{animation:clear-gem .5s ease-out}@keyframes clear-gem{0%{background:#fff6c9;box-shadow:0 0 18px #f9e698}100%{box-shadow:none}}
.orb-pair{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:clamp(.7rem,5vw,3rem);width:min(100%,560px);text-align:center}
.orb-pair>div{display:flex;flex-direction:column;align-items:center;justify-content:center;padding:.65rem;background:#161130a8;border:1px solid #b9b2ef66;border-radius:18px}
.orb-pair p{margin:.15rem 0 .6rem;line-height:1.3;font-size:.9rem;color:#fff}.game-screen .orb-pair .swatch{position:relative;isolation:isolate;width:min(100%,155px);height:auto;aspect-ratio:1;border:2px solid #f2e6ff99;border-radius:50%;background-image:radial-gradient(ellipse at 28% 20%,#ffffffee 0%,#ffffff77 12%,transparent 39%),radial-gradient(ellipse at 50% 45%,transparent 43%,#000a 100%);box-shadow:inset 0 0 18px #fff8,0 0 24px #b084ff66}
.game-screen .orb-pair .swatch::after{content:'';position:absolute;inset:7%;border-radius:50%;border:1px solid #ffffff55;border-bottom:0;border-right:0;transform:rotate(-25deg)}
.game-screen #color-buttons{justify-content:center;margin:.5rem 0;padding:.5rem 1rem;border-radius:999px;background:#10122fcf;border:1px solid #d4b5ee77}
.game-screen #color-buttons button{--channel:#cf6ad7;min-width:58px;min-height:58px;aspect-ratio:1;border-radius:50%;border:2px solid #fff7;color:white;font-weight:700;text-shadow:0 1px 4px #000;background:radial-gradient(circle at 35% 20%,#fff9,var(--channel) 30%,#181930 95%);box-shadow:0 0 10px #0004}
.game-screen #color-buttons button[data-channel="red"]{--channel:#d93e62}.game-screen #color-buttons button[data-channel="green"]{--channel:#168e64}.game-screen #color-buttons button[data-channel="blue"]{--channel:#3673dc}.game-screen #color-buttons button[aria-pressed=true]{border-color:#ffedbb;box-shadow:0 0 20px var(--channel),inset 0 0 10px #fff7}
.arcade-focus header.site-header,.arcade-focus footer,.arcade-focus .guide-skip{display:none!important}.arcade-focus main.shell{max-width:1250px;width:100%;padding:10px;min-height:100dvh}.arcade-focus .game-screen{margin:0 auto;max-width:1200px}.arcade-focus .game-stage{min-height:min(65vh,580px)}
@media(max-width:600px){.game-stage{min-height:0;border-radius:14px;padding:12px 8px}.game-screen{padding:12px}.game-top .game-kicker{display:none}.game-top .game-expand{margin-left:auto}.word-wheel{width:min(100%,290px)}.game-screen #pieces{padding:.55rem .35rem;gap:.35rem}.game-screen #pieces button{min-width:65px;font-size:.64rem}.prism-frame{width:100%}.game-screen .prism-board button{font-size:0}.game-screen .orb-pair .swatch{max-width:130px}.game-screen .block-board{gap:3px}.game-screen #word-form label{justify-content:center}.game-screen #word-form button{padding:.45rem .65rem}}
@media(prefers-reduced-motion:reduce){.line-cleared{animation:none!important}}.arcade-reduced .line-cleared{animation:none!important}

/* Game-route layout: do not let the global sticky header cover the game toolbar. */
.arcade-page .guide-skip:not(:focus){clip-path:inset(50%);width:1px;height:1px;overflow:hidden;padding:0;transform:none}
.arcade-page .guide-skip:focus{position:fixed;top:8px;left:8px;z-index:2000}
.arcade-page .guide-hero img{object-fit:cover;aspect-ratio:16/10}
.arcade-playing header.site-header{position:relative;top:auto}
.arcade-playing main.guide-main{padding-top:12px;padding-bottom:16px;min-height:0}
.arcade-playing .game-screen{margin:12px auto;min-height:0}
.arcade-playing .game-top{margin-bottom:.55rem}
.arcade-playing .game-screen h2{margin:.2rem 0 .6rem}
.game-help{margin:0 0 .6rem;color:#e0e4f5;font-size:.9rem}.game-help summary{cursor:pointer;display:list-item;width:fit-content;color:#d9c8ff;padding:.3rem 0}.game-help p{margin:.4rem 0;line-height:1.55}
.game-options{display:flex;flex-wrap:wrap;align-items:center;gap:.6rem;margin:.5rem 0}.game-options label{display:flex;align-items:center;gap:.4rem;flex-wrap:wrap}.game-options .game-meter{margin:0}
.game-audio{font-size:.8rem!important;min-height:36px!important}
.game-screen #letters button{width:var(--tile-size,16%);max-width:62px;min-width:40px;font-size:clamp(1.1rem,4vw,1.55rem)}
.game-screen #word-path polyline{stroke:#f8e0ff;stroke-width:2.8}
.prism-board [data-kind="emitter"]::before,.prism-board [data-kind="target"]::before{position:absolute;left:50%;top:50%;transform:translate(-50%,-50%) rotate(45deg)}
.prism-board [data-kind="mirror"]::before{transition:transform .18s ease}
.beam-halo{animation:beam-breathe 1.7s ease-in-out infinite alternate}@keyframes beam-breathe{from{opacity:.45}to{opacity:.95}}
.game-screen #color-buttons button{width:64px;height:64px;min-width:64px;min-height:64px;padding:0}
.win-particles{position:absolute;inset:0;pointer-events:none;z-index:5;overflow:hidden}.win-particles i{position:absolute;left:50%;top:50%;color:#fff3a8;font-size:1.5rem;font-style:normal;text-shadow:0 0 12px #ffcf79;animation:arcade-spark .9s ease-out both}@keyframes arcade-spark{from{transform:translate(-50%,-50%) rotate(var(--angle)) translateX(0) scale(.4);opacity:1}to{transform:translate(-50%,-50%) rotate(var(--angle)) translateX(var(--distance)) scale(.9);opacity:0}}
.arcade-page footer .copyright{display:flex;flex-wrap:wrap;gap:.8rem;justify-content:space-between}
.arcade-playing footer{padding-top:1rem;padding-bottom:1rem}
.arcade-focus main.guide-main{padding:10px;min-height:100dvh}.arcade-focus .game-screen{margin:0 auto}
@media(max-width:750px){.arcade-playing main.guide-main{padding:8px 12px 16px}.arcade-playing .game-screen{width:100%;margin:0 auto;padding:12px;min-height:0}.arcade-playing .game-stage{min-height:0;margin:.6rem 0}.arcade-playing .game-top{gap:.4rem;justify-content:flex-start}.arcade-playing .game-top .game-expand{margin-left:auto}.arcade-playing .game-top a{font-size:.9rem}.arcade-playing .game-screen h2{font-size:1.45rem}.arcade-playing .game-options{gap:.4rem;font-size:.85rem}.arcade-playing .game-options select{padding:.35rem;min-height:40px}.arcade-playing .game-meter{font-size:.8rem;padding:.4rem .65rem}.arcade-playing .game-help{font-size:.85rem}.arcade-playing .game-screen>.lab-buttons{gap:.4rem;margin:.65rem 0}.arcade-playing .game-screen>.lab-buttons button{font-size:.85rem;padding:.5rem .65rem}.arcade-playing .game-screen>p:not([role=status]){font-size:.85rem;line-height:1.45}.arcade-playing .game-screen [role=status]{margin:.5rem 0}.game-screen #color-buttons button{width:56px;height:56px;min-width:56px;min-height:56px}.game-screen .word-wheel{width:min(100%,270px)}.scene-word{background-position:50% 35%}.scene-prism{background-position:50% 40%}.scene-blocks{background-position:50% 50%}.scene-colors{background-position:50% 40%}}
.arcade-reduced .beam-halo,.arcade-reduced .win-particles i{animation:none!important}.arcade-reduced .prism-board [data-kind="mirror"]::before{transition:none!important}
@media(prefers-reduced-motion:reduce){.beam-halo,.win-particles i{animation:none!important}.prism-board [data-kind="mirror"]::before{transition:none!important}}

/* Advanced practice controls and local achievement milestones. */
.game-screen h2[tabindex="-1"]:focus{outline:none}.game-screen h2[tabindex="-1"]:focus-visible{text-decoration:underline;text-decoration-color:#b7a4e8;text-underline-offset:5px}
.achievement-grid{display:flex;flex-wrap:wrap;gap:8px;margin:12px 0 20px}.achievement-grid span{padding:8px 12px;border:1px solid #b4a5dd66;border-radius:12px;font-size:.86rem}.achievement-grid .earned{color:#ffe7a3;background:#5c442c55;border-color:#d5af6f}.achievement-grid .locked{color:#b8bdd2;background:#11182e}
.game-screen #pieces{flex-wrap:wrap}.game-screen #pieces button[data-shape="3"]::before{width:36px;height:36px;clip-path:polygon(0 0,50% 0,50% 50%,100% 50%,100% 100%,0 100%);background:linear-gradient(135deg,#f7ddff,#a565ed 35%,#6338a2)}.game-screen #pieces button[data-shape="4"]::before{width:36px;height:36px;background:linear-gradient(90deg,transparent 47%,#56316d 48% 52%,transparent 53%),linear-gradient(0deg,transparent 47%,#56316d 48% 52%,transparent 53%),linear-gradient(135deg,#f7ddff,#a565ed 35%,#6338a2)}.game-screen #pieces button[data-shape="5"]::before{width:54px;height:36px;clip-path:polygon(0 0,100% 0,100% 50%,66% 50%,66% 100%,33% 100%,33% 50%,0 50%);background:linear-gradient(135deg,#f7ddff,#a565ed 35%,#6338a2)}
#block-combo:empty{display:none}#block-combo{color:#ffe5a2;font-weight:700}#color-intensity{display:grid;gap:12px;width:min(100%,440px);padding:12px;background:#11152fdd;border-radius:14px;border:1px solid #c3a5ee77}#color-intensity label{display:grid;grid-template-columns:48px minmax(0,1fr) 35px;align-items:center;gap:8px;color:#fff;font-size:.85rem}#color-intensity input{width:100%;min-width:0;min-height:36px;accent-color:#cfb5ff}#color-intensity label:nth-child(1) input{accent-color:#ed5670}#color-intensity label:nth-child(2) input{accent-color:#38b78a}#color-intensity label:nth-child(3) input{accent-color:#6a99ff}#color-intensity output{font-variant-numeric:tabular-nums;text-align:right}

/* Spectral optics: color plus visible symbols for non-color recognition. */
.spectral-active>.beam-core,.spectral-active>.beam-halo{display:none}
.spectral-active .spectral-segment{filter:drop-shadow(0 0 2px currentColor)}
.spectral-board [data-color="1"]{--spectral-color:#ff626f}
.spectral-board [data-color="2"]{--spectral-color:#66f1a1}
.spectral-board [data-color="4"]{--spectral-color:#7da9ff}
.spectral-board [data-color="7"]{--spectral-color:#fff}
.game-screen .spectral-board [data-kind="emitter"]::before,.game-screen .spectral-board [data-kind="target"]::before{background:linear-gradient(135deg,#fff,var(--spectral-color) 45%,#233256);box-shadow:0 0 12px var(--spectral-color)}
.game-screen .spectral-board [data-kind="target"]:not(.matched)::before{background:#14213b;border:2px solid var(--spectral-color);box-shadow:none}
.game-screen .spectral-board [data-kind="target"].matched::before{background:var(--spectral-color);box-shadow:0 0 16px var(--spectral-color)}
.game-screen .spectral-board [data-kind="splitter"]::before{content:'↱';font-size:clamp(16px,4vw,28px);color:#c8f5ff;line-height:1;z-index:1}
.game-screen .spectral-board [data-kind="filter"]::before{content:'';width:46%;height:72%;background:var(--spectral-color);border:2px solid #e9f4ff;border-radius:5px;opacity:.8;transform:rotate(15deg)}
.game-screen .spectral-board [data-kind="obstacle"]::before{content:'×';font-size:clamp(18px,4vw,30px);font-weight:700;background:#302739;color:#e1bdc2;width:72%;height:72%;display:grid;place-items:center;border:1px solid #8c778e;border-radius:6px;line-height:1}
.spectral-board [data-color]::after{content:attr(data-symbol);position:absolute;bottom:2px;right:3px;font-size:10px;font-weight:800;color:#fff;text-shadow:0 1px 3px #000;z-index:2}
#spectral-legend{font-size:.84rem;line-height:1.5;color:#d5e8fc;margin:.5rem 0}
.floating-piece{position:fixed;z-index:10000;width:var(--unit);height:var(--unit);pointer-events:none;opacity:.85;filter:drop-shadow(0 5px 5px #0009)}
.floating-piece span{position:absolute;top:calc(var(--r)*var(--unit));left:calc(var(--c)*var(--unit));width:var(--unit);height:var(--unit);box-sizing:border-box;border:2px solid #eed6ff;border-radius:7px;background:linear-gradient(135deg,#f9e3ff 0%,#d5a5ef 22%,#9d68cf 50%,#62449a 75%,#b894ea);box-shadow:inset 0 0 0 2px #ffffff55}
.floating-piece[data-valid="true"] span{border-color:#91ffd5;box-shadow:inset 0 0 0 2px #ffffff66,0 0 8px #64efb8}
.floating-piece[data-valid="false"] span{border-color:#ff7c8d;background:linear-gradient(135deg,#ffd1da,#a54669);box-shadow:0 0 8px #ff738a}

/* Before the deferred game engine runs, reserve only the requested screen. */
html[data-arcade-entry] .arcade-page .guide-hero,html[data-arcade-entry] .arcade-page #arcade,html[data-arcade-entry] .arcade-page .arcade-progress,html[data-arcade-entry] .arcade-page #arcade-journal{display:none!important}
html[data-arcade-entry] .arcade-page .game-screen{display:none!important}
html[data-arcade-entry="word"] .arcade-page #word,html[data-arcade-entry="prism"] .arcade-page #prism,html[data-arcade-entry="blocks"] .arcade-page #blocks,html[data-arcade-entry="colors"] .arcade-page #colors{display:block!important}
html[data-arcade-hub] .arcade-page .game-screen{display:none!important}
.arcade-page .guide-hero p a,.arcade-page .lab p a,.arcade-page .arcade-journal p a,.arcade-page footer a{text-decoration:underline;text-underline-offset:.18em}
.arcade-page .game-top a{text-decoration:underline;text-underline-offset:.18em}
.arcade-page .guide-hero img{height:auto;aspect-ratio:16/10}

html[data-arcade-entry] .arcade-page header.site-header{position:relative;top:auto}
html[data-arcade-entry] .arcade-page main.guide-main{padding-top:12px;padding-bottom:16px;min-height:0}
html[data-arcade-entry] .arcade-page .game-screen{margin:12px auto;min-height:0}
html[data-arcade-entry-focus] .arcade-page header.site-header,html[data-arcade-entry-focus] .arcade-page footer,html[data-arcade-entry-focus] .arcade-page .guide-skip{display:none!important}
@media(max-width:750px){html[data-arcade-entry-focus] .arcade-page main.guide-main{max-width:1250px;width:100%;padding:8px 12px 16px;min-height:100dvh}html[data-arcade-entry-focus] .arcade-page .game-screen{width:100%;max-width:1200px;margin:0 auto;padding:12px;min-height:0}html[data-arcade-entry-focus] .arcade-page .game-stage{min-height:0;margin:.6rem 0}html[data-arcade-entry-focus] .arcade-page .game-screen h2{font-size:1.45rem;margin:.2rem 0 .6rem}}
