.mega-cover{background:linear-gradient(135deg,#ece4f7,#d9d4f0);position:relative;overflow:hidden;display:grid;place-items:center}.mega-cover.speed{background:linear-gradient(135deg,#dcedf1,#e1dff6)}.mega-cover.memory{background:linear-gradient(135deg,#f7e9d9,#efddc8)}.mega-cover-icon{position:relative;z-index:1;font-size:63px;font-weight:800;color:#8a77b1;text-shadow:0 5px 0 #ffffff4a;transform:rotate(-8deg);pointer-events:none}.mega-cover-orbit{position:absolute;width:115px;height:115px;border:1px solid #fff9;border-radius:50%;box-shadow:0 0 0 20px #ffffff20,0 0 0 43px #ffffff12;transform:rotate(-15deg)}.mega-search{display:flex;align-items:center;gap:15px;margin:18px 0 3px}.mega-search>label{display:flex;align-items:center;gap:12px;border:1px solid #e3ddec;background:#fff;border-radius:13px;max-width:520px;flex:1;padding:0 15px;color:#9e8aae}.mega-search input{padding:13px 0;width:100%;min-width:0;border:0;outline-offset:3px;background:transparent;font-size:12px;color:#776087}.mega-search>span{color:#ac9cbb;font-size:10px}.mega-launch{text-align:center;max-width:540px;margin:auto}.mega-launch>span{display:grid;place-items:center;width:78px;height:78px;margin:0 auto 18px;border:1px solid #e3d9ef;border-radius:23px;background:linear-gradient(135deg,#f0e8fa,#e8eff7);font-size:43px;color:#a18cbe}.mega-launch>small{font-size:9px;letter-spacing:2px;color:#aa96bc}.mega-launch h2{font-size:29px;color:#776087;letter-spacing:-1px;margin:12px 0}.mega-launch p{font-size:13px;line-height:1.9;color:#9c8fa7}.mega-difficulty .difficulty-option{min-height:100px!important}.mega-control-note{font-size:11px;line-height:1.7;text-align:center;color:#a494b4;margin:16px 0 0}.mega-game{max-width:610px;margin:auto}.mega-meta{display:flex;justify-content:space-around;align-items:center;gap:12px;flex-wrap:wrap;padding:10px 13px;border:1px solid #e9e1ef;border-radius:12px;background:#f8f5fc;font-size:12px;color:#a18caf;margin-bottom:14px;min-height:36px}.mega-meta b{color:#84689c;font-weight:800}.mega-instruction{font-size:12px;color:#a697b1;line-height:1.8;text-align:center;margin:12px 0 18px}.mega-grid{display:grid;grid-template-columns:repeat(var(--mega-cols),minmax(0,1fr));gap:5px;max-width:440px;margin:18px auto}.mega-grid>button,.mega-grid>.mega-soko-cell{aspect-ratio:1;min-height:0;min-width:0;padding:0;display:grid;place-items:center;font-size:22px;border:1px solid #e4daed;border-radius:9px;background:#f7f3fb;color:#a48bb8}.mega-grid>button:hover:not(:disabled){background:#eee5f7;border-color:#c4add8}.mega-grid>button:focus-visible,.mega-game button:focus-visible{outline:3px solid #889fc4;outline-offset:2px}.mega-grid .selected,.mega-game button.selected{background:#e8dcf5;border-color:#a88ac4;box-shadow:0 0 0 2px #c7addb50}.mega-grid button:disabled{opacity:1}.mega-game>.secondary,.mega-game>button:not(.start){display:block;margin:15px auto 0;border:1px solid #e2d6ec;border-radius:10px;padding:9px 16px;background:#f8f4fc;color:#9d83b0;font-size:11px;min-height:38px}.mega-soko{max-width:390px;gap:3px}.mega-grid .mega-soko-cell{border-radius:5px;border-color:#e9e3f0;background:#faf8fc;font-size:26px}.mega-grid .mega-soko-cell.wall{background:#ab9bbb;border-color:#a18cb4;box-shadow:inset 0 -5px #9480aa44}.mega-grid .mega-soko-cell.goal{background:#eee6cc;border-color:#e0d39c}.mega-dpad{display:flex;justify-content:center;gap:9px;margin-top:18px}.mega-dpad>button{min-width:49px;height:44px;border:1px solid #e0d6ed;border-radius:12px;background:#f2edf9;color:#987db5;font-size:21px}.mega-nono{display:grid;grid-template-columns:30px repeat(calc(var(--nono-cols) - 1),minmax(0,1fr));gap:3px;max-width:380px;margin:20px auto;align-items:stretch}.mega-nono-col,.mega-nono-row{font-size:11px;line-height:1.5;color:#8a749e;display:flex;align-items:center;justify-content:center;text-align:center;min-height:32px}.mega-nono-col{display:block;align-self:end;padding-bottom:5px}.mega-nono-cell{aspect-ratio:1;border:1px solid #dfd6e8;background:#f9f7fc;min-width:0;padding:0;border-radius:5px;color:#b7a3c7;font-size:24px}.mega-nono-cell.filled{background:#a28abd;border-color:#9677b7;box-shadow:inset 0 -3px #80639833}.mega-reversi-cell{background:#d9eadf!important;border-color:#c6dece!important;padding:6px!important}.mega-disc{display:block;width:80%;aspect-ratio:1;border-radius:50%;box-shadow:0 4px 0 #4c4b531a}.disc-1{background:#7b6990}.disc-2{background:#fefcf7;border:1px solid #e1d7e7}.mega-legal-dot{height:11px;width:11px;border-radius:50%;background:#abc3ac}.mega-dots{display:grid;grid-template-columns:repeat(var(--dots-cols),minmax(0,1fr));max-width:390px;gap:0;margin:20px auto;aspect-ratio:1}.mega-dot{width:9px;height:9px;background:#9d89b3;border-radius:50%;align-self:center;justify-self:center;z-index:2}.mega-dot-box{display:grid;place-items:center;font-size:22px;aspect-ratio:1;color:#fff;border-radius:5px}.box-1{background:#bba2d3}.box-2{background:#e2c79a}.mega-edge{border:0;background:transparent;position:relative;min-width:0;min-height:0;padding:0;display:grid;place-items:center}.mega-edge:after{content:'';display:block;background:#e2d9ec;border-radius:20px}.mega-edge.horizontal:after{height:10px;width:100%;min-height:10px}.mega-edge.vertical:after{width:10px;height:100%;min-width:10px}.mega-edge.edge-1:after{background:#a98ac6}.mega-edge.edge-2:after{background:#d7b37c}.mega-edge:hover:not(:disabled):after{background:#c6b2dc}.mega-chess.dark{background:#e7dded}.mega-chess.allowed{box-shadow:inset 0 0 0 3px #c8dcb6}.mega-chess.visited{background:#d9e7d3;color:#a0b38f;font-size:13px}.mega-chess.conflict{background:#f1d9df;color:#b57b8d}.mega-grid .mega-chess{font-size:35px}.mega-grid .mega-chess.visited:not(:has(span)){color:#8d769e}.mega-grid .mega-peg{border-radius:50%;background:#f0ebf5;font-size:37px;color:#9e86ba}.mega-grid .mega-peg.selected{background:#ddd0ee}.mega-pipe-labels{display:flex;justify-content:space-between;max-width:440px;margin:auto;font-size:11px;color:#99adbd}.mega-grid .mega-pipe{border-radius:5px;border-color:#dfe4ee;background:#f3f6fa;padding:0}.mega-pipe svg{width:100%;height:100%;stroke:#bac5d5;stroke-width:10;fill:#bac5d5;stroke-linecap:round}.mega-pipe.wet svg{stroke:#88b7cf;fill:#88b7cf}.mega-flood-cell{aspect-ratio:1;display:block;border-radius:4px}.mega-palette{display:flex;justify-content:center;gap:10px;flex-wrap:wrap}.mega-palette button{border:2px solid #fff;border-radius:50%;width:41px;height:41px;min-height:0;padding:0;box-shadow:0 0 0 1px #e3d9ec}.mega-palette button:disabled{opacity:.35}.mega-palette span{display:block;width:100%;height:100%;border-radius:50%}.mega-wordlist{display:flex;justify-content:center;gap:8px;flex-wrap:wrap;margin:15px 0}.mega-wordlist span{border:1px solid #e5deed;border-radius:30px;background:#faf7fd;padding:7px 12px;font-size:11px;color:#a58bb6}.mega-wordlist span.found{background:#e9f3e3;color:#8eaa7b;border-color:#d3e2c7;text-decoration:line-through}.mega-letters{gap:3px;max-width:455px}.mega-grid.mega-letters>button{font-size:15px;border-radius:5px;color:#8d7d9e}.mega-grid .mega-letter-found{background:#dfecd7;color:#77915e}.mega-flower{text-align:center;font-size:31px;min-height:42px;margin:19px 0}.mega-secret{display:flex;justify-content:center;gap:8px;margin:25px 0}.mega-secret>span{display:grid;place-items:center;min-width:29px;border-bottom:2px solid #c7b6d5;padding-bottom:9px;font-size:24px;color:#a68eb9;font-weight:800}.mega-alphabet{display:grid;grid-template-columns:repeat(7,minmax(0,1fr));gap:7px;max-width:460px;margin:auto}.mega-alphabet>button{min-height:42px;font-size:14px;border:1px solid #e4dbed;border-radius:9px;background:#f7f2fc;color:#a990bc}.mega-alphabet>button:disabled{opacity:.35}.mega-alphabet>button.correct{background:#e8f4df;color:#8ca879;opacity:1}.mega-type-target{text-align:center;font-size:42px;letter-spacing:5px;color:#a086b7;font-weight:800;margin:35px 0}.mega-input-label{display:block;max-width:450px;margin:20px auto;color:#9f8caa;font-size:12px}.mega-input-label input{display:block;width:100%;border:2px solid #ddd0e9;border-radius:14px;padding:15px;margin-top:12px;font-size:25px;text-align:center;color:#9a7bad;background:#fff;box-sizing:border-box}.mega-target{text-align:center;font-size:13px;color:#a58eb4;margin:20px 0}.mega-target strong{display:inline-block;color:#9c7db4;font-size:30px;margin-left:8px}.mega-number-tiles{display:flex;justify-content:center;gap:13px;flex-wrap:wrap;margin:25px 0}.mega-number-tiles button{display:grid;place-items:center;min-width:68px;min-height:72px;padding:10px;border:2px solid #e5dcec;border-radius:16px;background:#faf7fe;color:#a48bba;font-size:27px;font-weight:800}.mega-operations,.mega-clock-controls{display:flex;justify-content:center;gap:9px;flex-wrap:wrap}.mega-operations button,.mega-clock-controls button{border:1px solid #ddd2e9;background:#f5f0fc;color:#9c83b3;border-radius:10px;font-size:23px;min-height:45px;min-width:47px;padding:8px 13px}.mega-clock-controls button{font-size:13px}.mega-weights{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));max-width:440px;margin:20px auto;gap:10px}.mega-weights button{border:2px solid #dfd7e9;border-radius:13px;background:#f9f6fc;color:#9b85b1;font-size:23px;min-height:61px}.mega-weights small{display:block;font-size:9px;color:#b7a6c4}.mega-scale{position:relative;max-width:300px;height:140px;margin:25px auto}.mega-scale-beam{position:absolute;top:35px;left:10px;right:10px;height:8px;border-radius:9px;background:#bfa6d0;transition:transform .2s}.mega-scale-left,.mega-scale-right{position:absolute;top:55px;display:grid;place-items:center;width:64px;height:45px;border-radius:0 0 30px 30px;background:#e6dbef;border-top:3px solid #b69dc8;font-weight:800;color:#a68abb;font-size:23px}.mega-scale-left{left:5px}.mega-scale-right{right:5px}.mega-scale-base{display:block;position:absolute;left:130px;top:40px;color:#cdbbdc;font-size:70px}.mega-jugs{display:flex;justify-content:center;gap:25px;margin:25px auto;max-width:460px}.mega-jugs>section{flex:1;min-width:0}.mega-jug{height:155px;border:3px solid #b7c4d7;border-top:0;border-radius:0 0 20px 20px;background:#f9fbfd;position:relative;overflow:hidden}.mega-jug>span{position:absolute;left:0;bottom:0;right:0;background:linear-gradient(#a5ccdd,#84b6cf);transition:height .25s}.mega-jug>b{position:absolute;inset:0;display:grid;place-items:center;color:#8c9eb5;font-size:21px;text-shadow:0 1px #fff}.mega-jug-controls{display:grid;gap:6px;margin-top:15px}.mega-jug-controls button{border:1px solid #dce4ee;background:#f3f7fb;color:#95a4ba;border-radius:9px;font-size:10px;padding:10px;min-height:35px}.mega-binary-total{text-align:center;font-size:48px;color:#9c83b3;font-weight:800;margin:20px 0}.mega-binary{display:flex;gap:6px;justify-content:center}.mega-binary button{padding:11px 7px;min-width:34px;border:1px solid #e1d9ed;border-radius:10px;background:#f8f5fc;color:#a28cb6}.mega-binary b{font-size:22px}.mega-binary small{display:block;font-size:8px;margin-top:7px}.mega-clock{display:block;width:min(250px,70vw);height:auto;margin:20px auto}.mega-clock circle:first-child{stroke:#cfbfdc;stroke-width:3;fill:#fcf9ff}.mega-clock text{fill:#aa94ba;text-anchor:middle;font-size:15px;font-family:inherit}.mega-clock .hour{stroke:#9678ae;stroke-width:7;stroke-linecap:round}.mega-clock .minute{stroke:#a6bed2;stroke-width:4;stroke-linecap:round}.mega-clock circle:last-child{fill:#ac97bd}.mega-grid .mega-sea{background:#e5eff8;color:#a2bed1;border-color:#d3e2ed}.mega-grid .mega-sea.hit{background:#f0dce1;color:#bf8498}.mega-grid .mega-sea.sunk{background:#dfead6;color:#8aab76}.mega-grid .mega-sea.miss{background:#f2f6fa;color:#bdcdd9}.mega-answer{text-align:center;color:#a18ab4;font-size:15px;line-height:1.8}.mega-action-game{max-width:420px;margin:auto}#megaCanvas{display:block;width:100%;max-width:min(360px,calc((100dvh - 270px)*.9));height:auto;border:1px solid #e1d8ec;border-radius:17px;margin:auto;touch-action:none;user-select:none}.mega-action-controls{display:flex;gap:8px;justify-content:center;margin:14px 0 0}.mega-action-controls button{border:1px solid #e1d5ec;background:#f4edfc;color:#a68aba;border-radius:11px;min-height:43px;min-width:50px;padding:9px 14px;font-size:13px;touch-action:none;user-select:none}.mega-action-controls .start{background:#a18aba;color:#fff;border-color:#a18aba}.mega-action-game .mega-control-note{font-size:10px;margin-top:12px}#modal:has(.mega-game),#modal:has(.mega-action-game){width:min(760px,96vw)}
@media(max-width:600px){.mega-cover-icon{font-size:47px}.mega-search{gap:9px}.mega-search input{font-size:11px;padding:11px 0}.mega-launch h2{font-size:26px}.mega-launch p{font-size:12px}.mega-difficulty .difficulty-option{min-height:92px!important}.mega-grid{max-width:min(400px,calc(100dvh - 290px));gap:4px}.mega-letters{max-width:440px}.mega-grid.mega-letters>button{font-size:12px}.mega-grid>button{font-size:20px}.mega-instruction{font-size:11px;line-height:1.7}.mega-meta{font-size:11px}.mega-dpad>button{min-width:44px;height:40px}.mega-nono{max-width:320px}.mega-grid .mega-chess{font-size:29px}.mega-grid .mega-peg{font-size:27px}.mega-dots{max-width:min(330px,calc(100dvh - 290px))}.mega-number-tiles{gap:9px}.mega-number-tiles button{min-width:54px;min-height:62px;font-size:22px}.mega-target strong{font-size:26px}.mega-jugs{gap:15px}.mega-jug{height:130px}.mega-clock{width:210px}.mega-flower{font-size:25px}.mega-secret{gap:5px}.mega-secret>span{min-width:23px;font-size:21px}.mega-alphabet{gap:5px}.mega-alphabet>button{font-size:13px;min-height:37px}.mega-type-target{font-size:32px;letter-spacing:3px}.mega-input-label input{font-size:22px}.mega-action-controls button{min-width:42px;padding:10px 12px;font-size:12px}.mega-control-note{font-size:10px}.mega-binary button{padding:9px 5px;min-width:28px}.mega-binary b{font-size:20px}.mega-palette{gap:8px}.mega-palette button{width:36px;height:36px}}
@media(max-height:700px){.mega-grid{max-width:min(400px,calc(100dvh - 270px))}.mega-instruction{font-size:10px;line-height:1.6;margin-bottom:12px}.mega-game>.mega-meta{margin-bottom:8px}.mega-target{margin:12px 0}.mega-clock{width:170px;margin:12px auto}.mega-jug{height:100px}.mega-jugs{margin:16px auto}.mega-grid.mega-letters{max-width:min(420px,calc(100dvh - 240px))}.mega-nono{max-width:min(330px,calc(100dvh - 260px))}.mega-scale{height:115px;margin:15px auto}.mega-weights{margin:14px auto;gap:7px}.mega-weights button{min-height:47px}.mega-number-tiles{margin:16px 0}.mega-number-tiles button{min-height:56px}.mega-dpad{margin-top:10px}.mega-action-game .mega-control-note{font-size:9px;line-height:1.5}.mega-secret{margin:15px 0}.mega-flower{margin:10px 0}.mega-alphabet>button{min-height:33px}}
@media(prefers-reduced-motion:reduce){.mega-scale-beam,.mega-jug>span{transition:none}}
