/* MTG 2026-09-15: names and elapsed minutes own the sofa space. */
.room-scene .floor-seat-slot>.floor-cast.name-first{
 --cast-shade:#315f4e;display:flex!important;flex-direction:column!important;justify-content:center!important;align-items:stretch!important;gap:1px!important;padding:2px!important;
 background:#fff7f0!important;border:1px solid #bd977f!important;border-radius:6px;color:#683d23;overflow:visible;min-width:0;position:relative;
}
.room-scene .name-first .cast-name-large{font-size:clamp(12px,min(calc((100cqw - 9px)/var(--name-chars,3)),42cqh),27px);font-weight:900;line-height:1.12;text-align:center;white-space:normal;overflow-wrap:anywhere;margin:0;padding:0;background:none;color:inherit}
.room-scene .name-first>.timer{position:static!important;display:block;width:100%;max-width:none!important;padding:0!important;font-size:clamp(12px,min(28cqw,32cqh),23px)!important;line-height:1.1!important;font-weight:800;color:inherit!important;background:none!important;text-align:center;white-space:nowrap;font-variant-numeric:tabular-nums}
.room-scene .name-first.reserved,.room-scene .name-first.waiting,.room-scene .name-first.changeover{background:#f4f3efe6!important;border:1px dashed #aab1aa!important;color:#7c857d;animation:none!important}
.room-scene .name-first.cast-due,.room-scene .name-first.unattended-urgent{color:#81271c!important;animation:service-attention 1.4s ease-in-out infinite!important}
.room-scene .name-first.cast-soon{border:2px solid #d99828!important}
.name-seated-check{position:absolute;right:0;top:0;width:12px;height:12px;border-radius:50%;font-size:10px;line-height:12px;text-align:center;color:#fff;background:#20754f;font-style:normal}
.room-scene .name-first>.next-table-label{display:block;font-size:clamp(9px,19cqw,13px);line-height:1.05;white-space:nowrap;overflow:hidden;color:#426a58;font-weight:800;text-align:center}
.room-scene.room-detail .name-first .cast-name-large{font-size:clamp(20px,min(calc((100cqw - 10px)/var(--name-chars,3)),40cqh),38px)}
.room-scene.room-detail .name-first>.timer{font-size:clamp(18px,min(25cqw,30cqh),30px)!important}
.room-scene.room-detail .name-first>.next-table-label{font-size:15px}
.room-scene.room-vip .flow-vertical .name-first{gap:0!important;padding:0 2px!important}
.room-scene.room-vip .flow-vertical .name-first .cast-name-large{font-size:clamp(10px,min(calc((100cqw - 6px)/var(--name-chars,3)),48cqh),23px);line-height:1.02;white-space:nowrap}
.room-scene.room-vip .flow-vertical .name-first>.timer{font-size:clamp(10px,40cqh,17px)!important;line-height:1!important}
.room-scene.room-vip .flow-vertical .name-first:has(.next-table-label) .cast-name-large{font-size:clamp(10px,36cqh,17px)}
.room-scene.room-vip .flow-vertical .name-first:has(.next-table-label)>.timer{font-size:clamp(9px,28cqh,14px)!important}
.room-scene.room-vip .flow-vertical .name-first>.next-table-label{font-size:9px;line-height:1}
.cast-score,.score-value,.recommendation-score,.table-guest-points,.guest-score-summary,.live-score,.table-score,.seat-score{display:none!important}
.cast-card-head>.avatar,.recommendation-heading>.cast-visual,.replace-current>.cast-visual,.cast-route-current>.cast-visual,.cast-route-current>.avatar{display:none!important}
.cast-tile{--cast-shade:#315f4e!important}.cast-tile .cast-grip{width:24px!important;min-width:24px!important;font-size:23px;background:none!important}
.cast-tile .cast-pick{flex:1;padding:4px!important}.cast-tile .cast-pick strong{font-size:21px!important;line-height:1.15!important}
.dispatch-list .cast-tile{min-width:92px!important;max-width:155px!important}.dispatch-list .cast-pick{min-width:60px!important}
.cast-card h3,.replace-current strong,.cast-route-current strong{font-size:27px!important}.cast-card-head{gap:4px}
.recommendation-heading strong{font-size:25px!important}.recommendation-heading{justify-content:center}
.recommendation-reasons{font-size:13px!important}.replace-current{gap:8px}.replace-current .timer{font-size:28px!important}
.score-editor-list{display:grid;gap:9px}.score-editor-row{display:grid;grid-template-columns:1fr 85px 75px;gap:12px;align-items:center;padding:8px;border-bottom:1px solid #e2e5df}.score-editor-row strong{font-size:24px}.score-editor-row input{font-size:25px;min-height:48px;width:100%;text-align:center}
.history-total{display:flex;align-items:center;gap:18px;margin-bottom:15px}.history-total strong{font-size:40px}.history-total small{font-size:18px}
.table-history-rows{display:grid;gap:9px}.table-history-rows article{display:grid;grid-template-columns:1fr auto;gap:3px 10px;border-bottom:1px solid #ddd;padding:10px 0}.table-history-rows strong{font-size:23px}.table-history-rows article small{grid-column:1;min-width:0}.table-history-rows article>b{grid-column:2;grid-row:1/4;align-self:center;font-size:24px}
#modal.score-screen,#modal.table-history-screen{width:min(720px,calc(100vw - 24px))}.score-screen .modal-body,.table-history-screen .modal-body{overflow:auto!important}
@media(prefers-reduced-motion:reduce){.room-scene .name-first.cast-due,.room-scene .name-first.unattended-urgent{animation:none!important;outline:3px solid #bd402b}}
/* On a phone the floor is selected by table, with one readable room at a time. */
.phone-table-picker{display:none}
@media(max-width:699px){
 html,body,#app{height:auto!important;min-height:100dvh;overflow:auto!important}.app-shell{display:block!important;min-height:100dvh}.rail{width:100%!important;height:52px!important;position:sticky!important;top:0;z-index:12;display:flex!important;align-items:center;padding:0 10px!important}.rail>.brand{font-size:24px;width:36px;height:36px;margin:0 12px 0 0!important}.rail nav{display:flex!important;flex:1;justify-content:space-around;gap:4px}.rail .nav-item{min-height:46px!important;width:auto!important;display:flex;gap:5px;padding:5px!important;font-size:14px}.rail .nav-item svg{width:19px}.main-shell{width:100%!important;margin:0!important;min-width:0}.topbar{height:44px!important;padding:4px 12px!important}.topbar .wordmark{font-size:17px}.topbar .connection{display:none}.top-actions{gap:10px}.clock-display{font-size:24px!important}.topbar .icon-btn{width:38px!important;height:36px!important}
 .operations-workspace{height:auto!important;padding:7px!important;overflow:visible!important}.operations-layout{display:flex!important;flex-direction:column!important;gap:10px!important;height:auto!important}.operations-main{height:auto!important;min-height:0!important;overflow:visible!important}.live-floor-map{display:block!important;height:auto!important;max-height:none!important;min-height:0!important;padding:8px!important;aspect-ratio:auto!important;overflow:visible!important}.live-aisle{display:none!important}.live-booth{display:none!important;position:relative!important;height:410px!important;width:100%!important;margin:0!important}.live-booth.phone-selected{display:block!important}.live-booth.vip-booth{height:680px!important}.room-scene{height:100%!important}.phone-table-picker{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:5px;margin-bottom:8px}.phone-table-picker button{min-height:49px;border:1px solid #d6d9d0;border-radius:7px;background:#f1f1e9;font-size:18px;font-weight:800;color:#657268}.phone-table-picker .occupied{background:#f4d8bd;color:#693d22}.phone-table-picker .selected{outline:3px solid #477760}.phone-table-picker button small{display:block;font-size:11px;line-height:1.1}
 .central-console{position:static!important;width:100%!important;min-height:155px!important;height:auto!important;max-height:none!important;padding:10px!important;display:flex!important;flex-direction:column!important;margin:0!important}.console-summary{order:0}.console-controls{display:flex!important;flex-wrap:wrap;gap:6px}.roster-tabs{width:100%;display:grid!important;grid-template-columns:1.2fr 1fr 1fr}.roster-tabs>button{font-size:19px!important;min-height:50px!important;padding:6px!important}.console-controls .cast-search{width:100%!important;margin:0}.console-roster{height:auto!important;min-height:50px;max-height:225px;overflow:auto}.dispatch-list{display:grid!important;grid-template-columns:repeat(3,minmax(0,1fr));width:100%!important;overflow:visible!important}.dispatch-list .cast-tile{min-width:0!important;width:100%!important;height:52px!important}.floor-summary{gap:12px!important;justify-content:center;flex-wrap:wrap}.floor-count strong{font-size:30px!important}.floor-count span{font-size:12px!important}.serving-count{font-size:12px}.live-floor-legend{display:none!important}
 #modal{width:calc(100vw - 12px)!important;max-height:calc(100dvh - 12px)!important;margin:6px auto!important}.modal-heading{padding:10px!important}.modal-heading h2{font-size:21px!important}.modal-heading .modal-back{min-height:44px!important;font-size:16px!important;padding:6px 10px!important}.modal-body{padding:10px!important;overflow:auto!important}.modal-footer{padding:8px!important;flex-wrap:wrap}.modal-footer .btn{min-height:46px!important;font-size:17px!important}
 #modal.table-screen .table-screen-layout{display:flex!important;flex-direction:column!important;gap:12px}.table-screen-floor{width:100%!important;min-height:390px!important;max-height:none!important}.table-detail-map{height:400px!important}.table-screen-floor:has(.room-vip) .table-detail-map{height:650px!important}.table-screen-guests{width:100%!important}.table-guest-cards{display:grid!important;grid-template-columns:1fr!important}.table-screen .live-table-actions{display:grid;grid-template-columns:repeat(2,1fr)}.cast-action-layout{display:flex;flex-direction:column}.quick-moves{width:100%;padding:0}.quick-move-grid{grid-template-columns:repeat(3,minmax(0,1fr))}#modal.cast-actions-screen .replace-options{grid-template-columns:repeat(2,minmax(0,1fr))}.guest-screen .service-rounds{display:grid;grid-template-columns:1fr}.guest-screen .live-profile-fields{display:grid;grid-template-columns:1fr}.guest-screen .live-guest-actions{display:flex;flex-wrap:wrap;gap:6px}
 #modal.quick-intake-modal .quick-intake-rows{display:flex!important;flex-direction:column;gap:8px!important;height:auto!important}#modal.quick-intake-modal .quick-person{display:grid!important;grid-template-columns:44px 1fr 44px!important;grid-template-rows:auto!important;gap:7px!important;padding:10px!important;min-height:210px!important}#modal.quick-intake-modal .quick-person[hidden]{display:none!important}.quick-person-heading{grid-area:1/1!important}.quick-type{grid-area:1/2!important;display:flex!important}.quick-type button{flex:1;min-height:46px!important;font-size:20px!important}.quick-remove{grid-area:1/3!important}.quick-cast{grid-area:2/1/3/4!important;min-height:44px}.quick-colors{grid-area:3/1/4/4!important;display:flex!important;gap:6px}.quick-feature{grid-area:4/1/5/4!important;min-height:44px!important}.quick-customer{grid-area:5/1/6/4!important;min-height:42px!important}.quick-label{grid-area:6/1/7/4!important}.quick-note{grid-area:7/1/8/4!important}.intake-header-actions .intake-add-top{display:none!important}.intake-header-actions .intake-save-top{font-size:17px!important;min-height:44px!important}.intake-add-row{min-height:60px!important}.intake-add-under{width:100%!important;min-height:58px!important;font-size:24px!important}.intake-context{display:flex;flex-wrap:wrap;gap:5px}.intake-paging{margin-left:auto}
 .cast-grid,.customer-layout,.settings-grid,.more-menu{grid-template-columns:1fr!important}.cast-card{padding:14px!important}.page-title{padding:12px!important;display:flex;flex-wrap:wrap}.customer-list{overflow:hidden}.customer-row{padding:8px!important;gap:5px!important}.customer-row>div{min-width:0}.customer-row strong{font-size:18px}.score-editor-row{grid-template-columns:1fr 70px 65px;gap:7px}.score-editor-row strong{font-size:22px}
}
.guest-helmet{font-size:min(45px,80cqw);line-height:1;align-self:center;color:#b98a28}.unattended-table-alert{display:none!important}

/* Minutes remain legible even on the narrow seats at the bottom of VIP. */
.name-first [data-minute-clock]::after{content:'分';font-size:.6em;margin-left:1px}
.room-vip:not(.room-detail) .flow-horizontal .name-first [data-minute-clock]::after{display:block;margin:0;line-height:1.05}
.room-scene .name-first>.next-table-label{flex-shrink:0}
@media(max-width:699px){
 .topbar .clock-display{display:block!important;font-size:25px!important;line-height:32px;min-width:68px}
 .operations-workspace:has(.live-floor-map) .central-console{order:-1!important;min-height:0!important;transform:none!important}
 .operations-workspace:has(.live-floor-map) .central-console .console-controls{height:auto!important;flex-wrap:wrap!important}
 .operations-workspace:has(.live-floor-map) .central-console .console-roster{flex:none;max-height:118px!important;min-height:0!important}
 .operations-workspace:has(.live-floor-map) .central-console .roster-tabs{display:grid!important;width:100%;grid-template-columns:1.2fr 1fr 1fr}
 .operations-workspace:has(.live-floor-map) .central-console .roster-tabs button{min-width:0!important}
 .operations-workspace:has(.live-floor-map) .central-console.customer-mode .cast-search{display:none!important}
 .operations-workspace:has(.live-floor-map) .central-console .roster-idle{display:none}
 #modal.table-screen .table-screen-floor{display:block!important;min-height:0!important;flex:none!important}
 #modal.table-screen .table-detail-map{flex:none!important;height:400px!important;min-height:400px!important}
 #modal.table-screen .table-detail-map>.room-scene{height:376px!important;min-height:376px!important}
 #modal.table-screen .table-detail-map:has(.room-vip){height:650px!important;min-height:650px!important}
 #modal.table-screen .table-detail-map>.room-vip{height:626px!important;min-height:626px!important}
 .quick-person .quick-cast:has(select:disabled){display:none!important;min-height:0!important}
}

@media(max-width:699px){.quick-person .quick-cast:disabled{display:none!important;min-height:0!important}}

.room-scene.room-vip:not(.room-detail) .floor-seat-pair.flow-horizontal{gap:2px!important}
.room-scene.room-vip:not(.room-detail) .flow-horizontal .floor-cast.name-first{padding:0!important}
.room-scene .flow-vertical .floor-cast.name-first:has(.next-table-label){display:grid!important;grid-template-columns:minmax(0,1fr) minmax(0,1fr)!important;grid-template-rows:auto auto!important;gap:0!important;align-content:center!important;align-items:center!important}
.room-scene .flow-vertical .name-first:has(.next-table-label) .cast-name-large{grid-column:1/-1;font-size:clamp(10px,min(calc((100cqw - 9px)/var(--name-chars,3)),44cqh),25px);line-height:1.1}
.room-scene .flow-vertical .name-first:has(.next-table-label)>.timer{grid-column:1;font-size:clamp(10px,24cqw,19px)!important}
.room-scene .flow-vertical .name-first:has(.next-table-label)>.next-table-label{grid-column:2;font-size:clamp(9px,19cqw,15px);line-height:1.1}
#modal.table-history-screen{width:min(980px,calc(100vw - 24px))}
.history-toolbar{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:12px}
.history-toolbar>p{font-size:18px;margin:0}.history-toolbar>.btn{min-height:44px}
.history-customers{display:grid;gap:14px}
.history-customer{border:1px solid #c8d2c9;border-radius:10px;overflow:hidden;background:#fffdf7}
.history-customer>header{display:flex;align-items:baseline;flex-wrap:wrap;gap:4px 14px;padding:10px 14px;background:#fff0dc;color:#643514}
.history-customer>header>strong{font-size:24px;line-height:1.3}.history-customer>header>span{font-size:16px;overflow-wrap:anywhere}.history-customer>header>small{margin-left:auto;font-size:15px;white-space:nowrap}
.history-rotations{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px;padding:12px}
.history-rotation{min-width:0;border:1px solid #d6e0d7;border-radius:7px;background:#f5f8f2;padding:8px 12px}
.history-rotation h3{margin:0 0 6px;font-size:17px;color:#496752;line-height:1.4}
.history-rotation article{display:grid;gap:4px;min-width:0}.history-rotation article+article{margin-top:12px;padding-top:10px;border-top:1px solid #cad6cc}
.history-rotation article>b{font-size:26px;line-height:1.3;color:#20482d;overflow-wrap:anywhere}
.history-rotation time{font-size:17px;font-weight:650;font-variant-numeric:tabular-nums;white-space:nowrap;color:#273e33}
.history-rotation article>span,.history-rotation article>em{font-size:14px;color:#51675a;font-style:normal}
.history-change-note{font-size:14px;overflow-wrap:anywhere}.history-private-score{font-size:16px}
.history-pages{display:flex;align-items:center;gap:8px;flex:1;flex-wrap:wrap}.history-pages>.btn{min-height:44px}
.room-scene .live-stay>.table-round-label{font:700 12px/16px system-ui;color:#3c5144;letter-spacing:0;white-space:nowrap;display:block}
.room-scene.room-detail .live-stay>.table-round-label{font-size:16px;line-height:20px}
@media(max-width:699px){.history-rotations{grid-template-columns:1fr;padding:8px;gap:8px}.history-rotation{display:grid;grid-template-columns:76px minmax(0,1fr);gap:8px}.history-rotation article{grid-column:2}.history-rotation h3{font-size:16px}.history-rotation article>b{font-size:24px}.history-customer>header{padding:8px 10px}.history-customer>header>small{margin-left:0;width:100%}.history-toolbar{flex-wrap:wrap}}
