:root{--lightningcss-light:initial;--lightningcss-dark: ;color-scheme:light;--bg:#f4f6f8;--ink:#1c2430;--muted:#5c6775;--line:#1c24301a;--light:#f0d9b5;--dark:#b58863;--hint:#1f4b6e;--hint-alt:#3d5166;--last:#1f4b6e38;--check:#b4453a;--good:#1f6b45;--surface:#fff;--surface-2:#eef1f4}*{box-sizing:border-box}html,body{background:var(--bg);min-height:100%;color:var(--ink);margin:0;font-family:Figtree Variable,Figtree,sans-serif}button,.sq{-webkit-tap-highlight-color:transparent;font-family:inherit}button:focus-visible{outline:2px solid var(--hint);outline-offset:2px}.shell,#app{min-height:100dvh}.ad-rail[hidden]{display:none}@media (width<=1099px){.ad-side{display:none}}.ads-consent{z-index:20;border:1px solid var(--line);background:var(--surface);border-radius:16px;flex-wrap:wrap;justify-content:space-between;align-items:center;gap:12px;max-width:560px;margin:0 auto;padding:14px 16px;display:flex;position:fixed;bottom:16px;left:16px;right:16px;box-shadow:0 16px 40px oklch(0% 0 0/.35)}.ads-consent p{color:var(--muted);flex:220px;margin:0;font-size:.88rem;line-height:1.4}.ads-consent-actions{gap:8px;display:flex}.ads-consent button{border:1px solid var(--line);min-height:40px;color:var(--ink);font:inherit;cursor:pointer;background:0 0;border-radius:12px;padding:0 14px;font-size:.88rem;font-weight:700}.ads-consent [data-ads=grant]{color:#1c1612;background:oklch(78% .14 88);border:0}.ad-mobile:not([hidden]){width:100%;display:block}.ad-mobile .ad-slot{width:100%;min-height:100px;display:block}@media (width>=1100px){.ad-mobile,.ad-mobile:not([hidden]){display:none}.shell:has(.ad-side:not([hidden])){grid-template-columns:180px minmax(0,560px) 180px;justify-content:center;align-items:start;column-gap:24px;display:grid}.shell:has(.ad-side:not([hidden])) .app{width:100%}.ad-side:not([hidden]){justify-content:center;padding-top:28px;display:flex;position:sticky;top:16px}.ad-side .ad-slot{width:160px;min-height:600px;display:block}}.app{width:min(560px,100%);min-height:100dvh;padding:max(16px, env(safe-area-inset-top)) max(14px, env(safe-area-inset-right)) max(20px, env(safe-area-inset-bottom)) max(14px, env(safe-area-inset-left));flex-direction:column;gap:12px;margin:0 auto;display:flex}.top{justify-content:space-between;align-items:center;gap:12px;min-height:36px;display:flex}.top-main{flex:1;min-width:0}.back-header{border:1px solid var(--line);min-height:40px;color:var(--ink);font:inherit;cursor:pointer;background:0 0;border-radius:12px;flex:none;padding:0 12px;font-size:.88rem;font-weight:700}.setup-top .status{text-align:left;max-width:none;margin-top:4px}h1{letter-spacing:-.04em;margin:0;font-size:1.15rem;font-weight:750}.status{background:var(--surface-2);max-width:58%;color:var(--ink);text-align:right;border-radius:999px;margin:0;padding:6px 10px;font-size:.78rem;font-weight:700;line-height:1.25}.toolbar{background:var(--surface);border-radius:16px;gap:4px;padding:4px;display:grid;box-shadow:inset 0 1px oklch(100% 0 0/.05)}.board-toolbar{grid-template-columns:1fr 1fr}.play-header{flex-direction:column;align-items:stretch;gap:4px;display:flex}.brand{min-width:0;color:var(--ink);letter-spacing:-.045em;justify-content:center;align-items:center;gap:8px;margin:0;font-size:.95rem;font-weight:750;line-height:1;display:flex}.brand span{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.brand-mark{border-radius:8px;flex:none;width:32px;height:32px}.play-header .top{gap:4px}.play-header .brand{letter-spacing:-.06em;flex:1 0 auto;justify-content:flex-start;gap:6px;font-size:1.24rem}.play-header .brand span{text-overflow:unset;flex:none;overflow:visible}.menu-btn{border:1px solid var(--line);background:var(--surface);width:44px;height:44px;color:var(--ink);cursor:pointer;border-radius:12px;flex:none;place-items:center;display:grid}.menu-bars{flex-direction:column;justify-content:center;gap:4px;width:18px;display:flex}.menu-bars span{background:var(--ink);border-radius:1px;height:2px;display:block}.header-menu{background:var(--surface);border-radius:16px;flex-direction:column;gap:6px;margin-top:-6px;padding:10px;display:flex;box-shadow:inset 0 1px oklch(100% 0 0/.06),0 14px 28px oklch(0% 0 0/.22)}.header-menu[hidden]{display:none}.header-menu-item{background:var(--surface-2);min-height:48px;color:var(--ink);font:inherit;text-align:left;cursor:pointer;border:0;border-radius:12px;padding:0 14px;font-size:.92rem;font-weight:700}.header-menu-item:active{filter:brightness(.94)}.header-menu-item[data-position=mount]{color:oklch(30% .06 145);background:oklch(90% .05 145)}.header-menu .lang-select{background:var(--surface-2);border-radius:12px;align-items:center;gap:10px;min-height:48px;margin-bottom:4px;padding:0 8px 0 14px;display:flex}.lang-select span{color:var(--muted);letter-spacing:0;text-transform:none;flex:none;font-size:.92rem;font-weight:700}.lang-select select{appearance:none;width:auto;min-width:0;min-height:44px;color:var(--ink);font:inherit;text-align:right;cursor:pointer;background:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8'%3E%3Cpath fill='%23332624' d='M1 1.2 6 6.8 11 1.2'/%3E%3C/svg%3E") right 6px center/10px 7px no-repeat,0 0;border:0;border-radius:12px;flex:1;padding:0 28px 0 0;font-size:.92rem;font-weight:700}.play-header h1{font-size:1.05rem}.setup-toolbar{grid-template-columns:1fr 1fr 1fr}.clear{color:var(--ink);min-height:42px;font:inherit;cursor:pointer;background:0 0;border:0;border-radius:12px;padding:0 8px;font-size:.9rem;font-weight:700}.clear:active,.clear[aria-pressed=true]{color:var(--ink);background:oklch(90% .04 85)}.clear:disabled{opacity:.35;cursor:default}.stage{background:0 0;padding:0}.card{border:1px solid var(--line);background:var(--surface);border-radius:22px;flex-direction:column;gap:6px;padding:14px 16px 16px;display:flex;box-shadow:0 1px 2px #1c24300a}.card-move,.card-read,.card-odds{background:var(--surface)}.play-mode .card-odds,.play-mode .card-read-top{gap:4px;padding:10px 14px 12px}.play-mode .card-read-top .opening{font-size:1.02rem}.play-mode .card-read-top .why{font-size:.88rem;line-height:1.35}.play-mode .card-read-top .eval{font-size:.8rem}.card-pieces,.card-turn,.card-castle{background:var(--surface)}.kicker{color:var(--muted);letter-spacing:.14em;text-transform:uppercase;align-items:center;gap:8px;margin:0;font-size:.7rem;font-weight:750;display:flex}.kicker:before{content:"";background:var(--dot,var(--hint));border-radius:99px;flex:none;width:7px;height:7px}.card-move{--dot:var(--hint)}.card-read{--dot:var(--good)}.card-odds{--dot:oklch(52% .04 250)}.card-pieces{--dot:var(--dark)}.card-turn{--dot:oklch(55% .1 85)}.card-castle{--dot:oklch(50% .1 55)}.advice-move{letter-spacing:-.04em;margin:0;font-family:Figtree Variable,Figtree,sans-serif;font-size:clamp(2rem,9vw,2.7rem);font-weight:700;line-height:.95}.alts{flex-wrap:wrap;gap:8px;margin:8px 0 0;display:flex}.alt{color:var(--ink);letter-spacing:-.03em;background:oklch(93% .03 85);border-radius:999px;align-items:baseline;gap:6px;padding:7px 10px;font-size:.95rem;font-weight:750;display:inline-flex}.alt small{color:var(--muted);font-size:.75rem;font-weight:650}.advice-detail{color:var(--good);margin:2px 0 0;font-size:.95rem}.opening{color:var(--hint);letter-spacing:-.03em;margin:0;font-size:1.15rem;font-weight:750}.why{color:var(--ink);margin:0;font-size:.95rem;line-height:1.45}.eval{color:var(--muted);margin:2px 0 0;font-size:.82rem}.chances{flex-direction:column;gap:8px;display:flex}.chances-labels{justify-content:space-between;gap:12px;font-size:.95rem;font-weight:750;display:flex}.chances-labels span:first-child{color:var(--ink)}.chances-labels span:last-child{color:var(--muted)}.chances-bar{background:oklch(16% .01 70);border-radius:999px;height:14px;display:flex;overflow:hidden}.chances-white{background:linear-gradient(90deg,#fffaf2,#e7d3b4)}.chances-black{background:linear-gradient(90deg,#6d5b4a,#3d342c)}.chances-wait{color:var(--muted);margin:0;font-size:.92rem}.board-wrap{aspect-ratio:1;width:100%;max-width:100%;margin:0 auto}.board{box-sizing:border-box;touch-action:none;-webkit-user-select:none;user-select:none;background:#4a3728;border:6px solid #4a3728;border-radius:2px;grid-template-rows:repeat(8,minmax(0,1fr));grid-template-columns:repeat(8,minmax(0,1fr));width:100%;height:100%;display:grid;position:relative;overflow:hidden;box-shadow:inset 0 0 0 1px #2a1c12}.sq{aspect-ratio:1;cursor:pointer;width:100%;min-width:0;height:100%;min-height:0;font:inherit;border:0;place-items:center;margin:0;padding:0;display:grid;position:relative}.sq.light{color:#5c4a32;background:#ebecd0}.sq.dark{color:#f0f2e4;background:#779556}.sq.selected{box-shadow:inset 0 0 0 3px #f7f3ea}.sq.last{background-image:linear-gradient(var(--last), var(--last))}.sq.alt{box-shadow:inset 0 0 0 3px var(--hint-alt)}.sq.hint{box-shadow:inset 0 0 0 4px var(--hint)}.palette button{cursor:grab;touch-action:none}.board .sq:has(.piece){cursor:grab;touch-action:none}.sq.dragging{cursor:grabbing}.sq.dragging .piece{opacity:.28}.sq.drag-ok{box-shadow:inset 0 0 0 3px oklch(97% .01 90/.7)}.sq.drop{box-shadow:inset 0 0 0 4px #f7f3ea}.drag-ghost{z-index:80;pointer-events:none;filter:drop-shadow(0 12px 16px #00000073);position:fixed;top:0;left:0;transform:translate(-50%,-62%)}.sq.check{background-image:radial-gradient(circle, var(--check) 0 38%, transparent 62%)}.piece{object-fit:contain;pointer-events:none;filter:drop-shadow(0 1px 1px #28180859);width:92%;max-width:100%;height:92%;max-height:100%}.coord{opacity:.72;pointer-events:none;font-size:9px;font-weight:700;line-height:1;position:absolute}.coord.file{bottom:3px;right:3px}.coord.rank{top:3px;left:3px}.dot{pointer-events:none;background:#14110e47;border-radius:50%;width:28%;height:28%;margin:auto;position:absolute;inset:0}.sq.dark .dot{background:#fff8eb59}.ring{pointer-events:none;border:4px solid #14110e47;border-radius:50%;width:78%;height:78%;margin:auto;position:absolute;inset:0}.sq.dark .ring{border-color:#fff8eb66}.arrow{pointer-events:none;width:100%;height:100%;position:absolute;inset:0}.promo{-webkit-backdrop-filter:blur(8px);backdrop-filter:blur(8px);background:oklch(16% .01 70/.5);place-items:center;display:grid;position:absolute;inset:0}.promo-card{background:var(--surface);border-radius:20px;grid-template-columns:repeat(4,1fr);gap:8px;width:min(92%,360px);padding:10px;display:grid;box-shadow:0 16px 40px oklch(0% 0 0/.35)}.promo-card button{background:var(--light);color:#1c1612;min-height:84px;font:inherit;cursor:pointer;border:0;border-radius:14px;flex-direction:column;align-items:center;gap:2px;font-size:.78rem;font-weight:700;display:flex}.promo-card img{width:48px;height:48px}.setup-help-row{justify-content:space-between;align-items:center;gap:8px;display:flex}.setup-help-row .kicker{margin:0}.setup-help{color:var(--muted);margin:0;font-size:.9rem;line-height:1.35}.palette-block{flex-direction:column;gap:6px;display:flex}.palette-label{color:var(--muted);letter-spacing:.08em;text-transform:uppercase;margin:4px 0 0;font-size:.75rem;font-weight:750}.palette{grid-template-columns:repeat(6,1fr);gap:6px;display:grid}.palette button,.turn-switch button,.castle-row button,.ready,.eraser{font:inherit;cursor:pointer}.palette button{background:var(--light);border:1px solid #0000;border-radius:14px;place-items:center;min-height:48px;padding:2px;display:grid}.palette img{object-fit:contain;pointer-events:none;width:100%;height:40px}.palette button[aria-pressed=true]{box-shadow:inset 0 0 0 3px var(--hint)}.eraser{background:var(--surface-2);min-height:36px;color:var(--ink);border:0;border-radius:999px;padding:0 12px;font-size:.85rem;font-weight:750}.eraser[aria-pressed=true]{color:#1c1612;background:oklch(78% .14 88)}.turn-switch{grid-template-columns:1fr 1fr;gap:8px;display:grid}.turn-switch button{background:var(--surface-2);min-height:48px;color:var(--ink);border:0;border-radius:14px;font-weight:750}.turn-switch button[aria-pressed=true]{background:var(--ink);color:#f6f1e8}.castle-row{grid-template-columns:auto 1fr 1fr;align-items:center;gap:6px;display:grid}.castle-row span{color:var(--muted);font-size:.85rem;font-weight:700}.castle-row button{background:var(--surface-2);min-height:42px;color:var(--ink);border:0;border-radius:14px;padding:0 10px;font-size:.88rem;font-weight:750}.castle-row button[aria-pressed=true]{color:var(--hint);box-shadow:inset 0 0 0 1.5px var(--hint);background:oklch(84% .14 90/.2)}.castle-row button:disabled{opacity:.35;cursor:default}.setup-error{color:oklch(42% .12 30);background:oklch(94% .04 30);border-radius:16px;margin:0;padding:12px 14px;font-size:.92rem}.ready{color:#1c1612;letter-spacing:-.02em;background:oklch(78% .14 88);border:0;border-radius:16px;min-height:52px;font-weight:800;box-shadow:0 10px 24px oklch(84% .14 90/.22)}.play-mode,.setup-mode{height:100dvh;min-height:0;padding-top:max(8px, env(safe-area-inset-top));padding-bottom:max(8px, env(safe-area-inset-bottom));gap:6px;position:relative;overflow:hidden}.play-mode:has(.ad-mobile){height:auto;min-height:100dvh;overflow:visible}.play-mode .stage,.setup-mode .stage{flex:auto;place-items:center;min-height:0;display:grid;container-type:size}.play-mode .board-wrap,.setup-mode .board-wrap{width:min(100cqi,100cqb);max-width:100%;height:min(100cqi,100cqb)}.play-mode .sq,.setup-mode .sq{aspect-ratio:auto}.play-mode .board .sq{touch-action:manipulation;cursor:pointer}.play-mode .sq.pressed{filter:brightness(.92)}.move-ghost{z-index:30;pointer-events:none;object-fit:contain;transition:transform .15s cubic-bezier(.2,.8,.2,1);position:fixed}.play-header{position:relative}.play-mode .header-menu{z-index:6;margin:0;position:absolute;top:calc(100% + 6px);left:0;right:0}.play-mode .card{border-radius:14px;flex:none;gap:2px;padding:6px 10px 7px}.play-mode .menu-btn{width:36px;height:36px}.play-mode .brand{font-size:1.24rem}.play-mode .status{max-width:none;color:var(--muted);text-align:center;background:0 0;align-self:center;margin:0;padding:0;font-size:.95rem;font-weight:700;line-height:1.2}@media (width<=719px){.play-header .brand{letter-spacing:-.02em;font-size:1.45rem;font-weight:700;line-height:1.05}.play-header .brand-mark{border-radius:10px;width:44px;height:44px}.play-header .menu-btn{width:44px;height:44px}}.play-mode .kicker{letter-spacing:.1em;font-size:.62rem}.play-mode .kicker:before{width:5px;height:5px}.play-mode .opening{font-size:.95rem}.play-mode .why,.play-mode .advice-detail{-webkit-line-clamp:2;-webkit-box-orient:vertical;font-size:.78rem;line-height:1.25;display:-webkit-box;overflow:hidden}.play-mode .eval{margin:0;font-size:.72rem}.play-mode .chances{gap:4px}.play-mode .chances-labels{font-size:.78rem}.play-mode .chances-bar{height:8px}.play-mode .advice-move{font-size:1.45rem}.play-mode .alts{flex-wrap:nowrap;gap:6px;margin:2px 0 0;overflow-x:auto}.play-mode .alt{flex:none;padding:4px 8px;font-size:.82rem}.play-mode .clear,.setup-mode .clear{min-height:34px}.setup-top{align-items:center}.setup-top h1{flex:1;min-width:0;font-size:1rem}.setup-actions{gap:2px;display:flex}.setup-dock{background:var(--surface);border-radius:16px;flex-direction:column;flex:none;gap:6px;padding:8px;display:flex}.palette-row{grid-template-columns:1fr 1fr;gap:8px;display:grid}.setup-mode .palette-block{gap:2px}.setup-mode .palette-label{margin:0;font-size:.62rem}.setup-mode .palette{gap:3px}.setup-mode .palette button{border-radius:8px;min-height:40px}.setup-mode .palette img{height:30px}.setup-rules{flex-direction:column;gap:4px;display:flex}.setup-mode .turn-switch{gap:4px}.setup-mode .turn-switch button{border-radius:10px;min-height:34px;font-size:.78rem}.setup-mode .castle-row{flex-direction:column;gap:4px;display:flex}.castle-line{grid-template-columns:auto 1fr 1.35fr;align-items:center;gap:4px;display:grid}.castle-line span{color:var(--muted);font-size:.68rem;font-weight:750}.castle-line button{background:var(--surface-2);min-height:34px;color:var(--ink);border:0;border-radius:8px;padding:0 4px;font-size:.72rem;font-weight:750}.castle-line button[aria-pressed=true]{color:var(--hint);box-shadow:inset 0 0 0 1.5px var(--hint);background:oklch(84% .14 90/.2)}.castle-line button:disabled{opacity:.35;cursor:default}.setup-mode .ready{flex:none;min-height:40px}.setup-mode .setup-error{flex:none;padding:8px 10px;font-size:.82rem}@media (width>=720px){.app{padding-top:28px}.play-mode,.setup-mode{gap:12px;height:auto;overflow:visible}.play-mode .stage,.setup-mode .stage{flex:none;display:block;container-type:normal}.play-mode .board-wrap,.setup-mode .board-wrap{aspect-ratio:1;width:100%;height:auto}.play-mode .sq,.setup-mode .sq{aspect-ratio:1}}@font-face{font-family:Figtree Variable;font-style:normal;font-display:swap;font-weight:300 900;src:url(/assets/figtree-latin-ext-wght-normal-DCwSJGxG.woff2)format("woff2-variations");unicode-range:U+100-2BA,U+2BD-2C5,U+2C7-2CC,U+2CE-2D7,U+2DD-2FF,U+304,U+308,U+329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:Figtree Variable;font-style:normal;font-display:swap;font-weight:300 900;src:url(/assets/figtree-latin-wght-normal-D_ZTVpCC.woff2)format("woff2-variations");unicode-range:U+??,U+131,U+152-153,U+2BB-2BC,U+2C6,U+2DA,U+2DC,U+304,U+308,U+329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}
