:root{font-family:Segoe UI,system-ui,sans-serif;color:#292b28;background:#f6f5f0;font-synthesis:none;line-height:1.5;--ink: #292b28;--muted: #6d7068;--line: #dedfd5;--paper: #fffefa;--accent: #a3442e}*{box-sizing:border-box}html{scroll-behavior:smooth}body{margin:0}a{color:var(--accent);text-underline-offset:4px}button,input,select{font:inherit}button,.button-link{cursor:pointer;border:1px solid transparent;border-radius:6px;padding:.65rem 1rem;background:var(--ink);color:#fffefa;font-weight:600;font-size:.875rem;min-height:42px;transition:background .15s,border-color .15s}button:hover,.button-link:hover{background:#45493f}button:disabled{cursor:default;opacity:.45}button:focus-visible,a:focus-visible,input:focus-visible,select:focus-visible,summary:focus-visible{outline:3px solid #bd6a39;outline-offset:4px}button.secondary{background:#eeeee7;color:var(--ink);border-color:var(--line)}button.secondary:hover{background:#e3e4d9}.text-button{color:var(--muted);background:transparent;padding:.5rem 0;border-radius:0;text-decoration:none}.text-button:hover{color:var(--accent);background:transparent}h1,h2,h3,p{margin-top:0}h1{font-family:Georgia,serif;font-weight:400;letter-spacing:-.045em;line-height:1.1}h2{font-size:1.2rem;font-weight:650;letter-spacing:-.025em;margin-bottom:.8rem}h3{font-size:1rem;margin-bottom:.3rem}p{margin-bottom:.8rem}.eyebrow{font-size:.65rem;letter-spacing:.16em;color:var(--muted);font-weight:700;margin-bottom:.8rem}.hint{color:var(--muted);font-size:.8rem}main{max-width:1380px;margin:auto;padding:0 3rem}.app-header{height:88px;display:flex;justify-content:space-between;align-items:center;border-bottom:1px solid var(--line);gap:1rem}.brand{display:flex;align-items:center;gap:.7rem;color:var(--ink);font-size:1.7rem;font-weight:750;letter-spacing:-.07em;text-decoration:none}.brand-mark{display:flex;position:relative;align-items:center;width:35px;height:28px}.brand-mark i{position:absolute;width:23px;height:23px;border-radius:50%;background:var(--ink);border:1px solid var(--ink)}.brand-mark i:last-child{background:#fffefa;left:13px;top:5px}.account-menu{display:flex;align-items:center;gap:1.5rem}.account-menu h2{font-size:.85rem;font-weight:500;margin:0;letter-spacing:0}.header-note{font-size:.8rem;color:var(--muted)}.app-content{margin:0;padding:0}footer{font-size:.72rem;color:var(--muted);border-top:1px solid var(--line);margin-top:3rem;padding:1.4rem 0}.playground{position:relative;padding-top:1.5rem}.connection{display:flex;align-items:center;gap:.45rem;color:#92501b;font-size:.72rem;margin-bottom:1rem}.connection:before{content:"";background:currentColor;width:6px;height:6px;border-radius:50%}.connection[data-live=true]{color:#4c6950}[role=alert],.playground>p[role=status],.auth-card>p[role=status]{background:#f1eee2;border-left:3px solid #8a794b;padding:.8rem 1rem;font-size:.85rem}[role=alert]{background:#f8e9e3;color:#923c27;border-color:#a3442e}.lobby-heading{display:flex;justify-content:space-between;align-items:center;margin:1.4rem 0 2rem;gap:1rem}.lobby-heading h1{font-size:clamp(2.5rem,4vw,3.6rem);margin:0 0 .7rem}.lobby-heading p:last-child{color:var(--muted);font-size:.9rem;margin:0}.button-link{text-decoration:none;white-space:nowrap;display:inline-flex;align-items:center;background:var(--accent)}.lobby-layout{display:grid;grid-template-columns:minmax(0,1fr) 340px;gap:1.5rem 2rem;align-items:start}.lobby-layout>section{min-width:0;padding:1.5rem;background:var(--paper);border:1px solid var(--line);border-radius:9px}.create-panel{grid-column:2;grid-row:1 / span 3;scroll-margin-top:2rem}.games-list{grid-column:1;grid-row:1}.challenge-list{grid-column:1;grid-row:2}.demo-list{grid-column:1;grid-row:3}.legacy-list{grid-column:1}.section-heading{display:flex;justify-content:space-between;align-items:center;gap:1rem;margin-bottom:1rem}.section-heading h2{margin:0}.count{color:var(--muted);font-size:.72rem;background:#f0f0e9;border-radius:20px;padding:.25rem .6rem;white-space:nowrap}.game-filters{display:flex;border-bottom:1px solid var(--line);gap:1.4rem}button.filter{background:transparent;color:var(--muted);padding:.5rem 0 .8rem;border:0;border-bottom:2px solid transparent;border-radius:0;font-size:.8rem}button.filter.active{color:var(--accent);border-color:var(--accent)}.empty-state{padding:2.3rem .5rem;text-align:center;color:var(--muted);font-size:.85rem}.empty-state h3{color:var(--ink);font-weight:500;margin:.8rem 0 .4rem}.empty-state p{margin:0 auto;max-width:24rem}.empty-stones{font-size:2.5rem;letter-spacing:-.2em;color:#787d69}.list-card{position:relative;padding:1.1rem 0;border-top:1px solid var(--line);padding-right:150px;min-height:95px}.list-card h3{font-weight:600;overflow-wrap:anywhere}.list-card p{color:var(--muted);font-size:.8rem;margin:.35rem 0 0}.list-card>button{position:absolute;right:0;top:1.25rem;font-size:.8rem}.legacy-list .list-card{padding-right:0}.legacy-list .list-card>button{position:static;margin:.7rem .5rem 0 0}label{display:block;font-size:.78rem;font-weight:600;margin-bottom:1rem}input,select{display:block;width:100%;min-width:0;border:1px solid #c8cbc0;border-radius:5px;background:var(--paper);color:var(--ink);padding:.65rem;margin-top:.4rem;min-height:44px}.form-grid{display:grid;grid-template-columns:1fr 1fr;gap:0 1rem}.form-grid>label:first-child,.form-grid>label:nth-child(2),.form-grid>label:last-child{grid-column:1 / -1}.create-panel form>button,.auth-card form>button{width:100%;background:var(--accent)}.creation-rules{margin:0 0 1.2rem;font-size:.78rem;border:0;padding:0}.creation-rules summary{color:var(--muted)}.game-room{margin:.5rem 0}.room-heading{margin:.6rem 0 .8rem}.room-heading h2{font-family:Georgia,serif;font-size:2rem;font-weight:400;overflow-wrap:anywhere}.room-heading>p:last-child{font-size:.8rem;color:var(--muted)}.versus{color:#989d90;font-size:.65em;margin:0 .5rem;font-style:italic}.room-layout{display:grid;grid-template-columns:minmax(0,1fr) 320px;gap:2.5rem;align-items:start}.board-column{min-width:0}.turn{display:flex;align-items:center;background:#e9ecdf;color:#475440;font-size:.85rem;font-weight:600;border-radius:6px;padding:.7rem 1rem;margin-bottom:1rem}.room-sidebar{min-width:0;padding:1.3rem;background:var(--paper);border:1px solid var(--line);border-radius:9px;font-size:.82rem}.players{border-bottom:1px solid var(--line);padding-bottom:1rem;margin-bottom:1rem}.players>div{display:grid;grid-template-columns:28px minmax(0,1fr);gap:.1rem .6rem;margin:.7rem 0}.players strong{overflow-wrap:anywhere}.players span:last-child{grid-column:2;color:var(--muted);font-size:.75rem}.stone{display:block;width:23px;height:23px;border-radius:50%;grid-row:span 2;align-self:center;box-shadow:0 2px 3px #292b2820}.stone.black{background:#292b28}.stone.white{background:#faf9f4;border:1px solid #bfc3b5}.check{display:flex;align-items:center;gap:.5rem;font-weight:400;font-size:.8rem}.check input{width:16px;height:16px;min-height:0;margin:0;accent-color:var(--accent)}.pass-button{width:100%;margin:.3rem 0 .8rem}.danger-button{color:#943e2a;background:transparent;border:1px solid #dcc8bd;margin-top:1rem}.danger-button:hover{color:#fff;background:#943e2a}.scoring-controls{border-top:1px solid var(--line);padding-top:1rem}.scoring-controls>button,.confirmation button,dialog button{margin:.4rem .4rem .3rem 0}.score-card{background:#f2f3ea;padding:1rem;border:1px solid #dce0d0;border-radius:6px;margin:1rem 0}.score-card p{font-size:.78rem}.score-card button{margin:.4rem .4rem 0 0}.confirmation{padding:1rem;margin:.8rem 0;background:#f6eadf;border:1px solid #d9b696;border-radius:6px}.confirmation p{margin:0 0 .5rem;font-weight:600}details{border-top:1px solid var(--line);padding-top:.9rem;margin-top:1rem}summary{cursor:pointer;font-size:.8rem;font-weight:600;padding:.3rem 0}details>p,details>ol{margin-top:.7rem;color:var(--muted);font-size:.8rem}details ol{padding-left:1.5rem;max-height:18rem;overflow-y:auto}.download-link{display:block;padding:.6rem 0;font-size:.8rem}dialog{color:var(--ink);background:var(--paper);border:1px solid var(--line);border-radius:12px;width:min(92vw,500px);max-height:85vh;overflow:auto;padding:2rem;box-shadow:0 24px 100px #292b2822}dialog::backdrop{background:#252a2466;-webkit-backdrop-filter:blur(3px);backdrop-filter:blur(3px)}dialog p{color:var(--muted);font-size:.9rem}.demo-toolbar{display:flex;align-items:end;gap:.6rem;flex-wrap:wrap;background:#eaece2;border-radius:8px;padding:1rem;margin:1rem 0}.demo-toolbar label{margin:0;min-width:125px}.demo-toolbar .confirmation{flex-basis:100%}.demo-room>p{color:var(--muted);font-size:.8rem}.demo-room>.turn{color:#475440}.auth-page{display:grid;grid-template-columns:1.2fr 1fr;gap:0 5rem;min-height:100vh;align-content:start}.auth-page>.app-header,.auth-page>footer{grid-column:1 / -1}.auth-intro{padding:5rem 0 0}.auth-intro h1{font-size:clamp(3.5rem,6vw,5.7rem);margin:1rem 0 1.5rem}.auth-intro>p{color:var(--muted);font-size:.95rem}.auth-card{align-self:center;margin:4rem 0 2rem;padding:2.5rem;background:var(--paper);border:1px solid var(--line);border-radius:10px;max-width:430px}.auth-card h2{font-size:1.6rem}.auth-card>p{font-size:.85rem;color:var(--muted)}.auth-card form{margin:1.8rem 0 1rem}.intro-board{position:relative;width:230px;height:150px;margin:2rem 0;background:repeating-linear-gradient(0deg,transparent 0 28px,#b4b69d 29px 30px),repeating-linear-gradient(90deg,transparent 0 28px,#b4b69d 29px 30px);-webkit-mask-image:linear-gradient(90deg,black 50%,transparent);mask-image:linear-gradient(90deg,black 50%,transparent)}.intro-board i{position:absolute;background:#30372e;width:24px;height:24px;border-radius:50%;left:47px;top:48px;box-shadow:1px 2px 3px #292b2833}.intro-board i:nth-child(2n){background:#fffefa;border:1px solid #c7cabb}.intro-board i:nth-child(2){left:77px;top:78px}.intro-board i:nth-child(3){left:107px;top:48px}.intro-board i:nth-child(4){left:77px;top:18px}.intro-board i:nth-child(5){left:47px;top:78px}.intro-board i:nth-child(6){left:107px;top:78px}.intro-board i:nth-child(7){left:137px;top:18px}.auth-intro .intro-caption{font-size:.65rem;letter-spacing:.12em}.board{position:relative;width:100%;max-width:38rem;aspect-ratio:1;background:#dcb67d;border-radius:.4rem;overflow:hidden}.goban-host,.board-input{position:absolute;inset:0;width:100%;height:100%}.goban-host svg{width:100%;height:100%;display:block}.board-input button{min-height:0;position:absolute;border-radius:50%;padding:0;margin:0;background:transparent}.board-input button:not(:disabled):hover{background:#fff4}.board-input button:disabled{opacity:1;cursor:default}.board-input button:focus-visible{outline:3px solid #a74c23;outline-offset:-4px;background:#fff3}.board-input button[data-mark=dead]{outline:4px solid #bd4435;outline-offset:-5px}.board-input button[data-mark=neutral]{outline:4px dashed #286691;outline-offset:-5px}.board{max-width:none;border:1px solid #c7a575;border-radius:5px;box-shadow:0 12px 30px #51422d14}@media(min-width:1000px){.board-column>.board{max-width:min(100%,calc(100dvh - 380px));margin:0 auto}}@media(max-width:1000px){main{padding:0 1.5rem}.lobby-layout{grid-template-columns:minmax(0,1fr) 300px;gap:1.2rem}.room-layout{grid-template-columns:minmax(0,1fr) 280px;gap:1.4rem}.auth-page{gap:0 2rem}.auth-card{padding:1.8rem}}@media(max-width:760px){main{padding:0 1rem}.app-header{height:70px}.header-note{display:none}.account-menu{gap:.8rem}.account-menu h2{font-size:.75rem}.lobby-heading{margin:1rem 0 1.5rem;align-items:start}.lobby-heading h1{font-size:2.6rem}.lobby-heading .button-link{font-size:.75rem;padding:.6rem}.lobby-layout{display:flex;flex-direction:column}.lobby-layout>section{width:100%;padding:1.2rem}.games-list{order:0}.challenge-list{order:1}.create-panel{order:2}.demo-list{order:3}.legacy-list{order:4}.room-layout{grid-template-columns:1fr;gap:1.2rem}.room-sidebar{padding:1rem}.room-heading h2{font-size:1.6rem}.players{display:flex;gap:1rem;justify-content:space-between}.players>div{flex:1}.auth-page{display:block}.auth-intro{padding:2rem 0 .5rem}.auth-intro h1{font-size:3.2rem}.auth-intro br,.intro-board,.intro-caption{display:none}.auth-card{margin:1rem 0;max-width:none}footer{margin-top:2rem}}@media(max-width:420px){.list-card{padding-right:0}.list-card>button{position:static;margin-top:.7rem}.lobby-heading{flex-wrap:wrap}.game-filters{gap:1rem}.account-menu h2{max-width:120px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}}@media(prefers-reduced-motion:reduce){html{scroll-behavior:auto}*{transition:none!important}}.board-input button[data-preview=true]{background:#fff8;outline:2px solid #a74c23;outline-offset:-3px}.board-input button[data-dead=true]:before{content:"";position:absolute;inset:5%;border-radius:50%;opacity:.45}.board-input button[data-dead=true][data-stone=black]:before{background:#111}.board-input button[data-dead=true][data-stone=white]:before{background:#fff;border:1px solid #777}.board-input button[data-dead=true]:after{content:"";position:absolute;inset:15%;background:linear-gradient(45deg,transparent 44%,#b32424 45%,#b32424 54%,transparent 55%),linear-gradient(-45deg,transparent 44%,#b32424 45%,#b32424 54%,transparent 55%)}.count-square{position:absolute;left:37%;top:37%;width:26%;height:26%;z-index:2;border:1px solid;box-sizing:border-box}.count-square[data-owner=black]{background:#151515;border-color:#eee}.count-square[data-owner=white]{background:#fff;border-color:#444}.count-square[data-owner=neutral]{background:#addff2;border-color:#27647c}.score-totals{display:grid;grid-template-columns:1fr 1fr;gap:1rem;margin:.6rem 0}.score-totals>div{display:flex;flex-direction:column}.score-totals span{color:var(--muted);font-size:.75rem}.score-totals strong{font-size:2rem;font-weight:500;font-variant-numeric:tabular-nums}.demo-room .demo-toolbar{margin-top:0;padding:.8rem}.demo-room .demo-toolbar label{flex:1 0 100%}.demo-room .demo-toolbar button{flex:1}.game-room:not(:has(.room-layout))>.board{max-width:650px}.turn{justify-content:space-between;gap:.75rem;flex-wrap:wrap}.turn-badge{font-size:.72rem;border-radius:20px;background:#fffefa;color:#774735;padding:.2rem .6rem}.room-heading .eyebrow,.room-heading h2{margin-bottom:.4rem}.room-heading>p:last-child{margin-bottom:0}@media(min-width:761px)and (min-height:560px){.signed-in{height:100dvh;display:flex;flex-direction:column;padding-bottom:1rem}.signed-in>.app-header{height:64px;flex:0 0 64px}.signed-in>footer{display:none}.signed-in>.app-content{flex:1;min-height:0;display:flex;flex-direction:column}.playground{flex:1;min-height:0;display:flex;flex-direction:column;padding-top:.65rem}.playground>*{flex-shrink:0}.connection{margin-bottom:.35rem}.playground>.text-button,.game-room>.text-button{align-self:start;min-height:32px;padding:.3rem 0}.lobby-heading{margin:.6rem 0 1rem}.lobby-heading h1{font-size:2.4rem;margin-bottom:.3rem}.lobby-heading .eyebrow{margin-bottom:.35rem}.lobby-layout{flex:1;min-height:0;grid-template-rows:minmax(0,1.3fr) repeat(2,minmax(0,1fr));gap:1rem;align-items:stretch}.lobby-layout:has(.legacy-list){grid-template-rows:minmax(0,1.3fr) repeat(3,minmax(0,1fr))}.lobby-layout>section{min-height:0;overflow:auto;overscroll-behavior:contain;padding:1rem}.create-panel{grid-row:1 / -1}.section-heading{margin-bottom:.5rem}.empty-state{padding:.65rem .25rem}.empty-state h3{margin-top:.2rem}.empty-stones{display:none}.create-panel label{margin-bottom:.65rem}.create-panel input,.create-panel select{margin-top:.2rem;padding:.45rem .6rem;min-height:38px}.create-panel .eyebrow{margin-bottom:.4rem}.create-panel .hint{margin-bottom:.5rem}.creation-rules{margin-bottom:.6rem}.game-room{flex:1;min-height:0;margin:.2rem 0 0;display:flex;flex-direction:column}.game-room>*{flex-shrink:0}.room-heading{margin:.35rem 0 .7rem}.room-heading .eyebrow{display:none}.room-heading h2{font-size:1.65rem}.room-layout{flex:1;min-height:0;align-items:stretch;gap:1.5rem}.board-column{min-height:0;container-type:size;display:flex;flex-direction:column;align-items:center}.board-column>.turn{width:100%;min-height:42px;margin-bottom:10px;padding:.5rem .8rem;flex:0 0 42px}.board-column>.board{width:min(100cqw,calc(100cqh - 54px));max-width:none;flex:0 0 auto;margin:0 auto}.room-sidebar{min-height:0;overflow-y:auto;overscroll-behavior:contain;padding:1rem}.players{padding-bottom:.5rem;margin-bottom:.6rem}.players>div{margin:.4rem 0}.room-sidebar details{padding-top:.5rem;margin-top:.6rem}.demo-room>h2{margin-bottom:.2rem}.demo-room>p{margin-bottom:.5rem}.demo-room>p[role=status]{font-size:.7rem}.demo-room .demo-toolbar{margin-bottom:.7rem}.game-room:not(:has(.room-layout)){overflow-y:auto}.auth-page{height:100dvh;min-height:0;grid-template-rows:64px minmax(0,1fr) 44px;align-content:stretch}.auth-page>.app-header{height:64px}.auth-page>footer{margin:0;padding:.6rem 0}.auth-intro{min-height:0;padding:1.5rem 0;align-self:center}.auth-intro h1{font-size:clamp(3rem,5vw,4.8rem);margin:.8rem 0 1rem}.auth-card{margin:1rem 0;padding:1.8rem;max-height:100%;overflow-y:auto}.auth-card form{margin:1rem 0}.intro-board{height:110px;margin:1rem 0}}@media(min-width:761px)and (max-height:720px){.auth-intro .intro-board,.auth-intro .intro-caption{display:none}}@media(min-width:761px)and (min-height:560px){.create-panel .form-grid>label{grid-column:auto}.create-panel .form-grid>label:first-child,.create-panel .form-grid>label:last-child{grid-column:1 / -1}.room-sidebar .scoring-controls{border-top:0;padding-top:.2rem}}@media(min-width:761px)and (min-height:560px){.create-panel label{margin-bottom:.35rem}}@media(max-width:760px){.auth-intro{padding:.8rem 0 0}.auth-intro .eyebrow,.auth-intro>p{display:none}.auth-intro h1{font-size:2rem;margin:.5rem 0}.auth-page .auth-card{padding:1.3rem}.auth-page footer{margin-top:1rem;padding:.8rem 0}.signed-in>footer{display:none}}.room-layout{grid-template-areas:"turn" "board" "controls"}.room-layout>.turn{grid-area:turn}.room-layout>.board-column{grid-area:board}.room-layout>.room-sidebar{grid-area:controls}@media(min-width:761px){.signed-in:has(.room-layout){max-width:none;height:100dvh;display:flex;flex-direction:column;padding:0 .75rem .5rem}.signed-in:has(.room-layout)>.app-content{flex:1;min-height:0;display:flex;flex-direction:column}.signed-in:has(.room-layout)>footer{display:none}.signed-in:has(.room-layout)>.app-header{height:44px;flex:0 0 44px}.signed-in:has(.room-layout) .brand{font-size:1.3rem}.playground:has(.room-layout){flex:1;min-height:0;display:flex;flex-direction:column;padding-top:.4rem}.playground:has(.room-layout)>.connection{position:absolute;top:-30px;left:50%;transform:translate(-50%);white-space:nowrap;margin:0}.game-room:has(.room-layout){flex:1;min-height:0;display:flex;flex-direction:column;margin:0}.room-layout{flex:1;min-height:0;align-items:stretch;grid-template-areas:"board turn" "board controls";grid-template-columns:minmax(0,1fr) 264px;grid-template-rows:auto minmax(0,1fr);gap:.6rem .8rem;width:min(100%,calc(100dvh + 220px));margin:0 auto}.room-layout>.turn{margin:0;padding:.5rem .7rem;font-size:.75rem}.board-column{min-height:0;container-type:size;display:flex;flex-direction:column;align-items:center;justify-content:center}.board-column>.board{width:min(100cqw,100cqh);max-width:none;flex:0 0 auto;margin:0 auto}.room-sidebar{min-height:0;overflow-y:auto;overscroll-behavior:contain;padding:.8rem}.room-sidebar>.text-button{min-height:30px;padding:.15rem 0;margin-bottom:.3rem}.room-sidebar .room-heading{margin:.3rem 0 .7rem}.room-sidebar .room-heading h2{font-size:1.1rem}.room-sidebar .room-heading>p{font-size:.75rem}.room-sidebar>h2{font-size:1.1rem;margin:.3rem 0}.demo-room .room-sidebar>p[role=status]{margin-bottom:.3rem;font-size:.7rem}}@media(max-width:760px){.signed-in:has(.room-layout){padding:0 .5rem}.signed-in:has(.room-layout)>.app-header{height:52px}.playground:has(.room-layout){padding-top:.4rem}.playground:has(.room-layout)>.connection{margin-bottom:.4rem}.room-layout{gap:.6rem}.room-layout>.turn{margin:0;padding:.4rem .7rem}.room-sidebar .room-heading .eyebrow{display:none}.room-sidebar .room-heading h2{font-size:1.2rem}}.hidden-stone{position:absolute;inset:5%;border-radius:50%;opacity:.55;pointer-events:none;box-shadow:0 1px 3px #0004}.hidden-stone[data-color=black]{background:#161b18}.hidden-stone[data-color=white]{background:#fffefa;border:1px solid #777}.hidden-setup-controls{margin:.8rem 0}.hidden-setup-controls>button{width:100%}
