/* Reserve the controls' space in every state, so turns never resize the table. */
body[data-screen=table] .game-content{display:grid;grid-template-columns:minmax(0,1fr);grid-template-rows:58px 52px 32px minmax(0,1fr) 152px;grid-template-areas:'heading' 'toolbar' 'announcement' 'table' 'controls';gap:8px}
body[data-screen=table] .game-content:has(.online-table-info:not(.hidden)){grid-template-rows:58px 52px 28px 32px minmax(0,1fr) 152px;grid-template-areas:'heading' 'toolbar' 'online' 'announcement' 'table' 'controls'}
.table-heading{grid-area:heading;min-width:0;min-height:0;overflow:hidden}.table-heading>div:first-child{min-width:0}.room-title-row h1{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.table-toolbar{grid-area:toolbar;height:100%;min-width:0}.online-table-info{grid-area:online;min-height:0;height:100%;overflow:hidden;white-space:nowrap}.table-announcement{grid-area:announcement;height:100%;min-height:0;display:block;line-height:20px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;margin:0 auto}.online-table-info>span:first-child{overflow:hidden;text-overflow:ellipsis}
body[data-screen=table] .table-stage{grid-area:table;min-width:0;min-height:0;height:100%;margin:0;align-self:stretch}.poker-table{inset:48px 24px 48px}.table-stage .seat.self{--seat-y:calc(100% - 54px)}.table-stage .seat.self .seat-action{top:calc(100% + 4px)}
.action-section{grid-area:controls;display:grid;grid-template-columns:minmax(0,1fr);grid-template-rows:20px 48px 48px 15px;gap:5px;align-content:start;justify-items:center;height:100%;min-height:0;margin:0;padding:0}.turn-status{grid-column:1;grid-row:1;min-width:0;max-width:100%;height:20px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;margin:0}.bet-controls{grid-column:1;grid-row:2;display:grid;grid-template-columns:minmax(100px,1fr) auto auto auto;gap:10px;width:min(100%,900px);max-width:900px;min-height:0;height:48px;margin:0;padding:3px 10px;align-items:center}.bet-controls[data-available=false]{visibility:hidden;pointer-events:none}.bet-track{display:flex;justify-content:center;min-width:0;height:40px;gap:0}.bet-track input[type=range]{width:100%;height:24px;min-height:24px;margin:0;appearance:none;background:transparent;touch-action:pan-y}.bet-track input[type=range]::-webkit-slider-runnable-track{height:4px;background:#dce4d6;border-radius:9px}.bet-track input[type=range]::-webkit-slider-thumb{appearance:none;background:#638453;width:16px;height:16px;border-radius:50%;margin-top:-6px}.bet-track input[type=range]::-moz-range-track{height:4px;background:#dce4d6;border-radius:9px}.bet-track input[type=range]::-moz-range-thumb{background:#638453;width:16px;height:16px;border:0;border-radius:50%}.bet-presets{display:flex;gap:4px;align-items:center}.bet-presets button{min-width:48px;height:36px;min-height:36px;border:1px solid #e3e9dc;background:#f7f9f3;border-radius:6px;padding:4px 9px;font-size:13px;color:#6a7d5e}.bet-presets button.selected,.bet-presets button:hover{background:#e7eedf;border-color:#c7d7b9;color:#3f653d}.bet-amount-label{display:flex;align-items:center;justify-content:center;height:40px;min-width:0;gap:0}.bet-controls #bet-input{width:118px;height:40px;font-size:24px;padding:4px 10px}.all-in-button{height:40px;min-height:40px;min-width:82px;align-self:center;font-size:14px;padding:5px 10px}.action-buttons{grid-column:1;grid-row:3;align-items:center;width:min(100%,900px);height:48px;margin:0;gap:10px}.action-buttons .button{height:44px;font-size:16px;min-width:135px}.action-buttons .raise{min-width:208px}.action-hint{grid-column:1;grid-row:4;min-height:0;height:15px;line-height:15px;max-width:100%;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;margin:0}
.phase-controls{grid-column:1;grid-row:2 / 4;width:min(100%,900px);max-height:100%;height:100%;min-height:0;align-self:stretch;justify-content:center;gap:4px;overflow:auto;overscroll-behavior:contain;z-index:2;border-radius:10px;background:#f8faf5}.action-section[data-phase=done] .phase-controls{grid-row:2;height:48px;background:transparent}.action-section[data-phase=done] .phase-controls:has(#claim-chips){grid-row:2;height:48px}.ready-panel,.runout-panel{padding:8px 12px;min-height:0}.ready-members{margin:0 0 6px;font-size:11px;gap:3px 12px}.prepare-actions{gap:10px;flex-wrap:nowrap}.prepare-actions .button{height:38px;min-height:38px;font-size:13px;padding:7px 14px}.prepare-actions label{gap:5px;font-size:11px}.prepare-actions select{min-height:36px;padding:6px;font-size:12px}.phase-controls .text-button{margin:0;padding:2px 6px;font-size:11px}.runout-panel .vote-top{display:flex;align-items:center;justify-content:space-between;gap:8px}.runout-panel strong{font-size:14px}.runout-panel p{font-size:12px;line-height:1.5;margin:4px 0 6px}.runout-panel .vote-buttons .button{min-height:36px;padding:7px 20px;font-size:13px}.runout-panel small{display:block;margin-top:6px}.action-section[data-phase=ready] #next-hand{display:none}
/* Restore the card proportions and typography used before the compact table. */
@media(min-width:821px) and (min-height:481px){
  .table-stage .seat:not(.self) .hole-cards .card{width:43px!important;height:61px!important;border-radius:6px}
  .table-stage .seat.self .hole-cards .card{width:49px!important;height:71px!important;border-radius:6px}
  .table-stage .seat .hole-cards{gap:4px;margin-bottom:8px}.table-stage .seat.self .hole-cards{margin:0}
  .table-stage .seat .hole-cards .card-rank{font-size:19px;left:7px;top:5px}.table-stage .seat .hole-cards .card-suit{display:block;font-size:14px;left:7px;top:25px}.table-stage .seat .hole-cards .card-suit-big{font-size:23px;right:4px;bottom:5px}
  .table-stage .seat.self .hole-cards .card-rank{font-size:22px}.table-stage .seat.self .hole-cards .card-suit{top:29px}.table-stage .seat.self .hole-cards .card-suit-big{font-size:28px}
  .community-cards .card{width:58px;height:82px;border-radius:7px}.community-cards{gap:8px}.community-cards .card-rank{font-size:23px;left:9px;top:6px}.community-cards .card-suit{display:block;font-size:17px;left:9px;top:29px}.community-cards .card-suit-big{font-size:33px;right:7px;bottom:5px}
  .table-stage .board-area{top:48%}.double-board .community-cards .card{width:42px;height:55px}.double-board .community-cards .card-rank{font-size:18px;left:5px;top:4px}.double-board .community-cards .card-suit{display:none}.double-board .community-cards .card-suit-big{font-size:23px;right:4px;bottom:4px}
}
@media(min-width:1550px) and (min-height:801px){.community-cards .card{width:66px;height:94px}.community-cards .card-suit-big{font-size:38px}}
@media(max-height:800px) and (min-width:821px) and (min-height:481px){body[data-screen=table] .game-content{grid-template-rows:48px 42px 28px minmax(0,1fr) 142px;gap:5px}body[data-screen=table] .game-content:has(.online-table-info:not(.hidden)){grid-template-rows:48px 42px 24px 28px minmax(0,1fr) 142px}.table-toolbar{height:100%}.table-announcement{line-height:18px}.action-section{grid-template-rows:18px 44px 44px 14px;gap:5px}.bet-controls{height:44px;padding:2px 10px}.action-buttons{height:44px}.turn-status{height:18px}.poker-table{inset:40px 20px 48px}}
@media(min-width:821px) and (max-width:1100px) and (min-height:481px){.table-stage .seat:not(.self) .hole-cards .card{width:35px!important;height:51px!important}.table-stage .seat .hole-cards .card-rank{font-size:17px;left:5px;top:4px}.table-stage .seat .hole-cards .card-suit{font-size:12px;left:5px;top:24px}.table-stage .seat .hole-cards .card-suit-big{font-size:22px;right:4px;bottom:4px}.community-cards .card{width:49px;height:72px}.community-cards .card-suit-big{font-size:29px}.bet-presets button{min-width:36px;font-size:12px;padding:4px 6px}.bet-presets button span{display:none}.bet-controls #bet-input{width:96px}}
@media(max-width:820px){body[data-screen=table] .game-content{grid-template-rows:48px 44px 30px minmax(0,1fr) 160px;gap:5px}body[data-screen=table] .game-content:has(.online-table-info:not(.hidden)){grid-template-rows:48px 44px 26px 30px minmax(0,1fr) 160px}.table-toolbar{height:100%}.table-announcement{line-height:20px}.action-section{grid-template-rows:18px 66px 44px 14px;gap:5px}.turn-status{height:18px}.bet-controls{grid-template-columns:minmax(0,1fr) auto auto;grid-template-rows:12px 40px;height:66px;gap:4px 8px;padding:4px 8px}.bet-track{grid-row:1;grid-column:1/-1;height:12px}.bet-track input[type=range]{height:12px;min-height:12px}.bet-presets{grid-row:2;grid-column:1;justify-content:space-between;gap:3px}.bet-presets button{min-width:28px;height:36px;min-height:36px;padding:4px 6px;font-size:13px}.bet-presets button span{display:none}.bet-amount-label{grid-row:2;grid-column:2}.bet-controls #bet-input{width:88px;height:40px;font-size:22px;padding:4px 7px}.all-in-button{grid-row:2;grid-column:3;min-width:65px;height:40px;min-height:40px;font-size:12px;padding:5px 7px}.action-buttons{height:44px}.action-buttons .button{height:44px;min-width:0;flex:1;padding:7px 8px;font-size:14px}.action-buttons .raise{min-width:0;flex:1.45}.action-hint{height:14px;line-height:14px}.phase-controls .button{min-height:36px}.prepare-actions .button{font-size:12px;padding:6px 9px}.prepare-actions label{font-size:10px}.prepare-actions select{font-size:11px}.prepare-actions{gap:6px}.ready-panel,.runout-panel{padding:7px 9px}.runout-panel strong{font-size:13px}.runout-panel p{font-size:11px}.runout-panel .text-button{font-size:10px}.ready-members{font-size:10px;gap:3px 8px}.table-stage .seat.self{--seat-y:calc(100% - 48px)}}
@media(max-width:540px) and (min-height:701px){
  .table-stage .seat:not(.self):not(.dense) .hole-cards .card{width:32px;height:48px}.table-stage .seat.self .hole-cards .card{width:41px;height:62px}.table-stage .seat.self .hole-cards .card-rank{font-size:22px;left:6px;top:5px}.table-stage .seat.self .hole-cards .card-suit{font-size:14px;left:6px;top:29px}.table-stage .seat.self .hole-cards .card-suit-big{font-size:26px;right:4px;bottom:4px}.table-stage .seat:not(.dense) .hole-cards .card-rank{font-size:17px;left:5px;top:4px}.table-stage .seat:not(.self):not(.dense) .hole-cards .card-suit{font-size:12px;top:23px;left:5px}.table-stage .seat:not(.self):not(.dense) .hole-cards .card-suit-big{font-size:20px;right:3px;bottom:3px}.community-cards .card{width:33px;height:52px}.table-stage .seat.self{--seat-y:calc(100% - 48px)}
}
@media(max-width:540px) and (max-height:700px){body[data-screen=table] .game-content{grid-template-rows:40px 40px 26px minmax(0,1fr) 152px;gap:3px}body[data-screen=table] .game-content:has(.online-table-info:not(.hidden)){grid-template-rows:40px 40px 24px 26px minmax(0,1fr) 152px}.table-heading{min-height:0}.table-announcement{line-height:18px}.action-section{gap:3px}.bet-presets button{font-size:12px}.bet-controls #bet-input{width:78px;font-size:21px}.all-in-button{min-width:58px}.table-stage .seat.self{--seat-y:calc(100% - 38px)}.table-stage .seat:not(.dense)[data-side=center]:not(.self){--seat-y:18%}.table-stage .seat:not(.dense)[data-middle=true]{--seat-y:65%}.poker-table{inset:30px 10px 38px}.table-stage .seat.self .hole-cards .card{width:34px;height:49px}.table-stage .seat.self .hole-cards .card-rank{font-size:19px}.table-stage .seat.self .hole-cards .card-suit-big{font-size:22px}}
@media(max-width:360px){.bet-controls{gap:4px 5px;padding:4px 6px}.bet-presets{gap:2px}.bet-presets button{min-width:25px;padding:3px 4px}.bet-controls #bet-input{width:73px}.all-in-button{min-width:56px}.prepare-actions label{font-size:0}.prepare-actions select{max-width:106px}.prepare-actions .button{padding:6px 8px;font-size:11px}.runout-panel p{font-size:10px}}
@media(max-height:480px) and (orientation:landscape){body[data-screen=table] .game-content,body[data-screen=table] .game-content:has(.online-table-info:not(.hidden)){grid-template-columns:minmax(0,1fr) 290px;grid-template-rows:40px minmax(0,1fr);grid-template-areas:'heading toolbar' 'table controls';gap:6px 15px}.table-announcement{grid-area:table;position:static;align-self:start;justify-self:center;left:auto;top:auto;width:90%;height:25px;z-index:4}.online-table-info{display:none}body[data-screen=table] .table-stage{grid-area:table;height:100%;margin:0;padding-top:0}.action-section{grid-area:controls;height:180px;align-self:center;grid-template-rows:18px 66px 44px 14px;gap:6px}.table-stage .seat.self{--seat-y:calc(100% - 34px)}.table-stage .seat:not(.self)[data-side=center]{--seat-y:23%}.table-stage .seat.dense[data-upper=true]{--seat-y:24%}.table-stage .seat.self .seat-action{display:none}.poker-table{inset:35px 10px 25px}.action-section .action-buttons .button{font-size:12px;padding:6px 3px}.phase-controls{grid-row:2/4}.table-stage .board-area{top:53%}}
@media(min-width:1101px) and (min-height:481px){.table-stage .seat.dense[data-middle=true]{--seat-y:57%}}
@media(max-width:540px) and (min-height:701px){.table-stage[data-seats="7"] .board-area{top:53%}}
@media(max-width:540px) and (max-height:700px){.table-stage .seat.self{--seat-y:calc(100% - 24px)}.table-stage .seat.self .seat-action{display:none}}
@media(max-width:540px) and (max-height:700px){.table-stage .seat:not(.dense)[data-side=center]:not(.self){--seat-y:14%}}
.online-table-info #turn-countdown.overdue{color:#c13e3e;font-weight:750;font-variant-numeric:tabular-nums}.seat.active.turn-overdue .player-pill{border-color:#cc5757;box-shadow:0 0 0 3px #cc57571a}.seat.turn-overdue .player-name{color:#b53f3f}.ready-members>span{display:inline-flex;align-items:center;gap:3px}.ready-members [data-remove-member],.remove-seat{color:#b6534a;font-size:12px;min-width:26px;min-height:26px;padding:2px 5px}.remove-seat{margin-left:auto;font-size:11px}.hand-records{margin:22px 0 12px;padding-top:12px;border-top:1px solid #e1e8d9}.records-heading{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:10px}.records-heading h3{margin:0;color:#4d6741;font-size:14px}.records-heading label{display:flex;align-items:center;gap:7px;color:#7b8c6f;font-size:11px}.records-heading select{max-width:185px;padding:7px 9px;border:1px solid #d6dfcc;border-radius:6px;background:transparent;color:#536e43;font-size:12px}.records-scroll{height:180px;min-height:180px;max-height:180px;overflow-y:auto;overflow-x:hidden;overscroll-behavior:contain;touch-action:pan-y;background:transparent;border:1px solid #dfe7d6;border-radius:8px;padding:9px 12px;scrollbar-gutter:stable;cursor:grab;user-select:none}.records-scroll.dragging{cursor:grabbing}.records-scroll ol{list-style:none;padding:0;margin:0}.records-scroll li{display:flex;align-items:flex-start;gap:10px;font-size:12px;line-height:1.8;padding:3px 0;overflow-wrap:anywhere;color:#74866a}.records-scroll .record-index{flex-shrink:0;width:23px;color:#a1ad96;font-size:10px;font-variant-numeric:tabular-nums}.records-scroll li.raise-record{font-weight:600;color:#3b6141}.records-scroll li.record-note{font-size:11px;color:#9aab8c}.seat.revealing .hole-cards .card{animation:reveal-hand .42s ease-out both}.seat.revealing .hole-cards .card+.card{animation-delay:.08s}@keyframes reveal-hand{from{transform:rotateY(-90deg);opacity:.25}to{transform:rotateY(0);opacity:1}}@media(prefers-reduced-motion:reduce){.seat.revealing .hole-cards .card{animation:none}}@media(max-width:540px){.records-scroll{height:160px;min-height:160px;max-height:160px;padding:8px 10px}.records-heading{gap:7px;flex-wrap:wrap}.records-heading select{font-size:16px;max-width:195px}.records-heading label{font-size:10px}.online-table-info #turn-countdown.overdue{font-size:10px}}
