@font-face{font-family:Geist;src:url('../fonts/geist-sans.woff2') format('woff2');font-weight:100 900;font-display:swap}
@font-face{font-family:'Geist Mono';src:url('../fonts/geist-mono.woff2') format('woff2');font-weight:100 900;font-display:swap}
body.pool-page{--sans:Geist,'PingFang SC',sans-serif;--mono:'Geist Mono',monospace;--pool-panel:#242424;--pool-key:#2c2c2c;--pool-soft:#929b94;font-family:var(--sans);background:var(--paper)}
.pool-page .shell{width:100%;max-width:none;margin:0;padding:0 24px}.pool-page main{padding:8px 0 28px}.pool-layout{width:100%;max-width:1120px;margin:0 auto}.pool-page .game-intro{display:flex;align-items:center;justify-content:space-between;margin:16px 0}.pool-page .game-intro h1{font-size:28px;margin:0}.pool-page.game-framed .game-intro{display:none}
.pool-top{display:flex;justify-content:space-between;align-items:center;gap:12px;padding:0 0 22px}.pool-modes{display:flex;gap:4px;padding:4px;border-radius:11px;background:#222}.pool-modes button{background:transparent;color:var(--mute);border:0;border-radius:8px;min-height:36px;padding:8px 14px;font-size:14px;transition:background 180ms,color 180ms,transform 70ms}.pool-modes button[aria-pressed=true]{color:#e8ebe3;background:#3a3d38;box-shadow:0 2px 3px #0003}.pool-modes button:active{transform:translateY(1px)}
.pool-quiet{background:none;border:0;border-radius:7px;color:var(--mute);font-size:14px;padding:8px 10px;min-height:38px}.pool-quiet:hover{color:var(--ink);background:#292929}.pool-quiet:disabled{opacity:.4}
.pool-players{display:grid;grid-template-columns:1fr 1fr;gap:16px;padding:0 4px;margin-bottom:2px}.pool-player{padding:0 0 12px;border-bottom:2px solid #343734;min-width:0}.pool-player[data-active=true]{border-bottom-color:#b7c4a5}.pool-person{display:flex;gap:10px;align-items:center;min-height:24px;color:var(--mute);font-size:14px}.pool-person b{font-weight:500;color:var(--ink)}.pool-person>span:last-child{margin-left:auto;font-size:12px;white-space:nowrap}.pool-player-mark{font:11px var(--mono);color:#8b948c}.pool-player[data-active=true] .pool-player-mark{color:#c0cfad}.pool-targets{display:flex;gap:7px;min-height:20px;margin:10px 0 0 25px}.pool-ball{width:17px;height:17px;border-radius:50%;display:grid;place-items:center;font:600 8px var(--sans);color:#26322c;background:var(--ball-color);box-shadow:inset -1px -2px #0002;position:relative;overflow:hidden}.pool-ball[data-stripe=true]::before,.pool-ball[data-stripe=true]::after{content:'';height:4px;position:absolute;left:0;right:0;background:#e4e5d8}.pool-ball[data-stripe=true]::before{top:0}.pool-ball[data-stripe=true]::after{bottom:0}.pool-ball[data-potted=true]{opacity:.17}.pool-ball>span{position:relative;z-index:1;background:#edeade;border-radius:50%;width:10px;height:10px;display:grid;place-items:center}.pool-open-dots{display:flex;gap:6px}.pool-open-dots i{width:7px;height:7px;background:#485047;border-radius:50%;margin:5px 0}
.pool-stage{position:relative;aspect-ratio:1160/660;width:100%;background:#181818;border-radius:16px;overflow:hidden;touch-action:none;outline:none;cursor:crosshair}.pool-stage:focus-visible{outline:2px solid var(--accent);outline-offset:3px}#pool-canvas{display:block;width:100%;height:100%;image-rendering:auto}.pool-stage[data-locked=true]{cursor:default}
.pool-status-line{display:flex;gap:9px;align-items:center;min-height:42px;padding:0 4px;color:#d5dacf;font-size:14px}.pool-turn-dot{width:6px;height:6px;border-radius:50%;background:#b3c09e;flex:none}#game-status{line-height:1.45}#shot-count{margin-left:auto;font:11px var(--mono);color:#929b94;white-space:nowrap}
.pool-controls{display:flex;align-items:center;gap:18px;padding:14px 16px;background:#242724;border-radius:12px;margin-top:8px;font-size:14px;color:#b6bdb2}.pool-controls label{flex:none}#power{min-width:60px;flex:1;height:28px;margin:0;accent-color:#bac6a5;cursor:pointer}#power-value{width:43px;text-align:right;color:#dee4d5;font:13px var(--mono)}
.pool-primary,.pool-secondary{display:inline-flex;align-items:center;justify-content:center;gap:22px;min-height:42px;padding:10px 22px;border:0;border-radius:8px;font-size:14px;font-weight:500;transition:transform 70ms,background 180ms;white-space:nowrap}.pool-primary{background:#d9e0cd;color:#283128;box-shadow:0 3px 0 #8a9782}.pool-primary:hover{background:#e9eedf}.pool-primary:active:enabled{transform:translateY(2px);box-shadow:0 1px 0 #8a9782}.pool-primary:disabled{background:#3d453b;color:#909b89;box-shadow:none;cursor:default}.pool-secondary{background:#323631;color:#d8ddd2}.pool-secondary:hover{background:#3e443a}#shoot{min-width:120px;justify-content:space-between}
.pool-under{display:flex;justify-content:space-between;gap:12px;align-items:flex-start;margin:17px 4px 0;font-size:14px;line-height:1.5;color:var(--mute)}.pool-guide{display:flex;gap:8px;align-items:center;flex:none;cursor:pointer}.pool-guide input{margin:3px 0 0;accent-color:#b9c7aa;width:15px;height:15px}.pool-guide input:focus-visible{outline:2px solid var(--ink);outline-offset:4px}
.pool-result{position:absolute;inset:50% auto auto 50%;translate:-50% -50%;width:min(360px,90%);background:#252e29;border-radius:15px;padding:26px;text-align:center;box-shadow:0 4px 8px #0004;animation:pool-enter 240ms cubic-bezier(.2,.8,.2,1) both}.pool-result>span{color:#a7b49f;font:12px var(--mono)}.pool-result h2{font-size:32px;font-weight:450;letter-spacing:-.035em;margin:16px 0}.pool-result p{font-size:14px;line-height:1.6;color:#b8c1b1}.pool-result button{margin-top:10px}
.pool-network{display:flex;align-items:center;gap:8px;flex-wrap:wrap;margin-top:20px;border-radius:12px;padding:12px 14px;background:#252825;font-size:14px}.pool-network-status{margin-right:auto;color:#b9c9aa}.pool-network details{width:100%;color:var(--mute)}.pool-network summary{cursor:pointer;font-size:14px;min-height:32px;padding-top:6px}.pool-network input{margin-top:8px;width:100%;background:#1b201c;color:#c6cebe;border:0;border-radius:7px;padding:12px;font:12px var(--mono)}
.pool-dialog{width:min(420px,calc(100vw - 32px));padding:26px;border:1px solid #ffffff10;border-radius:17px;background:#252825;color:#e4e8df;box-shadow:0 6px 18px #0006;font:14px/1.6 var(--sans);animation:pool-enter 240ms cubic-bezier(.2,.8,.2,1) both}.pool-dialog::backdrop{background:#101510aa}.pool-dialog h2{font-size:24px;font-weight:450;letter-spacing:-.03em;margin:0}.pool-dialog p{color:#b2bca9;margin:12px 0 22px}.pool-dialog-head{display:flex;justify-content:space-between;gap:12px;align-items:center}.pool-icon{display:grid;place-items:center;min-width:36px;height:36px;border:0;border-radius:8px;background:#323932;color:#d1dac9}.pool-icon svg{width:18px;height:18px}.pool-full{width:100%}.pool-divider{display:flex;align-items:center;gap:12px;margin:24px 0 16px;color:#9aa58f;font-size:14px}.pool-divider::before,.pool-divider::after{content:'';height:1px;flex:1;background:#ffffff12}#join-form{display:grid;grid-template-columns:1fr auto;gap:10px}#join-form label{grid-column:1/-1;color:#b6c0ac}#room-code{min-width:0;width:100%;border:1px solid #455041;border-radius:8px;background:#1b211c;color:#e0e5d8;padding:12px;font:14px var(--sans)}#room-code:focus{outline:2px solid #b8c8a8;outline-offset:2px}#room-error{color:#e0b2a2;margin-bottom:0}.pool-dialog-actions{display:flex;gap:10px;justify-content:flex-end;margin-top:24px}
@keyframes pool-enter{from{opacity:0;transform:translateY(5px)}to{opacity:1;transform:none}}
@media(min-width:761px){.pool-page .pool-layout{padding-top:4px}}
@media(max-width:760px){.pool-page .shell{padding:0 12px}.pool-page.game-framed>.shell{height:auto!important;min-height:100dvh;overflow:visible!important}.pool-page main{padding-top:12px}.pool-top{gap:5px;padding-bottom:20px}.pool-modes{gap:2px;padding:3px}.pool-modes button{padding:8px 10px;font-size:12px;min-height:34px}.pool-top>.pool-quiet{padding:8px 4px;font-size:12px}.pool-players{gap:16px;padding:0 3px}.pool-person{gap:7px;flex-wrap:wrap;font-size:13px}.pool-person>span:last-child{margin-left:0;font-size:12px}.pool-player-mark{display:none}.pool-targets{margin:9px 0 0;gap:5px}.pool-ball{width:15px;height:15px}.pool-stage{border-radius:9px;overflow:hidden;aspect-ratio:auto;height:min(calc(100svh - 330px),650px);min-height:350px}.pool-status-line{font-size:13px;min-height:54px;align-items:center}.pool-controls{position:sticky;bottom:12px;z-index:8;padding:12px;gap:10px;margin-top:5px}.pool-controls label{font-size:12px}#shoot{min-width:82px;padding:10px 13px;gap:10px}.pool-under{font-size:13px;gap:16px;flex-direction:column;margin-top:18px}.pool-result{padding:18px}.pool-result h2{font-size:24px;margin:8px 0}.pool-result p{margin:8px 0}.pool-result button{min-height:38px}.pool-network{padding:12px;gap:4px;font-size:13px}.pool-network-status{width:100%;margin-bottom:4px}.pool-network .pool-quiet{font-size:13px}#shot-count{font-size:10px}.pool-dialog{padding:22px}}
@media(prefers-reduced-motion:reduce){.pool-page *{animation:none!important;transition:none!important}}
@media(forced-colors:active){.pool-stage,.pool-player,.pool-controls,.pool-dialog{border:1px solid CanvasText}}

@media(max-width:760px) and (orientation:landscape){.pool-stage{height:auto;min-height:0;aspect-ratio:1160/660}.pool-player{padding-bottom:4px}.pool-top{padding-bottom:12px}}
.pool-players[data-practice=true]{grid-template-columns:1fr}

/* Pool motion uses the product's press / feedback / entrance cadence. */
.pool-page{--pool-press:70ms;--pool-feedback:180ms;--pool-enter:240ms;--pool-ease:cubic-bezier(.2,.8,.2,1)}
.pool-players{position:relative;--pool-player-gap:16px;gap:var(--pool-player-gap)}
.pool-player[data-active=true]{border-bottom-color:#343734}
.pool-players::after{content:'';position:absolute;left:4px;bottom:0;width:calc((100% - var(--pool-player-gap) - 8px)/2);height:2px;background:#b7c4a5;transform:translateX(0);transition:transform var(--pool-feedback) var(--pool-ease),opacity var(--pool-feedback)}
.pool-players[data-turn='1']::after{transform:translateX(calc(100% + var(--pool-player-gap)))}
.pool-players[data-practice=true]::after{width:calc(100% - 8px)}
.pool-players[data-finished=true]::after{opacity:0}
.pool-player{border-radius:8px 8px 0 0;transition:background-color var(--pool-feedback)}
.pool-player[data-joined=true]{background:#354333;animation:pool-joined var(--pool-enter) var(--pool-ease)}
@keyframes pool-joined{from{transform:translateY(3px);background:#45583e}to{transform:none;background:#354333}}
.pool-players[data-online=true] .pool-player[data-friend=true] b::after{content:'';display:inline-block;width:8px;height:8px;margin-left:8px;border-radius:50%;background:#7f837c;vertical-align:middle}
.pool-players[data-online=true][data-connected=true] .pool-player[data-friend=true] b::after{background:#b7d69c}
.pool-ball{transition:opacity var(--pool-feedback),transform var(--pool-feedback) var(--pool-ease)}
.pool-ball[data-potted=true]{transform:scale(.85)}
.pool-expand{flex:none;font-size:14px;white-space:nowrap;min-height:44px}
.pool-status-line{gap:8px}.pool-status-line #game-status{flex:1}.pool-status-line #shot-count{margin-left:0;font-size:12px}
.pool-network{display:block;padding:0 14px}
.pool-network>summary{display:flex;gap:16px;align-items:center;min-height:48px;cursor:pointer;list-style:none}
.pool-network>summary::-webkit-details-marker{display:none}
.pool-network>summary::after{content:'⌄';margin-left:2px;color:var(--mute);transition:transform var(--pool-feedback)}
.pool-network[open]>summary::after{transform:rotate(180deg)}
.pool-network>summary>span:last-of-type{font-size:14px;color:var(--mute)}
.pool-network-actions{display:flex;gap:8px;flex-wrap:wrap;padding-bottom:12px}
.pool-network-actions details{flex-basis:100%}
.pool-network-status{color:#b9c9aa}
.pool-table-dialog{padding:0;border:0;background:var(--paper);color:var(--ink)}
.pool-table-dialog[open]{position:fixed;inset:0;width:100vw;height:100dvh;max-width:none;max-height:none;margin:0;display:flex;padding:max(8px,env(safe-area-inset-top)) max(8px,env(safe-area-inset-right)) max(8px,env(safe-area-inset-bottom)) max(8px,env(safe-area-inset-left));overflow:hidden}
.pool-table-dialog::backdrop{background:#181818}
body[data-pool-expanded=true]{overflow:hidden}
.pool-table-dialog .pool-layout{display:grid;grid-template-rows:auto minmax(0,1fr) auto auto auto;gap:6px;max-width:1600px;height:100%;padding:0}
.pool-table-dialog .game-intro,.pool-table-dialog .pool-top,.pool-table-dialog .pool-network{display:none}
.pool-table-dialog .pool-stage{height:100%;min-height:0;aspect-ratio:auto}
.pool-table-dialog .pool-players{margin:0}.pool-table-dialog .pool-player{padding-bottom:8px}
.pool-table-dialog .pool-controls{position:static;margin:0;padding:8px 12px}
.pool-table-dialog .pool-under{margin:0;align-items:flex-end;min-height:24px;font-size:14px}
.pool-table-dialog #input-hint{display:none}
.pool-table-dialog .pool-status-line{min-height:44px}
.pool-page button:focus-visible{outline:2px solid var(--accent);outline-offset:3px}
@media(max-width:760px){
 .pool-top{padding-bottom:12px}.pool-players{--pool-player-gap:12px}.pool-person{font-size:14px;gap:5px}.pool-person>span:last-child{font-size:12px}
 .pool-targets{margin-top:6px;gap:5px;min-height:16px}.pool-player{padding-bottom:8px}
 .pool-stage{height:min(calc(100svh - 245px),760px);min-height:390px}
 .pool-status-line{font-size:14px;min-height:48px}.pool-expand{padding-inline:6px;font-size:14px}
 .pool-controls{padding:10px;gap:9px;bottom:max(8px,env(safe-area-inset-bottom))}.pool-controls label{font-size:14px}
 .pool-under{font-size:14px;flex-direction:row;flex-wrap:wrap;gap:8px;margin-top:12px}.pool-under #input-hint{flex-basis:100%}
 .pool-network{margin-top:12px;padding-inline:12px}.pool-network-status{width:auto;margin-bottom:0}
 .pool-table-dialog .pool-person>span:last-child{display:none}.pool-table-dialog .pool-targets{margin-top:5px}
 .pool-table-dialog .pool-stage{min-height:0}.pool-table-dialog .pool-under{flex-direction:row}
}
@media(max-width:760px) and (orientation:landscape){.pool-page:not([data-pool-expanded=true]) .pool-stage{height:auto;min-height:0;aspect-ratio:1160/660}}
@media(prefers-reduced-motion:reduce){.pool-players::after,.pool-network>summary::after{transition:none}.pool-player[data-joined=true]{animation:none}}
@media(forced-colors:active){.pool-players::after,.pool-players[data-online=true] .pool-player[data-friend=true] b::after{background:CanvasText}.pool-player[data-joined=true]{outline:2px solid Highlight}}
.pool-status-line[data-event=joined]{background:#354333;border-radius:10px;color:#edf3e7;transition:background-color var(--pool-feedback)}
.pool-status-line[data-event=joined] .pool-turn-dot{background:#cae8ad;width:8px;height:8px}
@media(forced-colors:active){.pool-status-line[data-event=joined]{outline:2px solid Highlight}}
