:root{font-family:-apple-system,BlinkMacSystemFont,"PingFang SC","Microsoft YaHei",sans-serif;color:#233b35;background:#f3f2eb;font-size:14px;--green:#164d40;--gold:#dabb78;--red:#b7493e}*{box-sizing:border-box}body{margin:0}button,input{font:inherit}button{cursor:pointer;border:0;border-radius:8px;padding:10px 17px;font-weight:600;transition:background .15s,transform .15s}button:disabled{opacity:.38;cursor:default}button:not(:disabled):active{transform:translateY(1px)}button:focus-visible,summary:focus-visible,a:focus-visible{outline:3px solid #d2a34d;outline-offset:3px}header{height:88px;max-width:1320px;margin:auto;display:flex;align-items:center;justify-content:space-between;padding:0 32px;gap:20px}.brand{display:flex;align-items:center;gap:13px;text-decoration:none;color:#173f34;font-size:24px;font-weight:750;letter-spacing:3px}.brand small{display:block;font-size:10px;font-weight:500;letter-spacing:2px;margin-top:4px;color:#76857a}.brand-mark{border:1px solid #b5c3b5;border-radius:7px;transform:rotate(-8deg);height:48px;width:35px;font-family:Georgia;display:flex;flex-direction:column;align-items:center;font-size:27px;line-height:27px;letter-spacing:0;background:#fffefa}.brand-mark span{font-size:16px;line-height:15px}.scores{display:flex;gap:30px}.score{font-size:12px;color:#788578}.score b{font:600 25px Georgia;color:#244a3c;margin-left:8px}.score.active{color:#2e624d}nav{display:flex;gap:10px;align-items:center}#save-status{font-size:11px;color:#78917f}#save-status::before{content:'●';color:#66a17e;font-size:8px;margin-right:6px}.quiet{background:transparent;font-size:12px;color:#5d7064;padding:8px}main{max-width:1256px;margin:auto;padding:0 18px}.table{position:relative;min-height:400px;height:46vh;max-height:530px;border-radius:110px;background:radial-gradient(ellipse at 50% 35%,#236655,#164d40 65%,#103e34);box-shadow:inset 0 0 0 9px #d6c6a3,inset 0 0 0 12px #8c7957,0 12px 25px #18362c19;overflow:hidden;color:#f5f0db}.table-line{position:absolute;inset:25px;border:1px solid #ffffff14;border-radius:90px}.table-watermark{position:absolute;left:50%;top:49%;transform:translate(-50%,-50%);font-size:46px;letter-spacing:12px;color:#ffffff06;font-weight:800;white-space:nowrap}.table-watermark span{display:block;font-size:10px;letter-spacing:5px;text-align:center;margin-top:8px}.seat{position:absolute;z-index:2;display:flex;align-items:center;gap:10px;min-width:130px}.north{top:34px;left:50%;transform:translateX(-50%)}.west{left:40px;top:47%;transform:translateY(-50%);flex-direction:column;align-items:flex-start}.east{right:40px;top:47%;transform:translateY(-50%);flex-direction:column;align-items:flex-end}.south{bottom:31px;left:50%;transform:translateX(-50%)}.avatar{height:43px;width:43px;border-radius:50%;background:#c1cdb94a;border:1px solid #e4e7c73b;display:grid;place-items:center;font-size:20px;color:#eee8d0}.seat.current .avatar{box-shadow:0 0 0 3px var(--gold);background:#bfa66c;color:#233d32}.seat-name{font-size:12px;font-weight:600}.seat-info{font-size:10px;color:#b7cec1;margin-top:5px;max-width:140px}.badge{display:inline-block;background:#ffffff12;border:1px solid #ffffff16;padding:2px 5px;border-radius:4px;font-size:10px;margin-top:6px;color:#d2e3ce}.badge.open{color:#ebcf89;background:#c9a34a18}.seat .last{font-size:11px;color:#dfcf9a;margin-top:5px}.card-back{height:22px;width:30px;display:inline-block;border:1px solid #d7ddc373;background:repeating-linear-gradient(45deg,#2e6b5a,#2e6b5a 2px,#235846 2px,#235846 5px);border-radius:3px;vertical-align:middle;margin-right:4px}.center{position:absolute;left:50%;top:45%;transform:translate(-50%,-50%);width:56%;text-align:center}.round-label{font-size:10px;letter-spacing:2px;color:#b5d1c0;margin-bottom:15px}#trick{min-height:94px;display:flex;justify-content:center;align-items:center;flex-wrap:wrap;gap:3px}.empty-trick{font-size:12px;color:#7ea592}.turn-label{margin-top:14px;font-size:12px;color:#ecddb4;min-height:18px}.table-note{position:absolute;bottom:17px;right:72px;font-size:9px;color:#98b09b;letter-spacing:1px}.card{background:#fffdf6;color:#263e35;border:1px solid #cbd0bf;border-radius:6px;position:relative;display:inline-flex;flex-direction:column;justify-content:space-between;align-items:flex-start;width:66px;height:92px;padding:7px;font:700 23px Georgia;box-shadow:0 3px 5px #0002;flex-shrink:0;user-select:none}.card .suit{font-size:24px;align-self:flex-end}.card.red{color:#b8403c}.card .wild-label{position:absolute;font:9px sans-serif;bottom:7px;left:6px;background:#e7cc83;padding:2px;border-radius:2px;color:#4c452e}.card .lock-icon{font:9px sans-serif;position:absolute;bottom:6px;left:5px;color:#8b8171}.card.joker{font:700 13px sans-serif;writing-mode:vertical-rl;letter-spacing:3px}.card.mini{width:43px;height:62px;font-size:18px;padding:4px}.card.mini .suit{font-size:17px}.hand-area{padding:23px 24px 4px}.hand-top{display:flex;align-items:center;justify-content:space-between;gap:12px;color:#7e8779;font-size:11px}.eyebrow{font-size:10px;letter-spacing:2px;color:#858c78}.hand-top #hand-count{margin-left:9px}#lock-status{color:#987b39}.auto-label{display:flex;gap:5px;align-items:center;cursor:pointer}.auto-label input{accent-color:#205e49}.hand{display:flex;align-items:flex-end;min-height:132px;padding:24px 5px 8px;overflow-x:auto;overflow-y:hidden;justify-content:center}.hand .card{margin-left:-26px;cursor:pointer;transition:transform .16s,background .16s;text-align:left;padding:6px}.hand .card:first-child{margin-left:0}.hand .card .suit{align-self:flex-start;font-size:19px}.hand .card.selected{transform:translateY(-18px);background:#ffedb3;border:2px solid #b89844;z-index:3}.hand .card.locked{background:#e5e3d9;color:#90988d}.hand .card:hover{transform:translateY(-9px)}.hand .card.selected:hover{transform:translateY(-18px)}.controls{display:flex;justify-content:space-between;align-items:center;gap:10px;margin-top:14px}#selection-label{font-size:11px;color:#798878}.action-buttons{display:flex;gap:8px;align-items:center}.primary{background:#205742;color:white;min-width:92px}.primary:hover{background:#123d2d}.secondary{background:#e4e7dc;color:#50634f}.bao-button{background:#ecdfbb;color:#7b5e27}.bao-button:hover{background:#dfcb92}#notice{min-height:28px;font-size:11px;color:#ac643b;padding-top:10px}.history{margin:6px 24px;border-top:1px solid #dce1d4;padding-top:12px;color:#657760;font-size:12px}.history summary{cursor:pointer;list-style:none}.history summary::before{content:'＋';margin-right:8px}.history[open] summary::before{content:'−'}.history summary span{float:right;font-size:10px;color:#9ca393}.history ol{max-height:180px;overflow:auto;padding-left:26px;font-size:11px;line-height:1.9}.history li{border-bottom:1px solid #e6e9df}footer{text-align:center;color:#a2aa9a;font-size:10px;padding:20px 0 22px}dialog{border:1px solid #d6ddcc;border-radius:16px;background:#faf9f1;color:#314739;max-width:600px;width:calc(100% - 32px);padding:28px;max-height:86vh;overflow:auto;box-shadow:0 24px 80px #0004}dialog::backdrop{background:#0b2928a6;backdrop-filter:blur(3px)}.dialog-head{display:flex;justify-content:space-between;align-items:center;border-bottom:1px solid #dde2d2;padding-bottom:14px;margin-bottom:18px}h2{font-size:24px;margin:7px 0 0;font-weight:600}h3{font-size:14px;margin:21px 0 7px}.close{font-size:25px;padding:3px 10px;background:transparent;color:#76836c}dialog p{font-size:12px;line-height:1.9;color:#67735f}.muted{color:#909886!important}.result-teams{display:grid;grid-template-columns:1fr 1fr;gap:12px}.result-team{border:1px solid #dbe0cf;border-radius:9px;padding:17px}.result-team strong{display:block;font:34px Georgia;color:#26523e;margin:12px 0}.result-team p{margin:3px 0;font-size:11px}.result-list{padding:0;list-style:none;margin:20px 0;font-size:12px;line-height:2.2}.result-list li{border-bottom:1px solid #e0e5d9}.wide{width:100%;margin-top:12px}.seat.current .seat-name::after{content:' · 出牌中';color:#ebcf89;font-size:10px}.status-bar{font-size:11px;line-height:1.8;color:#8b805d;background:#f0ebd9;border-radius:6px;padding:9px;margin-top:15px}
@media(min-width:1300px){.hand .card{margin-left:-23px}}
@media(max-width:800px){header{height:72px;padding:0 18px;gap:10px}.brand{font-size:20px;gap:8px}.brand small{font-size:8px;letter-spacing:1px}.scores{gap:12px}.score b{font-size:20px}.score{font-size:10px}nav{gap:3px}#save-status{display:none}.quiet{font-size:10px;padding:5px}.table{height:340px;min-height:340px;border-radius:55px}.table-line{inset:20px;border-radius:40px}.west{left:25px}.east{right:25px}.north{top:28px}.south{bottom:25px}.seat{min-width:90px}.seat-name{font-size:11px}.avatar{height:33px;width:33px;font-size:16px}.center{width:48%}.table-note{display:none}.hand-area{padding:18px 0 0}.hand .card{margin-left:-37px;width:58px;height:83px;font-size:21px}.hand{justify-content:flex-start;padding-left:3px}.controls{flex-wrap:wrap;justify-content:center}#selection-label{width:100%;text-align:center}.action-buttons{gap:6px}.action-buttons button{padding:10px 12px;font-size:12px}.history{margin-left:0;margin-right:0}.card.mini{width:35px;height:52px;font-size:15px}.card.mini .suit{font-size:15px}.hand-top{gap:7px;font-size:10px}.seat-info{font-size:9px}.badge{font-size:9px}.round-label{margin-bottom:8px;font-size:9px}.turn-label{font-size:10px}footer{line-height:1.8}main{padding:0 10px}}
@media(max-width:480px){.scores{gap:8px}.score{font-size:9px}.score b{margin-left:4px;font-size:19px}.brand small{display:none}.brand-mark{width:28px;height:39px;font-size:23px;line-height:23px}.brand{letter-spacing:1px;font-size:19px}.table{height:350px}.west,.east{top:48%;min-width:70px}.west{left:20px}.east{right:20px}.seat-name{font-size:10px}.seat-info{max-width:76px}.center{width:45%}.hand{padding-right:20px}.hand .card{margin-left:-31px}.hand-top #hand-count{margin-left:3px}.eyebrow{letter-spacing:1px}.hand-top{flex-wrap:wrap}.hand .card{width:57px}.controls .action-buttons{flex-wrap:wrap;justify-content:center}.north{top:31px}.south{bottom:29px}.table-watermark{font-size:30px}.turn-label{line-height:1.6}.result-team{padding:12px}}
@media(prefers-reduced-motion:reduce){*{transition:none!important}}
@media(max-width:800px){.center{top:51%}#trick{min-height:78px}.north .last,.south .last{display:none}.hand .card{font-size:20px}.hand .card .lock-icon{font-size:8px}.hand .card .wild-label{font-size:8px}.north{top:26px}.south{bottom:27px}}
.pace-toolbar{display:flex;align-items:center;gap:9px;margin-bottom:16px;font-size:11px;color:#73816c;flex-wrap:wrap}.pace-toolbar select{font:inherit;color:#36523d;border:1px solid #cbd5c2;background:#fafaf3;border-radius:6px;padding:7px 8px}.pace-toolbar button{padding:7px 13px;font-size:11px}.pace-toolbar #pace-status{margin-left:auto;color:#8a957f;font-size:10px}.last-play{max-width:160px;min-height:0}.last-play:empty{display:none}.bubble-label{font-size:9px;color:#c3d4ba;margin-bottom:4px}.bubble-cards{display:flex;gap:2px;flex-wrap:wrap;max-width:158px;align-items:center}.bubble-cards .card.mini{width:24px;height:35px;padding:2px;font-size:13px;border-radius:3px;box-shadow:0 1px 2px #0002}.bubble-cards .card.mini .suit{font-size:11px}.bubble-cards .card.joker{font-size:8px;letter-spacing:1px}.bubble-cards.active-play{filter:drop-shadow(0 0 3px #e3c26470)}.pass-label{color:#f1d47b;font-size:16px;font-weight:700;letter-spacing:2px}.north .last-play,.south .last-play{margin-left:5px}.west .last-play,.east .last-play{margin-top:2px}.east .bubble-cards{justify-content:flex-end}.east .bubble-label{text-align:right}.collected-label{font-size:10px;color:#a8bfa9;width:100%;line-height:1.5}.collected-cards{display:flex;justify-content:center;gap:3px;opacity:.65;margin:6px auto}.final-cards{display:flex;flex-wrap:wrap;justify-content:center;gap:3px;width:100%;margin-top:12px}.recent-panel{margin:4px 24px 16px;border:1px solid #dce2d2;background:#f9f9f2;border-radius:8px;padding:12px 15px}.recent-heading{font-size:11px;color:#5b7259;display:flex;justify-content:space-between;margin-bottom:8px}.recent-heading span{font-size:10px;color:#929e86}#recent-actions{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:8px 16px}.recent-entry{min-width:0;font-size:11px;border-top:1px solid #e6eade;padding-top:7px;line-height:1.7}.recent-who{display:block;color:#8a957f;font-size:10px}.recent-face{display:block;color:#3c5541;overflow-wrap:anywhere}.recent-panel:has(#recent-actions:empty){display:none}.seat .last{display:none}
@media(max-width:800px){.pace-toolbar{gap:6px;margin-bottom:14px}.pace-toolbar #pace-status{width:100%;margin:0}.last-play{max-width:86px}.bubble-cards{max-width:86px;gap:1px}.bubble-cards .card.mini{width:26px;height:37px;font-size:14px}.bubble-cards .card.mini .suit{font-size:12px}.north .last-play,.south .last-play{max-width:126px}.north .bubble-cards,.south .bubble-cards{max-width:126px}.north,.south{gap:7px;min-width:120px;width:max-content;max-width:85%}.north{top:25px}.south{bottom:24px}.west,.east{width:86px;min-width:0;gap:6px}.west{left:19px;align-items:flex-start}.east{right:19px;align-items:flex-end}.center{width:42%;top:51%}.center .card.mini{width:32px;height:48px;font-size:15px}.center .card.mini .suit{font-size:14px}.pass-label{font-size:14px}.recent-panel{margin:4px 0 14px;padding:10px}#recent-actions{grid-template-columns:repeat(2,minmax(0,1fr))}.bubble-label{font-size:8px}.north .seat-info,.south .seat-info{max-width:110px}.table{min-height:380px;height:380px}.collected-label{font-size:9px}.turn-label{margin-top:10px}}
.collected-cards{flex-wrap:wrap;max-width:100%}
/* Autumn garden game table, with original generated environment art. */
body{background:#183f3d url('assets/garden.png') center top/cover fixed no-repeat;color:#f8e9c7;min-height:100vh}body::before{content:'';position:fixed;inset:0;pointer-events:none;background:linear-gradient(#102f3440,#0a302d75 65%,#0a282de8);z-index:-1}header{max-width:1320px;height:78px;padding:0 28px;background:linear-gradient(180deg,#143d40e6,#143d40a6);border-bottom:1px solid #d0b26955;box-shadow:0 5px 20px #071c2540;border-radius:0 0 20px 20px;margin-bottom:18px}.brand{color:#f8e4ad;text-shadow:0 2px 4px #183a33;font-size:26px}.brand small{color:#d3ca9e}.brand-mark{background:linear-gradient(145deg,#fffbde,#e4c477);border:2px solid #eacb7f;color:#1e5748;box-shadow:0 2px 7px #0005}.score{color:#dfd3b0}.score b{color:#ffe6a1;text-shadow:0 2px 2px #001c20}.score.active{color:#fff0c0}.quiet{color:#e8d8ad;background:#0d343a66;border:1px solid #ccb87933;border-radius:7px}#save-status{color:#c4d6bc}main{padding-bottom:15px}.table{background:radial-gradient(ellipse at 48% 35%,#238c73,#12624f 65%,#0c4b43);border:5px solid #5b3b1e;box-shadow:inset 0 0 0 5px #e9ce83,inset 0 0 0 8px #93713a,inset 0 0 0 12px #d9b766,inset 0 0 50px #052d3380,0 18px 40px #082b2da0;min-height:430px;max-height:540px}.table::after{content:'';position:absolute;inset:15px;pointer-events:none;border-radius:90px;background:repeating-linear-gradient(0deg,#ffffff02 0 1px,transparent 1px 3px);z-index:0}.table-line{inset:20px;border:1px solid #e8dba52c}.table-ornament{position:absolute;left:50%;top:46%;transform:translate(-50%,-50%);font:13px Georgia;letter-spacing:8px;color:#dfcf8f22;white-space:nowrap}.table-watermark{color:#f5dc8610}.table-watermark span{color:#e3ddb61c}.avatar{width:53px;height:53px;border:2px solid #ddc17d;background:linear-gradient(#c6e3d7,#50867d);box-shadow:0 3px 8px #082e3290}.portrait span{font-size:37px;filter:drop-shadow(0 2px 2px #143c34);line-height:1}.portrait-1{background:linear-gradient(#d5e7f2,#778cc0)}.portrait-2{background:linear-gradient(#e9d1aa,#9a744c)}.portrait-3{background:linear-gradient(#f0d7dd,#b07188)}.seat.current .avatar{background:linear-gradient(#ffefb5,#d39e3e);box-shadow:0 0 0 3px #ffdf88,0 0 22px #ffdb6680}.seat-name{color:#fff1cf;font-size:13px;text-shadow:0 1px 3px #08342a}.seat-info{color:#dde8c7}.badge{background:#063a3560;border:1px solid #d2ce9b35;color:#d1dfb8}.badge.open{color:#ffe7a3;background:#b79b4a25}.hand-area{margin-top:17px;border:1px solid #bba46f77;border-radius:15px;background:linear-gradient(180deg,#123c3ce8,#10312be8);box-shadow:0 8px 28px #08222c60;padding:17px 22px 5px}.eyebrow{color:#ecd89e}.hand-top{color:#d7dbc0}#lock-status{color:#edcb7c}.pace-toolbar{color:#e4d8b1}.pace-toolbar select{background:#214d49;color:#f9e8b6;border:1px solid #bdac7255}.pace-toolbar #pace-status{color:#c0cbb1}.pace-toolbar #ai-status{font-size:10px;color:#f8dc87;background:#0b2c2b80;border-radius:6px;padding:4px 7px}.ai-label{display:flex;align-items:center;gap:5px}.primary{background:linear-gradient(#ffc960,#d89727);border:1px solid #ffe0a0;color:#513b1c;text-shadow:0 1px #ffe7ae;box-shadow:0 3px 0 #91651e,0 4px 10px #001d2633}.primary:hover{background:linear-gradient(#ffdf86,#e8ad3a)}.secondary{color:#e5e4cc;background:linear-gradient(#316c64,#20554f);border:1px solid #6f9b8166;box-shadow:0 2px 0 #0d3934}.bao-button{background:linear-gradient(#f6df84,#c49b3d);color:#5f431b;border:1px solid #f6df9b;box-shadow:0 2px 0 #8f702c}#selection-label{color:#c8d7b6}#notice{color:#f2c97a}.card{background:linear-gradient(115deg,#fffdf2,#fffef9 60%,#f2ead9);border-color:#d2c8b3;border-radius:7px;box-shadow:0 3px 5px #051e2240}.hand .card.selected{background:linear-gradient(#fff4ba,#f5db7d);border-color:#edbd47;box-shadow:0 0 0 1px #ffeeba,0 4px 8px #001e2545}.hand .card.locked{background:linear-gradient(#d5d6c9,#b5bdb0);color:#6b7e6c}.hidden-stack{height:16px;margin-top:5px;display:flex;padding-left:7px}.hidden-stack i{display:inline-block;width:12px;height:17px;transform:rotate(-8deg);border:1px solid #e9dba5;border-radius:2px;background:repeating-linear-gradient(45deg,#b34937,#b34937 2px,#852f2d 2px,#852f2d 4px);margin-left:-4px}.count-warning{font-size:11px;font-weight:700;color:#ffda76;margin-top:5px}.recent-panel{background:#143932e8;border-color:#b09c5b55;color:#dfdfc5}.recent-heading{color:#ead8a1}.recent-heading span,.recent-who{color:#aabea3}.recent-entry{border-color:#87a58b26}.recent-face{color:#f6edd5}.history{color:#d6d4af;border-color:#c8b77a44}.history summary span{color:#bbc4a1}.history li{border-color:#a6b58a22}footer{color:#c1c6a0}dialog{background:linear-gradient(145deg,#fffbee,#f2ead6);color:#324334;border:2px solid #d2b16a}.table-note{color:#b1d2ae}.is-dealing #hand .card{visibility:hidden}.is-dealing .seat-info{visibility:hidden}.fx-layer{position:fixed;inset:0;z-index:2000;pointer-events:none;overflow:hidden}.flying-card{position:absolute;width:43px;height:62px;will-change:transform}.fx-card-back{width:38px;height:55px;border:2px solid #fae6b0;border-radius:5px;background:repeating-linear-gradient(45deg,#b34436,#b34436 3px,#94322c 3px,#94322c 6px);box-shadow:0 4px 8px #0004;display:grid;place-items:center}.fx-card-back span{font:25px Georgia;color:#eacb8c;border:1px solid #e8c17f88;padding:1px}.deal-banner,.tribute-banner,.bao-banner{position:absolute;left:50%;top:43%;transform:translate(-50%,-50%);background:linear-gradient(90deg,transparent,#0d3733f5 20%,#0d3733f5 80%,transparent);color:#ffe6a0;text-shadow:0 2px 3px #042f31;padding:13px 50px;font-size:22px;letter-spacing:7px;white-space:nowrap}.tribute-banner{top:35%;font-size:26px;color:#ffe09c}.bao-banner{font-size:30px;color:#ffdf66}.bomb-blast{position:absolute;left:50%;top:40%;transform:translate(-50%,-50%);width:280px;height:240px;display:flex;align-items:center;justify-content:center;flex-direction:column;background:radial-gradient(ellipse,#ffe38fe6,#f09a3766 45%,transparent 70%)}.bomb-blast b{font-size:72px;filter:drop-shadow(0 0 12px #fff085);z-index:1}.bomb-blast strong{font-size:46px;font-weight:900;color:#fff2a4;letter-spacing:10px;text-shadow:3px 3px #ac4021,-1px -1px #fff5aa;z-index:1}.bomb-blast>span{font:bold 13px Georgia;color:#fce9a9;letter-spacing:6px;z-index:1}.blast-ring{position:absolute;width:180px;height:180px;border-radius:50%;border:7px solid #ffcf5d;box-shadow:0 0 18px #ffdb71,inset 0 0 18px #ffdb71;animation:ring-out .85s ease-out both}.blast-ring.second{animation-delay:.12s;border-width:3px}@keyframes ring-out{from{transform:scale(.3);opacity:1}to{transform:scale(1.8);opacity:0}}@media(max-width:800px){header{height:67px;padding:0 14px;margin-bottom:12px;border-radius:0 0 14px 14px}.brand{font-size:21px}.table{min-height:410px;height:410px;border-width:3px}.table::after{border-radius:40px}.hand-area{padding:13px 10px 3px;margin-top:12px}.pace-toolbar{gap:6px}.pace-toolbar select{max-width:152px}.avatar{width:42px;height:42px}.portrait span{font-size:31px}.seat-name{font-size:11px}.north{top:30px}.south{bottom:27px}.west,.east{top:48%;gap:5px}.badge{font-size:8px}.center{top:51%}.recent-panel{margin-top:12px}.count-warning{font-size:10px}.hidden-stack{height:14px}.hidden-stack i{height:14px;width:10px}#ai-status{font-size:9px}.table-ornament{font-size:11px;letter-spacing:5px}}
/* Hand stays on the felt. Stacks expose a separate clickable strip for every card. */
.table{height:calc(620px + var(--hand-extra,0px));min-height:calc(620px + var(--hand-extra,0px));max-height:none;overflow:hidden}.center{top:33%;width:46%}.north{top:29px}.west,.east{top:35%}.south{left:30px;bottom:20px;transform:none;min-width:0;max-width:150px;gap:8px}.south .last-play{display:none}.south .seat-name{font-size:12px}.table-note{display:none}.table>.hand-area{position:absolute;left:22px;right:22px;bottom:77px;z-index:4;margin:0;padding:4px 8px 0;background:none;border:0;border-radius:0;box-shadow:none}.table>.hand-area .hand-top{padding:0 12px 2px;font-size:10px;color:#d3dcb9}.table>.hand-area .hand-top .eyebrow{font-size:10px}.table>.hand-area .controls{margin-top:7px;justify-content:center;flex-wrap:wrap;gap:5px}.table>.hand-area #selection-label{width:100%;text-align:center;font-size:10px}.table>.hand-area #notice{text-align:center;min-height:20px;padding-top:6px;font-size:10px}.table>.hand-area .action-buttons{gap:7px}.table>.hand-area .action-buttons button{padding:8px 16px;min-width:66px;font-size:12px}.hand{touch-action:none;-webkit-user-select:none;user-select:none;cursor:grab}.hand:active{cursor:grabbing}.hand.stacked-hand{display:block;min-height:0;overflow-x:auto;overflow-y:hidden;padding:18px 8px 3px;--stack-width:49px;--stack-step:22px;--stack-full:83px}.stack-grid{display:flex;align-items:flex-end;gap:3px;width:max-content;margin:0 auto;padding:0 4px}.stack-column{position:relative;flex:none;width:var(--stack-width);height:calc((var(--depth) - 1)*var(--stack-step) + var(--stack-full));}.hand .stack-column .card{position:absolute;left:0;top:calc(var(--index)*var(--stack-step));margin:0;width:100%;height:var(--stack-step);min-height:0;font-size:17px;line-height:1;padding:1px 4px;flex-direction:row;gap:2px;justify-content:flex-start;align-items:center;border-radius:4px 4px 0 0;box-shadow:0 -1px 2px #05251b40;overflow:hidden;z-index:1;transition:transform .12s,background .12s}.hand .stack-column .card .suit{align-self:auto;font-size:15px}.hand .stack-column .card.stack-bottom{height:var(--stack-full);flex-direction:column;align-items:flex-start;justify-content:space-between;padding:5px;border-radius:4px;font-size:20px}.hand .stack-column .card.stack-bottom .suit{font-size:25px;align-self:flex-end}.hand .stack-column .card:not(.stack-bottom) .wild-label,.hand .stack-column .card:not(.stack-bottom) .lock-icon{display:none}.hand .stack-column .card.selected{transform:translateY(-11px);background:#ffe390;border:2px solid #f5cd62;z-index:2;box-shadow:0 -2px 5px #fee58e50}.hand .stack-column .card:hover{transform:none}.hand .stack-column .card.selected:hover{transform:translateY(-11px)}.stack-card.wild-card:not(.stack-bottom)::after{content:'配';position:absolute;right:2px;top:2px;font:8px sans-serif;background:#e9c878;color:#60431b}.hand .stack-column .card.joker{writing-mode:horizontal-tb;font-size:10px;letter-spacing:0}.hand .stack-column .card.joker.stack-bottom{writing-mode:vertical-rl;letter-spacing:2px;font-size:12px}.arrange-controls{display:flex;gap:5px}.arrange-controls button{padding:4px 9px;font-size:10px}.pace-toolbar{margin:12px 0 15px;padding:10px 15px;background:#0f3535e8;border:1px solid #ba9d5944;border-radius:9px}.table>.hand-area .auto-label{font-size:10px}.table>.hand-area .auto-label input{height:12px;width:12px}
@media(max-width:800px){.table{height:calc(620px + var(--hand-extra,0px));min-height:calc(620px + var(--hand-extra,0px));max-height:none}.center{top:31%;width:43%}.north{top:25px}.west,.east{top:32%}.south{left:20px;bottom:22px;max-width:140px;width:auto;min-width:0;gap:7px}.south .seat-info{max-width:90px}.table>.hand-area{left:9px;right:9px;bottom:83px;padding:0}.table>.hand-area .hand-top{gap:5px;padding:0 5px;flex-wrap:wrap}.table>.hand-area #lock-status{font-size:9px}.hand.stacked-hand{--stack-width:32px;--stack-step:20px;--stack-full:69px;padding:17px 1px 4px}.stack-grid{gap:1px;padding:0 1px}.hand .stack-column .card{font-size:14px;padding:1px 2px;gap:1px}.hand .stack-column .card .suit{font-size:12px}.hand .stack-column .card.stack-bottom{font-size:17px;padding:4px}.hand .stack-column .card.stack-bottom .suit{font-size:22px}.table>.hand-area .controls{margin-top:4px}.table>.hand-area .action-buttons{gap:4px;flex-wrap:wrap;justify-content:center}.table>.hand-area .action-buttons button{padding:8px 9px;font-size:11px;min-width:52px}.table>.hand-area .hand-top .eyebrow{display:none}.pace-toolbar{padding:9px;gap:6px}.arrange-controls button{padding:3px 7px}.south .avatar{width:35px;height:35px}.south .portrait span{font-size:26px}}
@media(max-width:480px){.hand.stacked-hand{--stack-width:28px;--stack-step:19px;--stack-full:65px}.hand .stack-column .card{font-size:12px}.hand .stack-column .card .suit{font-size:11px}.hand .stack-column .card.stack-bottom{font-size:15px;padding:3px}.hand .stack-column .card.stack-bottom .suit{font-size:21px}.table>.hand-area .action-buttons button{padding:7px 7px;min-width:48px}.table>.hand-area .hand-top{font-size:9px}.arrange-controls button{font-size:9px}.table>.hand-area .controls{gap:3px}}
@media(min-width:650px) and (max-height:650px){header{height:56px;margin-bottom:6px}.table{height:calc(460px + var(--hand-extra,0px));min-height:calc(460px + var(--hand-extra,0px))}.center{top:27%}.north{top:17px}.west,.east{top:30%}.north .avatar{width:35px;height:35px}.north .portrait span{font-size:27px}.table>.hand-area{bottom:47px}.hand.stacked-hand{--stack-width:39px;--stack-step:18px;--stack-full:63px;padding-top:14px}.table>.hand-area .hand-top{display:none}.table>.hand-area #notice{min-height:14px;padding-top:3px}.south{bottom:11px}.south .badge{display:none}.table>.hand-area .action-buttons button{padding:6px 12px}.center #trick{min-height:50px}.center .round-label{margin-bottom:4px}.center .turn-label{margin-top:5px}}
/* Compact card bodies: keep rank strips clear without long lower faces. */
.hand.stacked-hand{--stack-full:64px}.hand:not(.stacked-hand) .card{height:74px}.hand .stack-column .card.stack-bottom{padding:3px 4px;font-size:19px}.hand .stack-column .card.stack-bottom .suit{font-size:22px}.center .card.mini{height:51px}.flying-card .card.mini{height:51px}
@media(max-width:800px){.hand.stacked-hand{--stack-full:44px}.hand .stack-column .card.stack-bottom{font-size:15px;padding:2px 3px}.hand .stack-column .card.stack-bottom .suit{font-size:18px}.center .card.mini{height:40px}.hand:not(.stacked-hand) .card{height:63px}}
@media(max-width:480px){.hand.stacked-hand{--stack-full:40px}.hand .stack-column .card.stack-bottom{font-size:14px;padding:2px}.hand .stack-column .card.stack-bottom .suit{font-size:17px}}
@media(min-width:650px) and (max-height:650px){.hand.stacked-hand{--stack-full:48px}}
/* Selection changes only paint, never geometry or stacking order. */
.hand .card.selected,.hand .card.selected:hover,.hand .stack-column .card.selected,.hand .stack-column .card.selected:hover{transform:none!important;z-index:1;border:1px solid #e4b33c;box-shadow:inset 0 0 0 2px #ffda70;background:linear-gradient(#fff0a5,#f9d979)}
.stack-column.manual-group{margin-left:7px;margin-right:3px}.stack-column.manual-group::after{content:'';position:absolute;left:1px;right:1px;bottom:-3px;height:2px;background:#e9c66e;border-radius:2px}.stack-column.flush-group::after{background:#a5e3ce}.stack-grid .stack-column:first-child{margin-left:0}
@media(min-width:650px) and (max-height:650px){.hand .stack-column .card{font-size:14px;padding:0 3px}.hand .stack-column .card .suit{font-size:13px}.hand .stack-column .card.stack-bottom{font-size:16px;padding:2px 3px}.hand .stack-column .card.stack-bottom .suit{font-size:21px}}
html{background:#10382f}
/* Joker labels use explicit top-to-bottom glyphs, never inherited writing-mode. */
.card.joker{writing-mode:horizontal-tb!important;letter-spacing:0!important;align-items:center!important;justify-content:center!important;overflow:hidden}.card.joker>.suit{display:none!important}.joker-text{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:1px;max-width:100%;white-space:nowrap;font:700 14px/1.05 -apple-system,BlinkMacSystemFont,"PingFang SC",sans-serif}.joker-text i{display:block;font-style:normal;line-height:1.05;letter-spacing:0}.card.joker.mini .joker-text{font-size:13px}.bubble-cards .card.joker.mini .joker-text{font-size:10px}.hand .stack-column .card.joker.stack-bottom .joker-text{font-size:12px}.hand .stack-column .card.joker:not(.stack-bottom) .joker-text{flex-direction:row;font-size:10px;gap:0}.turn-countdown{display:inline-flex;align-items:center;justify-content:center;min-width:49px;height:29px;padding:0 8px;margin-top:8px;border:2px solid #e8ca71;border-radius:18px;background:linear-gradient(#fff0ae,#cfa64d);color:#553d19;font-size:14px;font-weight:750;box-shadow:0 2px 5px #072d2b66;font-variant-numeric:tabular-nums}.turn-countdown.urgent{background:linear-gradient(#ffda9c,#df8d4f);border-color:#ffd68e;color:#762f1f}@media(max-width:800px){.turn-countdown{height:25px;min-width:44px;font-size:12px;margin-top:5px}}@media(min-width:650px) and (max-height:650px){.turn-countdown{height:23px;margin-top:3px;font-size:12px}.center{top:29%}}
.round-ready-note{font-size:11px;line-height:1.6;color:#e7dcac;width:100%}#confirm-round-start{margin-top:6px;padding:7px 14px;font-size:12px}
.anti-proof-player{border:1px solid #d8cba2;border-radius:8px;padding:15px;margin:10px 0;text-align:center}.anti-proof-player strong{display:block;color:#6b572e;font-size:14px;margin-bottom:12px}.anti-proof-player .card.mini{width:58px;height:76px;margin:0 4px}.anti-proof-player .card.joker.mini .joker-text{font-size:23px;gap:5px}
.count-warning{display:inline-flex;align-items:baseline;justify-content:center;gap:3px;min-width:48px;padding:3px 8px;border:1px solid #e9c36a99;border-radius:7px;background:#123c33cc;color:#ffe29a;box-shadow:0 2px 5px #062c2a55}.count-number{font-size:30px;line-height:1;font-weight:850;font-variant-numeric:tabular-nums;text-shadow:0 2px 2px #1a3429}.count-warning small{font-size:11px}.avatar{position:relative}.portrait .crown{position:absolute;left:50%;top:-24px;transform:translateX(-50%);font-size:29px;line-height:1;filter:drop-shadow(0 2px 3px #8b5e19);z-index:6}.seat.is-first .avatar{border:3px solid #ffe294;box-shadow:0 0 0 2px #ae7e2e,0 0 20px #eec65b77}.seat.is-first .seat-name{color:#ffe092}#hand-count{font-size:20px;font-weight:750;color:#ffe29a}.north.is-first{top:38px}@media(max-width:800px){.count-number{font-size:26px}.count-warning{padding:3px 6px;min-width:43px}.portrait .crown{font-size:26px;top:-21px}#hand-count{font-size:18px}.north.is-first{top:37px}}
/* Larger suit marks on exposed stack headers, keeping the same card footprint. */
.hand .stack-column .card:not(.stack-bottom) .suit{font-size:18px;line-height:1;flex-shrink:0}.hand .stack-column .card:not(.stack-bottom)>span:first-child{flex-shrink:0}
@media(max-width:800px){.hand .stack-column .card:not(.stack-bottom) .suit{font-size:16px}.hand .stack-column .card:not(.stack-bottom){gap:0;padding-left:1px;padding-right:1px}}
@media(max-width:480px){.hand .stack-column .card:not(.stack-bottom) .suit{font-size:14px}.hand .stack-column .card:not(.stack-bottom){padding-left:0;padding-right:0}.hand .stack-column .card:not(.stack-bottom)>span:first-child{letter-spacing:-.4px}}
@media(min-width:650px) and (max-height:650px){.hand .stack-column .card:not(.stack-bottom) .suit{font-size:16px}}
.round-reveal{margin:12px 0;padding:14px;border:1px solid #d2ba6e77;border-radius:10px;background:#123c35ed}.round-reveal[hidden]{display:none}.round-reveal h3{margin:0 0 10px;color:#f5df9e;font-size:15px}#round-reveal-hands,.result-reveal{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}.reveal-player{min-width:0;border:1px solid #c5b47844;border-radius:7px;padding:10px}.reveal-player-title{display:flex;justify-content:space-between;gap:6px;flex-wrap:wrap;margin-bottom:8px;font-size:12px}.reveal-player-title span{font-size:11px;opacity:.8}.reveal-cards{display:flex;gap:3px;flex-wrap:wrap;min-height:30px}.reveal-cards .card.mini{width:34px;height:45px;padding:3px;font-size:16px}.reveal-cards .card.mini .suit{font-size:17px}.reveal-empty{font-size:12px;opacity:.7}.result-reveal{margin-top:15px;color:#3c4f3d}.result-reveal .reveal-player{border-color:#d8d8c0}@media(max-width:600px){#round-reveal-hands,.result-reveal{grid-template-columns:1fr}.round-reveal{padding:10px}}
/* Friend rooms use compact controls and keep connection details outside the felt. */
[hidden]{display:none!important}input,select{font-size:16px}input{min-width:0;border:1px solid #b2b99c80;border-radius:8px;padding:11px 12px;background:#fffbec;color:#273c32}body[data-mode="home"] .scores{display:none}body[data-mode="home"] header{margin-bottom:0}.room-home{max-width:720px;margin:7vh auto 4vh;display:grid;grid-template-columns:1fr 1fr;gap:36px;padding:32px;border:1px solid #dfc78b60;border-radius:20px;background:#103c37ed;box-shadow:0 18px 60px #061d2940}.home-intro h1{font-size:32px;font-weight:650;margin:16px 0}.home-intro p{font-size:14px;line-height:1.8;color:#cbd7bc}.room-form{display:flex;flex-direction:column;gap:12px}.room-form>label{font-size:12px;color:#dacb9e}.room-form button{min-height:42px}.join-line{display:flex;gap:8px}.join-line input{width:100%}.join-line button{flex:none;min-width:95px}#room-code-input{text-transform:uppercase}#home-notice{font-size:12px;line-height:1.6;color:#f4d089;min-height:0}.room-bar{display:flex;align-items:center;gap:12px;flex-wrap:wrap;margin:0 4px 10px;font-size:12px}.room-bar strong{font:700 16px ui-monospace,monospace;letter-spacing:1px;color:#ffe4a1}.room-bar button{padding:6px 10px;font-size:12px}#room-connection{margin-right:auto;color:#b7e4c1;font-size:11px}#room-connection[data-state="reconnecting"],#room-connection[data-state="expired"]{color:#ffd087}#room-share-fallback{flex-basis:100%;display:flex;gap:8px;align-items:center;font-size:11px}#room-share-fallback input{flex:1;padding:8px}.room-lobby{max-width:620px;margin:6vh auto;padding:24px;border:1px solid #d7c28e60;border-radius:16px;background:#123e38ef}.lobby-heading h2{color:#f3dfaa;font-size:23px}.lobby-heading p{font-size:12px;color:#becfb8}.room-seats{display:grid;grid-template-columns:1fr 1fr;gap:10px;margin:20px 0}.lobby-seat{display:flex;flex-direction:column;gap:9px;border:1px solid #a9bb8d50;border-radius:9px;padding:15px;min-width:0}.lobby-seat.my-seat{border-color:#ecc76b}.lobby-seat span,.lobby-seat small{font-size:11px;color:#b8ceb5}.lobby-seat strong{font-size:16px;overflow-wrap:anywhere;color:#f8e6b6}.lobby-actions{display:flex;gap:12px;justify-content:center}.room-lobby>p{font-size:12px;color:#e3cf9d;min-height:18px;text-align:center}body[data-mode="online"] footer{font-size:0}body[data-mode="online"] footer::after{content:'四人好友局 · 刷新可恢复座位 · 断线自动重连';font-size:10px}.room-bar input:focus{outline:2px solid #e8c56e}
@media(max-width:600px){.room-home{margin:5vh auto;padding:24px 20px;grid-template-columns:1fr;gap:16px}.home-intro h1{font-size:28px;margin:12px 0}.home-intro p{margin:0;font-size:13px}.room-form{gap:10px}.room-lobby{margin:4vh auto;padding:18px}.lobby-seat{padding:13px;gap:8px}.room-bar{gap:7px;margin-bottom:7px}.room-bar strong{font-size:14px}.room-bar button{padding:6px 8px}.room-bar>span{white-space:nowrap}.table{border-radius:32px}.table>.hand-area{bottom:58px}.south{bottom:13px}.south .last,.south .badge{display:none}.center{top:30%}.table{height:calc(560px + var(--hand-extra,0px));min-height:calc(560px + var(--hand-extra,0px))}.recent-panel{margin-left:0;margin-right:0}.table>.hand-area .action-buttons button{min-height:36px}.hand.stacked-hand{padding-top:10px}.table>.hand-area .hand-top{min-height:25px}.room-bar #room-share-fallback{flex-wrap:wrap}.room-bar #room-share-fallback input{flex-basis:100%}}
@media(orientation:landscape) and (max-height:600px){header{height:42px;padding:0 14px;margin-bottom:4px;border-radius:0 0 9px 9px}.brand{font-size:18px}.brand small{display:none}.brand-mark{width:23px;height:31px;font-size:19px;line-height:18px}.brand-mark span{font-size:11px;line-height:10px}.score b{font-size:18px}.score{font-size:10px}.scores{gap:16px}.quiet{padding:5px 8px;font-size:11px}main{padding:0 8px 6px}.room-bar{margin:0 9px 5px;gap:9px;height:27px}.room-bar button{padding:4px 8px;font-size:11px}.table{height:max(calc(100dvh - 61px),280px);min-height:max(calc(100dvh - 61px),280px);border-radius:30px}body[data-mode="online"] .table{height:max(calc(100dvh - 84px),268px);min-height:max(calc(100dvh - 84px),268px)}.table>.hand-area{bottom:3px;left:50px;right:50px}.table>.hand-area .hand-top{display:flex;min-height:18px;gap:5px;padding:0 5px}.table>.hand-area #lock-status{font-size:9px}.table>.hand-area #hand-count{font-size:14px}.table>.hand-area .hand-top .eyebrow{display:none}.table>.hand-area .controls{margin-top:2px;gap:2px}.table>.hand-area #selection-label{font-size:9px;line-height:13px}.table>.hand-area .action-buttons{gap:7px}.table>.hand-area .action-buttons button{min-height:29px;min-width:58px;padding:4px 10px;font-size:12px}.table>.hand-area #notice{min-height:13px;padding-top:2px;line-height:12px;font-size:9px}.hand.stacked-hand{--stack-width:34px;--stack-step:14px;--stack-full:33px;padding:4px 1px 2px}.hand .stack-column .card{font-size:12px;padding:0 2px}.hand .stack-column .card:not(.stack-bottom) .suit{font-size:12px}.hand .stack-column .card.stack-bottom{font-size:14px;padding:1px 3px}.hand .stack-column .card.stack-bottom .suit{font-size:15px}.hand .stack-column .card.stack-bottom .joker-text{font-size:10px}.hand .card .lock-icon,.hand .card .wild-label{font-size:7px;bottom:1px;left:2px}.hand:not(.stacked-hand){min-height:62px;padding:4px 0 2px}.hand:not(.stacked-hand) .card{height:56px;width:41px;font-size:17px;margin-left:-17px}.center{top:27%;width:48%}.center #trick{min-height:32px;gap:2px}.center .round-label{margin-bottom:3px;line-height:11px}.center .turn-label{margin-top:3px;font-size:10px;min-height:12px;line-height:14px}.center .card.mini{width:27px;height:35px;padding:2px;font-size:14px}.center .card.mini .suit{font-size:13px}.turn-countdown{height:19px;min-width:40px;margin-top:2px;font-size:10px;padding:0 6px}.north,.north.is-first{top:13px;gap:5px}.north .avatar,.west .avatar,.east .avatar{width:29px;height:29px}.north .portrait>span,.west .portrait>span,.east .portrait>span{font-size:23px}.north .seat-info{margin-top:1px}.north .badge{display:none}.north .last-play{position:absolute;left:100%;width:115px;margin-left:9px}.west,.east{top:31%;gap:3px;max-width:115px;min-width:70px}.west{left:15px}.east{right:15px}.seat-name{font-size:10px}.seat-info{font-size:8px;margin-top:2px}.badge{font-size:8px;margin-top:3px;padding:1px 3px}.seat .last{display:none}.south{display:none}.bubble-cards .card.mini{width:18px;height:26px;font-size:10px}.bubble-cards .card.mini .suit{font-size:9px}.bubble-label{font-size:8px;margin-bottom:2px}.count-warning{margin-top:2px;padding:2px 4px;min-width:35px}.count-number{font-size:20px}.count-warning small{font-size:9px}.hidden-stack{margin-top:2px;height:10px}.hidden-stack i{height:11px;width:9px}.portrait .crown{font-size:19px;top:-15px}.room-home{margin:18px auto;padding:20px;gap:24px;grid-template-columns:1fr 1fr}.home-intro h1{font-size:26px}.room-form{gap:8px}.room-form input,.room-form button{padding:8px 10px;min-height:36px}.room-lobby{margin:12px auto;padding:16px;max-width:720px}.lobby-heading{display:flex;gap:15px;align-items:center}.lobby-heading h2{margin:0;font-size:19px}.room-seats{grid-template-columns:repeat(4,1fr);margin:12px 0}.lobby-seat{padding:10px;gap:6px}.lobby-seat strong{font-size:14px}.room-lobby>p{margin:9px 0 0}.lobby-actions button{padding:7px 16px}.round-ready-note{font-size:9px;line-height:1.2}#confirm-round-start{font-size:10px;margin-top:2px;padding:4px 9px}}
.hand-scroll-controls{display:flex;gap:3px}.hand-scroll-controls button{padding:1px 9px;font-size:19px;line-height:20px;min-width:27px}.hand.stacked-hand{scrollbar-width:thin}.hand .stack-column .card{min-width:0}.hand .stack-column .card>span:first-child{letter-spacing:-.5px}@media(max-width:480px){.hand .stack-column .card:not(.stack-bottom){font-size:11px;padding-left:0;padding-right:0;gap:0}.hand .stack-column .card:not(.stack-bottom) .suit{font-size:12px}.hand .stack-column .card.stack-bottom{padding-left:1px;padding-right:1px}.hand .stack-column .card.joker:not(.stack-bottom) .joker-text{font-size:9px}}@media(orientation:landscape) and (max-height:600px){.hand-scroll-controls button{padding:0 7px;font-size:17px;line-height:18px}}

body[data-mode="online"] footer{font-size:10px}body[data-mode="online"] footer::after{content:none}body[data-mode="home"] #save-status{display:none}

#sound-toggle{min-width:32px;padding:6px;font-size:17px}.cannot-beat-tip{color:#ffe4a4;font-size:12px;font-weight:700;line-height:1.4;margin-top:3px}.bao-result-summary{color:#ffedbc;font-size:14px;line-height:1.5}.bao-result-summary p{margin:3px 0}#replay-result{margin:6px 0 10px}#replay-result-dialog{margin-bottom:8px}
@media(orientation:landscape) and (max-height:500px){.cannot-beat-tip{font-size:10px;margin:0;position:absolute;left:0;right:0;bottom:-16px;white-space:nowrap}.hand-area{position:absolute}}
/* Waiting players sit at the same felt table before the first deal. */
.table-lobby{position:absolute;z-index:5;left:50%;top:50%;transform:translate(-50%,-50%);width:min(360px,54%);text-align:center}.lobby-room-label{display:block;font-size:12px;letter-spacing:4px;color:#e7d3a0}.table-room-code{display:block;font:750 66px/1.15 ui-monospace,SFMono-Regular,monospace;letter-spacing:9px;color:#ffe5a0;text-shadow:0 3px 12px #082d2c;margin:8px 0 5px}.table-lobby p{font-size:12px;line-height:1.7;color:#cddcbf;margin:8px 0}.table-lobby-actions{display:flex;justify-content:center;gap:10px;margin:14px 0}.table-lobby-actions button{font-size:13px;min-height:42px;padding:9px 15px}.table-lobby>#room-leave{margin-top:8px;font-size:11px;padding:5px 10px;background:transparent}.vacant-seat{opacity:.6}.vacant-seat .avatar{background:#143d35;border-style:dashed}.vacant-seat .portrait span{font-size:25px}.badge.ready-badge{background:#ffe1a02b;color:#ffe4a0;border-color:#e4c7788c}body[data-room-state="lobby"] .table>.hand-area,body[data-room-state="lobby"] .table>.center,body[data-room-state="lobby"] .table-note,body[data-room-state="lobby"] .recent-panel,body[data-room-state="lobby"] .history,body[data-room-state="lobby"] #round-reveal,body[data-room-state="lobby"] #scores{display:none!important}body[data-room-state="lobby"] .table{height:min(650px,calc(100dvh - 155px));min-height:460px;--hand-extra:0px}body[data-room-state="lobby"] .north,body[data-room-state="lobby"] .north.is-first{top:35px}body[data-room-state="lobby"] .west,body[data-room-state="lobby"] .east{top:50%}body[data-room-state="lobby"] .south{display:flex;left:50%;bottom:30px;transform:translateX(-50%);max-width:220px}body[data-room-state="lobby"] .south .badge{display:inline-block}body[data-room-state="lobby"] .seat-name{max-width:150px;overflow-wrap:anywhere}body[data-room-state="lobby"] .room-bar strong{font-size:20px;letter-spacing:2px}body[data-room-state="lobby"] footer{padding:12px 0}
@media(max-width:600px){body[data-room-state="lobby"] .table{height:calc(100dvh - 150px);min-height:480px;max-height:650px}.table-lobby{width:58%}.table-room-code{font-size:47px;letter-spacing:5px;margin-top:8px}.table-lobby p{font-size:11px;margin:6px 0}.table-lobby-actions{gap:6px;flex-wrap:wrap;margin:11px 0}.table-lobby-actions button{min-height:38px;padding:8px 10px;min-width:75px;font-size:12px}body[data-room-state="lobby"] .west{left:16px}body[data-room-state="lobby"] .east{right:16px}body[data-room-state="lobby"] .west,body[data-room-state="lobby"] .east{max-width:76px;min-width:60px}body[data-room-state="lobby"] .seat-name{font-size:10px;max-width:76px}body[data-room-state="lobby"] .south .seat-name,body[data-room-state="lobby"] .north .seat-name{max-width:150px}body[data-room-state="lobby"] .north{top:30px}body[data-room-state="lobby"] .south{bottom:25px}.lobby-room-label{font-size:10px;letter-spacing:3px}}
@media(orientation:landscape) and (max-height:600px){body[data-room-state="lobby"] .table{height:max(calc(100dvh - 84px),268px);min-height:max(calc(100dvh - 84px),268px)}.table-lobby{top:50%;width:48%}.table-room-code{font-size:40px;letter-spacing:7px;margin:2px 0}.lobby-room-label{font-size:10px}.table-lobby p{font-size:10px;line-height:1.4;margin:4px 0}.table-lobby-actions{margin:7px 0;gap:10px}.table-lobby-actions button{min-height:32px;padding:5px 12px;font-size:12px}.table-lobby>#room-leave{margin-top:0;font-size:10px;padding:3px 8px}body[data-room-state="lobby"] .north{top:13px}body[data-room-state="lobby"] .south{bottom:12px}body[data-room-state="lobby"] .south .avatar{width:29px;height:29px}body[data-room-state="lobby"] .south .portrait>span{font-size:23px}body[data-room-state="lobby"] .west,body[data-room-state="lobby"] .east{top:50%;max-width:130px}body[data-room-state="lobby"] .vacant-seat .avatar span{font-size:20px}}
body[data-room-state="lobby"] .north .badge{display:inline-block}

.room-members{margin:12px 0}.room-member{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:9px 0;border-bottom:1px solid #bfb28a36;font-size:14px}.room-member>span{min-width:0;overflow-wrap:anywhere}.kick-member{flex-shrink:0;min-height:38px;padding:7px 16px;color:#ffd2b0;border-color:#d6a68366}#room-manage-help,#room-manage-notice{font-size:13px;line-height:1.6}#room-manage-notice{color:#ffe5a0}.empty-seat-button{padding:0;cursor:pointer;color:#d3dfb8;touch-action:manipulation}.empty-seat-button:active{transform:scale(.94)}.empty-seat-button:focus-visible{outline:3px solid #ffe6a1;outline-offset:3px}

/* Small-screen tables require physical landscape orientation. */
#landscape-prompt{position:fixed;inset:0;margin:0;width:100vw;max-width:none;height:100dvh;max-height:none;border:0;border-radius:0;padding:max(24px,env(safe-area-inset-top)) 26px max(24px,env(safe-area-inset-bottom));background:radial-gradient(ellipse at 50% 40%,#247c65,#103c35 78%);color:#ffe5a6;text-align:center;overflow:auto}
#landscape-prompt::backdrop{background:#103c35;backdrop-filter:none}.landscape-prompt-inner{min-height:100%;display:flex;flex-direction:column;align-items:center;justify-content:center;max-width:400px;margin:auto}.rotate-phone{width:100px;height:100px;margin-bottom:25px;transform:rotate(20deg);color:#f4d38c}#landscape-prompt h2{font-size:25px;line-height:1.4;margin:0 0 14px}#landscape-prompt p{color:#d8e5cb;font-size:14px;line-height:1.8;margin:0 0 24px}#landscape-start{min-height:46px;min-width:160px;background:linear-gradient(#f0d993,#c5a35a);color:#254937;font-size:16px;margin:4px 0 18px}#landscape-prompt #landscape-help{font-size:12px;color:#bacdb6;margin:0;min-height:44px}
@media(orientation:landscape) and (max-height:600px){html{scroll-padding:0}body{overscroll-behavior-y:contain}header{padding-left:max(14px,env(safe-area-inset-left));padding-right:max(14px,env(safe-area-inset-right))}main{padding-left:max(8px,env(safe-area-inset-left));padding-right:max(8px,env(safe-area-inset-right))}}

/* Keep settlement controls in their own hand-area row, clear of played cards. */
.table.is-result .last-play{display:none!important}.table.is-result .controls{position:relative;z-index:9}.result-entry{min-height:42px;min-width:210px;position:relative;z-index:10;touch-action:manipulation}.table.is-result #trick{pointer-events:none}.table.is-result .final-cards{margin-top:0}.table.is-result .arrange-controls,.table.is-result .auto-label{visibility:hidden}
@media(orientation:landscape) and (max-height:600px){.action-buttons .result-entry{min-height:34px;padding:7px 20px;font-size:13px;min-width:220px}.table.is-result .controls{margin-top:2px}}

/* Do not let a long press select table labels or open iOS callouts. */
body{-webkit-user-select:none;user-select:none;-webkit-touch-callout:none}input,textarea,[contenteditable="true"]{-webkit-user-select:text;user-select:text;-webkit-touch-callout:default}img,svg{-webkit-user-drag:none}#sound-toggle{font-size:12px;min-width:45px;white-space:nowrap}#audio-feedback{min-height:40px;color:#475c42}#test-audio,#mute-audio{min-height:42px}
#show-result.result-entry{min-width:220px;min-height:42px;padding:9px 18px;font-size:14px}
@media(orientation:landscape) and (max-height:600px){#show-result.result-entry{min-height:36px;padding:7px 18px;font-size:13px}}
