:root{--bg:#0f0d0b;--bg-2:#161310;--panel:#1e1a16db;--panel-solid:#1e1a16;--line:#fff0dc14;--line-2:#fff0dc24;--text:#f3eee5;--text-2:#bdb4a7;--text-3:#a29686;--chip:#fff0dc0e;--chip-hover:#fff0dc1a;--accent:#d8b26c;--accent-2:#e8cd9a;--on-accent:#211704;--accent-soft:#d8b26c29;--trig-bg:#d8b26c14;--trig-line:#d8b26c3d;--good:#3ddc97;--bad:#ff5d73;--warn:#ffc857;--bad-text:#ffc2cb;--brass-top:#e3c07e;--brass-bottom:#cda45c;--brass-top-hover:#ecca8c;--brass-bottom-hover:#d8b06a;--radius:16px;--radius-sm:10px;--shadow:0 20px 50px -20px #000000b3, 0 1px 0 #fff0dc12 inset;--mono:"JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;--lightningcss-light: ;--lightningcss-dark:initial;color-scheme:dark}*{box-sizing:border-box}html,body{height:100%;margin:0}html{touch-action:manipulation}body{background:radial-gradient(1200px 800px at 50% 45%, #28211b 0%, transparent 60%), radial-gradient(900px 600px at 80% 110%, #d8b26c1a, transparent 60%), var(--bg);color:var(--text);-webkit-font-smoothing:antialiased;font-family:Inter,system-ui,-apple-system,Segoe UI,sans-serif;font-size:14px;line-height:1.45;overflow:hidden}button,input{font:inherit;color:inherit}svg{fill:none;stroke:currentColor;stroke-width:2px;stroke-linecap:round;stroke-linejoin:round;flex:none;width:18px;height:18px}.hidden{display:none!important}.sr-only{clip-path:inset(50%);white-space:nowrap;width:1px;height:1px;margin:-1px;position:absolute;overflow:hidden}.muted{color:var(--text-2)}.small{font-size:12.5px}.app{grid-template-rows:60px minmax(0,1fr);grid-template-columns:340px 1fr 340px;height:100dvh;display:grid}.stage{-webkit-user-select:none;user-select:none;-webkit-touch-callout:none;-webkit-tap-highlight-color:transparent;grid-area:1/1/-1/-1;min-height:0;position:relative}.stage canvas{touch-action:none;outline:none;width:100%;height:100%;display:block}.topbar{z-index:2;pointer-events:none;grid-area:1/1/auto/-1;justify-content:space-between;align-items:center;padding:0 18px;display:flex}.topbar>*{pointer-events:auto}.panel{z-index:2;background:var(--panel);-webkit-backdrop-filter:blur(10px);border:1px solid var(--line);box-shadow:var(--shadow);scrollbar-width:thin;border-radius:20px;flex-direction:column;grid-row:2;align-self:start;gap:14px;max-height:calc(100% - 20px);margin:4px 16px 16px;padding:16px;display:flex;overflow-y:auto}.panel>*{flex-shrink:0}.panel.left{grid-column:1}.panel.right{grid-column:3}.brand{letter-spacing:-.01em;align-items:center;gap:10px;font-size:15px;font-weight:650;display:flex}.logo{box-shadow:0 0 0 1px var(--line-2);background:#0d0f14;border-radius:5px;grid-template-columns:repeat(3,7px);gap:2px;padding:3px;display:grid}.logo i{background:#f4f4ef;border-radius:3px;width:7px;height:7px}.logo i:first-child,.logo i:nth-child(8){background:#e02a3c}.logo i:nth-child(2),.logo i:nth-child(6){background:#14a85a}.logo i:nth-child(3),.logo i:nth-child(7){background:#ffd21f}.logo i:nth-child(4){background:#2166e6}.logo i:nth-child(5){background:#ff7b1c}.top-actions{align-items:center;gap:4px;display:flex}.topbar{gap:12px}.puzzle-switch{position:absolute;left:50%;transform:translate(-50%)}.puzzle-switch button{white-space:nowrap}@media (width>=861px){.puzzle-switch{flex:none;position:static;transform:none}.topbar-start,.top-actions{flex:1 1 0;min-width:max-content}.top-actions{justify-content:flex-end}}.puzzle-select{display:none}.topbar-start{align-items:center;gap:16px;display:flex}.places{background:var(--panel);border:1px solid var(--line);border-radius:12px;gap:2px;padding:3px;display:flex}.places button{height:32px;color:var(--text-2);font:inherit;cursor:pointer;background:0 0;border:0;border-radius:9px;align-items:center;gap:7px;padding:0 14px;font-size:14px;font-weight:650;display:flex}.places button svg{width:17px;height:17px}.places button:hover{color:var(--text)}.places button.active{background:var(--accent-soft);color:var(--text);box-shadow:inset 0 0 0 1px #d8b26c59}.places button:focus-visible{outline:2px solid var(--accent);outline-offset:2px}.help-sub{display:contents}.divider{background:var(--line-2);width:1px;height:20px;margin:0 6px}.btn{border-radius:var(--radius-sm);border:1px solid var(--line);background:var(--chip);cursor:pointer;-webkit-user-select:none;user-select:none;white-space:nowrap;justify-content:center;align-items:center;gap:8px;height:38px;padding:0 14px;font-size:13.5px;font-weight:550;transition:background .15s,border-color .15s,transform 80ms,opacity .15s,color .15s;display:inline-flex}@media (hover:hover){.btn:hover{background:var(--chip-hover);border-color:var(--line-2)}}.btn:active{transform:scale(.97)}.btn:disabled{opacity:.35;cursor:default;transform:none}.btn:focus-visible,.move:focus-visible,.chip:focus-visible,.swatch:focus-visible,.net .cell:focus-visible{outline:2px solid var(--accent);outline-offset:2px}.btn.ghost{color:var(--text-2);background:0 0;border-color:#0000}@media (hover:hover){.btn.ghost:hover{background:var(--chip);color:var(--text)}}.btn.small{gap:6px;height:30px;padding:0 10px;font-size:12.5px}.btn.small svg{width:15px;height:15px}.btn.icon{width:38px;padding:0}.btn.grow,.grow{flex:1}.btn.primary-soft{background:var(--accent-soft);color:#eed9ae;border-color:#d8b26c47}@media (hover:hover){.btn.primary-soft:hover{background:#d8b26c3d}}.top-actions .btn{height:36px;padding:0 10px}.top-actions .btn:not(:has(.label)){width:36px;padding:0}#btn-help{font-size:15px;font-weight:700}.link{color:var(--text-3);cursor:pointer;background:0 0;border:0;padding:0;font-size:12px}.link:hover{color:var(--text)}.row{gap:8px;display:flex}.seg{border:1px solid var(--line);background:#0000004d;border-radius:12px;grid-auto-columns:1fr;grid-auto-flow:column;gap:2px;padding:4px;display:grid}.seg button{height:34px;color:var(--text-2);font:inherit;cursor:pointer;background:0 0;border:0;border-radius:9px;justify-content:center;align-items:center;gap:8px;padding:0 10px;font-weight:600;transition:background .2s,color .2s;display:flex}.seg button svg{width:16px;height:16px}.seg button:hover{color:var(--text)}.seg button.active{background:var(--chip-hover);color:var(--text);box-shadow:0 1px 2px #0006}.seg button:focus-visible{outline:2px solid var(--accent);outline-offset:1px}.seg--sm{border-radius:10px;padding:3px}.seg--sm button{border-radius:8px;height:28px;padding:0 8px;font-size:12.5px}.seg--bar{background:var(--panel);-webkit-backdrop-filter:blur(10px);border-radius:12px;padding:3px;display:flex}.seg--bar button{gap:7px;height:32px;padding:0 14px;font-size:13px}.label-row{justify-content:space-between;align-items:baseline;margin-bottom:-6px;display:flex}.eyebrow{letter-spacing:.08em;text-transform:uppercase;color:var(--text-3);font-size:11px;font-weight:650}.mode-play,.mode-paint{flex-direction:column;gap:14px;display:flex}.intro{margin:0}.intro b{color:var(--text);font-weight:600}.movepad{grid-template-columns:repeat(6,1fr);gap:5px;display:grid}.movepad:empty{display:none}.move{border:1px solid var(--line);background:var(--chip);height:34px;font-family:var(--mono);cursor:pointer;border-radius:8px;font-size:13px;font-weight:600;transition:background .12s,transform 80ms;position:relative;overflow:hidden}.move:before{content:"";background:var(--c,transparent);opacity:.9;height:2px;position:absolute;top:0;left:0;right:0}.move:hover{background:var(--chip-hover)}.move:active{transform:scale(.94)}.move.flash{background:#ffffff2e}.alg{gap:6px;display:flex}.alg input{border-radius:var(--radius-sm);border:1px solid var(--line);min-width:0;height:38px;font-family:var(--mono);background:#00000040;outline:none;flex:1;padding:0 12px;font-size:13px;transition:border-color .15s}.alg input:focus{border-color:#d8b26c99}.alg input::placeholder{color:var(--text-3);font-family:Inter,sans-serif}.alg-error{color:var(--bad);min-height:0;margin-top:-8px;font-size:12px}.alg-error .link{color:var(--text);font-weight:600;font-size:inherit;text-decoration:underline}.alg input[aria-invalid=true]{border-color:#ff5d7399}.alg-error:empty{display:none}.history{min-height:30px;max-height:100px;font-family:var(--mono);flex-wrap:wrap;gap:4px;font-size:12px;line-height:18px;display:flex;overflow-y:auto}.history>.muted{font-family:Inter,sans-serif}.history .h{background:var(--chip);color:var(--text-2);border-radius:5px;padding:2px 6px}.history .h:last-child{color:var(--text);background:var(--chip-hover)}.palette{justify-content:space-between;gap:12px 6px;display:grid}.swatch{aspect-ratio:1;cursor:pointer;background:var(--c);border:2px solid #0000;border-radius:10px;transition:transform .12s,border-color .12s;position:relative;box-shadow:inset 0 0 0 1px #0006,0 2px 6px #0000004d}.swatch:hover{transform:translateY(-2px)}.swatch.active{border-color:var(--text);transform:translateY(-2px)scale(1.04)}.swatch .n{background:var(--panel-solid);border:1px solid var(--line-2);min-width:18px;height:18px;color:var(--text-2);border-radius:9px;place-items:center;padding:0 4px;font-size:10.5px;font-weight:700;display:grid;position:absolute;top:-6px;right:-5px}.swatch .n.done{color:var(--good)}.swatch .n.over{color:var(--bad);border-color:var(--bad)}.swatch.tool{background:var(--chip);color:var(--text);place-items:center;display:grid}.swatch.tool svg{fill:none;stroke:currentColor;stroke-width:1.6px;stroke-linejoin:round;stroke-linecap:round;width:22px;height:22px}.swatch.eraser{background:repeating-linear-gradient(45deg,#362f29 0 5px,#2b2520 5px 10px)}.net{border:1px solid var(--line);background:#00000038;border-radius:12px;justify-content:center;padding:12px;display:flex}.net svg{-webkit-user-select:none;user-select:none;width:100%;max-width:290px;height:auto;display:block;overflow:visible}.net .cell{stroke:#00000059;stroke-width:4px;stroke-linejoin:round;transform-box:fill-box;transform-origin:50%;transition:fill .2s,stroke .12s}.net .cell.empty{display:none}.net.editable .cell{cursor:pointer}.net.editable .cell:focus-visible{stroke:#fff;stroke-width:12px;outline:none}.net.editable .cell:hover{stroke:#fff;stroke-width:10px}.net .label{fill:#00000080;stroke:none;text-anchor:middle;dominant-baseline:central;pointer-events:none;font-size:42px;font-weight:700}.net .cell.bad{animation:1.2s ease-in-out 2 pulse}.net .cell.missing{animation:1.2s ease-in-out 2 pulse-missing}.net .cell.vacant{visibility:hidden}.net .ghost{stroke:#00000059;stroke-width:4px;stroke-linejoin:round;pointer-events:none}.net:not(.editable) .cell{cursor:grab;touch-action:none}.net svg.dragging,.net svg.dragging .cell{cursor:grabbing}.net .dim{opacity:.4}.net .cell.hover{stroke:#fff;stroke-width:12px}.net .cell.mate,.net .cell.focused{stroke:#ffd68cf2;stroke-width:8px}.net.shaped .cell,.net.shaped .ghost{stroke:var(--bg-2);stroke-width:6px}.net .outline{pointer-events:none;stroke-linejoin:round;display:none}.net.shaped .outline{display:inline}.net .outline.mate,.net .outline.focused{stroke:#ffd68cf2;stroke-width:8px}.net .outline.hover{stroke:#fff;stroke-width:12px}.net svg:has(.vacant) .outlines{display:none}.map-tools{align-items:baseline;gap:10px;display:flex}.tool-close{color:var(--accent-2);font-weight:600;display:none}#btn-more{display:none}.popover{border:1px solid var(--line-2);background:var(--panel-solid);width:min(260px,100vw - 32px);color:var(--text);box-shadow:var(--shadow);border-radius:14px;margin:0;padding:12px;position:fixed;inset:auto}.popover:popover-open{flex-direction:column;gap:12px;display:flex}.popover-row{justify-content:space-between;align-items:center;gap:12px;display:flex}.popover-row .eyebrow{white-space:nowrap}.popover.menu{gap:2px;width:min(290px,100vw - 24px);padding:6px}.menu-item{text-align:left;cursor:pointer;background:0 0;border:0;border-radius:10px;align-items:center;gap:12px;width:100%;min-height:48px;padding:8px 10px;display:flex}.menu-item:hover,.menu-item:focus-visible{background:var(--chip-hover);outline:none}.menu-item:disabled{opacity:.35;cursor:default;background:0 0}.menu-item svg{color:var(--text-2)}.menu-item span{flex-direction:column;min-width:0;display:flex}.menu-item b{font-size:14.5px;font-weight:600}.menu-item small{color:var(--text-3);font-size:12px;line-height:1.35}.menu-item.on{background:var(--accent-soft)}.menu-item.on svg{color:var(--accent-2)}.menu-sep{background:var(--line);border:0;width:100%;height:1px;margin:4px 0}#map-head{align-items:center}.map-title{align-items:center;gap:10px;display:flex}.map-hint{text-align:center;color:var(--text-3);margin-top:-6px}.map-hint:empty{display:none}.rings .ring{fill:none;stroke:#ffffff29;stroke-width:5px;transition:stroke .15s}.rings .ring.grabbed{stroke:#ffffff52}.rings .ring.turning{stroke:#ffffff8c}.rings .cell{stroke-width:3.5px}.rings:not(.editable) .cell{transition:stroke .12s}.rings .ring-label{pointer-events:none}.rings .ring-label rect{stroke:#00000073;stroke-width:3.5px}.rings .ring-label text{fill:#000000b8;stroke:none;text-anchor:middle;dominant-baseline:central;font-weight:700}.rings .ring-label.slice rect{fill:#2e2823;stroke:#ffffff38}.rings .ring-label.slice text{fill:var(--text)}@keyframes pulse{50%{stroke:var(--bad);stroke-width:16px}}@keyframes pulse-missing{50%{stroke:var(--accent);stroke-width:16px}}.status{background:var(--chip);color:var(--text-2);border-radius:10px;align-items:flex-start;gap:8px;padding:10px 12px;font-size:12.5px;display:flex}.status:empty{display:none}.status .dot{background:var(--text-3);border-radius:50%;flex:none;width:8px;height:8px;margin-top:5px}.status.ok .dot{background:var(--good);box-shadow:0 0 10px var(--good)}.status.bad{color:var(--bad-text);background:#ff5d731a}.status.bad .dot{background:var(--bad)}.status.warn .dot{background:var(--warn)}.stage-hint{color:var(--text-3);pointer-events:none;white-space:nowrap;border:1px solid var(--line);background:#00000040;border-radius:99px;padding:7px 14px;font-size:12.5px;transition:opacity .6s;position:absolute;bottom:22px;left:50%;transform:translate(-50%)}.stage-hint.fade{opacity:0}.btn.stage-view{z-index:1;-webkit-backdrop-filter:blur(8px);backdrop-filter:blur(8px);opacity:0;visibility:hidden;background:#1c1814b8;gap:6px;height:36px;padding:0 12px 0 10px;font-size:13px;transition:opacity .2s,transform .2s cubic-bezier(.16,1,.3,1),visibility 0s .2s;position:absolute;top:70px;right:14px;transform:translateY(-4px)}.btn.stage-view svg{width:16px;height:16px}body.view-turned .btn.stage-view{opacity:1;visibility:visible;transition-delay:0s;transform:none}body.entering .btn.stage-view{display:none}.solved-badge{letter-spacing:.02em;color:var(--good);pointer-events:none;background:#3ddc971f;border:1px solid #3ddc974d;border-radius:99px;align-items:center;gap:6px;padding:6px 14px 6px 12px;font-size:12.5px;font-weight:650;animation:.4s cubic-bezier(.16,1,.3,1) pop;display:flex;position:absolute;top:76px;left:50%;transform:translate(-50%)}.mine-chip{z-index:1;white-space:nowrap;border:1px solid var(--line-2);-webkit-backdrop-filter:blur(8px);backdrop-filter:blur(8px);height:34px;color:var(--text-2);font:inherit;cursor:pointer;background:#1c1814b8;border-radius:99px;align-items:center;gap:7px;padding:0 14px 0 12px;font-size:13px;transition:background .15s,color .15s;display:flex;position:absolute;top:76px;left:50%;transform:translate(-50%)}.mine-chip:hover{color:var(--text);background:#28221cd9}.mine-chip:focus-visible{outline:2px solid var(--accent);outline-offset:2px}.mine-chip svg{width:15px;height:15px;color:var(--text-3)}.mine-chip b{color:var(--accent-2);font-weight:600}.mine-chip .dot{background:var(--accent);border-radius:50%;width:7px;height:7px}.mine-chip .sep{color:var(--text-3)}.mine-chip.mine{color:var(--text)}.solved-badge:not(.hidden)~.mine-chip{display:none}.solved-badge:before{content:"";background:var(--good);width:7px;height:7px;box-shadow:0 0 8px var(--good);border-radius:50%}@keyframes pop{0%{opacity:0;transform:translate(-50%)scale(.7)}}.btn.solve{background:linear-gradient(180deg, var(--brass-top), var(--brass-bottom));height:auto;color:var(--on-accent);border:0;border-radius:14px;flex-direction:column;gap:2px;padding:16px;position:relative;overflow:hidden;box-shadow:0 12px 24px -14px #000000e6,inset 0 1px #fff5e180,inset 0 -1px #462d0a59}.btn.solve:hover{background:linear-gradient(180deg, var(--brass-top-hover), var(--brass-bottom-hover))}.btn.solve.quiet{background:var(--panel-solid);color:var(--text);border:1px solid var(--line-2);box-shadow:none}.btn.solve.quiet:hover{background:var(--chip-hover)}.btn.solve.quiet .solve-sub{color:var(--text-2)}.solve-label{letter-spacing:-.01em;font-size:17px;font-weight:700}.solve-sub{font-size:12px;font-weight:500}.btn.solve.busy:after{content:"";background:linear-gradient(100deg,#0000 20%,#fffaf066 50%,#0000 80%);animation:1.1s linear infinite shimmer;position:absolute;inset:0}@keyframes shimmer{0%{transform:translate(-100%)}to{transform:translate(100%)}}.solution.empty .sol-body,.solution:not(.empty) .sol-empty{display:none}.sol-empty{text-align:center;color:var(--text-2);padding:18px 8px 6px;font-size:13px}.sol-empty p{margin:12px 0 0}.sol-empty b{color:var(--text)}.sol-empty-art{justify-content:center;gap:6px;display:flex}.sol-empty-art i{background:var(--chip-hover);border-radius:5px;width:14px;height:14px;animation:2.4s ease-in-out infinite bob}.sol-empty-art i:first-child{background:#e02a3c}.sol-empty-art i:nth-child(2){background:#14a85a;animation-delay:.2s}.sol-empty-art i:nth-child(3){background:#2166e6;animation-delay:.4s}@keyframes bob{50%{transform:translateY(-5px)}}.sol-body{flex-direction:column;gap:14px;display:flex}.sol-head{justify-content:space-between;align-items:flex-start;display:flex}.sol-count{letter-spacing:-.03em;font-variant-numeric:tabular-nums;font-size:34px;font-weight:700;line-height:1}.sol-count small{color:var(--text-2);letter-spacing:0;font-size:14px;font-weight:500}.sol-meta{color:var(--text-2);flex-wrap:wrap;align-items:center;gap:6px;margin-top:6px;font-size:12px;display:flex}.badge{border-radius:99px;align-items:center;gap:4px;padding:2px 8px;font-size:11px;font-weight:600;display:inline-flex}.badge.optimal{color:var(--good);background:#3ddc971f}.badge.searching{background:var(--accent-soft);color:#eed9ae}.badge.searching:before{content:"";background:currentColor;border-radius:50%;width:6px;height:6px;animation:.9s infinite blink}.badge.changed{color:var(--warn);background:#ffc8571f}@keyframes blink{50%{opacity:.2}}.sol-meta .link{color:var(--accent);font-size:12px;font-weight:600}.chips{scrollbar-width:thin;flex-wrap:wrap;align-content:flex-start;align-items:flex-start;gap:6px;max-height:246px;padding:2px;display:flex;position:relative;overflow-y:auto}.chip{border:1px solid var(--line);background:var(--chip);cursor:pointer;min-width:44px;font-family:var(--mono);border-radius:8px;justify-content:center;align-items:baseline;gap:4px;padding:6px 8px;font-size:14px;font-weight:600;transition:all .15s;animation:.3s both chipIn;display:inline-flex}.chip sub{color:var(--text-3);font-family:Inter,sans-serif;font-size:11px;font-weight:600}.chip:hover{background:var(--chip-hover)}.chip.done{opacity:.38}.chip.current{background:var(--accent-soft);color:var(--text);opacity:1;border-color:#d8b26c99;box-shadow:0 0 0 3px #d8b26c26}@keyframes chipIn{0%{opacity:0;transform:translateY(4px)}}.solution.changed .chips,.solution.changed:not(.guided) .player{opacity:.4;pointer-events:none}.player{border-top:1px solid var(--line);flex-direction:column;gap:10px;padding-top:4px;display:flex}.progress{background:var(--chip-hover);border-radius:5px;height:4px;margin-top:10px;overflow:hidden}.progress-fill{background:var(--accent);transform-origin:0;height:100%;transition:transform .25s;transform:scaleX(0)}.now,.solve-bar{display:none}.solution.learn:not(.drill) .player{border-top:0;gap:8px;padding-top:0}.solution.learn:not(.drill) .progress{border-radius:0;height:3px;margin:0 -16px}.player-more,.player-more-in{display:contents}.solution.learn:not(.drill) .player-more{visibility:hidden;grid-template-rows:0fr;margin-top:-8px;transition:grid-template-rows .25s cubic-bezier(.16,1,.3,1),margin-top .25s cubic-bezier(.16,1,.3,1),visibility 0s .25s;display:grid}.solution.learn:not(.drill) .player.open .player-more{visibility:visible;grid-template-rows:1fr;margin-top:0;transition-delay:0s}.solution.learn:not(.drill) .player-more-in{flex-direction:column;gap:8px;min-height:0;display:flex;overflow:hidden}.solution.learn:not(.drill) .now{align-items:center;gap:6px;min-height:52px;display:flex}.now-text{flex:1;align-items:center;gap:10px;min-width:0;display:flex}.progress-row{position:relative}.player-handle{display:none}.solution.learn:not(.drill) .player-handle{z-index:1;border:1px solid var(--line-2);background:var(--panel-solid);width:48px;height:20px;color:var(--text-2);cursor:pointer;border-bottom:0;border-radius:10px 10px 0 0;justify-content:center;align-items:center;margin-left:-24px;padding:0;display:flex;position:absolute;bottom:100%;left:50%}.player-handle:before{content:"";position:absolute;inset:-10px -12px -12px}.player-handle svg{width:16px;height:16px}.player-handle:focus-visible{outline:2px solid var(--accent);outline-offset:2px}@media (hover:hover){.player-handle:hover{color:var(--text);border-color:var(--text-2)}}.now-move{font-family:var(--mono);color:var(--text);white-space:nowrap;font-size:34px;font-weight:600;line-height:1}.now-meta{min-width:0;color:var(--text-2);font-size:12px;line-height:1.3}.now-meta:empty{display:none}.now .btn{flex:none;height:48px}.now .btn.icon{width:44px}#now-more svg{transition:transform .2s}#now-more[aria-expanded=true] svg{transform:rotate(180deg)}.now-next{background:var(--text);color:var(--bg);border:0;gap:2px;padding:0 10px 0 14px;font-weight:650}@media (hover:hover){.now-next:hover{background:var(--accent-2)}}@media (width>=861px){#now-prev{display:none}.now .btn.icon{width:36px}}.now-off{gap:6px;display:flex}.now-off:empty,.solution.changed.guided .now,.solution.changed.guided .player-row,.solution.changed.guided .speed{display:none}.now-off .btn{flex:1;height:48px;padding:0 12px}.solution.finished.guided .now,.solution.finished.guided .player-row,.solution.finished.guided .speed{display:none}.now-finish{flex-wrap:wrap;flex:1;justify-content:flex-end;align-items:center;gap:6px;min-width:0;min-height:52px;animation:.42s cubic-bezier(.16,1,.3,1) finish-in;display:flex}.now-done{min-width:0;color:var(--text-2);flex-direction:column;flex:1 1 0;gap:2px;font-size:12px;line-height:1.3;display:flex}.now-done b{letter-spacing:-.01em;color:var(--good);white-space:nowrap;font-size:17px;font-weight:700}.now-off .now-finish .btn{flex:none}.now-off .now-finish .btn.icon{width:44px;padding:0}.now-off .now-finish .now-next{padding:0 14px}.now-finish .now-next svg{margin-right:-4px}.now-finish.wide{min-height:0}.now-finish.wide .now-done{flex-direction:row;flex:100%;align-items:baseline;gap:8px}.now-finish.wide .now-done b{font-size:15px}.now-off .now-finish.wide .now-next{white-space:normal;text-align:center;flex:1 1 0;justify-content:center;min-width:0;line-height:1.15}@keyframes finish-in{0%{opacity:0;transform:translateY(8px)}}@media (prefers-reduced-motion:reduce){.now-finish{animation:none}#now-more svg{transition:none}}.player-row{grid-template-columns:1fr auto 1fr;align-items:center;display:grid}.step{white-space:nowrap;font-family:var(--mono);color:var(--text-2);font-variant-numeric:tabular-nums;font-size:12px}.transport{align-items:center;gap:2px;display:flex}.btn.play{background:var(--text);width:46px;height:46px;color:var(--bg);border:0;border-radius:50%;margin:0 4px}.btn.play:hover{background:var(--accent-2)}.btn.play svg{fill:currentColor;stroke-width:0}.btn.play .i-pause{fill:none;stroke-width:3px}.btn.play .i-pause,.btn.play.playing .i-play{display:none}.btn.play.playing .i-pause{display:block}.speed{color:var(--text-2);align-items:center;gap:10px;font-size:12px;display:flex}.speed input{accent-color:var(--accent);flex:1}.speed span:last-child{text-align:right;width:34px;font-family:var(--mono)}.scanner{z-index:40;padding:max(16px, env(safe-area-inset-top)) 16px max(16px, env(safe-area-inset-bottom));background:#000;flex-direction:column;justify-content:space-between;align-items:center;display:flex;position:fixed;inset:0}.scanner video{object-fit:cover;width:100%;height:100%;position:absolute;inset:0}.scanner.mirrored video,.scanner.mirrored .scan-grid,.scanner.mirrored .scan-face{transform:scaleX(-1)}.scanner>div{position:relative}.scan-top,.scan-bottom{z-index:1;border-radius:var(--radius);-webkit-backdrop-filter:blur(12px);border:1px solid var(--line);background:#0f0d0bb8;flex-direction:column;gap:6px;width:min(100%,440px);padding:12px 14px;display:flex}.scan-step{color:var(--text-2);justify-content:space-between;gap:12px;font-size:12px;display:flex}.scan-look{color:var(--text);text-align:right}.scan-prompt{font-size:17px;font-weight:650}.scan-colors{color:var(--text-2);font-size:13px}.scan-colors b{color:var(--text);white-space:nowrap;font-weight:600}.scan-colors b i{vertical-align:-1px;border-radius:3px;width:12px;height:12px;margin-right:5px;display:inline-block;box-shadow:0 0 0 1px #00000080}.scan-warn{color:var(--warn);font-size:12.5px}.scan-colors:empty,.scan-warn:empty{display:none}.scan-grid{aspect-ratio:1;width:min(78vw,46vh)}.scan-grid svg{width:100%;height:100%;display:block;overflow:visible}.scan-grid .cells>*{fill:none;stroke:#ffffff8c;stroke-width:1.5px;stroke-linejoin:round;vector-effect:non-scaling-stroke}.scan-grid circle{fill:var(--c,transparent);stroke:#00000073;stroke-width:2px;vector-effect:non-scaling-stroke;opacity:0;transition:opacity .15s}.scan-grid circle[style]{opacity:1}.scan-grid .cells>.center{stroke:var(--face);stroke-width:3px;filter:drop-shadow(0 0 1px #0009)}.scan-grid:after{content:"";height:8px;width:calc(90% / var(--n));background:var(--top,transparent);border-radius:5px;position:absolute;top:-14px;left:50%;transform:translate(-50%);box-shadow:0 0 0 1.5px #0000008c}.scanner.light .scan-grid:before{content:"";pointer-events:none;border-radius:20px;position:absolute;inset:-18px;box-shadow:0 0 0 200vmax #fff}.scanner [data-act=light][aria-pressed=true]{color:#111;background:#fff;border-color:#fff}.scan-faces{justify-content:center;gap:8px;display:flex}.scan-face{border:1px solid var(--line-2);background:var(--chip);cursor:pointer;border-radius:8px;width:40px;height:40px;padding:3px}.scan-face svg{width:100%;height:100%;display:block}.scan-face svg>*{fill:none;stroke-linejoin:round}.scan-face svg>:not([style*=fill]){stroke:#ffffff38;stroke-width:1px;vector-effect:non-scaling-stroke}.scan-face.active{border-color:var(--accent);box-shadow:0 0 0 2px var(--accent)}.scan-capture{background:var(--accent);border-color:var(--accent);color:var(--on-accent);font-weight:650}.scan-capture:hover{background:var(--accent-2);border-color:var(--accent-2)}.scan-capture svg{fill:currentColor}.scan-keys{color:var(--text-2);text-align:center;font-size:12px}.scan-keys kbd{min-width:20px;height:20px;font-size:11px}.scanner .btn kbd{min-width:18px;height:18px;color:inherit;opacity:.85;background:#0000002e;border-color:#ffffff38;margin:0 0 0 4px;padding:0 5px;font-size:10.5px}@media (hover:none){.scan-keys,.scanner .btn kbd{display:none}}.solution.learn{flex-direction:column;gap:14px;display:flex}.solution.learn .sol-empty,.solution.learn .sol-meta,.solution.learn:not(.drill) .sol-head,.solution.learn:not(.drill) .chips,.solution:not(.learn) .guided-step,.solution:not(.learn) .learn-intro,.solution.learn:not(.empty) .learn-intro,.solution:not(.drill) .case-card,.solution.drill .guided-step{display:none}.solution.drill .chips{max-height:160px}.solution.learn .player{z-index:1;background:var(--panel-solid);border-top:1px solid var(--line);margin:0 -16px -16px;padding:10px 16px 16px;position:sticky;bottom:-16px}.learn-foot{justify-content:space-between;gap:12px;display:flex}.learn-foot .link{padding:8px 6px;font-size:12.5px}.solve-actions{flex:none;justify-content:space-between;margin-top:-4px}.solve-actions .btn{height:36px;padding:0 10px;font-size:13px;font-weight:550}.solve-actions .btn svg{width:16px;height:16px}body.learn .solve-actions,body.painting .solve-actions,body.painting #btn-solve{display:none}.paint-done .btn{height:44px}.paint-goal{border-bottom:1px solid var(--line);flex-direction:column;gap:8px;padding-bottom:14px;display:flex}.paint-goal p{color:var(--text);margin:0;font-size:13.5px}.paint-goal .btn{height:44px}.paint-head{justify-content:space-between;align-items:center;gap:8px;display:flex}.paint-exits{gap:2px;display:flex}.paint-exits .link{color:var(--text-2);padding:6px;font-size:12.5px}.paint-nav{gap:8px;display:flex}#btn-goal-scan,body.entering .intro,body.entering #paint-tools{display:none}@media (width>=861px){:is(body.entering .panel.right,body.painting .panel.right:has(.solution.empty)){display:none}}.learn-intro p{color:var(--text-2);margin:0 0 10px}.learn-intro p:last-child{margin-bottom:0}.learn-intro b{color:var(--text);font-weight:600}.solution code{font-family:var(--mono);background:var(--chip-hover);color:var(--text);white-space:nowrap;border-radius:5px;padding:1px 5px;font-size:12px;font-weight:600}.guided-step{flex-direction:column;gap:10px;display:flex}.learn-head{flex-wrap:wrap;justify-content:space-between;align-items:baseline;gap:2px 8px;display:flex}.learn-head .eyebrow{white-space:nowrap}.learn-title{letter-spacing:-.01em;text-wrap:balance;font-size:17px;font-weight:700;line-height:1.3}.learn-title:focus{outline:none}.learn-text{color:var(--text-2);font-size:13px}.learn-text p{max-width:68ch;margin:0 0 8px}.learn-text p:last-child{margin-bottom:0}.learn-text b{color:var(--text)}.pname{color:var(--text);white-space:nowrap;font-weight:600}.picon{stroke:none;margin-right:5px;display:inline-block;overflow:visible}.picon.cube{vertical-align:-2.5px}.picon.pyra{vertical-align:-1.5px}.move-groups{flex-direction:column;gap:8px;display:flex}.move-group{flex-direction:column;gap:5px;display:flex}.move-group-label{letter-spacing:.04em;text-transform:uppercase;color:var(--text-3);font-size:11px;font-weight:650}.move-group-moves{flex-wrap:wrap;align-items:flex-start;gap:5px;display:flex}.move-group-moves .chip{min-width:40px;padding:4px 6px;font-size:13px;animation:none}.learn-nav{justify-content:space-between;gap:8px;display:flex}.learn-nav .btn.ghost{padding:0 6px}.setup-nav .btn{flex:1;height:44px}.copy-door{color:var(--accent-2);text-align:left;align-self:flex-start;font-size:12.5px;font-weight:600}.link.inline{color:var(--accent-2);font-size:inherit;font-weight:600}.learn-banner{color:var(--warn);background:#ffc8571a;border-radius:10px;padding:8px 10px;font-size:12.5px}.learn-banner .link{color:var(--text);font-size:12.5px;font-weight:600;text-decoration:underline}.solution.changed .guided-step>:not(.learn-banner,.learn-foot){opacity:.4;pointer-events:none}.panel.course{grid-column:1;display:none}body.learn .app{grid-template-columns:minmax(400px,1.3fr) minmax(240px,1fr) 340px}body.learn .stage{grid-column:2}body.learn .panel.left{display:none}body.learn .panel.course{display:flex}.learn-home,.learn-stage{flex-direction:column;gap:16px;display:none}body.lv-home .learn-home,body.lv-stage .learn-stage{display:flex}body.lv-guided .panel.course,body.learn-bare .panel.right{display:none}@media (width>=861px){body.learn.learn-bare .app{grid-template-columns:minmax(400px,1fr) minmax(240px,1.2fr)}body.learn.lv-guided .app{grid-template-columns:minmax(320px,1fr) 400px}body.learn.lv-guided .stage{grid-column:1}body.learn.lv-guided .panel.right{grid-column:2}body.learn.guiding .panel.right{align-self:stretch}body.learn.guiding #solution,body.learn.guiding .sol-body{flex:1 0 auto}body.learn.guiding .solution.learn .player{margin-top:auto}}.home-body{flex-direction:column;gap:14px;display:flex}.home-intro{color:var(--text-2);margin:0;font-size:13.5px}.home-intro b{color:var(--text)}.home-intro-more{display:none}.home-guided{flex-direction:column;gap:8px;margin-top:6px;display:flex}.stage-row .num.guided-icon{color:var(--accent-2);background:var(--accent-soft);border-color:#d8b26c59}.stage-row .num.guided-icon svg{fill:currentColor;width:11px;height:11px;margin-left:2px}.home-new{color:var(--text-2);align-self:center;font-size:13px}.home-new:hover{color:var(--text)}.home-stages{flex-direction:column;gap:8px;margin-top:6px;display:flex}.stage-list{flex-direction:column;gap:6px;margin:0;padding:0;list-style:none;display:flex}.stage-row{text-align:left;border:1px solid var(--line-2);background:var(--chip);width:100%;color:var(--text);font:inherit;cursor:pointer;border-radius:12px;align-items:center;gap:12px;padding:12px 12px 12px 14px;transition:background .15s,border-color .15s;display:flex}.stage-row:hover{background:var(--chip-hover);border-color:var(--accent)}.stage-row:focus-visible{outline:2px solid var(--accent);outline-offset:2px}.stage-row .num{background:var(--panel-solid);border:1px solid var(--line-2);width:24px;height:24px;color:var(--text-2);border-radius:50%;flex:none;place-items:center;font-size:12px;font-weight:700;display:grid}.stage-row-text{flex-direction:column;flex:1;gap:2px;min-width:0;display:flex}.stage-row-text b{font-size:14.5px;font-weight:650}.stage-row-text small{color:var(--text-2);-webkit-line-clamp:2;line-clamp:2;-webkit-box-orient:vertical;font-size:12.5px;display:-webkit-box;overflow:hidden}.stage-row-meta{color:var(--text-3);white-space:nowrap;flex:none;align-items:center;gap:4px;font-size:12px;display:flex}.stage-row-meta svg{fill:none;stroke:currentColor;stroke-width:2px;stroke-linecap:round;stroke-linejoin:round;width:16px;height:16px}.stage-top{flex-wrap:wrap;justify-content:space-between;align-items:center;gap:12px;display:flex}.back-home{color:var(--text-2);font-size:13px;font-weight:600}.back-home:hover{color:var(--text)}.course p{max-width:68ch}.methods.single{display:none}.learn-method{flex:none;justify-content:space-between;align-items:center;gap:12px;display:none}body.lv-guided .learn-method{display:flex}.learn-back{color:var(--text-2);font-size:13px;font-weight:600}.learn-back:hover{color:var(--text)}.learn-where{letter-spacing:.06em;text-transform:uppercase;color:var(--text-3);white-space:nowrap;text-overflow:ellipsis;font-size:12px;font-weight:600;overflow:hidden}.learn-where:empty,.more-text{display:none}.method-name{font-size:15px;font-weight:700}.no-cases{border:1px dashed var(--line-2);border-radius:12px;margin:0;padding:12px}.course-steps{scrollbar-width:none;z-index:3;box-shadow:0 0 0 16px var(--panel-solid);background:var(--panel-solid);gap:12px;padding:3px 0;display:flex;position:sticky;top:-4px;overflow-x:auto}.course-steps button+button:before{content:"›";color:var(--text-3);pointer-events:none;font-weight:400;position:absolute;left:-9px}.course-steps.stuck:after{content:"";background:linear-gradient(var(--panel-solid), transparent);pointer-events:none;height:18px;position:absolute;top:calc(100% + 16px);left:-16px;right:-16px}.course-steps::-webkit-scrollbar{display:none}.course-steps button{white-space:nowrap;cursor:pointer;color:var(--text-2);background:0 0;border:0;border-radius:8px;flex:1 0 auto;justify-content:center;align-items:center;gap:6px;padding:6px 4px;font-size:13px;font-weight:600;transition:background .2s,color .2s;display:flex;position:relative}.course-steps button:hover{color:var(--text)}.course-steps button.active{background:var(--chip-hover);color:var(--text);box-shadow:0 1px 2px #0006}.course-steps button:focus-visible{outline:2px solid var(--accent);outline-offset:1px}.course-steps .num{background:var(--chip-hover);font-variant-numeric:tabular-nums;border-radius:50%;place-items:center;width:18px;height:18px;font-size:10.5px;font-weight:700;display:grid}.course-steps button.active .num{background:var(--accent);color:var(--on-accent)}.course-intro{flex-direction:column;gap:8px;display:flex}.course-intro .more{color:var(--accent-2);align-self:flex-start;font-weight:600;display:none}.course-intro .practise-stage{align-self:flex-start}.course-intro .practise-stage svg{fill:currentColor;stroke:none}.panel.course code,.case-card code,#notation code,#help code{font-family:var(--mono);background:var(--chip-hover);color:var(--text);white-space:nowrap;border-radius:5px;padding:1px 5px;font-size:12px;font-weight:600}.course-sets{flex-direction:column;gap:18px;display:flex}.case-set{flex-direction:column;gap:8px;display:flex}.case-set>p{margin:-4px 0 0}.cases,.legend-section.wrap .legend-grid{grid-template-columns:repeat(auto-fill,minmax(124px,1fr));gap:8px;display:grid}.tile{border:1px solid var(--line);background:var(--chip);min-width:0;color:inherit;font:inherit;cursor:pointer;text-align:center;touch-action:manipulation;border-radius:12px;flex-direction:column;align-items:center;transition:background .15s,border-color .15s,transform 80ms;display:flex}.tile:hover{background:var(--chip-hover);border-color:var(--line-2)}.tile:active{transform:scale(.97)}.tile:focus-visible{outline:2px solid var(--accent);outline-offset:2px}.case{gap:6px;padding:10px 8px 9px;position:relative}.case.active{background:var(--accent-soft);border-color:#d8b26c99}.case-hit{z-index:1;border-radius:inherit;cursor:pointer;touch-action:manipulation;background:0 0;border:0;padding:0;position:absolute;inset:0}.case-hit:focus-visible{outline:2px solid var(--accent);outline-offset:2px}.case .diagram{width:84px;height:84px}.case-name{font-size:12px;font-weight:650}.alias{color:var(--text-2);white-space:nowrap;font-weight:500}.level{background:var(--accent-soft);color:#eed9ae;vertical-align:1px;border-radius:999px;margin:0 4px 0 2px;padding:1px 7px;font-size:11px;font-weight:600;display:inline-block}.panel.course .case-alg{color:var(--text-2);white-space:normal;background:0 0;padding:0;font-size:10.5px;line-height:1.35}.diagram{stroke:none;stroke-width:0}.trig{background:var(--trig-bg);box-shadow:inset 0 0 0 1px var(--trig-line);-webkit-box-decoration-break:clone;box-decoration-break:clone;border-radius:4px;margin:0 -1px;padding:0 3px}.trig-group{flex-direction:column;gap:3px;display:inline-flex}.trig-moves{gap:inherit;background:var(--trig-bg);box-shadow:inset 0 0 0 1px var(--trig-line);border-radius:11px;margin:-3px 0 0;padding:3px;display:flex}.chips .trig-moves{gap:6px}.move-group-moves .trig-moves{gap:5px}.trig-name{color:var(--accent-2);opacity:.8;white-space:nowrap;padding-left:6px;font-size:10.5px;font-weight:600;line-height:1.2}.case-head{flex-direction:column;align-items:center;gap:2px;min-width:0;display:flex}.case .case-meta{display:none}.trig-unit{white-space:nowrap;flex-direction:column;align-items:center;display:inline-flex}.trig-label,.case-ctl{display:none}.case.active .mv.done{opacity:.35}.case.active .mv.next{color:var(--on-accent);background:var(--accent);border-radius:4px;margin:0 -3px;padding:1px 3px}.case.teach .mv.next{animation:1.4s ease-in-out infinite next-pulse}@keyframes next-pulse{50%{box-shadow:0 0 0 4px #d8b26c59}}@media (prefers-reduced-motion:reduce){.case.teach .mv.next{animation:none}}#notation{--sheet-w:560px}#notation h2{margin-bottom:10px}.legend-live{flex-direction:column;flex:none;align-items:center;gap:4px;margin-bottom:10px;display:flex}#notation-cube{width:100%;height:170px}#notation-cube canvas{width:100%;height:100%;display:block}#notation-move{min-height:20px;color:var(--text-2);margin:0;font-size:13px}#notation-body{scrollbar-width:thin;scrollbar-color:var(--line-2) transparent;margin:0 -6px;padding:5px 6px}.legend-section{flex-direction:column;gap:8px;display:flex}.legend-section+.legend-section{margin-top:16px}.legend-caption{color:var(--text-2);margin:0;font-size:13px;line-height:1.4}.legend-caption b{color:var(--text);font-weight:650}.legend-grid{grid-template-columns:repeat(var(--cols), minmax(0, 1fr));gap:6px;display:grid}@media (width<=600px){.legend-grid{grid-template-columns:repeat(var(--cols-narrow), minmax(0, 1fr))}}.legend-tile{color:var(--text-2);gap:4px;padding:8px 4px 7px}.legend-tile[aria-pressed=true]{border-color:var(--accent);background:var(--chip-hover);color:var(--text)}.legend-tile .diagram{width:58px;height:58px}.legend-label{flex-wrap:wrap;justify-content:center;align-items:baseline;gap:2px 6px;min-width:0;padding:0 4px;display:flex}.legend-tile small{text-align:center;font-size:11.5px;line-height:1.3}.diagram .arrows{stroke-linecap:round;stroke-linejoin:round}.diagram .arrows .outline{fill:#0b0d12;stroke:#0b0d12}.diagram .arrows .outline line,.diagram .arrows .outline path{stroke-width:.26px}.diagram .arrows .outline polygon{stroke-width:.16px}.diagram .arrows .fill{fill:#fff;stroke:#fff}.diagram .arrows .fill line,.diagram .arrows .fill path{stroke-width:.12px}.diagram .arrows path{fill:none}.diagram .arrows .fill polygon{stroke-width:.04px}.case-card{flex-direction:column;gap:10px;display:flex}.back-guided{color:var(--accent-2);align-self:flex-start;font-size:13px;font-weight:600}.back-guided:hover{color:var(--text)}.case-link{text-align:left;font:inherit;color:var(--text);border:1px solid var(--line);background:var(--chip);cursor:pointer;border-radius:12px;align-items:center;gap:12px;padding:8px 12px 8px 8px;display:flex}.case-link:hover{background:var(--chip-hover)}.case-link:focus-visible{outline:2px solid var(--accent);outline-offset:2px}.case-link .diagram{flex:none;width:56px;height:56px}.case-link-text{flex-direction:column;gap:1px;min-width:0;display:flex}.case-link-text b{font-size:13.5px}.case-link-text small{color:var(--text-3);font-size:11.5px}.case-link-go{color:var(--accent-2);margin-top:3px;font-size:12.5px;font-weight:600}.case-card p{margin:0}.case-big{justify-content:center;padding:4px 0;display:flex}.case-big .diagram{width:150px;height:150px}.toasts{z-index:50;pointer-events:none;flex-direction:column;align-items:center;gap:8px;display:flex;position:fixed;top:70px;left:16px;right:16px}.toast{background:var(--panel-solid);border:1px solid var(--line-2);box-shadow:var(--shadow);text-align:center;border-radius:12px;max-width:min(420px,100vw - 32px);padding:9px 16px;font-size:13px;font-weight:500;animation:.25s cubic-bezier(.16,1,.3,1) toastIn}.toast.bad{border-color:#ff5d7366}.toast.good{border-color:#3ddc9766}.toast.has-action,.toast.bad{pointer-events:auto;text-align:left;align-items:center;gap:12px;display:flex}.toast.bad:not(.has-action){padding-right:8px}.toast-close{width:24px;height:24px;color:var(--text-3);cursor:pointer;background:0 0;border:0;border-radius:5px;flex:none;margin:-4px -2px -4px 0;font-size:18px;line-height:1}.toast-close:hover{background:var(--chip-hover);color:var(--text)}.toast-action{white-space:nowrap;border:1px solid var(--line-2);background:var(--chip-hover);color:var(--text);font:inherit;cursor:pointer;border-radius:8px;flex:none;padding:4px 10px;font-weight:650}.toast-action:hover{background:var(--line-2)}.toast.out{opacity:0;transition:all .25s;transform:translateY(-6px)}@keyframes toastIn{0%{opacity:0;transform:translateY(-8px)scale(.96)}}dialog{border:1px solid var(--line-2);background:var(--panel-solid);color:var(--text);width:min(440px,100vw - 32px);box-shadow:var(--shadow);border-radius:20px;padding:24px}dialog::backdrop{-webkit-backdrop-filter:blur(4px);backdrop-filter:blur(4px);background:#08060599}dialog h2{letter-spacing:-.01em;margin:0 0 16px;font-size:18px}dialog form{margin-top:16px;display:flex}dialog.sheet{width:min(var(--sheet-w,440px), calc(100vw - 32px));padding:20px}dialog.sheet h2{margin-bottom:6px}dialog.sheet[open]{flex-direction:column;max-height:calc(100dvh - 24px);display:flex}dialog.sheet :is(.choices,.sheet-scroll){overscroll-behavior:contain;flex:auto;min-height:0;overflow-y:auto}dialog.sheet .choices{margin:12px -4px 0;padding:3px 4px}dialog.sheet form{flex:none}.sheet-lead{color:var(--text-2);margin:0 0 14px;font-size:13px;line-height:1.45}.choices{flex-direction:column;gap:8px;margin-top:12px;display:flex}.choices-head{letter-spacing:.08em;text-transform:uppercase;color:var(--text-3);margin:8px 2px 0;font-size:11px;font-weight:650}.choice{text-align:left;border:1px solid var(--line-2);background:var(--chip);width:100%;color:var(--text);font:inherit;cursor:pointer;border-radius:14px;align-items:center;gap:14px;padding:12px 14px;transition:background .15s,border-color .15s;display:flex}.choice:hover,.choice:focus-visible{background:var(--chip-hover);border-color:var(--accent)}.choice:focus-visible{outline:2px solid var(--accent);outline-offset:2px}.choice svg{fill:none;width:22px;height:22px;stroke:var(--accent-2);stroke-width:1.8px;stroke-linecap:round;stroke-linejoin:round;flex:none}.choice span{flex-direction:column;gap:2px;display:flex}.choice b{font-size:15px;font-weight:650}.choice small{color:var(--text-2);font-size:12.5px}dialog.about{width:min(560px,100vw - 32px);max-height:calc(100vh - 48px);color:var(--text-2);font-size:13.5px;line-height:1.55;overflow-y:auto}.about p{margin:0 0 12px}.about b,.about h2{color:var(--text)}.about h3{color:var(--text);margin:20px 0 6px;font-size:14px}.about code{font-family:var(--mono);color:var(--text);font-size:12px}.about h4{letter-spacing:.06em;text-transform:uppercase;color:var(--text-2);margin:14px 0 4px;font-size:11px;font-weight:600}.sources{grid-template-columns:11.5em 1fr;gap:3px 16px;margin:0;display:grid}.sources dt{color:var(--text);font-weight:600}.sources dd{margin:0}.sources a{color:var(--accent-2);text-decoration:none}.sources a:hover{text-decoration:underline}.help-grid{color:var(--text-2);grid-template-columns:auto 1fr;align-items:center;gap:10px 16px;font-size:13px;display:grid}.help-head{letter-spacing:.08em;text-transform:uppercase;color:var(--text-3);grid-column:1/-1;margin-top:6px;font-size:11px;font-weight:650}.help-head:first-child{margin-top:0}#help{width:min(760px,100vw - 32px);max-height:calc(100dvh - 32px);overflow-y:auto}.help-cols{grid-template-columns:1fr 1fr;align-items:start;gap:16px 32px;display:grid}@media (width<=700px){.help-cols{grid-template-columns:1fr}}kbd{border:1px solid var(--line-2);background:var(--chip);min-width:24px;height:24px;font-family:var(--mono);color:var(--text);border-bottom-width:2px;border-radius:5px;place-items:center;margin-right:3px;padding:0 6px;font-size:11.5px;display:inline-grid}@media (width<=1400px){.brand-name{display:none}}@media (width<=1100px) and (width>=861px){.top-actions .label{display:none}.top-actions .btn:has(.label){width:36px;padding:0}}@media (width<=1280px) and (width>=861px){.puzzle-switch button svg{display:none}}@media (width<=1000px) and (width>=861px){#btn-help,.divider{display:none}.puzzle-switch button{padding:0 10px}}@media (width<=1100px) and (width>=861px){.topbar{gap:8px;padding:0 12px}.topbar-start{gap:10px}.places button{padding:0 10px}}@media (width<=1100px){.app{grid-template-columns:300px 1fr 300px}body.learn .app{grid-template-columns:minmax(330px,1.2fr) minmax(200px,1fr) 300px}body.learn.learn-bare .app{grid-template-columns:minmax(330px,1fr) minmax(200px,1fr)}body.learn.lv-guided .app{grid-template-columns:minmax(240px,1fr) 360px}.panel{margin:4px 10px 10px}}@media (width<=860px){html,body{height:auto;min-height:100%}body{overflow:auto}.app{flex-direction:column;height:auto;min-height:100dvh;display:flex}.topbar{flex:none;height:56px;padding:0 12px}.top-actions .label{display:none}.top-actions .btn:has(.label){width:36px;padding:0}:root{--stage-h:max(46vh, 300px);--tabbar:calc(76px + env(safe-area-inset-bottom))}body.drilling{--stage-h:max(38vh, 240px)}body.guiding{--stage-h:max(40vh, 250px)}body.learn.lv-home{--stage-h:max(27vh, 180px)}body.learn.lv-home .stage-hint{display:none}body.lv-home .panel.course{box-shadow:none;-webkit-backdrop-filter:none;backdrop-filter:none;background:0 0;border:0;padding:0}body.lv-home .stage-list{border-top:1px solid var(--line);gap:0}body.lv-home .stage-row{border:0;border-bottom:1px solid var(--line);background:0 0;border-radius:0;padding:13px 2px}body.lv-home .stage-row:hover{background:0 0}body.lv-home .stage-row:active{background:var(--chip)}body.lv-home .home-stages{margin-top:10px}body.lv-home .home-guided .stage-row{border-top:1px solid var(--line)}.stage{height:var(--stage-h);z-index:3;background:radial-gradient(600px 400px at 50% 50%, #28211b, var(--bg) 70%);border-bottom:1px solid var(--line);flex:none;margin-bottom:16px;position:sticky;top:0}.stage-hint{font-size:11.5px;bottom:10px}.solved-badge,.mine-chip{top:12px}.btn.stage-view{height:40px;top:56px;right:8px}.panel{align-self:stretch;max-height:none;margin:0 16px 16px;overflow:visible}.panel.left,.panel.right{z-index:auto;-webkit-backdrop-filter:none;backdrop-filter:none}.panel.left{order:3}.panel.right{order:4}body.learn .panel.right{order:3}.panel.course{order:4}.topbar{z-index:30}.places{z-index:20;max-width:440px;left:16px;right:16px;bottom:calc(10px + env(safe-area-inset-bottom));border:1px solid var(--line-2);-webkit-backdrop-filter:blur(20px)saturate(1.4);backdrop-filter:blur(20px)saturate(1.4);background:#1e1a16b3;border-radius:31px;grid-template-columns:1fr 1fr;gap:4px;height:62px;margin:0 auto;padding:5px;display:grid;position:fixed;box-shadow:0 10px 30px -8px #000000bf,inset 0 1px #fff0dc1a}.places button{height:50px;color:var(--text-2);border-radius:25px;flex-direction:column;justify-content:center;gap:2px;padding:0;font-size:11.5px;font-weight:600}.places button svg{width:22px;height:22px}.places button.active{background:var(--accent-soft);color:var(--accent-2);box-shadow:inset 0 0 0 1px #d8b26c4d}.places button:focus-visible{outline-offset:-3px}.app{padding-bottom:calc(var(--tabbar) + 16px)}.solution.learn .player{bottom:var(--tabbar);box-shadow:0 12px 0 var(--panel-solid);border-radius:0 0 20px 20px;margin:0 -16px;padding-bottom:12px}.solve-bar{z-index:19;left:0;right:0;bottom:var(--tabbar);background:linear-gradient(transparent, var(--bg) 10px);flex-wrap:wrap;align-items:center;gap:8px;padding:10px 16px 12px;display:flex;position:fixed}.solve-bar:has(>.solve-bar-status.hidden){min-height:70px}body.solve-bar-on #btn-solve{z-index:20;left:16px;right:16px;bottom:calc(var(--tabbar) + 12px);flex-direction:row;height:48px;padding:0 14px;font-size:15px;font-weight:650;position:fixed}body.solve-bar-on #btn-solve .solve-label{font:inherit;letter-spacing:inherit}body.solve-bar-on #btn-solve .solve-sub{display:none}body.solve-bar-on:has(#bar-status:not(.hidden)) #btn-solve{display:none}body.solve-bar-on .panel.right:has(.solution.empty){display:contents}body.solve-bar-on .panel.right:has(.solution.empty)>:not(#btn-solve){display:none}dialog.sheet{width:100%;max-width:100%;padding-bottom:calc(16px + env(safe-area-inset-bottom));border-bottom:0;border-radius:20px 20px 0 0;margin:auto 0 0}.solve-bar-status{border:1px solid var(--line-2);background:var(--panel-solid);box-shadow:var(--shadow);text-align:center;color:var(--text);border-radius:14px;flex:1;padding:13px 14px;font-size:13px;line-height:1.35}body.solve-bar-on .app,body.painting .app{padding-bottom:calc(var(--tabbar) + 72px)}body.puzzle-home{--stage-h:calc(100dvh - 56px - var(--tabbar) - 70px);overflow:hidden}body.puzzle-home .app{padding-bottom:calc(var(--tabbar) + 70px)}body.puzzle-home .stage{background:0 0;border-bottom:0;margin-bottom:0}body.puzzle-home .solve-bar{background:0 0}body.puzzle-home .panel.left{display:none}#btn-more{display:inline-flex}#btn-display,#btn-share,#btn-about{display:none}.tool-close{display:inline}body:not(.painting):not(.tool-moves):not(.tool-map) .panel.left,body:not(.painting).tool-map .mode-play,body:not(.painting).tool-moves :is(#map-head,.net,.map-hint,#status),body.painting .tool-close{display:none}body.painting #palette{z-index:19;left:12px;right:12px;bottom:calc(var(--tabbar) + 8px);border:1px solid var(--line-2);background:var(--panel-solid);box-shadow:var(--shadow);border-radius:14px;padding:8px 10px;position:fixed}body.painting #palette .swatch{height:40px}body.entering{--stage-h:max(38vh, 240px)}body.entering .stage-hint{display:none}#btn-goal-scan{display:inline}body.solve-bar-on .solve-actions{display:none}body:not(.learn) .panel.right:has(.solution:not(.empty)){order:2}body:not(.learn):not(.solve-bar-on) .panel.right:has(.solution:not(.empty)) #btn-solve{display:none}body:not(.learn) .solution:not(.empty) .player{bottom:var(--tabbar);z-index:1;background:var(--panel-solid);border-top:1px solid var(--line);box-shadow:0 12px 0 var(--panel-solid);margin:0 -16px;padding:8px 16px 10px;position:sticky}body:not(.learn) .solution:not(.empty) .sol-body{gap:8px}body:not(.learn) .solution:not(.empty) .chips{max-height:max(42px, calc(100dvh - var(--stage-h) - 332px))}body:not(.learn) .solution:not(.empty) .speed{width:56px;height:46px;position:absolute;bottom:10px;right:16px}body:not(.learn) .solution:not(.empty) .speed span{display:none}body:not(.learn) .solution:not(.empty) .speed input{width:100%;margin:0}.panel.right{scroll-margin-top:calc(var(--stage-h) + 16px)}.learn-foot .link{flex:1;min-height:44px}.course-steps{top:calc(var(--stage-h) + 12px)}body.drilling .panel.right{display:none}.case.active{text-align:left;order:-1;grid-column:1/-1;grid-template-columns:84px minmax(0,1fr);grid-template-areas:"pic head""alg alg""status status""bar bar";align-items:start;gap:0 12px;padding:12px;display:grid}.case.active:active{transform:none}.case.active .diagram{grid-area:pic}.case.active .case-head{grid-area:head;align-self:center;align-items:flex-start;gap:3px;padding-right:36px}.case.active .case-name{font-size:16px;line-height:1.25}.case.active .case-meta{color:var(--text-3);font-size:12px;display:block}.case.active .case-alg{grid-area:alg;margin-top:12px}.case.active .trig-label{color:var(--accent-2);opacity:.8;font-family:Inter,system-ui,sans-serif;font-size:10.5px;font-weight:600;line-height:1.3;display:block}.case.active .case-ctl{display:contents}.case-close{z-index:2;border-radius:var(--radius-sm);width:40px;height:40px;color:var(--text-2);cursor:pointer;background:0 0;border:0;place-items:center;padding:0;display:grid;position:absolute;top:6px;right:6px}.case-close svg{width:18px;height:18px}.case-status{z-index:2;color:var(--text-2);grid-area:status;margin-top:8px;font-size:13px;line-height:1.4;position:relative}.case-status:empty{display:none}.case-status b{color:var(--text);font-weight:600}.case-undo{border:1px solid var(--line-2);background:var(--chip-hover);color:var(--text);cursor:pointer;border-radius:999px;margin:0 2px;padding:3px 9px;font-size:12px;font-weight:600}.case-bar{z-index:2;pointer-events:none;background:linear-gradient(var(--accent-soft), var(--accent-soft)), #1e1916;border-radius:0 0 11px 11px;grid-area:bar;justify-content:space-between;align-items:center;gap:8px;margin:6px -12px -12px;padding:4px 8px 8px;display:flex;position:relative}.case-bar button,.case-close,.case-undo{pointer-events:auto;touch-action:manipulation}.case-step{align-items:center;gap:2px;display:flex}.case-play,.case-back{border-radius:var(--radius-sm);width:44px;height:44px;color:var(--text-2);cursor:pointer;background:0 0;border:0;place-items:center;padding:0;display:grid}.case-back svg{width:22px;height:22px}.case-play svg{width:20px;height:20px}.case-play .i-play,.case-play .i-pause{fill:currentColor;stroke:none}.case-play .i-pause,.case.playing .case-play .i-play{display:none}.case.playing .case-play .i-pause{display:inline}.case-back.off,.case-play.off,.case.changed .case-count{visibility:hidden}.case-count{text-align:center;min-width:7.5ch;font-family:var(--mono);color:var(--text-3);font-size:13px;font-weight:600}.case-count b{color:var(--text);font-weight:600}.case.ended .case-count b{color:var(--good)}.case-next{border-radius:var(--radius-sm);background:var(--text);min-width:6.75em;height:44px;color:var(--bg);cursor:pointer;border:0;justify-content:center;align-items:center;gap:4px;padding:0 10px 0 16px;font-size:15px;font-weight:650;display:flex}.case-next svg{width:18px;height:18px}.case-next .i-again,.case.ended .case-next .i-next,.case.changed .case-next .i-next{display:none}.case.ended .case-next .i-again,.case.changed .case-next .i-again{display:inline}.case-close:active,.case-back:active,.case-play:active{background:var(--chip)}.case-next:active{transform:scale(.97)}.case-close:focus-visible,.case-back:focus-visible,.case-play:focus-visible,.case-next:focus-visible,.case-undo:focus-visible{outline:2px solid var(--accent);outline-offset:2px}.panel.course .case-alg{font-size:13px;line-height:1.45}.panel.course .case.active .case-alg{font-size:16px;line-height:1.6}body.drilling .stage-hint,body.guiding .stage-hint{display:none}.case{scroll-margin-top:calc(var(--stage-h) + 88px);scroll-margin-bottom:calc(var(--tabbar) + 8px)}.course-intro .collapsible:not(.open)>:not(:first-child){display:none}.course-intro .collapsible:not(.open)>:first-child{margin-bottom:0}.course-intro .more{display:inline}.learn-text.clamp{-webkit-line-clamp:2;line-clamp:2;-webkit-box-orient:vertical;display:-webkit-box;overflow:hidden}.learn-text.clamp p{display:inline}.learn-text.clamp p+p:before{content:" "}.home-intro{-webkit-line-clamp:2;line-clamp:2;-webkit-box-orient:vertical;display:-webkit-box;overflow:hidden}.home-intro.open{display:block}.home-intro .level{display:none}.home-lead{flex-direction:column;align-items:flex-start;gap:4px;display:flex}.home-intro-more:not([hidden]){font-size:13px;display:inline-block}.more-text:not([hidden]){align-self:flex-start;margin-top:-4px;font-size:13px;display:inline-block}.puzzle-switch{display:none}.puzzle-select{border:1px solid var(--line);background:var(--panel) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23bdb4a7' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E") no-repeat right 9px center / 14px;min-width:0;height:36px;color:var(--text);font:inherit;appearance:none;--lightningcss-light: ;--lightningcss-dark:initial;color-scheme:dark;border-radius:10px;padding:0 30px 0 12px;font-size:14px;font-weight:600;display:block}.brand,.top-actions{flex:none}#btn-help,.divider,.brand-name{display:none}.toasts{top:60px}}@media (width<=860px) and (height<=500px){body.solve-bar-on .places{max-width:none;margin:0;left:12px;right:calc(50% + 6px)}.solve-bar{left:50%;bottom:calc(10px + env(safe-area-inset-bottom));padding:0 16px 0 6px}.solve-bar:has(>.solve-bar-status.hidden){min-height:48px}body.solve-bar-on #btn-solve{left:calc(50% + 6px);bottom:calc(10px + env(safe-area-inset-bottom))}body.solve-bar-on .app{padding-bottom:var(--tabbar)}body.puzzle-home{--stage-h:calc(100dvh - 56px - var(--tabbar))}body.puzzle-home .app{padding-bottom:var(--tabbar)}body.puzzle-home .stage-hint{display:none}}@media (width<=400px){.brand{display:none}}@media (prefers-reduced-motion:reduce){*,:before,:after{transition-duration:.01ms!important;animation-duration:.01ms!important}}
