:root{font-family:-apple-system,BlinkMacSystemFont,Segoe UI,sans-serif;color:#f4f1df;background:#153e32;font-synthesis:none;text-rendering:optimizeLegibility;-webkit-font-smoothing:antialiased;--canvas: #f7f5ef;--pine: #183e35;--sage: #bdd5a8;--ink: #f4f1df;--muted: #b1c5b8;--line: #dce0d7;--coral: #c45648;--card: #fffcf5;--serif: Georgia, "Times New Roman", serif}*{box-sizing:border-box}body{margin:0;min-width:320px}body:before{content:"";position:fixed;inset:0;pointer-events:none;z-index:-1;background:radial-gradient(ellipse at 50% 40%,#22573b22,#071e1b80),linear-gradient(#163e3266,#163e3266),url(/art/felt.webp) center / 680px}button,input{font:inherit}button{cursor:pointer;border:0;color:inherit;touch-action:manipulation}button,input,a{-webkit-tap-highlight-color:transparent}button,a,input{outline-offset:5px}:focus-visible{outline:2px solid #c7dda7}button:disabled{cursor:default}a{color:inherit}input{width:100%;height:56px;border:1px solid #eff7dd38;border-radius:13px;background:#05261e50;padding:0 16px;color:var(--ink);font-size:16px;box-shadow:inset 0 1px 3px #001b1a25}input:focus{border-color:#ccddbe}input::placeholder{color:#9fb7a7}.app-shell{max-width:1100px;min-height:100svh;min-height:100dvh;margin:auto;padding:max(10px,env(safe-area-inset-top)) 32px max(24px,env(safe-area-inset-bottom));display:flex;flex-direction:column}.app-header{height:76px;display:flex;align-items:center;justify-content:space-between;position:relative;z-index:20;flex-shrink:0}.brand-button{background:none;padding:0;min-height:44px;text-align:left}.brand{display:inline-flex;gap:11px;align-items:center;font-family:var(--serif);font-size:27px;letter-spacing:-.7px;font-weight:500}.brand-mark{display:grid;grid-template-columns:repeat(2,8px);gap:3px}.brand-mark i{width:8px;height:8px;background:#efedda;border-radius:2px}.brand-mark i:nth-child(2n){background:#9abb96}.header-actions{display:flex;align-items:center;position:relative}.icon-button{width:44px;height:44px;padding:0;display:inline-flex;align-items:center;justify-content:center;border-radius:50%;background:transparent;flex-shrink:0}.icon-button:hover{background:#ffffff12}.menu-button{background:#09291f50;box-shadow:inset 0 0 0 1px #efffde20,0 2px 5px #09201b15}.text-button{min-height:44px;background:none;display:inline-flex;align-items:center;justify-content:center;gap:9px;padding:4px 0;font-size:14px;color:#d3dfcb;text-underline-offset:4px}.text-button:hover{color:#fff;text-decoration:underline}.menu-dismiss{position:fixed;inset:0;background:transparent;z-index:21;cursor:default}.menu{z-index:22;position:absolute;top:52px;right:0;width:232px;background:#163b30;border:1px solid #e8f3d92b;border-radius:17px;padding:8px;box-shadow:0 15px 40px #061c1b70}.menu button{background:transparent;display:flex;gap:10px;align-items:center;width:100%;text-align:left;padding:14px 12px;border-radius:10px;font-size:14px}.menu button:hover{background:#ffffff0d}.menu-name{color:var(--muted);font-size:12px;padding:12px;border-bottom:1px solid #e2eddb26;margin-bottom:4px;overflow-wrap:anywhere}.primary-button,.secondary-button{width:100%;min-height:56px;padding:14px 20px;border-radius:14px;display:flex;align-items:center;justify-content:center;gap:12px;background:#f2f0de;color:#183e35;font-size:16px;font-weight:550;box-shadow:inset 0 1px #ffffffb3,0 3px 8px #09251d20;transition:background .15s,transform .15s}.primary-button span,.secondary-button span{flex:1;text-align:center}.primary-button:hover:not(:disabled){background:#fffdee}.primary-button:active:not(:disabled),.secondary-button:active:not(:disabled){transform:scale(.987)}.primary-button:disabled{background:#e6ecda20;color:#d5dfc9a6;box-shadow:inset 0 0 0 1px #f4f7e11a}.secondary-button{background:#0c302548;color:var(--ink);border:1px solid #d8e9cd3d;box-shadow:none}.secondary-button:hover:not(:disabled){background:#c9e2b519}.secondary-button:disabled{opacity:.5}.nickname-form{display:flex;flex-direction:column;gap:14px}.nickname-form label,.join-form label{font-size:14px;font-weight:500}.form-note{font-size:12px;line-height:1.6;text-align:center;color:#788479;margin:2px 0}.lobby{width:100%;max-width:350px;margin:auto;padding:35px 0 60px}.lobby-cards{margin-bottom:52px}.lobby-cards .card-fan{--card-width: 106px;--card-step: 65px;height:185px}.lobby-cards .card-slot:first-child{--fan-rotation: -13deg !important}.lobby-cards .card-slot:last-child{--fan-rotation: 13deg !important}.lobby h1{margin:0 0 10px;text-align:center;font:29px/1.2 var(--serif);letter-spacing:-.7px}.lobby h1 label{font:inherit}.play-options{display:flex;flex-direction:column;gap:13px}.play-options button span{text-align:left}.join-link{margin-top:6px}.join-form{display:flex;flex-direction:column;gap:9px;margin-top:8px}.join-input-row{display:flex;gap:9px}.join-input-row input{min-width:0;letter-spacing:2px}.join-input-row .primary-button{width:100px}.resume-button{display:flex;align-items:center;gap:12px;padding:16px 20px;color:#e3ebd9;background:#cee5ba16;border:1px solid #d8e9cd30;border-radius:14px;min-height:56px;font-size:16px}.resume-button span{flex:1;text-align:left}.game-layout{width:100%;max-width:560px;margin:0 auto;flex:1;display:flex;flex-direction:column}.scoreboard{display:flex;flex-direction:column;gap:16px;margin:6px 0 16px;flex-shrink:0}.score-row{position:relative;display:flex;justify-content:space-between;align-items:center;padding:0 4px}.player-score{max-width:43%}.opponent-score{text-align:right}.opponent-score .score-name{justify-content:flex-end}.score-name{font-size:13px;color:#d1decd;display:flex;align-items:center;gap:6px;min-height:22px}.player-name{overflow:hidden;white-space:nowrap;text-overflow:ellipsis;max-width:125px}.score-dot{width:6px;height:6px;border-radius:50%;background:#bdd5a8;flex-shrink:0}.score-dot.coral{background:#ee8974}.dealer-marker{border:1px solid #d9e5c850;border-radius:50%;width:16px;height:16px;flex-shrink:0;display:inline-flex;justify-content:center;align-items:center;font-size:9px}.score-numbers strong{font:48px/1 var(--serif);letter-spacing:-1.8px;font-variant-numeric:tabular-nums}.round-number{position:absolute;left:50%;top:50%;transform:translate(-50%,-50%);color:#b5cab7;font-size:11px;white-space:nowrap}.peg-board{padding:0 1px}.peg-board svg{display:block;width:100%;height:auto}.table{position:relative;display:flex;flex-direction:column;flex:1;min-height:380px;padding:10px 0 0}.opponent-zone{display:flex;align-items:flex-start;justify-content:center;min-height:105px;position:relative}.opponent-area{width:56%}.crib,.starter{display:flex;flex-direction:column;align-items:center;gap:9px}.opponent-zone .starter{position:absolute;right:5px;top:13px}.crib{position:absolute;left:5px;top:13px}.crib>span,.starter>span{color:#c1d1bc;font-size:11px}.crib-stack{position:relative;border-radius:6px;box-shadow:2px 3px #bbc3a6,3px 5px #061f1b75}.crib-stack .card-small{--card-width: 44px}.crib-empty{width:44px;height:64px;border:1px solid #daebc62e;box-shadow:inset 0 0 0 3px #123728}.table-middle{display:flex;flex-direction:column;align-items:center;justify-content:center;flex:1;min-height:120px;padding:20px 0 28px}.hand-area{width:100%;padding-top:20px;flex-shrink:0}.table-action{margin-top:10px;min-height:56px;font-size:18px;font-weight:500;flex-shrink:0}.table-action.settling-play{visibility:hidden}.table-action.awaiting-turn{background:#07281e66;border:1px solid #e3ead020;color:#c6d8bc;box-shadow:none;font-size:15px}.table-action.awaiting-turn>span:not(.turn-pulse){flex:initial}.turn-pulse{flex:0 0 5px!important;width:5px;height:5px;background:#bdd5a8;border-radius:50%;animation:breathe .7s infinite alternate}.pegging-area{display:flex;flex-direction:column;align-items:center;width:100%;gap:20px}.running-count{display:flex;align-items:center;justify-content:center;gap:12px;min-width:116px;height:51px;padding:6px 20px;border-radius:40px;background:#05251c60;box-shadow:inset 0 1px #d6e7c00b}.running-count>span{color:#c4d5bb;font-size:12px}.running-count strong{font:34px/.95 var(--serif);animation:score-in .2s ease-out;min-width:33px;text-align:center}.played-cards{display:flex;justify-content:center;min-height:93px;padding:0 8px}.played-cards .card-small{--card-width: 65px}.played-card+.played-card{margin-left:-34px}.played-card{position:relative;align-self:flex-start;animation:opponent-deal-in .26s ease-out;transition:filter .2s ease}.played-card-complete{filter:brightness(.58) saturate(.35)}.played-by-you{animation-name:deal-in}.played-card:after{content:"";position:absolute;left:4px;right:4px;bottom:-2px;height:3px;border-radius:3px;background:#d78a74}.played-by-you:after{background:#b5d59d}.counting-layout{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:30px;flex:1;padding:24px 0 38px}.counting-cards{width:100%;max-width:440px;display:flex;align-items:center;justify-content:center;gap:14px}.counting-cards .hand-area{width:calc(100% - 80px);padding:0}.counting-cards .card-fan{--card-step: 43px}.counting-cards .starter{margin-top:16px}.count-result{width:100%;max-width:310px;padding:0 12px}.count-result h1{display:flex;align-items:baseline;justify-content:space-between;gap:16px;margin:0 0 12px;font:24px/1.2 var(--serif)}.count-result h1 span{overflow-wrap:anywhere}.count-result h1 strong{font-size:38px;font-weight:400;font-variant-numeric:tabular-nums}.score-details{font-size:13px}.score-details>div{display:flex;justify-content:space-between;gap:14px;padding:9px 0;border-top:1px solid #dce7c926}.score-details span{color:#c3d3bf}.score-details strong{font-variant-numeric:tabular-nums;font-weight:500}.game-result,.counting-title{font:30px/1.2 var(--serif);text-align:center;margin:0;overflow-wrap:anywhere}.waiting-code{display:flex;flex-direction:column;align-items:center;gap:12px;margin:auto;padding:30px 0;width:100%}.waiting-cards{width:100%;margin-bottom:30px}.waiting-code h1{font:28px/1.2 var(--serif);margin:0 0 16px}.waiting-code>span{color:#b8d0b8;font-size:12px}.waiting-code strong{letter-spacing:4px;font-size:31px;font-weight:400;font-variant-numeric:tabular-nums}.waiting-code input{max-width:350px;margin-top:16px;font-size:12px;height:44px;text-align:center}.card-fan{--card-width: 91px;--card-step: 55px;--selection-lift: 18px;position:relative;isolation:isolate;width:100%;height:154px}.playing-card{display:block;position:relative;width:var(--card-width, 91px);height:calc(var(--card-width, 91px) * 1.4);padding:0;background:transparent;border-radius:calc(var(--card-width, 91px) * .05);border:0;box-shadow:0 5px 10px #041b1855;flex-shrink:0;transition:filter .15s}.card-slot{position:absolute;left:calc(50% - var(--card-width) / 2);top:8px;width:var(--card-width);z-index:var(--card-index);pointer-events:none;transform:translate3d(calc(var(--fan-x) * var(--card-step)),var(--fan-y),0)}.card-lift{transform:translateZ(0);transition:transform .18s cubic-bezier(.2,.8,.2,1);will-change:transform}.card-lift[data-selected=true]{transform:translate3d(0,calc(-1 * var(--selection-lift)),0)}.card-slot .playing-card{pointer-events:auto;transform:rotate(var(--fan-rotation));transform-origin:50% 120%}.card-slot .playing-card.selected{box-shadow:0 0 0 3px #bdd5a8,0 8px 12px #061b2133}.card-art{display:block;width:100%;height:100%;pointer-events:none;-webkit-user-select:none;user-select:none;-webkit-user-drag:none}.playing-card:disabled{filter:saturate(.85) brightness(.94)}.card-small{--card-width: 54px}.fan-small{--card-width: 54px;--card-step: 33px;height:91px}.error-banner{display:flex;gap:10px;align-items:center;padding:8px 12px;background:#f6e7de;border:1px solid #e8c5b4;border-radius:12px;color:#8c3f29;font-size:13px;margin:0 auto 14px;max-width:650px}.error-banner>span{flex:1}.error-banner svg{flex-shrink:0}.connection-note{background:#eee8cb;color:#6b602c;font-size:12px;padding:12px;margin-bottom:10px;border-radius:10px}.loading-state{display:flex;flex-direction:column;align-items:center;justify-content:center;min-height:65vh}.loading-dot{width:12px;height:12px;border-radius:50%;background:#8ca393;animation:breathe 1s infinite alternate}.sheet{border:0;border-radius:24px;background:var(--canvas);color:var(--pine);max-width:510px;width:calc(100% - 32px);max-height:85dvh;padding:0;box-shadow:0 24px 100px #10271e33}.sheet::backdrop{background:#14271f75;-webkit-backdrop-filter:blur(4px);backdrop-filter:blur(4px)}.sheet-content{padding:25px}.sheet-heading{display:flex;align-items:center;justify-content:space-between;gap:16px;margin-bottom:18px}.sheet-heading h2{font:27px/1.1 var(--serif);margin:0;letter-spacing:-.5px}.help-content p{font-size:14px;line-height:1.7;color:#6d7d6f;margin:7px 0 21px}.help-content h3{margin:22px 0 6px;font-size:15px;font-weight:600}.scoring-guide{font-size:13px;line-height:1.5;padding:12px 0;margin:0}.scoring-guide>div{display:flex;justify-content:space-between;gap:20px;padding:9px 0;border-bottom:1px solid var(--line)}.scoring-guide dd{margin:0;white-space:nowrap;font-weight:600}.help-content .muted{font-size:12px}.source-link{font-size:12px;text-underline-offset:4px;line-height:1.5}.history-list{list-style:none;padding:0;margin:0}.history-list li{display:flex;gap:15px;justify-content:space-between;font-size:13px;line-height:1.5;padding:12px 0;border-bottom:1px solid var(--line)}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}.sheet{--muted: #6f8077}.sheet .primary-button{background:var(--pine);color:var(--canvas)}.sheet .primary-button:disabled{opacity:.5}.sheet .icon-button:hover{background:#173e3510}.sheet input{color:var(--pine);background:#fffdf8;border-color:#ccd4c8}@keyframes breathe{0%{opacity:.4;transform:scale(.8)}to{opacity:1;transform:scale(1.1)}}@keyframes deal-in{0%{opacity:.3;transform:translateY(30px) rotate(-4deg)}to{opacity:1;transform:none}}@keyframes opponent-deal-in{0%{opacity:.3;transform:translateY(-30px) rotate(4deg)}to{opacity:1;transform:none}}@keyframes score-in{0%{transform:scale(.9);opacity:.5}to{transform:scale(1);opacity:1}}@media(min-width:800px){.game-layout{max-width:580px}.table{min-height:410px}.opponent-zone{min-height:115px}.scoreboard{margin-top:4px}.lobby{max-width:360px}}@media(max-width:650px){.app-shell{padding:max(2px,env(safe-area-inset-top)) 22px max(16px,env(safe-area-inset-bottom))}.app-header{height:64px}.brand{font-size:23px;gap:10px}.brand-mark{display:none}.menu-button{width:40px;height:40px}.lobby{padding:28px 3px 35px}.lobby-cards{margin-bottom:40px}.scoreboard{gap:13px;margin:7px 0 16px}.score-name{font-size:12px;min-height:20px}.score-numbers strong{font-size:43px}.player-name{max-width:100px}.peg-board svg{height:auto}.table{min-height:385px;padding-top:7px}.opponent-zone{min-height:90px}.opponent-zone .starter,.crib{top:12px}.opponent-zone .starter{right:0}.crib{left:0}.opponent-area{width:54%}.table-middle{min-height:125px;padding:18px 0 24px}.pegging-area{gap:16px}.table-action{margin-top:6px;font-size:17px}.card-fan{--card-width: 80px;--card-step: 47px;--selection-lift: 16px;height:148px}.fan-small{--card-width: 48px;--card-step: 25px;height:80px}.card-small{--card-width: 43px}.played-cards .card-small{--card-width: 68px}.played-cards{min-height:100px}.played-card+.played-card{margin-left:-34px}.counting-cards{gap:8px}.counting-cards .hand-area{width:calc(100% - 58px)}.counting-cards .card-fan{--card-step: 40px}.counting-layout{padding:20px 0 30px;gap:22px}.count-result{max-width:285px}.count-result h1{font-size:23px}.error-banner{font-size:12px;padding:6px 10px}.sheet{border-radius:22px}.sheet-content{padding:23px 20px}.sheet-heading h2{font-size:25px}}@media(max-width:375px){.app-shell{padding-inline:16px}.brand{font-size:22px}.card-fan{--card-width: 72px;--card-step: 42px;height:136px}.fan-small{--card-width: 40px;--card-step: 21px;height:75px}.counting-cards .card-fan{--card-step: 35px}}@media(max-height:740px)and (max-width:650px){.app-header{height:56px}.scoreboard{margin-bottom:9px;gap:9px}.score-numbers strong{font-size:38px}.table{min-height:345px}.table-middle{padding-block:12px 15px;min-height:112px}.running-count{height:44px}.running-count strong{font-size:30px}.hand-area{padding-top:14px}.counting-layout{padding-block:16px;gap:16px}.lobby-cards{margin-bottom:28px}}@media(max-width:350px){.card-fan{--card-width: 66px;--card-step: 37px;height:118px}.fan-small{--card-width: 38px;--card-step: 20px;height:72px}.counting-cards .card-fan{--card-step: 33px}.lobby h1{font-size:26px}.played-cards .card-small{--card-width: 61px}.played-cards{min-height:86px}.pegging-area{gap:12px}}@media(prefers-reduced-motion:reduce){*,*:before,*:after{animation:none!important;transition:none!important;scroll-behavior:auto!important}}
