/* One floor geometry at PC/iPad sizes, in both orientations. */
@media (min-width:700px) {
 .operations-workspace:has(.live-floor-map){height:100dvh!important;padding:6px 8px 4px!important}
 .operations-workspace:has(.live-floor-map) .operations-layout{display:flex!important;flex-direction:column!important;height:100%!important;min-height:0!important;gap:0!important}
 .operations-workspace:has(.live-floor-map) .operations-main{flex:1!important;height:100%!important;min-height:0!important;overflow:hidden!important}
 .operations-workspace .live-floor-map.photo-floor{display:grid!important;flex:1!important;min-height:0!important;height:auto!important;max-height:none!important;aspect-ratio:auto!important;grid-template-columns:repeat(4,minmax(0,1fr)) minmax(174px,1.5fr)!important;grid-template-rows:minmax(0,1fr) 146px minmax(0,1fr)!important;gap:6px!important;padding:6px!important}
 .live-aisle.roster-docked{grid-area:2/1/3/5!important;display:block!important;min-width:0;padding:0!important}
 .live-aisle.roster-docked>span,.live-aisle.roster-docked>small{display:none!important}
 .operations-workspace:has(.live-floor-map) .dispatch-panel.roster-inside{position:static!important;inset:auto!important;transform:none!important;width:100%!important;margin:0!important;order:0!important;border-radius:12px}
 .operations-workspace:has(.live-floor-map) .compact-console .console-controls{grid-template-columns:minmax(124px,.65fr) minmax(160px,.9fr) minmax(194px,1.15fr)!important;gap:5px!important}
 .compact-console .console-left{grid-template-columns:56px minmax(0,1fr)!important;gap:4px!important}
 .operations-workspace:has(.live-floor-map) .compact-console .roster-tabs .console-arrival{width:56px!important;font-size:21px!important}
 .compact-console .cast-metrics{grid-template-columns:minmax(88px,1.6fr) repeat(2,minmax(32px,1fr))!important;gap:2px!important}
 .compact-console .cast-metrics .metric-label{font-size:clamp(14px,1.5vw,18px)!important;white-space:nowrap}
 .compact-console .cast-metrics .metric-value b{font-size:26px!important}
 .compact-console .roster-label{font-size:16px!important;white-space:nowrap}
 .compact-console .console-clock{width:100%!important;min-width:0!important;grid-template-columns:28% minmax(0,1fr)!important;gap:1px!important}
 .compact-console .console-clock .clock-face{width:100%!important;height:auto!important;max-height:64px!important;min-width:0!important}
 .compact-console .console-clock time{font-size:clamp(29px,19cqw,42px)!important;letter-spacing:-.055em}
 .compact-console .console-clock [data-clock-date]{font-size:clamp(15px,9cqw,20px)!important}
 .phone-table-picker{display:none!important}
}

/* The cushions do not grow with text. Fit whole names, never arbitrary wraps. */
:is(#app,#modal) .room-scene .floor-seat-slot>.floor-cast.name-first{position:relative!important;display:flex!important;flex-direction:column!important;align-items:center!important;justify-content:center!important;gap:1px!important;min-width:0!important;min-height:0!important;grid-template:none!important}
:is(#app,#modal) .room-scene .floor-seat-slot>.floor-cast.name-first .cast-name-large{font-size:var(--fit-name,16px)!important;line-height:1!important;white-space:nowrap!important;overflow-wrap:normal!important;word-break:keep-all!important;writing-mode:horizontal-tb!important;text-orientation:upright;letter-spacing:0!important;width:auto!important;max-width:100%!important;margin:0!important;flex:none!important}
:is(#app,#modal) .room-scene .floor-seat-slot>.floor-cast.name-first.fit-vertical .cast-name-large{writing-mode:vertical-rl!important;align-self:flex-start!important;margin-left:2px!important}
:is(#app,#modal) .room-scene .floor-cast .cast-time-check{flex:none!important;display:flex!important;flex-direction:row!important;gap:2px!important;align-items:center!important;justify-content:center!important;min-height:0!important;width:100%!important}
:is(#app,#modal) .room-scene .floor-cast .name-seated-check{flex:none!important;width:var(--fit-check,18px)!important;height:var(--fit-check,18px)!important;font-size:calc(var(--fit-check,18px) - 3px)!important;border-width:1.5px!important}
:is(#app,#modal) .room-scene .floor-cast.fit-vertical .name-seated-check{position:absolute!important;right:1px!important;top:2px!important}
:is(#app,#modal) .room-scene .floor-cast .cast-time-check>.timer{font-size:var(--fit-timer,15px)!important;line-height:1.1!important;white-space:nowrap!important;font-variant-numeric:tabular-nums}
.room-scene .floor-cast .next-table-label{position:static!important;font-size:var(--fit-route,11px)!important;line-height:1.1!important;white-space:nowrap!important;flex:none!important}
.room-scene .floor-cast [data-minute-clock]::after{display:inline!important;font-size:.65em!important;margin-left:1px!important}
.room-scene:not(.room-detail) .floor-seat-slot>.floor-customer{--portrait-w:clamp(15px,42cqw,28px);--portrait-h:clamp(20px,46cqh,40px);gap:1px!important;padding:1px!important;align-content:center!important;grid-template-rows:var(--portrait-h) auto!important}
.room-scene:not(.room-detail) .floor-seat-slot>.floor-customer .floor-person-copy>b{font-size:var(--fit-caption,14px)!important;line-height:1.1!important;white-space:nowrap!important;padding:1px!important;max-width:100%}
.room-scene:not(.room-detail) .floor-customer.fit-compact{display:flex!important;flex-direction:column!important;justify-content:center!important}
.room-scene:not(.room-detail) .floor-customer.fit-compact .floor-portrait{display:none!important}
.room-scene:not(.room-detail) .floor-customer.fit-compact:has(.floor-main-star)::before{content:'★';position:absolute;top:-7px;left:-4px;color:#754400;background:#ffda4b;border-radius:3px;font-size:15px;line-height:18px}
.room-scene.room-corner:not(.room-detail) .floor-seat-pair.seat-bottom{top:64%!important;height:34%!important}
.room-scene:not(.room-detail) .live-table-core .table-round-label{white-space:nowrap!important;font-size:clamp(12px,25cqw,19px)!important}
.room-scene:not(.room-detail) .live-table-core .live-stay b{font-size:clamp(17px,34cqw,28px)!important}
.room-scene:not(.room-detail) .live-table-core .guest-count-label{font-size:clamp(10px,24cqw,12px)!important}
.room-scene:not(.room-detail) .live-table-core .room-headcount b{font-size:20px!important}

/* Phone is an action surface; it does not shrink a nine-table floor map. */
.phone-operations{display:flex;flex-direction:column;gap:12px;max-width:640px;margin:auto}
.phone-toolbar{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:4px 0}
.phone-toolbar>div{display:flex;align-items:baseline;gap:8px;color:var(--nav,#152c35)}
.phone-toolbar time{font-size:30px;font-weight:750;font-variant-numeric:tabular-nums;letter-spacing:-.03em}
.phone-toolbar [data-clock-date]{font-size:15px}
.phone-toolbar .btn{min-height:48px;font-size:20px;white-space:nowrap}
.phone-counts{display:flex;justify-content:space-between;gap:6px;padding:10px 8px;background:#e5eeea;border-radius:8px;color:#254b3c}
.phone-counts>span{white-space:nowrap;font-size:14px}.phone-counts b{font-size:21px}
.phone-tables{display:grid;gap:20px}.phone-table{min-width:0;background:#fff;border:1px solid #cad5cf;border-radius:12px;overflow:hidden}
.phone-table>header{display:flex;align-items:center;justify-content:space-between;gap:6px;background:#254b3c;color:#fff;padding:4px 10px}
.phone-table>header>button{display:flex;align-items:center;gap:10px;background:transparent;border:0;color:inherit;text-align:left;min-height:52px;min-width:0;padding:0}
.phone-table>header strong{font-size:24px;white-space:nowrap}.phone-table>header span{font-size:16px;white-space:nowrap}.phone-table>header i{font-size:25px;font-style:normal}
.phone-table>header .phone-table-time{font-size:23px;font-weight:750;font-variant-numeric:tabular-nums}
.phone-guest{padding:12px;border-bottom:1px solid #d8dfda}.phone-guest:last-child{border:0}
.phone-guest-heading{display:flex;align-items:center;justify-content:space-between;gap:6px;border:0;border-radius:0;background:transparent;color:#633c1e;min-height:44px;width:100%;padding:0 0 6px;text-align:left}
.phone-guest-heading strong{font-size:19px;line-height:1.25;overflow-wrap:anywhere;min-width:0}.phone-guest-heading span{font-size:14px;line-height:1.4;text-align:right;flex:0 0 auto;max-width:55%;overflow-wrap:anywhere}.phone-guest-heading i{font-style:normal}
.phone-service{display:flex;justify-content:space-between;align-items:center;gap:10px;min-height:84px;padding:10px 12px;border-radius:8px;background:#e0eee5;color:#194c37}
.phone-service>div{display:flex;flex-direction:column;gap:2px;min-width:0}.phone-service strong{font-size:28px;line-height:1.15;white-space:nowrap}.phone-state{font-size:15px;font-weight:750;line-height:1.3}.phone-service .timer{font-size:27px;color:inherit;white-space:nowrap;font-variant-numeric:tabular-nums;background:transparent;border:0;flex:none;padding:0}.phone-service .gap-clock{font-size:16px;white-space:normal;max-width:112px;text-align:right}
.phone-guest.reserved .phone-service,.phone-guest.waiting .phone-service{background:#fff0e9;color:#9d351e;border:2px solid #c15e3d}
.phone-guest.changeover .phone-service,.phone-guest.complete .phone-service{background:#e0edf4;color:#24516b}
.phone-guest.needs-attention .phone-service{outline:2px solid #b53e20;animation:unseated-outline 1.6s ease-in-out infinite}
.phone-guest.reserved .phone-state{color:#a4321c}.phone-next{margin:7px 0 0;color:#355d49;font-size:16px;line-height:1.4}
.phone-guest-actions{display:flex;gap:8px;margin-top:10px}.phone-guest-actions>.btn{flex:1;min-width:0;min-height:52px;font-size:19px;font-weight:800}
.phone-seat{background:#216741!important;color:#fff!important;border-color:#216741!important}.phone-exchange{background:#dceaf0!important;color:#24516b!important;border-color:#8eacbd!important}.phone-book{background:#eef4ef!important;color:#28503c!important;border-color:#9fbaa9!important}
.phone-empty{text-align:center;color:#52695d;padding:30px 8px}.phone-empty h2{font-size:24px}.phone-empty p{font-size:17px;line-height:1.7}
.phone-exchange-review strong{display:block;font-size:26px}.phone-exchange-review p{font-size:18px;line-height:1.65}
.phone-alerts.floor-alerts{min-height:0!important;height:auto!important;display:flex;gap:8px;border-radius:8px;padding:8px}.phone-alerts[hidden]{display:none!important}.phone-alerts .floor-alert-count{min-width:90px!important;flex:none}.phone-alerts .floor-alert-list{display:none!important}.phone-alerts .alert-controls{flex:1;display:flex;flex-direction:row;align-items:center;justify-content:flex-end}.phone-alerts .alert-controls button{min-height:48px!important;font-size:16px!important}

@media (max-width:699px), (max-height:500px) and (max-width:1000px) {
 html,body,#app{height:auto!important;min-height:100dvh;overflow:auto!important}
 body:has(.phone-operations) .main-shell{width:100%!important;margin-left:0!important;padding-bottom:0!important}
 body:has(.phone-operations) .app-shell{display:block!important;height:auto!important}
 body:has(.phone-operations) .rail{position:sticky!important;top:0;width:100%!important;height:52px!important;min-height:52px!important;z-index:20;display:flex!important;align-items:center}
 body:has(.phone-operations) .rail .brand{width:44px;margin:0 8px;border:0;font-size:30px}.rail nav{min-width:0}
 body:has(.phone-operations) .rail nav{display:flex!important;flex:1;gap:3px;justify-content:space-evenly}
 body:has(.phone-operations) .rail .nav-item{display:flex;flex-direction:row;align-items:center;justify-content:center;gap:4px;min-height:48px;margin:0;padding:4px 8px;width:auto}
 body:has(.phone-operations) .rail .nav-item svg{width:19px;height:19px}.rail .nav-item span{white-space:nowrap}
 .operations-workspace:has(.phone-operations){height:auto!important;min-height:calc(100dvh - 52px);padding:10px 12px calc(20px + env(safe-area-inset-bottom))!important;overflow:visible!important}
 .operations-layout.phone-operations{align-items:stretch!important;width:100%!important;display:flex!important;flex-direction:column!important;height:auto!important;gap:12px!important}
 #modal,#modal.wide,#modal.table-screen,#modal.quick-intake-modal{width:calc(100% - 16px)!important;max-width:620px!important;max-height:calc(100dvh - 16px)!important;min-width:0!important;margin:auto!important}
 #modal .modal-body{overflow:auto!important;min-height:0!important;padding:12px!important}
 #modal .modal-header{padding:12px!important;gap:8px;min-height:56px}#modal .modal-header h2{font-size:21px!important;line-height:1.35;overflow-wrap:anywhere}
 #modal .modal-footer{padding:10px!important;display:flex;flex-wrap:wrap;gap:8px!important}#modal .modal-footer .btn{min-height:48px!important;font-size:17px!important;flex:1;white-space:normal}
 #modal .next-cast-options,#modal .replace-options{grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:8px!important}
 #modal .next-cast-option,#modal .replace-option{min-width:0!important;min-height:106px!important;padding:10px!important;text-align:left}
 #modal .candidate-name{font-size:24px!important;white-space:nowrap}
 #modal .cast-action-layout{display:flex!important;flex-direction:column!important;gap:10px!important}
 #modal .table-screen-layout{display:flex!important;flex-direction:column!important;overflow:auto!important}
 #modal .table-screen-map{display:none!important}
 #modal .table-screen-guests{width:100%!important;min-width:0!important;overflow:visible!important}
 #modal .table-guest-cards{display:flex!important;flex-direction:column!important;overflow:visible!important}
 #modal input,#modal select,#modal textarea{min-width:0;font-size:16px!important}
 .connection-status.offline{position:fixed!important;top:52px!important;left:0!important;right:0!important;z-index:50;padding:10px!important;text-align:center;background:#b33922!important;color:white!important;font-size:18px!important}
}
@media(prefers-reduced-motion:reduce){.phone-guest.needs-attention .phone-service{animation:none!important}}

/* Give names most of each narrow vertical sofa; the customer remains one clear line. */
.room-scene:not(.room-detail) .floor-seat-pair.flow-vertical{grid-template-rows:24px minmax(0,1fr)!important}
.room-scene.room-vip:not(.room-detail) .floor-seat-pair.flow-vertical{grid-template-rows:19px minmax(0,1fr)!important}
.room-scene.room-vip:not(.room-detail) .floor-seat-pair.seat-bottom{height:15%!important;grid-template-rows:19px minmax(0,1fr)!important}

:is(#app,#modal) .room-scene .floor-seat-slot>.floor-cast.name-first.fit-top-check{padding-top:calc(var(--fit-check) + 4px)!important}
:is(#app,#modal) .room-scene .floor-seat-slot>.floor-cast.name-first.fit-top-check .cast-name-large{align-self:center!important;margin-left:0!important}
:is(#app,#modal) .room-scene .floor-cast.fit-top-check .name-seated-check{right:calc(50% - var(--fit-check)/2)!important}
.room-scene:not(.room-detail) .floor-seat-pair.flow-vertical:has(>.floor-seat-slot:first-child>.floor-cast){grid-template-rows:minmax(0,1fr) 24px!important}
.room-scene.room-vip:not(.room-detail) .floor-seat-pair.flow-vertical:has(>.floor-seat-slot:first-child>.floor-cast),.room-scene.room-vip:not(.room-detail) .floor-seat-pair.seat-bottom:has(>.floor-seat-slot:first-child>.floor-cast){grid-template-rows:minmax(0,1fr) 19px!important}
@media(min-width:700px) and (max-width:900px){
 .operations-workspace:has(.live-floor-map) .compact-console .console-controls{grid-template-columns:minmax(104px,.6fr) minmax(140px,.9fr) minmax(172px,1.1fr)!important;gap:4px!important}
 .compact-console .console-left{grid-template-columns:52px minmax(0,1fr)!important;gap:3px!important}
 .operations-workspace:has(.live-floor-map) .compact-console .roster-tabs .console-arrival{width:52px!important;font-size:20px!important}
 .compact-console .cast-metrics{grid-template-columns:minmax(82px,1.6fr) repeat(2,minmax(26px,1fr))!important;gap:2px!important}
 .operations-workspace:has(.live-floor-map) .compact-console .roster-tabs [data-tab="customers"]{padding:0 2px!important}
 .compact-console .cast-metrics .metric-label{font-size:13px!important}
 .compact-console .cast-metrics .roster-metric b,.compact-console .arrival-metric b{font-size:23px!important}
 .compact-console .cast-metrics .roster-metric small,.compact-console .arrival-metric small{font-size:11px!important}
 .compact-console .roster-label{font-size:14px!important}
}
.phone-table-tabs{display:flex;gap:6px;overflow-x:auto;position:sticky;top:52px;z-index:12;padding:8px 0;background:#f5f7f4;scrollbar-width:thin}
.phone-table-tabs button{min-height:46px;min-width:57px;flex:none;border:1px solid #aec1b5;border-radius:7px;color:#355d49;background:#edf3ee;font-size:17px;font-weight:750;padding:6px 10px}
.phone-table-tabs button[aria-pressed="true"]{background:#254b3c;color:white;border-color:#254b3c}

.room-scene:not(.room-detail) .floor-seat-slot>.floor-customer.fit-compact{border:2px solid var(--clothing-color,#788f97)!important;background:#fffdf4!important;border-radius:5px}

@media(max-width:699px),(max-height:500px) and (max-width:1000px){
 #modal .next-cast-option,#modal .replace-option{border-color:#c4d4c8!important;color:#254b3c!important}
 #modal .next-cast-option[aria-pressed="true"],#modal .replace-option[aria-pressed="true"]{background:#e2eee5!important;border-color:#417958!important;box-shadow:inset 0 0 0 1px #417958!important}
 #modal .recommendation-name,#modal .candidate-section-title{color:#254b3c!important}
 #modal .service-round{background:#edf3ee!important;border-color:#c4d4c8!important}
 #modal .service-round .btn{background:#e1ede5!important;border-color:#afc7b7!important;color:#254b3c!important}
}

:is(#app,#modal) .room-scene .floor-seat-slot>.floor-cast.name-first.fit-side-status{padding-right:calc(var(--fit-sideWidth) + 3px)!important}
:is(#app,#modal) .room-scene .floor-cast.fit-side-status .cast-time-check{position:absolute;right:2px;top:2px;bottom:calc(var(--fit-route) + 2px);width:var(--fit-sideWidth)!important;flex-direction:column!important;gap:5px!important}
:is(#app,#modal) .room-scene .floor-cast.fit-side-status .name-seated-check{position:static!important}

:is(#app,#modal) .room-scene:not(.room-detail) .live-table-core .live-stay [data-stay-time]{font-size:var(--fit-table-time,22px)!important;white-space:nowrap!important}
:is(#app,#modal) .room-scene:not(.room-detail) .live-table-core .table-round-label{font-size:var(--fit-table-round,16px)!important;white-space:nowrap!important}

/* Fit the complete tabletop, including long elapsed times and finish controls. */
:is(#app,#modal) .room-scene:not(.room-detail).occupied .live-table-core{gap:2px!important;padding:2px!important;display:flex!important;flex-direction:column!important;justify-content:center!important}
:is(#app,#modal) .room-scene:not(.room-detail).occupied .live-table-core.fit-core-wide{display:grid!important;grid-template-columns:minmax(0,.85fr) minmax(0,1fr)!important;grid-template-rows:auto auto!important;gap:1px 4px!important;align-content:center!important}
:is(#app,#modal) .live-table-core.fit-core-wide>.table-number-plate{grid-area:1/1!important;justify-self:center}
:is(#app,#modal) .live-table-core.fit-core-wide>.core-counts{grid-area:2/1!important;justify-self:center}
:is(#app,#modal) .live-table-core.fit-core-wide>.live-stay{grid-area:1/2/3/3!important;min-width:0!important;justify-self:center}
:is(#app,#modal) .room-scene:not(.room-detail).occupied .live-table-core .table-number-plate{font-size:calc(22px * var(--fit-core-scale,1))!important;line-height:1.05!important;padding:0 2px!important}
:is(#app,#modal) .room-scene:not(.room-detail).occupied .live-table-core .room-headcount b{font-size:calc(22px * var(--fit-core-scale,1))!important}
:is(#app,#modal) .room-scene:not(.room-detail).occupied .live-table-core .room-headcount small{font-size:calc(14px * var(--fit-core-scale,1))!important}
:is(#app,#modal) .room-scene:not(.room-detail).occupied .live-table-core .guest-count-label{font-size:calc(12px * var(--fit-core-scale,1))!important;line-height:1.05!important}

.room-scene:not(.room-detail) .floor-seat-pair.flow-vertical:has(>.floor-seat-slot:first-child>.floor-cast):has(>.floor-seat-slot:last-child>.floor-cast),
.room-scene:not(.room-detail) .floor-seat-pair.flow-vertical:has(>.floor-seat-slot:first-child>.floor-customer):has(>.floor-seat-slot:last-child>.floor-customer){grid-template-rows:minmax(0,1fr) minmax(0,1fr)!important}

/* End-check is a small overlay; it must never take height from the room. */
.live-booth:has(>.booth-finish-button){position:relative!important}
.live-booth:has(>.booth-finish-button)>.room-scene{height:100%!important;flex:1!important;min-height:0!important}
.live-booth>.booth-finish-button{position:absolute!important;z-index:6;left:4px;top:4px;display:inline-flex;align-items:center;justify-content:center;gap:3px;width:58px!important;max-width:none!important;height:28px!important;min-height:28px!important;padding:1px 3px!important;font-size:14px!important;line-height:1!important;font-weight:750!important;white-space:nowrap;flex:none;background:#edf4ef!important;border:1px solid #68947c!important;border-radius:5px!important;color:#28563c!important;box-shadow:0 1px 2px #1b39231a;touch-action:manipulation}
.live-booth>.booth-finish-button>span:first-child{font-size:16px;line-height:1}
.live-booth>.booth-finish-button:disabled{width:70px!important;opacity:.65}
.live-booth:has(>.room-opposed)>.booth-finish-button{left:50%;top:2%;transform:translateX(-50%)}
.live-booth:has(>.room-corner)>.booth-finish-button{left:4%;top:2%}
.live-booth:has(>.room-banquette)>.booth-finish-button{left:auto;right:calc(8% + 3px);top:calc(36% + 3px);width:49px!important;height:24px!important;min-height:24px!important;font-size:13px!important;gap:1px;padding:1px 2px!important}
.live-booth:has(>.room-banquette)>.booth-finish-button>span:first-child{font-size:14px}
.live-booth:has(>.room-banquette)>.booth-finish-button:disabled{width:49px!important;font-size:10px!important}
:is(#app,#modal) .live-booth:has(>.booth-finish-button)>.room-banquette .live-table-core{display:grid!important;grid-template-columns:minmax(0,.85fr) minmax(0,1fr)!important;grid-template-rows:24px auto auto!important;align-content:center!important}
:is(#app,#modal) .live-booth:has(>.booth-finish-button)>.room-banquette .live-table-core>.table-number-plate{grid-area:1/1!important;justify-self:center}
:is(#app,#modal) .live-booth:has(>.booth-finish-button)>.room-banquette .live-table-core>.core-counts{grid-area:2/1/3/3!important;justify-self:center}
:is(#app,#modal) .live-booth:has(>.booth-finish-button)>.room-banquette .live-table-core>.live-stay{grid-area:3/1/4/3!important;justify-self:center}
:is(#app,#modal) .live-booth:has(>.booth-finish-button)>.room-banquette .live-table-core.fit-core-wide{grid-template-rows:24px auto!important}
:is(#app,#modal) .live-booth:has(>.booth-finish-button)>.room-banquette .live-table-core.fit-core-wide>.core-counts{grid-area:2/1!important}
:is(#app,#modal) .live-booth:has(>.booth-finish-button)>.room-banquette .live-table-core.fit-core-wide>.live-stay{grid-area:2/2!important}
.live-booth:has(>.room-joined)>.booth-finish-button{left:2%;top:35%}
.live-booth:has(>.room-vip)>.booth-finish-button{left:4%;top:4%}

.set-choice-buttons{display:flex;gap:10px;align-items:stretch;min-width:0}
#modal .modal-footer>.set-choice-buttons{width:100%}
.set-choice-buttons .btn{flex:1;min-width:88px;min-height:48px;font-size:21px;font-weight:800;white-space:nowrap}
.set-extend{background:#eaa157!important;border-color:#b87533!important;color:#4b2a0e!important}
.set-finish{background:#e3eee6!important;border-color:#6c987c!important;color:#254b3c!important}
.set-decision{text-align:center;padding:8px 4px 16px}
.set-decision>strong{display:block;font-size:42px;line-height:1.1;font-variant-numeric:tabular-nums;color:#254b3c}
.set-decision>span{display:block;font-size:15px;color:#587361}
.set-decision p{font-size:17px;line-height:1.6}
.set-decision small{display:block;font-size:14px}
.set-completed{font-size:17px;color:#315f43;font-weight:700;align-self:center}
.phone-set-actions{padding:10px 12px;display:flex;gap:8px;align-items:center;background:#f5f8f4}
.phone-set-actions>.set-choice-buttons{flex:1}

/* Table details prioritize the people, sets and rotations over an enlarged map. */
#modal.table-screen.history-first-screen{width:min(1160px,calc(100vw - 24px))!important;height:min(840px,calc(100dvh - 24px))!important;max-height:calc(100dvh - 24px)!important}
#modal.table-screen.history-first-screen .modal-body{overflow:hidden!important;padding:12px!important;flex:1;min-height:0}
.table-history-layout{display:grid;grid-template-columns:190px minmax(0,1fr);gap:14px;height:100%;min-height:0}
.table-history-summary{display:flex;flex-direction:column;gap:12px;background:#f2f4ef;border:1px solid #d4dfd5;border-radius:10px;padding:12px;overflow:auto;min-width:0}
.table-history-count{display:flex;flex-direction:column;gap:4px;color:#294e3d}
.table-history-count>strong{font-size:22px;white-space:nowrap}.table-history-count>span{font-size:17px}
#modal.history-first-screen .table-stay-panel{display:flex;flex-direction:column;gap:5px;min-width:0;width:100%;padding:10px 4px!important;margin:0;border:1px solid #b4c7b8;border-radius:8px;background:#fff;color:#274b3c}
#modal.history-first-screen .table-stay-panel>strong{font-size:34px!important;line-height:1.2;white-space:nowrap;font-variant-numeric:tabular-nums}
#modal.history-first-screen .table-stay-panel>span{font-size:16px}#modal.history-first-screen .table-stay-panel>small{font-size:12px;line-height:1.5}
.history-primary-actions{display:flex;flex-direction:column;gap:8px}
#modal.history-first-screen .history-primary-actions>.btn{font-size:17px;min-height:46px;padding:6px}
#modal.history-first-screen .set-choice-buttons{gap:6px}
#modal.history-first-screen .set-choice-buttons .btn{min-width:0;font-size:19px}
#modal.table-screen.history-first-screen .live-table-actions{display:grid!important;grid-template-columns:1fr!important;gap:7px;margin-top:auto}
#modal.history-first-screen .live-table-actions>.btn{font-size:15px;min-height:42px;background:#fff;border-color:#c6d1c7;color:#315440}
.table-history-main{display:flex;flex-direction:column;min-width:0;min-height:0;gap:10px}
.table-history-heading{display:flex;align-items:center;justify-content:space-between;gap:8px;flex:none}
.table-history-heading>h3{font-size:19px;color:#294e3d;margin:0}
.table-history-heading .panel-pages{margin:0;gap:6px;font-size:14px}.table-history-heading .panel-pages .btn{min-width:44px;min-height:42px;padding:4px 8px}
#modal.table-screen.history-first-screen .table-guest-cards{display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr))!important;grid-template-rows:none!important;grid-auto-rows:max-content;align-content:start;gap:12px!important;min-height:0;overflow:auto!important;flex:1!important;padding:0 3px 6px 0}
#modal.table-screen.history-first-screen .table-guest-summary{display:block;min-height:0!important;padding:12px!important;background:#fffdf8;border:1px solid #d8d4c7;border-radius:9px;gap:0!important;justify-content:start!important}
.history-person-heading{display:flex;justify-content:space-between;align-items:flex-start;gap:10px;color:#294f3f;padding-bottom:8px;border-bottom:1px solid #e1e5dc}
.history-person-heading>div{min-width:0;flex:1}.history-person-heading strong{font-size:23px;line-height:1.25;overflow-wrap:anywhere}.history-person-heading>div>span{display:block;font-size:15px;line-height:1.4;margin-top:3px;color:#596b61}
.history-set-count{font-size:16px!important;white-space:nowrap;background:#e6eee6;color:#315540;border-radius:5px;padding:4px 7px;line-height:1.2}
#modal.table-screen.history-first-screen .table-guest-title{min-height:0;gap:8px}
#modal.table-screen.history-first-screen .table-guest-link{min-height:0!important;gap:3px!important}
#modal.table-screen.history-first-screen .table-guest-link b{font-size:23px!important;line-height:1.2;white-space:normal;overflow-wrap:anywhere}
#modal.table-screen.history-first-screen .table-guest-link span{font-size:15px!important;line-height:1.35!important}
#modal.history-first-screen .history-guest-kind{display:block;font-size:14px;line-height:1.4;color:#637066;margin-top:4px}
#modal.table-screen.history-first-screen .main-toggle{width:34px;min-width:34px;height:34px;min-height:34px;font-size:23px;padding:0}
.history-person-note{font-size:14px;line-height:1.5;margin:6px 0;color:#526357;overflow-wrap:anywhere}.history-person-note.nomination{color:#96503d}
.history-set{margin-top:10px;min-width:0}.history-set>h3{font-size:17px;color:#315440;margin:0 0 6px;display:flex;align-items:center;gap:8px}.history-set>h3>span{font-size:12px;background:#dceadc;padding:2px 6px;border-radius:4px}
.history-set .history-rotations,#modal.table-screen.history-first-screen .table-rounds{display:grid!important;grid-template-columns:repeat(3,minmax(0,1fr))!important;gap:6px!important;flex:none!important;padding:0}
#modal.table-screen.history-first-screen .table-round{min-height:94px!important;display:flex;flex-direction:column!important;justify-content:flex-start;align-items:center;gap:4px!important;padding:7px 5px!important;border-radius:6px;container-type:inline-size;background:#f0f5ee;border:1px solid #c2d2c3;color:#274e3b}
#modal.table-screen.history-first-screen .table-round.pending{background:#fff0df;border-color:#d8995b}.table-round.booked{background:#e9f2f1}
#modal.table-screen.history-first-screen .table-round small{font-size:14px!important;line-height:1.25!important}
#modal.table-screen.history-first-screen .table-round b{font-size:min(24px,calc((100cqw - 4px) / var(--history-name-chars,3)))!important;line-height:1.25!important;white-space:nowrap!important;overflow:visible!important}
#modal.table-screen.history-first-screen .table-round>span,#modal.table-screen.history-first-screen .table-round>em{font-size:12px!important;line-height:1.3!important;font-style:normal;white-space:normal}
#modal.history-first-screen .table-guest-seat{font-size:17px!important;margin-top:7px;padding:5px 10px}
.table-history-archive{overflow:auto;min-height:0;flex:1;padding-right:3px}
.saved-visit{margin-bottom:18px}.saved-visit-heading{display:flex;justify-content:space-between;gap:8px;align-items:center;padding:6px 0 10px;color:#375545}.saved-visit-heading strong{font-size:18px}.saved-visit-heading span{font-size:14px;color:#607367}
.saved-visit-customers{display:grid;grid-template-columns:minmax(0,1fr);gap:10px}
.saved-visit .history-customer{display:grid;grid-template-columns:210px minmax(0,1fr);padding:0;background:#fffdf8;border:1px solid #d8d4c7;border-radius:9px;min-width:0}
.saved-visit .history-person{padding:12px;background:#fff0dc;min-width:0}
.saved-visit .history-person-heading{display:block;padding:0;border:0;color:#643514}
.saved-visit .history-set-count{display:inline-block;margin-top:8px}
.saved-visit .history-sets{padding:10px;min-width:0}
.saved-visit .history-set{display:grid;grid-template-columns:80px minmax(0,1fr);align-items:start;gap:8px;margin:0}
.saved-visit .history-set+.history-set{border-top:1px solid #dce5db;padding-top:10px;margin-top:10px}
.saved-visit .history-set>h3{margin:0;padding-top:8px;font-size:16px;white-space:nowrap}
.saved-visit .history-rotation article{padding-bottom:0}
.saved-visit .history-rotation time{font-size:14px}
.history-set .history-rotation{display:block!important;padding:7px 5px;background:#f0f5ee;border:1px solid #c2d2c3;border-radius:6px;min-width:0;text-align:center}
.history-set .history-rotation h4{font-size:14px;margin:0 0 5px;color:#43604c}.history-rotation article{container-type:inline-size;display:flex;flex-direction:column;gap:3px;padding-bottom:6px}.history-rotation article+article{border-top:1px solid #cddbcf;padding-top:7px}
.history-set .history-rotation article>b{font-size:min(24px,calc((100cqw - 4px) / var(--history-name-chars,3)));font-weight:800;line-height:1.25;white-space:nowrap;color:#274e3b}
.history-set .history-rotation time,.history-set .history-rotation article>span,.history-set .history-rotation em{font-size:12px;line-height:1.3;font-style:normal;color:#536957}
.history-set .history-rotation time{white-space:normal;overflow-wrap:anywhere}
.history-set .history-rotation.unrecorded{background:#fafbf8;border-color:#e3e6df}.history-no-record{font-size:14px;color:#839084}.history-empty,.history-loading,.history-load-error{font-size:18px;padding:24px 8px;color:#627469}
.history-type,#modal.table-screen.history-first-screen .table-guest-link .history-type{display:inline-block;font-size:13px!important;line-height:1.4!important;white-space:nowrap;background:#f0e4ca;color:#72572f;border-radius:4px;padding:1px 5px;margin-top:3px}
#modal.history-first-screen[data-guests="0"] .table-history-layout{display:flex;flex-direction:column}
#modal.history-first-screen[data-guests="0"] .table-history-summary{display:flex;flex-direction:row;justify-content:space-between;align-items:center;flex:none;padding:7px 12px;overflow:visible}
#modal.history-first-screen[data-guests="0"] .table-history-summary .history-primary-actions{display:none}
#modal.history-first-screen[data-guests="0"] .live-table-actions{margin:0;min-width:100px}
#modal.history-first-screen[data-guests="0"] .table-history-main{flex:1}
@media(max-width:900px){
 .table-history-layout{grid-template-columns:1fr;grid-template-rows:auto minmax(0,1fr);gap:10px}
 .table-history-summary{display:grid;grid-template-columns:130px 160px minmax(0,1fr);gap:8px;padding:8px;overflow:visible;align-items:center}
 #modal.table-screen.history-first-screen .live-table-actions{grid-column:1/-1;grid-template-columns:repeat(3,minmax(0,1fr))!important;margin:0}
 #modal.history-first-screen .table-stay-panel{padding:5px!important}#modal.history-first-screen .table-stay-panel>strong{font-size:28px!important}
}
@media(max-width:699px),(max-height:500px) and (max-width:1000px){
 #modal.table-screen.history-first-screen{height:calc(100dvh - 16px)!important;max-height:calc(100dvh - 16px)!important}
 #modal.table-screen.history-first-screen .modal-body{padding:8px!important}
 .table-history-summary{grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:6px}
 .history-primary-actions{grid-column:1/-1}.history-primary-actions:empty{display:none}
 .table-history-heading{flex-wrap:wrap}.table-history-heading>h3{font-size:18px}
 #modal.table-screen.history-first-screen .table-guest-cards,.saved-visit-customers{grid-template-columns:minmax(0,1fr)!important}
 #modal.table-screen.history-first-screen .table-guest-summary,.saved-visit .history-customer{padding:9px!important}
 #modal.table-screen.history-first-screen .table-guest-link b,.history-person-heading strong{font-size:21px!important}
 .history-set-count{font-size:14px!important}.history-person-heading{gap:6px}
 .saved-visit-heading{flex-wrap:wrap}.saved-visit-heading strong{font-size:16px}
 .saved-visit .history-customer{grid-template-columns:minmax(0,1fr);padding:0!important}
 .saved-visit .history-person{padding:9px 11px}
 .saved-visit .history-person-heading{display:flex;align-items:center;gap:8px}
 .saved-visit .history-set-count{margin-top:0}
 .saved-visit .history-sets{padding:9px}
 .saved-visit .history-set{grid-template-columns:minmax(0,1fr);gap:5px}
 .saved-visit .history-set>h3{padding:0}
 .saved-visit .history-rotation time{font-size:12px}
}

/* The next reservation is separate from the current cast and their destination. */
:is(#app,#modal) .room-scene .floor-cast:has(.next-cast-label){padding-bottom:calc(var(--fit-nextHeight,28px) + 3px)!important}
:is(#app,#modal) .room-scene .floor-cast .next-cast-label{position:absolute;bottom:2px;left:2px;right:2px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:1px;border-top:1px solid #aac0ac;background:#f0f5ed;color:#274d3c;line-height:1.15;border-radius:0 0 3px 3px;padding-top:2px;white-space:nowrap;letter-spacing:0}
:is(#app,#modal) .room-scene .floor-cast .next-cast-label small{font-size:9px;line-height:10px;font-weight:650;color:#506853}
:is(#app,#modal) .room-scene .floor-cast .next-cast-label b{font-size:var(--fit-next,13px);line-height:1.15;white-space:nowrap;letter-spacing:0}
:is(#app,#modal) .room-scene .floor-cast .next-cast-label i{position:absolute;right:1px;top:1px;font-size:10px;line-height:10px;color:#b53e19;font-style:normal}
:is(#app,#modal) .room-scene .floor-cast.fit-side-status:has(.next-cast-label) .cast-time-check{bottom:calc(var(--fit-route) + var(--fit-nextHeight) + 3px)}
:is(#app,#modal) .room-scene .floor-cast:not(.fit-next-stack) .next-cast-label{flex-direction:row;gap:3px;min-height:18px}
:is(#app,#modal) .room-scene .floor-cast.fit-next-vertical .next-cast-label b{writing-mode:vertical-rl;text-orientation:upright;line-height:1}
.live-booth.group-drop-target{outline:4px solid #398566;outline-offset:-3px;background:#d9eddf!important;box-shadow:inset 0 0 0 7px #e5f5e5;z-index:3}
.live-booth.group-drop-blocked{outline:4px solid #b84d2d;outline-offset:-3px;background:#fae2d6!important;z-index:3}
.drag-ghost:has(.drop-plan-label){display:flex;flex-direction:column;gap:4px;max-width:280px;padding:12px 16px;background:#245942;color:#fff;border:2px solid #b6d8bd}
.drag-ghost .drop-plan-label{font-size:18px;font-weight:750;white-space:nowrap}
.joined-table-seam{fill:none;stroke:#a79983;stroke-width:.5;opacity:.65}
#app-update-notice{position:fixed;z-index:30000;top:8px;left:50%;transform:translateX(-50%);border:1px solid #a75523;border-radius:10px;padding:14px 20px;background:#fff2dc;color:#633213;font:700 16px/1.4 sans-serif;box-shadow:0 3px 14px #0003;max-width:calc(100vw - 24px)}
/* Cast selection prioritizes names and actual service history. */
#modal.candidate-screen[open]{display:flex;flex-direction:column;height:min(790px,calc(100dvh - 24px));max-height:calc(100dvh - 24px)}
#modal.candidate-screen .modal-heading,#modal.candidate-screen .modal-footer{flex:none}
#modal.candidate-screen .modal-body{flex:1;min-height:0;padding:10px 16px}
#modal.candidate-screen .cast-action-layout{grid-template-columns:minmax(0,.72fr) minmax(0,1.28fr);gap:14px}
#modal.candidate-screen .replace-options,#modal.candidate-screen .next-cast-options{grid-template-columns:repeat(var(--candidate-columns,3),minmax(0,1fr))!important;gap:6px!important;align-items:stretch}
#modal.candidate-screen :is(.replace-option,.next-cast-option){min-height:64px;padding:6px 5px;gap:3px;justify-content:center;text-align:center}
#modal.candidate-screen .recommendation-heading{justify-content:center;gap:0}
#modal.candidate-screen .recommendation-heading strong{font-size:23px!important;line-height:1.2;white-space:nowrap;color:#254b3c}
#modal.candidate-screen .candidate-current-place{font-size:13px;line-height:1.3;color:#526459}
#modal.candidate-screen .candidate-history{display:flex;flex-direction:column;gap:2px;font-size:13px;line-height:1.35;color:#854c18}
#modal.candidate-screen :is(.replace-option,.next-cast-option).served-before{background:#fff1d9;border:2px solid #d39748;color:#713f14}
#modal.candidate-screen :is(.replace-option,.next-cast-option).served-before:disabled{opacity:1;background:#f4e5d7;border-color:#b47c55;color:#70462b}
#modal.candidate-screen .candidate-restriction{font-size:13px;line-height:1.3}
#modal.candidate-screen .current-cast-kind{font-weight:700;line-height:1.3;font-style:normal;font-size:15px;margin-left:10px;color:#6e5b35;white-space:nowrap}
#modal.candidate-screen .quick-moves{padding-right:10px}
#modal.candidate-screen .quick-move-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:6px}
#modal.candidate-screen .quick-move-button{display:flex;flex-direction:column;justify-content:center;min-height:64px!important;padding:8px 4px!important}
#modal.candidate-screen .quick-move-button strong{font-size:17px;line-height:1.2;white-space:nowrap}
#modal.candidate-screen .quick-move-button small{font-size:14px;line-height:1.2}
#modal.candidate-screen .move-route-summary{margin:6px 0;display:grid;gap:5px}
#modal.candidate-screen .move-route-item{padding:7px 9px;min-height:50px;text-align:left}
#modal.candidate-screen .move-route-item strong{font-size:16px;line-height:1.3}
#modal.candidate-screen .move-route-item span{font-size:14px}
#modal.candidate-screen .immediate-moves{margin-top:8px}
#modal.candidate-screen .immediate-moves summary{font-size:15px;min-height:40px;cursor:pointer}
#modal.candidate-screen .replace-note{font-size:14px;margin:3px 0}
#modal.candidate-screen .replace-shortcuts{gap:5px;margin-top:5px}
#modal.candidate-screen .replace-shortcuts :is(.btn,.text-btn){min-height:40px;font-size:13px!important;padding:5px 8px}
#modal.candidate-screen .panel-pages{min-height:40px;margin-top:6px}
#modal.candidate-screen .next-explanation{display:none}
@media(max-width:699px){
 #modal.candidate-screen .cast-action-layout{display:flex;flex-direction:column}
 #modal.candidate-screen .quick-moves{width:100%;border:0;padding:0}
 #modal.candidate-screen .quick-move-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
 #modal.candidate-screen .modal-heading h2{font-size:18px;line-height:1.35;text-wrap:balance}
 #modal.candidate-screen :is(.replace-option,.next-cast-option){min-height:76px!important;padding:7px 5px!important}
 #modal.candidate-screen .recommendation-heading strong{font-size:22px!important}
}

#modal.candidate-screen .candidate-controls strong{color:#254b3c}

/* The tabletop owns its labels; the cast cushion owns its current/next names. */
:is(#app,#modal) .room-scene.room-joined.occupied .live-table-core{display:grid!important;grid-template-columns:minmax(0,2.5fr) minmax(0,1fr) minmax(0,1.5fr)!important;grid-template-rows:1fr!important;gap:8px!important;padding:3px 6px!important;background:transparent!important;box-shadow:none!important;transform:none!important}
:is(#app,#modal) .room-scene.room-joined.occupied .live-table-core>.table-number-plate{grid-area:1/1!important;max-width:100%!important;white-space:nowrap!important}
:is(#app,#modal) .room-scene.room-joined.occupied .live-table-core>.core-counts{grid-area:1/2!important}
:is(#app,#modal) .room-scene.room-joined.occupied .live-table-core>.live-stay{grid-area:1/3!important}
:is(#app,#modal) .room-scene:not(.room-detail).occupied .live-table-core .table-number-plate{font-size:var(--fit-plate,20px)!important}
:is(#app,#modal) .room-scene .room-headcount>span{white-space:nowrap}
:is(#app,#modal) .room-scene .floor-seat-slot>.floor-cast.name-first{height:calc(100% - 6px)!important;margin-bottom:6px!important;padding:3px 2px 5px!important;overflow:visible!important;gap:2px!important}
:is(#app,#modal) .room-scene .floor-cast.name-first .name-seated-check{position:absolute!important;top:-9px!important;right:-5px!important;bottom:auto!important;left:auto!important;z-index:3;box-shadow:0 0 0 2px #fff8}
:is(#app,#modal) .room-scene .floor-cast.name-first .name-seated-check.unchecked{background:#fff7ec!important;border:2px dashed #b9592e!important;box-shadow:0 0 0 2px #fff8}
:is(#app,#modal) .room-scene .floor-cast.name-first .cast-time-check{position:absolute!important;left:50%!important;right:auto!important;top:auto!important;bottom:-7px!important;transform:translateX(-50%);width:max-content!important;max-width:calc(100% - 4px)!important;padding:0 3px;gap:2px!important;line-height:1.1;background:var(--seat-fill);border-radius:3px;z-index:2}
:is(#app,#modal) .room-scene .floor-cast.name-first.serving .cast-time-check::before{content:none;display:none}
:is(#app,#modal) .room-scene .floor-cast.name-first .cast-time-check [data-minute-clock]::after{content:'分経過';display:inline!important;font-size:1em!important;margin-left:0!important}
:is(#app,#modal) .room-scene .floor-cast.name-first:is(.waiting,.reserved) .cast-time-check{background:var(--unseated-fill);color:var(--unseated-ink)}
:is(#app,#modal) .room-scene .floor-cast.name-first:is(.changeover,.complete) .cast-time-check{background:var(--exchange-fill);color:var(--exchange-ink)}
:is(#app,#modal) .room-scene .floor-cast.name-first .next-cast-label{position:static!important;display:flex;flex-direction:row;align-items:center;justify-content:center;gap:3px;min-height:0!important;border:0;background:transparent;padding:0;line-height:1.15;max-width:100%;color:inherit}
:is(#app,#modal) .room-scene .floor-cast.name-first .next-cast-label small{font-size:min(11px,var(--fit-next,11px));line-height:1.15;color:inherit;font-weight:650}
:is(#app,#modal) .room-scene .floor-cast.name-first .next-cast-label b{color:inherit;font-weight:750}
:is(#app,#modal) .room-scene .floor-cast.name-first.fit-next-stack .next-cast-label{flex-direction:column;gap:0}
:is(#app,#modal) .room-scene .floor-cast.name-first .next-cast-label i{position:static;font-weight:850}
:is(#app,#modal) .room-scene .floor-cast.name-first>.next-table-label{position:absolute!important;left:2px!important;right:auto!important;top:-6px!important;bottom:auto!important;max-width:calc(100% - var(--fit-check) - 7px);padding:0 2px;background:var(--seat-fill);border-radius:2px;font-size:var(--fit-route,10px)!important;overflow:visible;z-index:2}
:is(#app,#modal) .room-scene .floor-cast.name-first:is(.waiting,.reserved)>.next-table-label{background:var(--unseated-fill);color:var(--unseated-ink)}

/* Service severity wins over the seated green, including reduced-motion mode. */
:is(#app,#modal) .room-scene .floor-cast.name-first .cast-time-check [data-floor-overdue]::after{content:'分'!important}
:is(#app,#modal) .room-scene .floor-seat-slot>.floor-cast.name-first[data-service-level=pending]{background:#fff0d6!important;color:#78350f!important;border:2px dashed #cc7529!important;animation:nomination-wait-pulse 2s ease-in-out infinite!important}
:is(#app,#modal) .room-scene .floor-seat-slot>.floor-cast.name-first[data-service-level=overdue]{background:#ffe0d3!important;color:#862a19!important;border:2px solid #c24728!important;animation:service-overdue-outline 1.8s ease-in-out infinite!important}
:is(#app,#modal) .room-scene .floor-seat-slot>.floor-cast.name-first[data-service-level=critical]{background:#a52c20!important;color:#fff!important;border:2px solid #ffb380!important;animation:service-critical-outline 1.8s ease-in-out infinite!important;outline:2px solid #a52c20;outline-offset:1px}
:is(#app,#modal) .room-scene .floor-cast.name-first .cast-time-check{background:inherit!important;color:inherit!important}
:is(#app,#modal) .room-scene .floor-cast.name-first .name-seated-check.alerted{display:inline-flex!important;background:#a52c20!important;color:#fff!important;border:2px solid #ffc6a4!important;font-weight:900}
:is(#app,#modal) .room-scene .floor-cast.name-first[data-service-level=critical] .name-seated-check.unchecked{background:#fff6eb!important;border:2px solid #a52c20!important}
:is(#app,#modal) .room-scene .floor-cast.name-first .next-cast-label.unbooked{opacity:.8}
.live-booth>.booth-finish-button.needs-decision{background:#fff0d6!important;color:#862a19!important;border:2px solid #c24728!important}
.live-booth>.booth-finish-button.needs-decision>span:first-child{font-weight:900;border:1px solid currentColor;border-radius:50%;width:15px;height:15px;font-size:12px}
.live-booth>.booth-finish-button.scheduled{background:#e5eff1!important;color:#365b64!important;border-color:#83a3ab!important}
@keyframes service-overdue-outline{50%{box-shadow:0 0 0 3px #e56c38}}
@keyframes service-critical-outline{0%,100%{box-shadow:0 0 0 2px #b42f20}50%{box-shadow:0 0 0 5px #f29960}}
@media(prefers-reduced-motion:reduce){:is(#app,#modal) .room-scene .floor-seat-slot>.floor-cast.name-first[data-service-level]{animation:none!important}}

.phone-guest[data-service-level=overdue] .phone-service{background:#ffe0d3;color:#862a19;border:2px solid #c24728}
.phone-guest[data-service-level=critical] .phone-service{background:#a52c20;color:#fff;border:2px solid #ffb380;outline:2px solid #a52c20}
.phone-guest:is([data-service-level=overdue],[data-service-level=critical]) .phone-service :is(strong,.phone-state,.timer){color:inherit!important;background:transparent!important}
/* Inline destination rounds and compact, alphabetical cast names. */
#modal.candidate-screen .cast-action-layout{display:grid;grid-template-columns:minmax(0,1.45fr) minmax(0,1fr);align-items:start;gap:14px}
#modal.candidate-screen .quick-moves{padding-right:12px}
#modal.candidate-screen .quick-moves h3{margin:0 0 6px;font-size:20px}
.inline-move-board{display:grid;gap:8px}
.inline-move-table{border:1px solid #b8cfc0;border-radius:9px;background:#fff;overflow:hidden;min-width:0}
.inline-move-table>header{display:flex;justify-content:space-between;align-items:center;gap:8px;padding:7px 9px;background:#e9f1e9;color:#244937}
.inline-move-table>header strong{font-size:18px;line-height:1.25}
.inline-move-table>header small{font-size:13px;margin-left:4px;white-space:nowrap}
.inline-move-table>header b{font-size:16px;white-space:nowrap;font-variant-numeric:tabular-nums}
.inline-round-head,.inline-move-row{display:grid;grid-template-columns:minmax(90px,1.15fr) repeat(3,minmax(0,1fr));gap:4px;padding:3px 6px}
.inline-round-head{font-size:13px;text-align:center;background:#f4f6f2;color:#4e5c52}
.inline-move-row{border-top:1px solid #e8ece7}
.inline-move-seat{display:flex;flex-direction:column;justify-content:center;min-width:0;padding:0 2px}
.inline-move-seat strong{font-size:14px;line-height:1.3;overflow-wrap:anywhere}
.inline-move-seat small{font-size:12px;line-height:1.3;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.inline-round{display:flex;flex-direction:column;align-items:center;justify-content:center;min-width:0;min-height:44px;padding:3px;border:1px solid #c9d9cd;border-radius:6px;background:#f0f6ef;color:#27553d;cursor:pointer;font:inherit}
.inline-round strong{font-size:18px;line-height:1.2;white-space:nowrap}
.inline-round small{font-size:11px;line-height:1.3;white-space:nowrap}
.inline-round:disabled{opacity:1;cursor:default;background:#f7f8f5;color:#546057;border-color:transparent}
.inline-round.serving{background:#dcebdd;color:#245538}.inline-round.pending{background:#fff0d6;color:#7e4c10}.inline-round.booked{background:#e5edf6;color:#2d5377}
.inline-round[aria-pressed=true]{background:#244f3b;color:white;border-color:#244f3b;box-shadow:0 0 0 2px #e4a253}
.inline-round.blocked{color:#a1a8a0}
.inline-booking-confirm{display:flex;justify-content:space-between;align-items:center;gap:8px;background:#fff0dd;border:1px solid #e5ac6e;border-radius:8px;padding:6px 8px}
.inline-booking-confirm>div{display:flex;flex-direction:column;gap:3px;min-width:0}.inline-booking-confirm strong{font-size:16px}.inline-booking-confirm span{font-size:14px}
.inline-booking-confirm .btn{font-size:16px;padding:8px;min-height:44px;flex:none}
.inline-booking-hint{margin:0;font-size:13px;color:#6a756b}
.inline-booking-undo{display:flex;align-items:center;justify-content:space-between;font-size:14px;color:#285a40}
.inline-booking-undo .text-btn{min-height:44px}
.inline-table-pages,.inline-seat-pages{display:flex;justify-content:center;align-items:center;gap:10px;font-size:14px}
.inline-table-pages .btn,.inline-seat-pages .btn{min-height:44px;padding:4px 12px}
#modal.candidate-screen :is(.replace-option,.next-cast-option){min-height:44px!important;padding:6px 3px!important;gap:2px;border-width:1px;border-radius:7px;box-shadow:none;height:auto}
#modal.candidate-screen .recommendation-heading strong{font-size:21px!important;line-height:1.2}
#modal.candidate-screen .candidate-current-place{font-size:11px;line-height:1.2}
#modal.candidate-screen .candidate-history{font-size:11px;line-height:1.25}
#modal.candidate-screen .candidate-controls{margin:0 0 8px;padding:0}
#modal.candidate-screen .cast-search{margin:8px 0 0}
#modal.candidate-screen .cast-search input{min-height:44px;font-size:16px}
#modal.candidate-screen .replace-current{min-height:60px;padding:8px 12px;margin:0 0 10px}
#modal.candidate-screen .replace-current>svg{display:none}
#modal.candidate-screen .replace-current strong{font-size:25px}
#modal.candidate-screen .replace-shortcuts{justify-content:flex-start;padding-top:8px}
@media(max-width:699px){
 #modal.candidate-screen .cast-action-layout{display:flex;flex-direction:column;gap:16px}
 #modal.candidate-screen .quick-moves,#modal.candidate-screen .cast-replacements{width:100%;padding:0;border:0}
 .inline-round-head,.inline-move-row{grid-template-columns:minmax(80px,1.05fr) repeat(3,minmax(0,1fr));gap:3px;padding-inline:4px}
 .inline-move-table>header{flex-wrap:wrap;gap:2px}.inline-move-table>header strong{font-size:16px}
 .inline-round strong{font-size:17px}.inline-round small{font-size:10px}
 .inline-booking-confirm{flex-wrap:wrap}
}
#modal.candidate-screen .modal-body{overflow:auto}
#modal.candidate-screen .immediate-moves{margin:0}
#modal.candidate-screen .immediate-moves summary{min-height:40px;padding:8px;font-size:13px;border:1px solid #ccd7cd;border-radius:7px}
.inline-round.nomination{background:#fff0d6;color:#7e4c10}
#modal.candidate-screen .next-unavailable[hidden]{display:none}
.inline-move-table>header{padding-block:4px}
.inline-move-row{padding-block:2px}
#modal.cast-actions-screen .modal-heading{padding-block:10px}
#modal.candidate-screen .replace-shortcuts{display:block;min-height:44px}
#modal.candidate-screen .replace-shortcuts>summary{font-size:14px;line-height:28px;cursor:pointer}
.replace-secondary-actions{display:flex;gap:5px;flex-wrap:wrap;padding-top:6px}
#modal.cast-actions-screen .replace-current{padding-block:4px}
#modal.cast-actions-screen .replace-current>div>small{display:none}
/* A real seating diagram links directly to the next booking target. */
#modal.cast-actions-screen .cast-action-layout{grid-template-columns:minmax(0,1.8fr) minmax(0,1fr);gap:12px}
.inline-table-content{display:grid;grid-template-columns:minmax(150px,.9fr) minmax(0,1.9fr);align-items:stretch;gap:5px;padding:3px}
.inline-rotations{min-width:0}
.inline-table-content .inline-round-head,.inline-table-content .inline-move-row{grid-template-columns:minmax(66px,.9fr) repeat(3,minmax(0,1fr));padding-inline:2px;gap:3px}
.inline-table-content .inline-round strong{font-size:16px}
.inline-table-content .inline-move-seat strong{font-size:12px}
.inline-table-content .inline-round-head{font-size:12px}
.inline-table-content .inline-round small{font-size:10px;white-space:normal}
.booking-mini-wrap{position:relative;min-width:0;min-height:162px;align-self:stretch;border-radius:7px;overflow:hidden;background:#f8f3e9}
.booking-mini-map{position:absolute;inset:0;isolation:isolate}
.booking-mini-map>.room-furniture{position:absolute;inset:0;width:100%;height:100%;z-index:0;opacity:.65}
.booking-mini-table-label{position:absolute;display:none;align-items:center;justify-content:center;text-align:center;font-size:16px;z-index:1;color:#7a6a53;pointer-events:none}
.booking-mini-seat{position:absolute;display:flex;align-items:center;justify-content:center;z-index:2;min-width:0;min-height:36px;padding:2px;border:1px solid #6f987f;border-radius:6px;background:#e2efe3;color:#244b35;cursor:pointer;overflow:hidden;touch-action:manipulation;font:inherit}
.booking-mini-seat b{font-size:clamp(11px,calc(56px / var(--map-name-length)),17px);line-height:1.15;white-space:nowrap}
.booking-mini-seat.empty,.booking-mini-seat.reserved{background:#fff1d6;color:#824919;border-style:dashed;border-color:#c59150}
.booking-mini-seat[aria-pressed=true]{background:#28563f;color:white;border:2px solid #28563f;box-shadow:0 0 0 2px #fff}
.booking-mini-seat.destination-selected{outline:3px solid #d96812;outline-offset:-3px}
.booking-mini-wrap .booking-map-expand{position:absolute;z-index:3;left:50%;top:40%;transform:translateX(-50%);min-height:44px;min-width:54px;padding:5px;color:#385447;background:#fffaf2de;border:1px solid #d6cbb5;border-radius:6px;font-size:13px}
.booking-mini-map.kind-vip .sofa-body{fill:#715151}
.booking-targets{display:grid;gap:5px;margin-bottom:9px}
.booking-target-group{display:grid;grid-template-columns:58px minmax(0,1fr);align-items:center;gap:5px}
.booking-target-group>small{font-size:12px;line-height:1.3;color:#637568}
.booking-target-group>div{display:flex;gap:4px;flex-wrap:wrap}
.booking-target-chip{flex:1 1 76px;min-height:40px;padding:5px;border:1px solid #b4c8b9;border-radius:7px;background:#f0f5ed;color:#2b503b;font:700 14px/1.2 inherit;cursor:pointer}
.booking-target-chip[aria-pressed=true]{background:#28563f;color:#fff;border-color:#28563f}
.booking-candidate-for{font-size:18px;font-weight:750;color:#2e543d;margin-bottom:3px}
#modal.candidate-screen .booking-candidate-for+.candidate-controls strong{font-size:15px}
#modal.booking-map-screen{max-width:760px}
#modal.booking-map-screen .booking-mini-wrap.expanded{height:min(65dvh,600px);min-height:360px;width:min(100%,610px);margin:auto}
.booking-mini-wrap.expanded .booking-mini-seat{min-height:44px}
.booking-mini-wrap.expanded .booking-mini-seat b{font-size:clamp(15px,calc(110px / var(--map-name-length)),27px)}
.booking-mini-wrap.expanded .booking-mini-table-label{display:flex;font-size:22px}
.booking-map-help{font-size:16px;text-align:center;margin:10px 0 0;color:#506556}
@media(min-width:700px) and (max-width:900px){
 #modal.cast-actions-screen .cast-action-layout{grid-template-columns:minmax(0,1.55fr) minmax(0,1fr)}
 .inline-table-content{grid-template-columns:1fr}
 .booking-mini-wrap{height:150px;min-height:150px}
 .booking-mini-map{max-width:320px;left:50%;transform:translateX(-50%);width:100%}
}
@media(max-width:699px){
 #modal.cast-actions-screen .cast-action-layout{display:flex}
 .inline-table-content{grid-template-columns:1fr}
 .booking-mini-wrap{height:170px;min-height:170px}
 .booking-mini-map{max-width:360px;left:50%;transform:translateX(-50%);width:100%}
 .booking-mini-seat{min-height:44px}.booking-mini-seat b{font-size:18px}
 .inline-table-content .inline-round strong{font-size:18px}
 .booking-target-chip{min-height:44px;font-size:15px}
}
.booking-target-chip{font:inherit;font-size:14px;font-weight:700;line-height:1.2;white-space:nowrap}
.booking-mini-seat{container-type:inline-size}
.booking-mini-seat b{font-size:clamp(11px,calc((100cqw - 6px) / var(--map-name-length)),17px)}
.booking-mini-map.dense .booking-mini-seat{min-height:0}
.booking-mini-map.dense .booking-mini-seat b{font-size:11px}
.booking-mini-wrap.expanded .booking-mini-seat b{font-size:clamp(13px,calc((100cqw - 8px) / var(--map-name-length)),27px)}
@media(max-width:699px){.booking-target-chip{font-size:15px}}
.booking-mini-seat{min-height:44px}
.booking-mini-map.dense .booking-mini-seat:disabled{opacity:1;cursor:default}
@media(min-width:700px) and (max-width:900px){#modal.cast-actions-screen[open]{height:calc(100dvh - 24px)}}
/* Keep the direct nomination picker beside Free / Nomination on phones too. */
@media(max-width:699px){
 #modal.quick-intake-modal.compact-intake .quick-person-main{grid-template-columns:minmax(0,1fr) minmax(0,1fr) 40px!important}
 #modal.quick-intake-modal.compact-intake .quick-person-main .quick-person-heading{grid-area:1/1!important}
 #modal.quick-intake-modal.compact-intake .quick-person-main .quick-style{grid-area:1/2!important;font-size:16px!important}
 #modal.quick-intake-modal.compact-intake .quick-person-main .quick-type{grid-area:2/1!important;min-width:0!important;width:100%!important}
 #modal.quick-intake-modal.compact-intake .quick-person-main .quick-type button{min-width:0!important;padding-inline:4px!important;font-size:17px!important}
 #modal.quick-intake-modal.compact-intake .quick-person-main .quick-cast:not(:disabled){grid-area:2/2/3/4!important;font-size:18px!important}
}

/* Give the facing sofas the unused vertical room, instead of shrinking their names. */
@media(min-width:700px){
 .operations-workspace .live-floor-map.photo-floor{grid-template-rows:minmax(0,1fr) max-content minmax(0,1.25fr)!important}
 .operations-workspace:has(.live-floor-map) .dispatch-panel.central-console.compact-console.roster-inside{height:auto!important;min-height:0!important;max-height:none!important}
 .operations-workspace:has(.live-floor-map) .compact-console .console-lower[hidden]{display:none!important}
 .operations-workspace:has(.live-floor-map) .compact-console.roster-collapsed{gap:0!important}
}
.roster-close{flex:0 0 36px;min-height:44px;align-self:stretch;border:1px solid #c2cfc7;border-radius:7px;background:#edf3ee;color:#365c48;font:700 24px/1 system-ui;cursor:pointer}
.room-scene:not(.room-detail) .floor-seat-pair.full-sofa.flow-vertical{grid-template-rows:30px minmax(0,1fr)!important;gap:8px!important}
.room-scene:not(.room-detail) .floor-seat-pair.full-sofa.flow-vertical:has(>.floor-seat-slot:first-child>.floor-cast){grid-template-rows:minmax(0,1fr) 30px!important}
.room-scene:not(.room-detail) .floor-seat-pair.full-sofa.flow-vertical:has(>.floor-seat-slot:first-child>.floor-cast):has(>.floor-seat-slot:last-child>.floor-cast),
.room-scene:not(.room-detail) .floor-seat-pair.full-sofa.flow-vertical:has(>.floor-seat-slot:first-child>.floor-customer):has(>.floor-seat-slot:last-child>.floor-customer){grid-template-rows:1fr 1fr!important}
/* Moderate cards on a lone sofa; leave room for the seating state. */
.room-scene:not(.room-detail) .floor-seat-pair.full-sofa{max-height:230px}
:is(#app,#modal) .room-scene .full-sofa .floor-seat-slot>.floor-cast.name-first{gap:5px!important;padding:18px 2px 22px!important;max-height:164px}
:is(#app,#modal) .room-scene .full-sofa .floor-seat-slot>.floor-cast.name-first:not(:has(.next-cast-label)){max-height:132px}
:is(#app,#modal) .room-scene .full-sofa .floor-cast.name-first .cast-name-large{align-self:center!important;margin:0!important;line-height:1.05!important}
:is(#app,#modal) .room-scene .full-sofa .floor-cast.name-first .name-seated-check{top:1px!important;right:1px!important}
:is(#app,#modal) .room-scene .full-sofa .floor-cast.name-first .cast-time-check{bottom:4px!important;padding-inline:0!important}
:is(#app,#modal) .room-scene .full-sofa .floor-cast.name-first .next-cast-label{padding-top:3px}
:is(#app,#modal) .room-scene .full-sofa .floor-cast.name-first.fit-next-side .cast-name-large{align-self:flex-start!important;margin-left:1px!important}
:is(#app,#modal) .room-scene .full-sofa .floor-cast.name-first.fit-next-side .next-cast-label{position:absolute!important;left:auto;right:3px;top:50%;bottom:auto;transform:translateY(-50%);width:var(--fit-next);border-top:0;border-left:1px solid currentColor;padding:0 0 0 3px;box-sizing:content-box;gap:3px}
:is(#app,#modal) .room-scene .full-sofa .floor-cast.name-first.fit-next-side .next-cast-label small{writing-mode:vertical-rl;font-size:9px}
/* The next booking and elapsed time each own a row on horizontal sofas. */
:is(#app,#modal) .room-scene:is(.room-joined,.room-banquette) .flow-horizontal .floor-seat-slot>.floor-cast.name-first{padding:3px 2px 2px!important}
:is(#app,#modal) .room-scene:is(.room-joined,.room-banquette) .flow-horizontal .floor-cast.name-first .name-seated-check{top:calc(-1 * var(--fit-check,18px))!important}
:is(#app,#modal) .room-scene:is(.room-joined,.room-banquette) .flow-horizontal .floor-cast.name-first .cast-name-large{order:1}
:is(#app,#modal) .room-scene:is(.room-joined,.room-banquette) .flow-horizontal .floor-cast.name-first .next-cast-label{order:2}
:is(#app,#modal) .room-scene:is(.room-joined,.room-banquette) .flow-horizontal .floor-cast.name-first .cast-time-check{position:static!important;transform:none!important;order:3;width:100%!important;max-width:100%!important;padding:0!important;margin:0!important;line-height:1.1}
:is(#app,#modal) .room-scene .floor-cast.name-first .next-cast-label.unbooked{color:#783e13;background:#fff1d8;border-radius:3px;padding:2px 3px;font-weight:750;line-height:1.1;opacity:1}
@media(min-width:700px){
 /* Empty action rows must not reserve 48px between sofas and the centre bar. */
 .live-booth>.booth-seat-actions:empty{display:none!important}
 .operations-workspace .live-booth:has(>.booth-seat-actions:empty)>.room-scene{height:100%!important}
 .operations-workspace .live-booth.joined-booth:has(>.booth-seat-actions:empty)>.room-scene,
 .operations-workspace .live-booth.vip-booth:has(>.booth-seat-actions:empty)>.room-scene{height:100%!important}
 .room-scene.room-joined>.floor-seat-pair.seat-back,.room-scene.room-banquette>.floor-seat-pair.seat-back{top:6%!important;height:30%!important}
 .room-scene.room-joined>.floor-seat-pair.seat-front,.room-scene.room-banquette>.floor-seat-pair.seat-front{top:70%!important;height:29%!important}
 .operations-workspace:has(.live-floor-map) .compact-console .console-controls{height:58px!important}
 .operations-workspace:has(.live-floor-map) .compact-console .roster-tabs button{height:58px!important;min-height:58px!important}
 .operations-workspace:has(.live-floor-map) .compact-console .roster-tabs .console-arrival{font-size:19px!important}
 .compact-console .console-clock{height:58px!important}
 .compact-console .console-clock .clock-face{max-height:52px!important}
 .compact-console .console-clock time{font-size:clamp(26px,16cqw,32px)!important;line-height:1.05!important}
 .compact-console .console-clock [data-clock-date]{font-size:15px!important;line-height:1.1!important}
 .compact-console .cast-metrics .metric-label,.compact-console .roster-label{font-size:14px!important;line-height:19px!important}
 .compact-console .cast-metrics .metric-value b,.compact-console .arrival-metric b{font-size:22px!important;line-height:25px!important}
 .compact-console .cast-metrics{height:44px!important}
 .compact-console .cast-metrics .roster-metric{grid-template-rows:19px 25px!important}
 .compact-console .cast-metrics .metric-value,.compact-console .arrival-metric{height:25px!important;grid-template-rows:25px!important;line-height:25px!important}
.compact-console .roster-metric small{font-size:12px!important;line-height:20px!important}
}

/* Compact notices keep three readable lines and give height back to the floor. */
@media(min-width:700px){
 .operations-workspace .floor-status-bar:has(.floor-alerts:not([hidden])){height:80px!important;flex-basis:80px!important}
 .operations-workspace .floor-alerts{height:76px!important;padding:4px!important;gap:6px!important}
 .operations-workspace .floor-alert-list{height:64px!important;gap:6px!important}
 .operations-workspace .floor-alert-count{height:64px!important;min-height:64px!important;min-width:72px!important;flex-basis:72px!important;padding:3px 5px}
 .operations-workspace .floor-alert-count>span{font-size:13px;line-height:20px}
 .operations-workspace .floor-alert-count>b{font-size:24px;line-height:28px}
 .operations-workspace .floor-alert-count>b small{font-size:12px}
 .operations-workspace .floor-alert-chip{height:64px!important;min-height:64px!important;min-width:202px!important;padding:3px 9px!important;gap:0!important}
 .operations-workspace .floor-alert-chip .alert-card-top{flex-wrap:nowrap;line-height:18px;gap:6px}
 .operations-workspace .floor-alert-chip .alert-table,.operations-workspace .floor-alert-chip .alert-who{font-size:15px;line-height:18px}
 .operations-workspace .floor-alert-chip .alert-note{font-size:15px;line-height:19px;font-weight:750}
 .operations-workspace .floor-alert-chip .alert-card-bottom{line-height:18px;gap:6px}
 .operations-workspace .floor-alert-chip .alert-card-bottom strong{font-size:13px!important;line-height:18px!important;white-space:nowrap}
 .operations-workspace .floor-alert-chip .alert-card-bottom i{font-size:18px;line-height:18px}
 .operations-workspace .alert-controls{flex:0 0 132px;flex-direction:row;align-items:center;gap:4px}
 .operations-workspace .alert-controls .floor-alert-all{height:44px;min-height:44px;flex:1 1 70px;font-size:13px;padding:3px}
 .operations-workspace .alert-controls .alert-audio{height:44px;min-height:44px;flex:1 1 58px;font-size:12px;padding:3px}
}
/* A customer name and nomination badge use separate columns, never overlays. */
.room-scene:not(.room-detail) .floor-seat-slot>.floor-customer.fit-compact{flex-direction:row!important;align-items:center!important;justify-content:center!important;gap:1px!important;padding:0!important}
.room-scene:not(.room-detail) .floor-customer.fit-compact>.floor-person-copy{flex:1 1 0;min-width:0}
.room-scene:not(.room-detail) .floor-customer.fit-compact .floor-person-copy>b{padding:0!important;line-height:1.1!important;max-width:100%}
.room-scene:not(.room-detail) .floor-customer.fit-compact>.floor-nomination{position:static!important;flex:0 0 10px;min-width:10px;width:10px;padding:0!important;font-size:10px;line-height:15px;align-self:center}
.room-scene:not(.room-detail) .floor-customer.fit-caption-wrap .floor-person-copy>b{white-space:normal!important;word-break:break-all!important;overflow-wrap:anywhere}
/* Use the actual tabletop bounds rather than the old 40%-wide text overlay. */
:is(#app,#modal) .room-scene.room-opposed:not(.room-detail).occupied .live-table-core{left:36%!important;width:28%!important;min-width:0!important}
:is(#app,#modal) .room-scene.room-opposed:not(.room-detail).occupied .live-table-core>.core-counts{display:flex!important;max-width:100%;line-height:1.1!important}
:is(#app,#modal) .room-scene.room-opposed:not(.room-detail).occupied .live-table-core .room-headcount b{font-size:var(--fit-count,16px)!important}
:is(#app,#modal) .room-scene.room-opposed:not(.room-detail).occupied .live-table-core .room-headcount small{font-size:calc(var(--fit-count,16px) * .65)!important}

/* The centre controls take only the height their touch targets need. */
@media(min-width:700px){
 .operations-workspace .live-floor-map.photo-floor{grid-template-rows:minmax(0,1.1fr) max-content minmax(0,1fr)!important;row-gap:4px!important}
 .operations-workspace:has(.live-floor-map) .dispatch-panel.central-console.compact-console.roster-inside{padding:4px!important;gap:2px!important;border-radius:8px}
 .operations-workspace:has(.live-floor-map) .compact-console .console-controls{height:48px!important}
 .operations-workspace:has(.live-floor-map) .compact-console .roster-tabs button{height:48px!important;min-height:48px!important}
 .compact-console .console-clock{height:48px!important;padding:1px!important}
 .compact-console .console-clock .clock-face{max-height:42px!important}
 .compact-console .console-clock time{font-size:26px!important}
 .compact-console .console-clock [data-clock-date]{font-size:13px!important}
 .compact-console .cast-metrics{height:40px!important}
 .compact-console .cast-metrics .roster-metric{grid-template-rows:18px 22px!important}
 .compact-console .cast-metrics .metric-label,.compact-console .roster-label{font-size:13px!important;line-height:18px!important}
 .compact-console .cast-metrics .metric-value,.compact-console .arrival-metric{height:22px!important;grid-template-rows:22px!important;line-height:22px!important}
 .compact-console .cast-metrics .metric-value b,.compact-console .arrival-metric b{font-size:20px!important;line-height:22px!important}
 .operations-workspace:has(.live-floor-map) .compact-console .console-lower:has([data-cast-results=roster]){height:46px!important}
 .operations-workspace:has(.live-floor-map) .compact-console .console-roster:has([data-cast-results=roster]){height:46px!important;min-height:46px!important;max-height:46px!important}
 .room-scene.room-joined>.floor-seat-pair.seat-back{height:28%!important}
}
/* A joined table owns separate, non-overlapping controls on its tabletop. */
:is(#app,#modal) .room-scene.room-joined .live-table-core.joined-table-panel{display:grid!important;grid-template-columns:minmax(0,1fr) minmax(0,1fr)!important;grid-template-rows:minmax(0,1fr)!important;gap:6px!important;padding:3px!important;background:#faf7ed!important;border-radius:5px;align-items:stretch!important;overflow:visible!important;min-width:0!important}
.joined-table-summary,.joined-table-clock{display:flex;flex-direction:column;justify-content:center;align-items:center;gap:3px;border:0;border-radius:4px;background:transparent;color:inherit;padding:2px;min-width:0!important;min-height:44px;cursor:pointer;font:inherit;touch-action:manipulation}
.joined-table-summary{grid-area:1/1!important}
.joined-table-timing{grid-area:1/2!important;display:flex;align-items:center;justify-content:center;gap:4px;min-width:0}
.joined-table-clock{flex:1 1 0;width:0;padding:0}
:is(#app,#modal) .room-scene.room-joined .joined-table-panel .core-counts{display:flex!important;flex-direction:row!important;line-height:1.1!important;max-width:100%}
:is(#app,#modal) .room-scene.room-joined .joined-table-panel .room-headcount b{font-size:var(--fit-count,20px)!important}
:is(#app,#modal) .room-scene.room-joined .joined-table-panel .room-headcount small{font-size:calc(var(--fit-count,20px) * .65)!important}
.joined-stay-choice{position:static!important;flex:0 0 48px;width:48px!important;height:44px!important;min-height:44px!important;min-width:44px!important;margin:0!important;padding:2px!important;border:1px solid #c24728!important;border-radius:5px!important;background:#fff0d6!important;color:#862a19!important;font-size:13px!important;font-weight:750;line-height:1.1!important;box-shadow:none!important;white-space:nowrap}
.joined-stay-choice.scheduled{background:#e5eff1!important;color:#365b64!important;border-color:#83a3ab!important}
.joined-stay-choice.completed{background:#edf4ef!important;color:#28563c!important;border-color:#68947c!important}
.joined-stay-choice:focus-visible,.joined-table-clock:focus-visible,.joined-table-summary:focus-visible{outline:3px solid #377d76;outline-offset:2px}

/* Reserve every seat's rounds together; keep the candidate names in a wide grid. */
#modal.table-reservation-screen .cast-action-layout{grid-template-columns:minmax(0,1.15fr) minmax(0,1fr);gap:16px;align-items:start}
.table-booking-side,.table-booking-board{min-width:0}
.table-booking-board{border:1px solid #c0cec2;border-radius:9px;background:#fff;overflow:hidden}
.table-booking-board>header{display:flex;justify-content:space-between;align-items:center;gap:8px;padding:7px 10px;background:#eaf1e9;color:#294d3b}
.table-booking-board>header strong{font-size:18px}.table-booking-board>header span{font-size:14px;font-variant-numeric:tabular-nums}
.table-booking-board>.booking-mini-wrap{height:160px;min-height:160px;margin:4px}
.table-booking-head,.table-booking-row{display:grid;grid-template-columns:minmax(74px,1.1fr) repeat(3,minmax(0,1fr));gap:5px;padding:4px 6px}
.table-booking-head{background:#f1f5ef;text-align:center;font-size:13px;line-height:20px;color:#49604f}
.table-booking-rows{max-height:280px;overflow:auto;overscroll-behavior:contain}
.table-booking-row{border-top:1px solid #e8eee5}
.table-booking-person{display:flex;flex-direction:column;justify-content:center;gap:3px;min-width:0}
.table-booking-person strong{font-size:16px;color:#294d3b;overflow-wrap:anywhere;line-height:1.2}
.table-booking-person small{font-size:11px;color:#687367;line-height:1.2}
.table-booking-cell{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:2px;min-width:0;min-height:48px;padding:3px 2px;border:1px solid #b8cbb9;border-radius:6px;background:#eef5ea;color:#28513a;cursor:pointer;font:inherit;touch-action:manipulation}
.table-booking-cell strong{font-size:16px;line-height:1.2;white-space:nowrap}
.table-booking-cell small{font-size:11px;line-height:1.1}
.table-booking-cell:disabled{opacity:1;cursor:default;background:#f3f5f0;color:#687064;border-color:transparent}
.table-booking-cell.pending,.table-booking-cell.nomination{background:#fff0d7;color:#835021}
.table-booking-cell.serving{background:#dcebdc;color:#285839}
.table-booking-cell.booked{background:#e6edf4;color:#2d5271}
.table-booking-cell[aria-pressed=true]{background:#28563f;color:#fff;border-color:#28563f;box-shadow:inset 0 0 0 1px #28563f}
.cast-move-disclosure{margin-top:7px}.cast-move-disclosure>summary{display:flex;align-items:center;min-height:44px;font-size:14px;font-weight:700;color:#335740;cursor:pointer;list-style:revert}.cast-move-disclosure>summary::before{content:'›';font-size:22px;margin-right:7px}.cast-move-disclosure[open]>summary::before{content:'⌄'}
#modal.table-reservation-screen .cast-replacements{min-width:0}
#modal.table-reservation-screen .booking-candidate-for{font-size:19px;margin:0 0 3px}
#modal.table-reservation-screen .candidate-controls{margin:0 0 10px}
#modal.table-reservation-screen .candidate-controls{display:flex;align-items:baseline;justify-content:space-between;gap:8px}
#modal.table-reservation-screen .candidate-controls small{font-size:12px;line-height:1.3;color:#6a796d;text-align:right}
#modal.table-reservation-screen .recommendation-heading strong{font-size:17px!important;line-height:1.2}
#modal.table-reservation-screen :is(.replace-option,.next-cast-option){min-height:48px!important;padding:5px 3px!important}
#modal.table-reservation-screen .candidate-history{font-size:11px;line-height:1.2}
#modal.table-reservation-screen .replace-current{margin-bottom:8px}
#modal.table-reservation-screen .replace-current .cast-visual{display:none}
#modal.table-reservation-screen .replace-shortcuts{margin-top:3px;padding-top:0}
#modal.table-reservation-screen .next-unavailable>summary{font-size:13px}
@media(min-width:700px) and (max-width:900px){
 #modal.table-reservation-screen .cast-action-layout{display:grid;grid-template-columns:minmax(0,1.15fr) minmax(0,1fr);gap:10px}
 .table-booking-head,.table-booking-row{grid-template-columns:minmax(64px,1.05fr) repeat(3,minmax(0,1fr));gap:3px;padding-inline:4px}
 .table-booking-cell strong{font-size:14px}.table-booking-person strong{font-size:14px}
 #modal.table-reservation-screen .recommendation-heading strong{font-size:16px!important}
}
@media(max-width:699px){
 #modal.table-reservation-screen .cast-action-layout{display:flex;flex-direction:column;gap:12px}
 .table-booking-side{width:100%}.table-booking-board>.booking-mini-wrap{display:none}
 .table-booking-cell strong{font-size:15px}.table-booking-person strong{font-size:14px}
 .table-booking-rows{max-height:240px}
}
.table-booking-cell{appearance:none;position:relative;isolation:isolate}
.table-booking-cell>strong,.table-booking-cell>small{position:relative;z-index:1;color:inherit}

/* Select and confirm in the same touch target, without a trip to the footer. */
#modal .quick-booking-option{container-type:inline-size;touch-action:manipulation}
#modal .quick-booking-option .recommendation-heading{flex-wrap:nowrap;justify-content:center;gap:4px;min-width:0}
#modal .quick-booking-option .recommendation-heading strong{flex:0 1 auto;min-width:0;white-space:nowrap}
#modal .quick-booking-option .candidate-confirm{display:none;flex:0 0 auto;font-size:12px;line-height:20px;font-weight:750;padding:0 3px;background:#28563f;color:#fff;border-radius:4px}
#modal .quick-booking-option[aria-pressed=true] .candidate-confirm{display:inline-block}
#modal .quick-booking-option[aria-pressed=true] .recommendation-heading strong{font-size:clamp(12px,calc((100cqi - 34px) / var(--candidate-name-length,5)),17px)!important}
#modal .quick-booking-option[aria-pressed=true]{border-width:1px!important;background:#e2eee5!important;border-color:#417958!important;box-shadow:inset 0 0 0 1px #417958!important}
.booking-reservation{display:flex;flex-wrap:wrap;align-items:center;gap:4px 8px;color:#294d3b}
.booking-reserved-name{display:flex;align-items:center;gap:7px;min-height:44px;padding:4px 8px;border:1px solid #bdcfc0;border-radius:6px;background:#eef5ee;color:inherit;font:inherit;cursor:pointer;touch-action:manipulation}
.booking-reserved-name strong{font-size:18px}.booking-reserved-name small{font-size:11px}
.booking-cancel{min-height:44px;padding:4px 10px;border:1px solid #cf9d88;border-radius:6px;background:#fff5eb;color:#943d25;font:inherit;font-size:14px;font-weight:700;cursor:pointer;touch-action:manipulation}
.service-booked-name{min-height:44px;border:0;border-radius:5px;background:#e6edf4;color:#2d5271;font:inherit;font-size:21px;font-weight:750;padding:3px 8px;cursor:pointer;touch-action:manipulation}
.booking-reserved-name:focus-visible,.booking-cancel:focus-visible,.service-booked-name:focus-visible{outline:3px solid #417958;outline-offset:2px}

/* Leave a reachable backdrop; an empty table should not occupy the whole floor. */
#modal.table-screen.history-first-screen{height:min(800px,calc(100dvh - 96px))!important;max-height:calc(100dvh - 96px)!important;margin:auto!important}
#modal.table-screen.history-first-screen[data-guests="0"]{width:min(680px,calc(100vw - 64px))!important;max-width:calc(100vw - 32px)!important;height:fit-content!important;min-height:0!important;max-height:min(600px,calc(100dvh - 112px))!important}
#modal.table-screen.history-first-screen[data-guests="0"] .modal-body{flex:0 1 auto;overflow:auto!important}
#modal.history-first-screen[data-guests="0"] .table-history-layout{height:auto}
#modal.history-first-screen[data-guests="0"] .table-history-main{flex:none}
#modal.history-first-screen[data-guests="0"] .table-history-archive{flex:none;overflow:visible}
#modal.table-screen.history-first-screen::backdrop{background:rgb(20 42 34 / 22%);backdrop-filter:none}
@media(max-width:699px){
 #modal.table-screen.history-first-screen[data-guests="0"]{width:calc(100vw - 32px)!important}
 #modal.history-first-screen[data-guests="0"] .modal-heading{padding:10px;gap:8px}
 #modal.history-first-screen[data-guests="0"] .modal-heading h2{font-size:18px}
}

/* Repeated table service is a warning, never a yellow recommendation. */
#modal.candidate-screen :is(.replace-option,.next-cast-option).served-before,
#modal.table-reservation-screen :is(.replace-option,.next-cast-option).served-before{
 background:#f2efed!important;border:1px solid #c7b8b2!important;color:#77564b!important;box-shadow:none!important;opacity:1!important
}
#modal :is(.replace-option,.next-cast-option).served-before .candidate-history{color:#9a3e2d!important;font-weight:750}
#modal :is(.replace-option,.next-cast-option).served-before .candidate-restriction{color:#8d3022!important;font-weight:750}

/* Drag an eligible cast directly onto the second/third-round cell. */
#modal .replace-option[data-drag-booking-cast]{cursor:grab;touch-action:none;-webkit-user-select:none;user-select:none}
body.booking-cast-dragging #modal .table-booking-cell[data-drop-booking]{outline:3px dashed #dd7a19;outline-offset:-3px;background:#fff3df;color:#7b4717;box-shadow:0 0 0 3px rgb(221 122 25 / 18%)}
body.booking-cast-dragging #modal .table-booking-cell[data-drop-booking].drag-over{outline-style:solid;background:#dff0e2;color:#24583a;transform:scale(1.04);box-shadow:0 0 0 4px rgb(55 125 86 / 24%)}
#modal.table-reservation-screen .drag-ghost{display:flex;flex-direction:column;align-items:center;justify-content:center;min-width:92px;min-height:54px;padding:6px 12px;border:2px solid #377d56;border-radius:9px;background:#fff;color:#244e38;box-shadow:0 8px 22px rgb(18 50 35 / 28%);pointer-events:none;z-index:40}
#modal.table-reservation-screen .drag-ghost strong{font-size:18px;line-height:1.2}#modal.table-reservation-screen .drag-ghost small{font-size:11px}

/* Use the table panel's spare column for rapid second/third-round booking. */
#modal.table-screen .table-cast-dock{margin-top:auto;padding-top:8px;border-top:1px solid #d8e1d8;min-width:0}
#modal.table-screen .table-cast-dock header{display:flex;flex-direction:column;gap:1px;margin-bottom:5px;color:#315441}
#modal.table-screen .table-cast-dock header strong{font-size:16px}#modal.table-screen .table-cast-dock header small{font-size:11px;line-height:1.25}
#modal.table-screen .table-cast-dock>div{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:5px;max-height:218px;overflow:auto;overscroll-behavior:contain;padding:1px}
#modal.table-screen .table-cast-dock button{min-width:0;min-height:44px;padding:3px 4px;border:1px solid #abc4b0;border-radius:6px;background:#eef5ee;color:#28513a;font:750 16px/1.1 system-ui;cursor:grab;touch-action:none;-webkit-user-select:none;user-select:none}
#modal.table-screen .table-cast-dock button b{display:block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
#modal.table-screen .table-round[data-drop-booking]{touch-action:manipulation}
@media(max-width:900px){
 #modal.table-screen .table-cast-dock{grid-column:1/-1;margin-top:7px;padding-top:6px}
 #modal.table-screen .table-cast-dock header{flex-direction:row;align-items:baseline;justify-content:space-between}
 #modal.table-screen .table-cast-dock>div{grid-template-columns:repeat(5,minmax(0,1fr));max-height:100px}
}
@media(max-width:699px){
 #modal.table-screen .table-cast-dock>div{grid-template-columns:repeat(4,minmax(0,1fr));max-height:100px}
 #modal.table-screen .table-cast-dock button{font-size:15px}
}

/* A stable, finger-sized drop surface for every customer and every set. */
#modal.table-reservation-screen [data-drop-booking]{min-height:56px;scroll-margin:16px;touch-action:manipulation}
body.booking-cast-dragging #modal [data-drop-booking]{outline:2px dashed #b57830;outline-offset:-2px;background:#fff6e9;color:#704a22}
body.booking-cast-dragging #modal [data-drop-booking].drag-over{outline:3px solid #286548;outline-offset:-3px;background:#d6ecdf;color:#174b32;box-shadow:0 0 0 3px #28654830;transform:none}
#modal.booking-saving .modal-heading::after{content:'予約を保存中';font-size:12px;color:#315844;white-space:nowrap}
#modal.table-reservation-screen .table-booking-row{padding-block:3px}
#modal .inhouse-action,.phone-guest-actions .inhouse-action{min-height:44px;background:#edf5ff;color:#174c89;border:1px solid #5790d0;white-space:nowrap;font-weight:750;padding:8px 12px}
#modal .replace-current .inhouse-action{flex:none;margin-left:auto}
@media(max-width:699px){#modal .replace-current .inhouse-action{margin-left:0}}
#modal .table-booking-cell.continuing,#modal .table-round.nomination-continuing{background:#edf5ff;color:#174c89;border-color:#b7cfe9}
#modal .table-booking-cell.continuing small{font-size:11px}
/* Put the names alongside the booking work, rather than below the table tools. */
#modal.table-screen .table-history-main .table-cast-dock{flex:none;margin:0;padding:7px 0;border-top:0;border-bottom:1px solid #d8e1d8}
#modal.table-screen .table-history-main .table-cast-dock header{flex-direction:row;align-items:baseline;justify-content:space-between}
#modal.table-screen .table-history-main .table-cast-dock>div{grid-template-columns:repeat(auto-fit,minmax(78px,1fr));max-height:145px;gap:6px}
@media(max-width:699px){#modal.table-screen .table-history-main .table-cast-dock>div{grid-template-columns:repeat(4,minmax(0,1fr));max-height:96px}}

/* Open a person/seat from the whole heading, including its padding. */
.tap-surface{appearance:none;box-sizing:border-box;min-height:48px;border:1px solid #bacdbe;border-radius:7px;background:#f2f6f1;color:#294d3b;font:inherit;text-align:left;padding:8px;cursor:pointer;touch-action:manipulation}
@media (hover:hover){.tap-surface:hover{background:#e5efe6;border-color:#6b9379}}
.tap-surface:focus-visible{outline:3px solid #b17c37;outline-offset:2px}
.tap-surface:active{background:#d9e8dc}
.table-booking-person.tap-surface,.inline-move-seat.tap-surface,.move-booking-guest.tap-surface{width:100%;align-self:stretch;min-height:56px;gap:4px}
.table-booking-person.tap-surface[aria-pressed=true]{background:#28563f;color:#fff;border-color:#28563f}
.table-booking-person.tap-surface[aria-pressed=true] :is(strong,small){color:inherit}
.cast-card-head.tap-surface{display:flex;align-items:center;justify-content:space-between;width:100%;gap:8px;min-height:56px}
.cast-card-name{font-size:25px;font-weight:750;line-height:1.3;overflow-wrap:anywhere}
#modal .history-person-open.tap-surface{display:flex;align-items:flex-start;justify-content:space-between;gap:8px;flex:1;min-width:0;align-self:stretch}
.history-person-open .history-person-copy{display:flex;flex-direction:column;gap:4px;min-width:0}
#modal .history-person-open .table-guest-link{display:flex;padding:0;border:0;background:transparent;text-align:left}
#modal .history-person-open .history-set-count{flex:none;white-space:nowrap}
#modal .history-person-open .history-guest-kind{font-size:14px;line-height:1.35}
#modal .history-person-open.tap-surface,.move-booking-guest.tap-surface{background:#fff1dc;border-color:#dfc195;color:#65482b}
@media (hover:hover){#modal .history-person-open.tap-surface:hover,.move-booking-guest.tap-surface:hover{background:#f9e5c5;border-color:#b98e58}}
/* v4.24 — Names are primary; customer identity and service notes are secondary. */
:is(#app,#modal) .room-scene .floor-cast.name-first .next-cast-label{min-height:0!important;line-height:1.15!important}
:is(#app,#modal) .room-scene .floor-cast.name-first .next-cast-label b{font-weight:600!important}
:is(#app,#modal) .room-scene .floor-cast.name-first.fit-vertical .cast-name-large{align-self:center!important;margin-left:0!important}
:is(#app,#modal) .room-scene:is(.room-opposed,.room-corner) .floor-cast.name-first{padding-top:5px!important;padding-bottom:8px!important}
:is(#app,#modal) .room-scene .full-sofa .floor-seat-slot>.floor-cast.name-first{padding-top:16px!important;padding-bottom:20px!important;gap:4px!important}
.room-scene:is(.room-opposed,.room-corner) .floor-person-copy>b{font-weight:650!important}
.room-scene .floor-cast .nomination-moving,.room-scene .floor-cast .nomination-help{border-radius:3px;background:#fff4db;padding:2px 3px;color:#65471e!important}
/* Keep side swaps and manually moved cast/customer positions symmetric. */
.room-scene:is(.room-banquette,.room-joined) .floor-seat-pair.flow-horizontal:has(>.floor-seat-slot:first-child>.floor-customer):has(>.floor-seat-slot:last-child>.floor-cast){grid-template-columns:minmax(0,.8fr) minmax(0,1.2fr)!important}
.room-scene:is(.room-banquette,.room-joined) .floor-seat-pair.flow-horizontal:has(>.floor-seat-slot:first-child>.floor-cast):has(>.floor-seat-slot:last-child>.floor-customer){grid-template-columns:minmax(0,1.2fr) minmax(0,.8fr)!important}
/* 4卓: current name at left, next booking at right, clock inside the frame. */
:is(#app,#modal) .room-scene .floor-seat-slot>.floor-cast.name-first.sofa-cast{
 display:grid!important;grid-template:"name next" minmax(0,1fr) "time time" max-content / minmax(0,1.25fr) minmax(0,.75fr)!important;
 align-items:center!important;justify-items:center!important;gap:2px!important;padding:2px 2px 1px!important;
}
:is(#app,#modal) .room-scene .floor-seat-slot>.floor-cast.name-first.sofa-cast:not(:has(.next-cast-label)){grid-template:"name name" minmax(0,1fr) "time time" max-content / 1fr 1fr!important}
:is(#app,#modal) .room-scene .floor-cast.name-first.sofa-cast .cast-name-large{grid-area:name;align-self:center!important;justify-self:center!important;margin:0!important;font-weight:850!important}
:is(#app,#modal) .room-scene .floor-cast.name-first.sofa-cast .next-cast-label{grid-area:next;position:static!important;align-self:center!important;flex-direction:column!important;gap:2px!important;padding:0!important;margin:0!important;background:transparent!important;color:inherit!important;opacity:1!important;border:0!important;transform:none!important;width:auto!important;box-sizing:border-box!important}
:is(#app,#modal) .room-scene .floor-cast.name-first.sofa-cast .next-cast-label small{writing-mode:horizontal-tb!important;font-size:9px!important;line-height:1!important}
:is(#app,#modal) .room-scene .floor-cast.name-first.sofa-cast .next-cast-label b{writing-mode:vertical-rl!important;line-height:1!important}
:is(#app,#modal) .room-scene .floor-cast.name-first.sofa-cast .cast-time-check{grid-area:time;position:static!important;transform:none!important;padding:0!important;width:100%!important;max-width:100%!important;border-radius:0!important}
:is(#app,#modal) .room-scene .floor-cast.name-first.sofa-cast .cast-time-check [data-floor-overdue]{display:flex!important;flex-direction:column;align-items:center;gap:1px;line-height:1!important;font-weight:750}
:is(#app,#modal) .room-scene .floor-cast.name-first.sofa-cast .cast-time-check [data-floor-overdue]::after{content:none!important;display:none!important}
.sofa-cast .overdue-caption{font-size:9px;line-height:1}
.sofa-cast .overdue-minutes{font-size:inherit;line-height:1;white-space:nowrap;font-variant-numeric:tabular-nums}
.sofa-cast .overdue-minutes small{font-size:.85em;line-height:1}
/* Fixed name scale per screen size; guest count never changes the type size. */
.sofa-cast{--fixed-cast-name:18px}
@media(min-width:1250px){.sofa-cast{--fixed-cast-name:22px}}
@media(max-width:900px){.sofa-cast{--fixed-cast-name:16px}}
:is(#app,#modal) .room-scene .floor-cast.name-first.sofa-cast .cast-name-large{font-size:var(--fixed-cast-name)!important;line-height:1!important}
:is(#app,#modal) .room-scene .floor-seat-pair.flow-vertical:has(.sofa-cast){grid-template-rows:22px minmax(0,1fr)!important;gap:2px!important}
:is(#app,#modal) .room-scene .floor-seat-pair.flow-vertical:has(>.floor-seat-slot:first-child>.sofa-cast){grid-template-rows:minmax(0,1fr) 22px!important}
:is(#app,#modal) .room-scene .floor-seat-pair.flow-vertical:has(>.floor-seat-slot:first-child>.sofa-cast):has(>.floor-seat-slot:last-child>.sofa-cast){grid-template-rows:1fr 1fr!important}
/* Longer names keep the same font; use two vertical columns if needed. */
:is(#app,#modal) .room-scene .floor-seat-slot>.floor-cast.name-first.sofa-cast.fixed-name-columns{grid-template-columns:calc(var(--fixed-cast-name) * 2) minmax(0,1fr)!important;border-width:1px!important;padding:1px!important;column-gap:1px!important}
:is(#app,#modal) .room-scene .floor-cast.name-first.sofa-cast.fixed-name-columns .cast-name-large{height:calc(var(--fixed-cast-name) * 3)!important;width:calc(var(--fixed-cast-name) * 2)!important;max-width:none!important;white-space:normal!important;overflow-wrap:anywhere!important;word-break:break-all!important}

/* Sofa layout must not override the shared service-severity colors. */
:is(#app,#modal) .room-scene .floor-cast.name-first.sofa-cast .next-cast-label{
 color:inherit!important;border-left:1px solid #a9937945!important;padding-left:2px!important;
}
:is(#app,#modal) .room-scene .floor-cast.name-first.sofa-cast .next-cast-label b{font-weight:500!important}
:is(#app,#modal) .room-scene .floor-cast.name-first.sofa-cast .next-cast-label small{color:inherit!important;font-weight:500!important}
:is(#app,#modal) .room-scene .floor-cast.name-first.sofa-cast .cast-time-check:has([data-floor-overdue]){
 background:#b93423!important;color:#fff!important;border-radius:3px!important;
}
:is(#app,#modal) .room-scene .floor-cast.name-first.sofa-cast .cast-time-check [data-floor-overdue]{color:#fff!important}
:is(#app,#modal) .room-scene .floor-cast.name-first.sofa-cast .overdue-caption{font-weight:600!important;letter-spacing:.08em}
:is(#app,#modal) .room-scene .floor-cast.name-first.sofa-cast .overdue-minutes{font-weight:800!important}
