:root{--bg:#0f1115;--panel:#181b22;--panel2:#20242d;--line:#2c313c;--text:#eceff4;--muted:#8b93a3;--p0:#4cc9f0;--p1:#f72585;--ok:#7ae582;--warn:#ffb703;--radius:14px;--lightningcss-light: ;--lightningcss-dark:initial;color-scheme:dark}*{box-sizing:border-box;-webkit-tap-highlight-color:transparent}html,body,#root{min-height:100%;margin:0}body{background:var(--bg);color:var(--text);-webkit-font-smoothing:antialiased;font-family:Space Grotesk,system-ui,sans-serif;font-size:17px;line-height:1.45}h1,h2,h3{margin:0 0 .4em;line-height:1.15}.muted{color:var(--muted)}.small{font-size:.9rem}.error{color:#ff6b6b;text-align:center}.page{max-width:560px;padding:max(16px, env(safe-area-inset-top)) 16px max(24px, env(safe-area-inset-bottom));flex-direction:column;gap:16px;margin:0 auto;display:flex}.page.center{text-align:center;justify-content:center;align-items:center;min-height:100dvh}.row{flex-wrap:wrap;justify-content:center;gap:10px;display:flex}.btn{appearance:none;border:1px solid var(--line);background:var(--panel2);color:var(--text);font:inherit;cursor:pointer;border-radius:12px;min-height:48px;padding:0 20px;font-weight:500}.btn:active{transform:scale(.98)}.btn:disabled{opacity:.45;cursor:default}.btn.primary{background:var(--text);color:var(--bg);border-color:var(--text);font-weight:700}.btn.big{min-height:56px;padding:0 32px;font-size:1.1rem}.link{color:var(--muted);font:inherit;cursor:pointer;background:0 0;border:none;min-height:44px;padding:8px 0}label{color:var(--muted);margin-bottom:6px;font-size:.9rem;display:block}input{width:100%;font:inherit;color:var(--text);background:var(--bg);border:1px solid var(--line);border-radius:12px;outline:none;min-height:50px;padding:0 14px;font-size:18px}input:focus{border-color:var(--p0)}.card{background:var(--panel);border:1px solid var(--line);border-radius:var(--radius);padding:16px}.hero{padding:24px 0 4px}.hero h1{letter-spacing:-.02em;font-size:2.6rem}.hero h1:after{content:".";color:var(--p1)}.hero p{color:var(--muted);margin:0}.game-list{flex-direction:column;gap:12px;display:flex}.game-card{appearance:none;text-align:left;font:inherit;color:var(--text);background:var(--panel);border:1px solid var(--line);border-radius:var(--radius);cursor:pointer;flex-direction:column;gap:4px;padding:18px;display:flex}.game-card:active{background:var(--panel2)}.game-card:disabled{opacity:.6}.game-name{font-size:1.25rem;font-weight:700}.game-desc{color:var(--muted);font-size:.95rem}.game-cta{color:var(--p0);margin-top:8px;font-weight:500}.join .row{flex-wrap:nowrap}.code-input{text-transform:uppercase;letter-spacing:.2em;font-weight:700}.name-form{text-align:left;flex-direction:column;gap:12px;width:100%;max-width:360px;display:flex}.topbar{justify-content:space-between;align-items:center;gap:8px;display:flex}.topbar-title{text-align:center;white-space:nowrap;text-overflow:ellipsis;flex:1;font-weight:700;overflow:hidden}.code-chip{letter-spacing:.15em;background:var(--panel2);border-radius:8px;padding:4px 8px;font-size:.9rem;font-weight:700}.banner{text-align:center;border-radius:10px;padding:10px 14px;font-size:.95rem}.banner.warn{color:var(--warn);background:#ffb7031f}.toast{left:50%;bottom:max(24px, env(safe-area-inset-bottom));color:#ffb3c1;z-index:10;text-align:center;background:#3a1d24;border:1px solid #5c2a35;border-radius:12px;max-width:90vw;padding:12px 18px;position:fixed;transform:translate(-50%)}.waiting{text-align:center;flex-direction:column;gap:14px;padding-top:32px;display:flex}.share-link{background:var(--panel);border:1px dashed var(--line);word-break:break-all;cursor:pointer;border-radius:12px;padding:16px;font-size:1.15rem;font-weight:700}.pulse{color:var(--muted);margin-top:12px;animation:1.8s ease-in-out infinite pulse}@keyframes pulse{50%{opacity:.35}}.players{grid-template-columns:1fr 1fr;gap:10px;display:grid}.player{background:var(--panel);border:2px solid #0000;border-radius:12px;align-items:center;gap:8px;min-width:0;padding:10px 12px;display:flex}.player .dot{border-radius:50%;flex:none;width:12px;height:12px}.player.p0 .dot{background:var(--p0)}.player.p1 .dot{background:var(--p1)}.player.p0.active{border-color:var(--p0)}.player.p1.active{border-color:var(--p1)}.pname{white-space:nowrap;text-overflow:ellipsis;font-weight:500;overflow:hidden}.you{color:var(--muted);font-weight:400}.offline{color:var(--warn);margin-left:auto;font-size:.75rem}.turn{text-align:center;background:var(--panel);color:var(--muted);border-radius:12px;padding:12px;font-size:1.35rem;font-weight:700}.turn.mine{color:var(--bg)}.turn.mine.p0{background:var(--p0)}.turn.mine.p1{background:var(--p1)}.turn.win{background:var(--ok);color:var(--bg)}.turn.lose{color:var(--text)}.board-wrap{justify-content:center;display:flex}.rematch{text-align:center;flex-direction:column;align-items:center;gap:8px;display:flex}.p0{--pc:var(--p0)}.p1{--pc:var(--p1)}.dots{flex-direction:column;gap:10px;width:100%;display:flex}.scores{justify-content:center;gap:28px;display:flex}.score{flex-direction:column;align-items:center;display:flex}.score-num{color:var(--pc);font-size:2rem;font-weight:700;line-height:1}.score-name{color:var(--muted);font-size:.85rem}.dots-svg{touch-action:manipulation;-webkit-user-select:none;user-select:none;width:100%;max-width:480px;margin:0 auto;display:block}.dots-svg .pt{fill:var(--text)}.dots-svg .ln{stroke:var(--pc);stroke-width:2.4px;stroke-linecap:round}.dots-svg .ln.last{stroke-width:3.4px;filter:drop-shadow(0 0 2px var(--pc))}.dots-svg .ghost{stroke:var(--line);stroke-width:1px;stroke-dasharray:1.5 2;pointer-events:none}.dots-svg .hit{fill:#0000;cursor:pointer}.dots-svg .hit:active{fill:var(--pc);fill-opacity:.18}@media (hover:hover){.dots-svg .hit:hover{fill:var(--pc);fill-opacity:.12}}.dots-svg .box{fill:var(--pc);fill-opacity:.3}.uttt{flex-direction:column;align-items:center;gap:8px;width:100%;display:flex}.uttt .mark{color:var(--pc);font-weight:700}.uttt-big{aspect-ratio:1;background:var(--line);border-radius:14px;grid-template-columns:repeat(3,1fr);gap:6px;width:100%;max-width:480px;padding:6px;display:grid}.uttt-small{background:var(--bg);border-radius:8px;outline:2px solid #0000;grid-template-columns:repeat(3,1fr);gap:2px;padding:3px;display:grid;position:relative}.uttt-small.playable{outline-color:var(--text);background:#1d2230}.uttt-cell{appearance:none;background:var(--panel);color:var(--pc,var(--text));font:inherit;cursor:pointer;touch-action:manipulation;border:none;border-radius:4px;padding:0;font-size:clamp(14px,4.5vw,24px);font-weight:700}.uttt-cell:disabled{cursor:default}.uttt-small.playable .uttt-cell:not(:disabled){background:var(--panel2)}.uttt-cell.last{box-shadow:inset 0 0 0 2px var(--pc)}.uttt-over{color:var(--pc,var(--muted));pointer-events:none;background:#0f1115b8;border-radius:8px;justify-content:center;align-items:center;font-size:clamp(48px,20vw,110px);font-weight:700;display:flex;position:absolute;inset:0}.wordle{flex-direction:column;align-items:center;gap:12px;width:100%;display:flex}.wordle-info{text-align:center;flex-direction:column;align-items:center;gap:8px;display:flex}.wordle-info p{margin:0}.wordle-grids{grid-template-columns:1fr auto;align-items:start;gap:14px;width:100%;display:grid}.wordle-label{color:var(--muted);margin:0 0 6px;font-size:.8rem}.wordle-label .secret{color:var(--text);letter-spacing:.08em}.wordle-opp .wordle-label{max-width:110px}.wordle-grid{flex-direction:column;gap:5px;display:flex}.wordle-row{grid-template-columns:repeat(5,1fr);gap:5px;display:grid}.wordle>.wordle-row{width:min(100%,300px)}.tile{aspect-ratio:1;border:2px solid var(--line);text-transform:uppercase;border-radius:6px;justify-content:center;align-items:center;font-size:clamp(18px,6vw,28px);font-weight:700;display:flex}.tile.filled{border-color:var(--muted)}.wordle-row.active .tile:not(.filled){border-color:#3b4250}.tile.m0,.kb-key.m0{color:var(--muted);background:#2a2e37;border-color:#2a2e37}.tile.m1,.kb-key.m1{color:var(--bg);background:#c9a227;border-color:#c9a227}.tile.m2,.kb-key.m2{color:var(--bg);background:#3fa34d;border-color:#3fa34d}.wordle-grid.mini{gap:3px;width:110px}.wordle-grid.mini .wordle-row{gap:3px}.wordle-grid.mini .tile{border-width:1px;border-radius:3px;font-size:11px}.wordle-msg{color:#ffb3c1;text-align:center;margin:0}.wordle-reveal{text-align:center;margin:0;font-size:1.1rem}.wordle-reveal b{letter-spacing:.1em}.center-text{text-align:center;margin:0}.kb{-webkit-user-select:none;user-select:none;flex-direction:column;gap:6px;width:100%;display:flex}.kb-row{justify-content:center;gap:4px;display:flex}.kb-key{appearance:none;min-width:0;max-width:44px;height:54px;color:var(--text);font:inherit;cursor:pointer;touch-action:manipulation;background:#3a404c;border:none;border-radius:6px;flex:1 1 0;padding:0;font-size:.95rem;font-weight:700}.kb-key.wide{flex:1.6 1 0;max-width:72px;font-size:.8rem}.kb-key:active{filter:brightness(1.3)}.hint{min-height:1.4em;font-weight:500}.c4{justify-content:center;width:100%;display:flex}.c4-grid{background:#1b2a4a;border-radius:14px;gap:4px;width:min(100%,460px);padding:8px;display:grid}.c4-col{appearance:none;cursor:pointer;touch-action:manipulation;background:0 0;border:none;border-radius:10px;flex-direction:column;gap:4px;padding:0;display:flex}.c4-col:disabled{cursor:default}.c4-col.can:active,.c4-col.can:focus-visible{background:#ffffff14}@media (hover:hover){.c4-col.can:hover{background:#ffffff14}}.c4-cell{aspect-ratio:1;padding:3px;display:flex}.c4-disc{background:var(--bg);border-radius:50%;flex:1;box-shadow:inset 0 2px 4px #0009}.c4-disc.p0,.c4-disc.p1{background:var(--pc);box-shadow:inset 0 -3px #00000040}.c4-disc.last{outline:2px solid var(--text);outline-offset:1px}.c4-disc.win{outline:3px solid var(--text);animation:.9s ease-in-out infinite pulse}.rev{flex-direction:column;align-items:center;gap:10px;width:100%;display:flex}.rev-grid{background:#0d3b2a;border-radius:10px;gap:2px;width:min(100%,460px);padding:4px;display:grid}.rev-cell{aspect-ratio:1;cursor:pointer;touch-action:manipulation;background:#17694a;border:none;border-radius:3px;padding:12%;display:flex}.rev-cell:disabled{cursor:default}.rev-disc{background:var(--pc);border-radius:50%;flex:1;box-shadow:inset 0 -3px #00000040}.rev-disc.last{outline:2px solid var(--text);outline-offset:1px}.rev-hint{background:var(--pc);opacity:.55;border-radius:50%;width:30%;height:30%;margin:auto}.mc{flex-direction:column;gap:10px;width:100%;display:flex}.mc-board{background:#3b2a1c;border-radius:18px;grid-template-columns:52px 1fr 52px;gap:6px;padding:8px;display:grid}.mc-store{box-shadow:inset 0 0 0 2px var(--pc);background:#2a1d12;border-radius:26px;flex-direction:column;justify-content:center;align-items:center;gap:2px;display:flex}.mc-store-n{color:var(--pc);font-size:1.6rem;font-weight:700}.mc-store-name{color:var(--muted);text-overflow:ellipsis;white-space:nowrap;max-width:48px;font-size:.65rem;overflow:hidden}.mc-rows{flex-direction:column;gap:8px;display:flex}.mc-row{grid-template-columns:repeat(6,1fr);gap:5px;display:grid}.mc-pit{aspect-ratio:1;color:var(--text);font:inherit;cursor:pointer;touch-action:manipulation;background:#2a1d12;border:none;border-radius:50%;padding:0;position:relative}.mc-pit:disabled{cursor:default}.mc-pit.can{box-shadow:inset 0 0 0 2px var(--pc)}.mc-pit.last{box-shadow:inset 0 0 0 2px var(--text)}.mc-n{background:#3b2a1c;border-radius:8px;padding:0 4px;font-size:.85rem;font-weight:700;position:absolute;bottom:-4px;right:-2px}.mc-seeds{justify-content:center;align-items:center;display:flex;position:absolute;inset:0}.mc-seeds i{background:#e8d3a9;border-radius:50%;width:7px;height:7px;position:absolute;box-shadow:inset 0 -1px #0000004d}.mylly{flex-direction:column;align-items:center;gap:6px;width:100%;display:flex}.mylly-svg{touch-action:manipulation;-webkit-user-select:none;user-select:none;width:min(100%,460px);display:block}.mylly-line{stroke:#4a5160;stroke-width:.8px}.mylly-pt .hit{fill:#0000}.mylly-pt .piece{fill:#4a5160}.mylly-pt.o0 .piece{fill:var(--p0)}.mylly-pt.o1 .piece{fill:var(--p1)}.mylly-pt.target{cursor:pointer}.mylly-pt.t0 .hit{fill:var(--p0);fill-opacity:.18}.mylly-pt.t1 .hit{fill:var(--p1);fill-opacity:.18}.mylly-pt.movable{cursor:pointer}.mylly-pt.movable .piece{stroke:var(--text);stroke-width:.5px}.mylly-pt.sel .piece{stroke:var(--text);stroke-width:1.4px}.mylly-pt.removable{cursor:pointer}.mylly-pt.removable .piece{stroke:#ff6b6b;stroke-width:1.2px;stroke-dasharray:1.5 1}.mylly-pt.last .piece{stroke:var(--text);stroke-width:.8px}.mylly-pt .from{fill:none;stroke:var(--muted);stroke-width:.6px;stroke-dasharray:1 1}.muuri{flex-direction:column;align-items:center;gap:10px;width:100%;display:flex}.muuri-svg{touch-action:manipulation;-webkit-user-select:none;user-select:none;width:min(100%,460px);display:block}.muuri-bg{fill:#12151b}.muuri-cell{fill:var(--panel2)}.muuri-cell.goal-me{fill:#22303a}.muuri-cell.goal-opp{fill:#2b2230}.muuri-cell.can{fill:var(--pc);fill-opacity:.35;cursor:pointer}.muuri-pawn{fill:var(--pc);stroke:var(--bg);stroke-width:.8px}.muuri-wall{fill:#e9c46a}.muuri-wall.preview.ok{fill:var(--ok);opacity:.85}.muuri-wall.preview.bad{fill:#ff6b6b;opacity:.7}.muuri-isect{cursor:pointer}.muuri-isect .hit{fill:#0000}.muuri-isect .dot{fill:var(--muted)}.muuri-controls{flex-direction:column;align-items:center;gap:8px;display:flex}.muuri-controls p{margin:0}.laivat{flex-direction:column;align-items:center;gap:10px;width:100%;display:flex}.laivat p{margin:0}.sea{background:#0b2238;border-radius:10px;gap:2px;width:min(100%,440px);padding:4px;display:grid}.sea.small{width:min(70%,280px)}.sea.aim{box-shadow:0 0 0 2px var(--text)}.sea-cell{aspect-ratio:1;color:var(--text);font:inherit;touch-action:manipulation;background:#123352;border:none;border-radius:3px;justify-content:center;align-items:center;padding:0;font-size:clamp(10px,3vw,16px);font-weight:700;display:flex}.sea.small .sea-cell{border-radius:2px;font-size:9px}.sea-cell:disabled{cursor:default}.sea-cell.tappable{cursor:pointer}.sea-cell.ship{background:#6b7a90}.sea-cell.ship.enemy{background:#4a2a35}.sea-cell.hl{background:#a9b8cc}.sea-cell.miss{color:#a9c3e0;font-size:clamp(16px,5vw,26px)}.sea-cell.hit{background:#c0392b}.sea-cell.sunk{color:#ff8a80;background:#5c1d17}.sea-cell.last{outline:2px solid var(--warn);outline-offset:-2px}.fleet-pick{flex-wrap:wrap;justify-content:center;gap:8px;display:flex}.fleet-ship{border:2px solid var(--line);background:var(--panel);cursor:pointer;border-radius:8px;gap:2px;padding:8px;display:flex}.fleet-ship i{background:#6b7a90;border-radius:3px;width:14px;height:14px}.fleet-ship.placed i{background:#3d4655}.fleet-ship.sel{border-color:var(--text)}.armeija{flex-direction:column;align-items:center;gap:10px;width:100%;display:flex}.armeija p{margin:0}.army-grid{background:#1d2b1a;border-radius:10px;gap:2px;width:min(100%,460px);padding:4px;display:grid}.army-cell{aspect-ratio:1;cursor:pointer;touch-action:manipulation;background:#33472c;border:none;border-radius:4px;padding:3px;display:flex}.army-cell:disabled{cursor:default}.army-cell.lake{background:#1e4f73}.army-cell.sel{box-shadow:inset 0 0 0 2px var(--text)}.army-cell.target.t0{background:color-mix(in srgb, var(--p0) 35%, #33472c)}.army-cell.target.t1{background:color-mix(in srgb, var(--p1) 35%, #33472c)}.army-cell.last{box-shadow:inset 0 0 0 2px var(--warn)}.army-piece{background:var(--pc);color:var(--bg);border-radius:4px;flex:1;justify-content:center;align-items:center;font-size:clamp(12px,4vw,20px);font-weight:700;line-height:1;display:flex}.army-piece.revealed{box-shadow:inset 0 0 0 2px var(--text)}.army-lost{flex-direction:column;gap:4px;width:100%;display:flex}.lost-chip{text-align:center;background:var(--pc);min-width:22px;color:var(--bg);opacity:.7;border-radius:4px;margin:1px;padding:1px 4px;font-size:.8rem;font-weight:700;display:inline-block}.army-legend{background:var(--panel);border-radius:10px;width:100%;padding:10px 14px;font-size:.9rem}.army-legend summary{cursor:pointer;font-weight:500}.army-legend ul{margin:8px 0;padding-left:18px}.tykki{flex-direction:column;gap:8px;width:100%;display:flex}.tykki p{margin:0}.tykki-hud{grid-template-columns:1fr 1fr;gap:10px;display:grid}.tykki-hp{grid-template-rows:auto auto;grid-template-columns:1fr auto;gap:2px 6px;font-size:.85rem;display:grid}.tykki-name{color:var(--muted);white-space:nowrap;text-overflow:ellipsis;overflow:hidden}.hp-n{color:var(--pc);grid-area:1/2/3;align-self:center;font-size:1.2rem;font-weight:700}.hp-bar{background:var(--panel2);border-radius:4px;height:8px;overflow:hidden}.hp-bar i{background:var(--pc);height:100%;transition:width .4s;display:block}.tykki-meta{justify-content:space-between;display:flex}.tykki-svg{border-radius:12px;width:100%;display:block}.tykki-ground{fill:#3d5a3a;stroke:#6c9a5e;stroke-width:.6px}.tykki-aim{fill:none;stroke:var(--text);stroke-width:.5px;stroke-dasharray:1 1.5;opacity:.6}.tykki-tank .body{fill:var(--pc)}.tykki-tank .barrel{stroke:var(--pc);stroke-width:1.4px;stroke-linecap:round}.tykki-shell{fill:#fff3b0}.tykki-trail{fill:none;stroke:#fff3b0;stroke-width:.5px;opacity:.5}.tykki-boom{fill:#ffb703;fill-opacity:.55;stroke:#fb8500;stroke-width:.8px}.tykki-controls{flex-direction:column;gap:10px;display:flex}.tykki-controls.disabled{opacity:.55}.slider{color:var(--text);grid-template-columns:92px 1fr auto;align-items:center;gap:8px;margin:0;font-size:.95rem;display:grid}.slider input[type=range]{min-height:0;accent-color:var(--text);background:0 0;border:none;height:32px;padding:0}.nudge{gap:4px;display:flex}.nudge .btn{min-width:40px;min-height:40px;padding:0}.weapons{grid-template-columns:repeat(4,1fr);gap:6px;display:grid}.weapon{appearance:none;border:1px solid var(--line);background:var(--panel);color:var(--text);font:inherit;cursor:pointer;border-radius:10px;min-height:44px;padding:4px;font-size:.8rem}.weapon.sel{border-color:var(--text);background:var(--panel2)}.weapon:disabled{opacity:.4}.bluff-panel{background:var(--panel);border:1px solid var(--line);text-align:center;border-radius:12px;flex-direction:column;gap:8px;width:100%;padding:12px;display:flex}.t-hit{color:#ff6b6b}.t-miss{color:#a9c3e0}.sea-cell.pending{outline:3px solid var(--text);outline-offset:-3px;animation:1s ease-in-out infinite pulse}.sea-cell.caught{box-shadow:inset 0 0 0 2px var(--warn)}.sea-cell.lied{background-image:repeating-linear-gradient(45deg,#0000 0 3px,#ffffff40 3px 5px)}
