/*943: stable controls and a room menu that overlays without resizing the game.*/
#poker943Tools{display:inline-flex;gap:4px;align-items:center;min-width:0}
#poker943Tools button{font:600 11px/16px Arial;min-height:24px;padding:2px 7px;border:1px solid #627581;border-radius:5px;background:#183441;color:#eff5f7;white-space:nowrap}
#poker943Tools button:disabled{background:#25323a;color:#aab7be;opacity:1!important;cursor:default}
#poker943Tools button[hidden]{display:none!important}
#poker943Back{background:#08766e!important;color:white!important;border:2px solid #6ad9ce!important}
#poker943Dialog{background:#10242d;color:#f3f6f7;border:1px solid #d8b967;border-radius:12px;max-width:min(380px,88vw);padding:20px}
#poker943Dialog::backdrop{background:#0009}
#poker943Dialog label{display:flex;gap:10px;align-items:center;margin:16px 0}#poker943Dialog input{width:20px;height:20px}
#poker943Dialog p{font:13px/1.5 system-ui;color:#c3d0d7}
#view-table #pbb-actions #actionBar .poker-action-slot>label{opacity:1!important;color:#e2e9ed!important;visibility:visible!important}
#view-table #pbb-actions #actionBar .poker-action-slot>label:has(input:disabled){color:#aab7be!important;opacity:1!important}
#view-table #pbb-actions #actionBar input[type=checkbox],#view-table #preactionPersistent input{appearance:auto!important;opacity:1!important;accent-color:#d4b568;outline:1px solid #879aa5;outline-offset:-1px}
#view-table .pbb-v3 label:has(input:checked){color:#ffe397!important}
#view-table #pbb-log-host{overflow-y:auto!important;min-height:0;flex:1}
#view-table #preactionPersistent label{opacity:1!important;color:#d9e3e8!important}
@media(max-width:600px) and (orientation:portrait){
 body[data-usa-client].usa-menu-open #view-desktop .desk-menubar{height:48px!important;min-height:48px!important;flex:0 0 48px!important;flex-wrap:nowrap!important}
 body[data-usa-client].usa-menu-open #view-desktop .desk-menu{position:absolute!important;top:52px!important;right:8px!important;left:auto!important;width:min(300px,calc(100vw - 16px))!important;display:flex!important;flex-direction:column!important;align-items:stretch!important;gap:4px!important;padding:10px!important;background:#102730!important;border:1px solid #b89b5b!important;border-radius:12px!important;box-shadow:0 10px 40px #000b!important;z-index:2000002!important}
 body[data-usa-client].usa-menu-open #view-desktop .desk-menu>.desk-menu-btn{width:100%!important;text-align:left!important;min-height:40px!important;font-size:14px!important}
 body[data-usa-client].usa-menu-open #view-desktop .desk-user{display:none!important}
 #poker943Tools{gap:2px}#poker943Tools button{font-size:10px;padding:2px 4px}
 #view-table #pbb-actions #actionBar .poker-action-slot>label{font-size:9px!important;line-height:11px!important;min-width:0;white-space:normal!important}
}

body[data-usa-client] #view-table #poker943Tools button[hidden]{display:none!important}
#usaTurn,#pbb-readout{position:relative}
#poker943Tools{position:absolute;right:0;top:0;z-index:3}
body[data-usa-client] #view-table #poker943Tools button{height:22px!important;min-height:22px!important;max-height:22px!important;font:600 10px/16px Arial!important;padding:1px 4px!important}

body[data-usa-client] #view-table .pbb-v3 #usaTurn{position:relative!important;width:100%!important;min-height:22px!important;max-height:22px!important;box-sizing:border-box}
body[data-usa-client] #view-table .pbb-v3 #poker943Tools button:disabled{opacity:1!important;color:#aab7be!important;background:#25323a!important;filter:none!important}

body[data-usa-client] #view-table .pbb-v3 #usaTurn{left:0!important;top:0!important;right:auto!important;bottom:auto!important;max-width:none!important;width:100%!important;margin:0!important;transform:none!important;text-align:left!important}
body:not([data-usa-client]) #view-table #actionBar .poker-action-slot{display:grid!important;grid-template-rows:44px 36px!important;gap:4px!important;min-width:0!important}
body:not([data-usa-client]) #view-table #actionBar .poker-action-slot>label{font:16px/18px Arial!important;display:flex!important;align-items:center!important;gap:5px!important;white-space:normal!important;margin:0!important;padding:0!important}
body:not([data-usa-client]) #view-table #actionBar .poker-action-slot>button{height:44px!important;margin:0!important}
body:not([data-usa-client]) #view-table #actionBar .poker-action-slot>button:disabled{color:#bdc9d0!important;background:#28353c!important;opacity:1!important}

#poker943Back[hidden],#poker943Post[hidden],#poker943Bank[hidden]{display:none!important}
body[data-usa-client] #view-table .usa-seat-tools #poker943Back[hidden],body[data-usa-client] #view-table .usa-seat-tools #poker943Post[hidden]{display:none!important}
@media(max-width:600px) and (orientation:portrait){
 body[data-usa-client][data-usa-controls] #view-table .usa-mobile-tools button{flex:1 1 0!important;width:auto!important;min-width:0!important;font-size:10px!important;white-space:nowrap!important}
 body[data-usa-client][data-usa-controls] #view-table .usa-mobile-tools #poker943Prefs{flex:0 0 24px!important}
 body[data-usa-client][data-usa-controls] #view-table .usa-mobile-tools #poker943Bank{flex:1.3 1 0!important;color:#ffdd8a!important}
 body[data-usa-client][data-usa-controls] #view-table .usa-mobile-tools #poker943Bank:disabled{color:#aab7be!important;opacity:1!important}
}

/*949: account/table opt-in; hiding UI never changes server chat permissions.*/
body[data-usa-client].poker943-callouts-off #view-table .pbb-v3>.z-right,
body[data-usa-client].poker943-callouts-off #view-table .usa-quick{display:none!important}
@media(min-width:601px),(orientation:landscape){
 body[data-usa-client].poker943-callouts-off.usa929-bottom #view-table .pbb-v3{grid-template-columns:minmax(0,38fr) minmax(0,62fr)!important}
 body[data-usa-client].poker943-callouts-off:not(.usa929-bottom) #view-table .pbb-v3{grid-template-rows:auto auto minmax(0,1fr)!important}
}
@media(max-width:600px) and (orientation:portrait){
 body[data-usa-client][data-usa-controls].poker943-callouts-off #view-table .pbb-v3{grid-template-rows:156px 28px!important;height:calc(204px + var(--usa-safe-bottom))!important;min-height:calc(204px + var(--usa-safe-bottom))!important;max-height:calc(204px + var(--usa-safe-bottom))!important;flex-basis:calc(204px + var(--usa-safe-bottom))!important}
 body[data-usa-client][data-usa-controls].poker943-callouts-off #view-table .usa-mobile-tools{grid-row:2!important}
}

body[data-usa-client] #poker943Config{flex:0 0 21px;min-height:21px;box-sizing:border-box;background:#10242d;color:#dbcba9;font:600 11px/21px Arial;padding:0 8px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;border-bottom:1px solid #314851}
body[data-usa-client] #view-table .pbb-v3 #pbb-readout:has(#poker943Tools){padding-right:145px!important}

/* Chips and position markers are twenty percent larger; editor size is relative. */
body[data-usa-client] #view-table .seat .bet-chip,
body[data-usa-client] #view-table .seat .role,
body[data-usa-client] #view-table #potDisplayWrap .pot-chips,
body[data-usa-client] #view-table .winner-chip-flight .pot-chips{scale:1.2!important;transform-origin:center center!important}
body[data-usa-client] #view-table .seat .bet-chip.usa-card-adjusted,
body[data-usa-client] #view-table .seat .role.usa-card-adjusted,
body[data-usa-client] #view-table #potDisplayWrap .pot-chips.usa-card-adjusted{scale:calc(1.2 * var(--uce-size,1))!important;translate:var(--uce-x,0px) var(--uce-y,0px)!important}
body.usa-card-editing #view-table .bet-chip,body.usa-card-editing #view-table .role,body.usa-card-editing #view-table .pot-chips{touch-action:none!important;cursor:move!important}

@media(max-width:600px) and (orientation:portrait){
 body[data-usa-client][data-usa-controls] #view-table .pbb-v3{grid-template-rows:168px 48px 28px!important;height:calc(268px + var(--usa-safe-bottom))!important;min-height:calc(268px + var(--usa-safe-bottom))!important;max-height:calc(268px + var(--usa-safe-bottom))!important;flex-basis:calc(268px + var(--usa-safe-bottom))!important}
 body[data-usa-client][data-usa-controls] #view-table .pbb-v3>.z-ctr{grid-template-rows:40px 88px 32px!important;height:168px!important;min-height:168px!important;max-height:168px!important}
 body[data-usa-client][data-usa-controls] #view-table #pbb-actions,body[data-usa-client][data-usa-controls] #view-table #actionBar{height:88px!important;min-height:88px!important}
 body[data-usa-client][data-usa-controls] #view-table #actionBar .poker-action-slot{grid-template-rows:42px 42px!important;height:88px!important}
 body[data-usa-client][data-usa-controls] #view-table #actionBar .poker-action-slot>label{font-size:11px!important;line-height:12px!important;height:42px!important;white-space:normal!important}
 body[data-usa-client][data-usa-controls].poker943-callouts-off #view-table .pbb-v3{grid-template-rows:168px 28px!important;height:calc(216px + var(--usa-safe-bottom))!important;min-height:calc(216px + var(--usa-safe-bottom))!important;max-height:calc(216px + var(--usa-safe-bottom))!important;flex-basis:calc(216px + var(--usa-safe-bottom))!important}
}

#poker943AdminSection{display:none}
@media(max-width:600px), (max-height:500px) and (pointer:coarse){
 #adminModalBackdrop .poker-admin-panel{width:calc(100vw - 16px)!important;max-height:calc(100dvh - 16px)!important;min-width:0!important;font-size:14px!important}
 #adminModalBackdrop .poker-admin-heading{flex:none!important;padding:10px!important;gap:8px!important}
 #adminModalBackdrop .poker-admin-heading>div{display:flex;align-items:center;gap:6px}
 #adminModalBackdrop #adminPanelStatus{font-size:12px!important;margin:0!important;max-width:130px}
 #adminModalBackdrop .poker-admin-tabs{display:none!important}
 #poker943AdminSection{display:block;margin:8px 10px;padding:10px;min-height:42px;color:#f2e5c5;background:#193440;border:1px solid #768472;border-radius:5px;font:600 14px Arial;flex:none}
 #adminBody{padding:10px!important;overflow:auto!important;overscroll-behavior:contain;min-width:0!important}
 #adminBody input:not([type=checkbox]),#adminBody select{min-height:40px!important;font-size:16px!important;min-width:0!important;max-width:100%!important;box-sizing:border-box}
 #adminBody button,#adminClose{min-height:38px!important;padding:6px 9px!important;font-size:12px!important;max-width:100%;white-space:normal!important}
 #adminBody table,#adminBody tbody{display:block!important;width:100%!important}
 #adminBody thead{display:none!important}
 #adminBody tbody tr{display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;border:1px solid #45606c!important;border-radius:7px;padding:10px;margin:8px 0;background:#102b32}
 #adminBody td{display:block!important;padding:0!important;min-width:0!important;font-size:13px!important;text-align:left!important;overflow-wrap:anywhere}
 #adminBody td:before{content:attr(data-label);display:block;color:#a9bbc3;font:600 10px/16px Arial;text-transform:uppercase}
 #adminBody td:last-child{grid-column:1/-1}
 #adminBody .adm-act-btn{margin:3px!important;font-size:12px!important}
}

/* Give the activity log the space not needed by the hand summary. */
@media(min-width:601px),(orientation:landscape){
 body[data-usa-client].usa929-bottom #view-table #usaHandSummary{height:auto!important;min-height:28px!important;max-height:50px!important;padding-bottom:3px!important}
 body[data-usa-client] #view-table #pbb-log-host{overflow-y:auto!important;max-height:none!important}
}

@media(min-width:601px),(orientation:landscape){
 body[data-usa-client][data-usa-controls=left] #view-table .pbb-v3 #pbb-readout{height:44px!important;min-height:44px!important;max-height:44px!important;flex:0 0 44px!important;position:relative!important;top:auto!important;left:auto!important;transform:none!important;margin:0!important}
}
@media(max-height:500px) and (orientation:landscape){
 body[data-usa-client][data-usa-controls=left] #view-table .pbb-v3 #pbb-readout{height:44px!important;min-height:44px!important;max-height:44px!important;flex:0 0 44px!important;padding:22px 0 0!important;line-height:11px!important}
 body[data-usa-client] #view-table .pbb-v3>.z-ctr{height:auto!important;min-height:0!important;flex:none!important;gap:3px!important}
 body[data-usa-client] #view-table .pbb-v3>.z-left{display:flex!important;flex-direction:column!important;flex:1!important;min-height:30px!important;padding-top:0!important;gap:2px!important}
 body[data-usa-client] #view-table #pbb-log-host{display:block!important;flex:1!important;min-height:12px!important;max-height:none!important;overflow-y:auto!important;font:11px/14px Arial!important}
 body[data-usa-client] #view-table .pbb-v3 .usa-sidebar-subtitle{display:none!important}
 body[data-usa-client] #view-table .pbb-v3 .usa-game-heading{min-height:24px!important;height:26px!important;padding-bottom:0!important}
}

/* Compact bottom dock for tiled and short desktop table windows. Fixed action slots stay readable. */
@media(min-width:601px) and (max-height:740px){
 body[data-usa-client].usa929-bottom #view-table .table-panel{grid-template-rows:minmax(0,1fr) 104px!important}
 body[data-usa-client].usa929-bottom #view-table .pbb-v3{grid-template-rows:20px minmax(0,1fr) 22px!important;padding:4px 8px!important;gap:2px 8px!important}
 body[data-usa-client].usa929-bottom.poker943-callouts-off #view-table .pbb-v3{grid-template-columns:minmax(0,28fr) minmax(0,72fr)!important}
 body[data-usa-client].usa929-bottom #view-table .poker-control-heading,
 body[data-usa-client].usa929-bottom #view-table .poker-control-position,
 body[data-usa-client].usa929-bottom #view-table .poker-control-position button{height:20px!important;min-height:20px!important;font-size:11px!important}
 body[data-usa-client].usa929-bottom #view-table .pbb-v3>.z-ctr{gap:2px!important;padding-left:8px!important}
 body[data-usa-client].usa929-bottom #view-table #pbb-readout{height:18px!important;min-height:18px!important;max-height:18px!important;font-size:10px!important;line-height:18px!important}
 body[data-usa-client].usa929-bottom #view-table #pbb-actions,
 body[data-usa-client].usa929-bottom #view-table #actionBar,
 body[data-usa-client].usa929-bottom #view-table #actionBar .poker-action-slot{height:50px!important;min-height:50px!important}
 body[data-usa-client].usa929-bottom #view-table #actionBar{gap:5px!important}
 body[data-usa-client].usa929-bottom #view-table #actionBar .poker-action-slot{grid-template-rows:28px 20px!important;gap:2px!important}
 body[data-usa-client].usa929-bottom #view-table #actionBar .poker-action-slot>button{height:28px!important;min-height:28px!important;font:700 11px/12px Arial!important;padding:1px 3px!important}
 body[data-usa-client].usa929-bottom #view-table #actionBar .poker-action-slot>label{height:20px!important;min-height:20px!important;font:10px/10px Arial!important;gap:4px!important}
 body[data-usa-client].usa929-bottom #view-table #actionBar input,
 body[data-usa-client].usa929-bottom #view-table #preactionPersistent input{width:14px!important;height:14px!important;flex:0 0 14px!important}
 body[data-usa-client].usa929-bottom #view-table #preactionPersistent{padding-top:0!important;gap:4px!important}
 body[data-usa-client].usa929-bottom #view-table #preactionPersistent label{min-height:20px!important;font:10px/11px Arial!important}
 body[data-usa-client].usa929-bottom #view-table .pbb-v3>.z-left{gap:2px!important}
 body[data-usa-client].usa929-bottom #view-table #usaHandSummary{min-height:22px!important;max-height:26px!important;font:10px/11px Arial!important;padding-bottom:1px!important}
 body[data-usa-client].usa929-bottom #view-table .z-title{height:14px!important;min-height:14px!important;font:600 10px/14px Arial!important}
 body[data-usa-client].usa929-bottom #view-table #pbb-log-host{display:block!important;min-height:12px!important;overflow-y:auto!important;font:10px/12px Arial!important;padding:2px!important}
 body[data-usa-client].usa929-bottom #view-table .pbb-v3>.z-right{gap:2px!important;padding-left:8px!important}
 body[data-usa-client].usa929-bottom #view-table #pbb-phrases{grid-template-rows:22px 22px!important;gap:2px!important}
 body[data-usa-client].usa929-bottom #view-table #pbb-phrases button{height:22px!important;min-height:22px!important;font:10px/12px Arial!important}
 body[data-usa-client].usa929-bottom #view-table .z-in,
 body[data-usa-client].usa929-bottom #view-table .z-in input,
 body[data-usa-client].usa929-bottom #view-table .z-in button{height:24px!important;min-height:24px!important;font-size:10px!important}
}
