:root {
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: #27232c;
  background: #d0d9e2;
  --purple: #ca72e1;
  --purple-dark: #59435f;
  --purple-deep: #4c3655;
  --pink: #d9a6e9;
  --empty: #c9d3dd;
  --closed: #d0cece;
  --dirty: #ffe3b7;
  --ready: #00bc69;
  --occupied: #ff7f86;
  --due: #edbc72;
  --defective: #9f607e;
}
* {box-sizing:border-box}
[hidden] {display:none !important}
html, body {margin:0;min-height:100%;}
button, input, select {font:inherit}
button {cursor:pointer}
button:disabled {cursor:not-allowed;opacity:.45}
button:focus-visible, input:focus-visible, select:focus-visible, .board-scroller:focus-visible {outline:3px solid #503f70;outline-offset:2px}
.sr-only {position:absolute;width:1px;height:1px;margin:-1px;padding:0;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}
.topbar {height:64px;display:flex;justify-content:space-between;align-items:center;padding:0 22px 0 36px;background:linear-gradient(100deg,#c86bdc 0%,#d09de6 100%);gap:16px}
.brand {font-size:clamp(24px,2.15vw,38px);font-weight:750;letter-spacing:-.035em;color:#4c3e50;white-space:nowrap}
.brand span {font-weight:710}
.topbar-right {display:flex;align-items:center;gap:14px;min-width:0}
.ui-pill {height:39px;border-radius:50px;background:#cfd8e2;padding:0 20px;display:flex;justify-content:center;align-items:center;font-size:15px;font-weight:750;white-space:nowrap}
.account-pill {max-width:200px;overflow:hidden;text-overflow:ellipsis;display:block;line-height:39px}
.role-pill {background:#c7d2de}
.icon-button {border:0;background:#614a6a;color:#fff;border-radius:12px;min-width:38px;height:38px;font-size:24px;line-height:1}
.icon-button:hover {background:#49334f}
.ops-layout {display:flex;align-items:stretch;height:calc(100vh - 132px);min-height:460px}
.filter-rail {width:50px;min-width:50px;background:#c7d0d9;display:flex;flex-direction:column;align-items:stretch;padding-top:7px;z-index:2}
.rail-title {font-size:9px;font-weight:900;letter-spacing:.04em;text-align:center;color:#58616d;margin:4px 0 8px}
#status-nav {display:flex;flex-direction:column;gap:1px}
.rail-filter {min-height:61px;border:0;background:transparent;color:#24232b;font-size:11px;font-weight:800;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:2px;padding:3px 0}
.rail-filter small {font-size:10px;font-weight:500;color:#4f5863}
.rail-filter.active {background:#79717c;color:#fff}
.rail-filter.active small {color:#fff}
.rail-filter:hover:not(.active) {background:#b3bac8}
.workspace {flex:1;min-width:0;min-height:0;display:flex;flex-direction:column;overflow:hidden;background:#fff}
.board-tools {padding:8px 12px 7px;display:flex;gap:12px;align-items:center;justify-content:space-between;border-bottom:1px solid #dbe2e9;min-height:48px}
.board-heading {display:flex;align-items:baseline;gap:10px;white-space:nowrap}
.board-heading strong {font-size:13px;color:#513d5a}
.board-heading span {font-size:11px;color:#677284}
.board-controls {display:flex;gap:8px;align-items:center;justify-content:flex-end;min-width:0}
.board-controls input, .board-controls select {height:31px;max-width:180px;border:1px solid #c8c6d2;border-radius:8px;background:#f8f6fa;padding:4px 10px;font-size:12px;color:#333}
.board-controls input {width:118px}
.board-controls select {width:150px}
.hotel-clock {font-size:11px;color:#63606c;white-space:nowrap}
.board-error {margin:8px 12px;padding:10px;background:#fee2e2;color:#8c1515;border-radius:7px}
.board-scroller {width:100%;min-height:0;flex:1;overflow:auto;background:#fff;scrollbar-color:#aab0bb #eee;overscroll-behavior:contain}
.room-board {display:flex;flex-direction:column;gap:18px;padding:8px 7px 6px 4px;width:100%;min-width:1500px;min-height:100%}
.floor-row {flex:1;min-height:51px;max-height:91px;display:grid;grid-template-columns:repeat(38,minmax(0,1fr));gap:2px}
.grid-cell {position:relative;min-width:0;height:100%;border:0;border-radius:0;background:var(--empty)}
.grid-cell.empty {background:var(--closed)}
.grid-cell.empty.long-gap {background:#d4d2d2}
.grid-cell.room {padding:5px 0 4px;display:flex;flex-direction:column;align-items:center;justify-content:flex-start;gap:2px;font-size:11px;font-weight:750;color:#2b2228;overflow:hidden;transition:filter .15s,transform .15s}
.grid-cell.room:hover {filter:brightness(.94);outline:2px solid #594166;outline-offset:-2px;z-index:1}
.grid-cell.room:active {transform:scale(.97)}
.grid-cell.room .number {font-size:12px;line-height:1.2;font-variant-numeric:tabular-nums;font-weight:850;white-space:nowrap;letter-spacing:-.04em}
.grid-cell.room .room-kind {font-size:10px;line-height:1.1;white-space:nowrap}
.grid-cell.room .room-state {font-size:9px;letter-spacing:-.01em;line-height:1.15;white-space:nowrap}
.grid-cell.room.ready {background:var(--ready);color:#072d1f}
.grid-cell.room.dirty {background:var(--dirty)}
.grid-cell.room.occupied {background:var(--occupied)}
.grid-cell.room.dueout {background:var(--due)}
.grid-cell.room.defective {background:var(--defective);color:#fff}
.grid-cell.room.dimmed {background:var(--empty);color:transparent;pointer-events:none}
.grid-cell.room.dimmed span {visibility:hidden}
.grid-cell.room.match {outline:3px solid #402b55;outline-offset:-3px;z-index:1}
.legend {min-height:30px;padding:5px 10px;display:flex;flex-wrap:wrap;gap:6px 16px;align-items:center;border-top:1px solid #e3e0e6;color:#59505b;font-size:11px;background:#fff}
.legend span {display:inline-flex;align-items:center;gap:5px;white-space:nowrap}
.swatch {width:11px;height:11px;display:inline-block;border:1px solid #0001}
.swatch-ready {background:var(--ready)} .swatch-dirty {background:var(--dirty)} .swatch-occupied {background:var(--occupied)} .swatch-dueout {background:var(--due)} .swatch-defective {background:var(--defective)} .swatch-empty {background:var(--closed)}
.bottom-bar {min-height:68px;height:68px;background:linear-gradient(110deg,#d7a4e5,#cea0e0);display:flex;justify-content:space-between;align-items:center;gap:10px;padding:12px 16px 12px 50px;color:#654e6a;font-size:12px}
.updated-pill {background:#cbd1d9;color:#6a676c;border-radius:26px;padding:8px 14px;font-size:13px;white-space:nowrap}

/* Room overlay, based on the two-panel reference. */
.modal-root {position:fixed;inset:0;z-index:100;display:flex;align-items:center;justify-content:center;padding:22px}
.modal-shade {position:absolute;inset:0;background:#17121a94;backdrop-filter:blur(1px)}
.modal-layout {position:relative;display:grid;grid-template-columns:minmax(420px,1.15fr) minmax(350px,.95fr);width:min(1160px,94vw);max-height:calc(100vh - 44px);gap:20px;align-items:stretch}
.room-modal,.calendar-modal {background:var(--purple-dark);border-radius:26px;color:#f7f4f8;min-height:510px;max-height:calc(100vh - 44px);overflow-y:auto;padding:26px 25px;box-shadow:0 18px 55px #27162b3b}
.room-modal {display:flex;flex-direction:column;gap:13px}
.modal-headline {display:flex;flex-wrap:wrap;align-items:flex-start;gap:8px;justify-content:space-between}
.modal-headline h2 {font-size:clamp(28px,3.2vw,49px);letter-spacing:-.04em;margin:0;font-weight:750;color:#e8e1ea;line-height:1.06}
.modal-headline .room-subtitle {font-size:26px;font-weight:750;color:#e8e1ea;margin-top:4px}
.warning-pill {border-radius:20px;padding:7px 11px;background:#d6ad6a;color:#513d61;font-size:11px;font-style:italic;font-weight:750;max-width:320px}
.detail-meta {font-size:12px;color:#e3d6e5;display:flex;align-items:center;flex-wrap:wrap;gap:8px}
.status-chip {display:inline-block;border-radius:30px;padding:5px 9px;background:#b19ab3;color:#2b2130;font-weight:800;font-size:12px}
.status-chip.ready {background:var(--ready)} .status-chip.dirty {background:var(--dirty)} .status-chip.occupied {background:var(--occupied)} .status-chip.dueout {background:var(--due)} .status-chip.defective {background:#d893b2}
.detail-facts {display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px}
.detail-facts div {background:#ffffff16;padding:9px 10px;border-radius:11px;min-width:0}
.detail-facts small {display:block;font-size:10px;color:#e0d0e4;margin-bottom:4px}
.detail-facts strong {font-size:12px;overflow-wrap:anywhere}
.action-button {border:0;border-radius:11px;min-height:46px;padding:10px 16px;font-size:16px;font-weight:750;color:#3f3345;transition:filter .15s}
.action-button:hover:not(:disabled) {filter:brightness(1.07)}
.action-button.primary {background:#47bd35;color:#3f3345}
.action-button.secondary {background:#c2b6c5;color:#45314e}
.action-button.rose {background:#f1b1b6;color:#543448}
.action-button.full-width {width:100%}
.action-button.dark {background:#906f9a;color:#fff}
.action-button.tiny {min-height:33px;font-size:12px;padding:6px 9px}
.room-actions {display:flex;flex-direction:column;gap:8px;margin-top:4px}
.action-row {display:grid;grid-template-columns:1fr 1fr;gap:10px}
.spacer {flex:1;min-height:8px}
.modal-section {border-top:1px solid #ffffff2e;padding-top:12px}
.modal-section h3 {font-size:12px;letter-spacing:.04em;text-transform:uppercase;color:#ded2e4;margin:0 0 9px}
.condition-actions {display:flex;flex-wrap:wrap;gap:8px}
.inline-form {background:#ffffff12;padding:12px;border-radius:12px;display:flex;flex-direction:column;gap:8px}
.inline-form label {font-size:12px;font-weight:700}
.inline-form input,.inline-form select {width:100%;background:#f5eff6;border:1px solid #bbaabd;border-radius:7px;height:37px;color:#302334;padding:6px 9px;font-size:13px}
.inline-form .checkbox-label {display:flex;gap:9px;align-items:center;font-size:12px;font-weight:500}
.inline-form input[type="checkbox"] {width:16px;height:16px}
.inline-form p {margin:0;font-size:12px;color:#e7dce9}
.form-buttons {display:flex;justify-content:flex-end;gap:8px}
.history-list {display:grid;gap:6px;margin:0;padding:0;list-style:none}
.history-list li {display:flex;justify-content:space-between;gap:9px;font-size:11px;border-bottom:1px solid #ffffff1c;padding:4px 0}
.history-list time {color:#cfc0d5;flex-shrink:0}

.calendar-modal {display:flex;flex-direction:column;padding:26px}
.calendar-header {display:grid;grid-template-columns:1fr 1.4fr;gap:24px;margin:0 0 18px}
.calendar-header button {border:0;background:linear-gradient(110deg,#c867e3,#dda5e7);color:#514055;font-size:clamp(17px,2vw,24px);font-weight:750;border-radius:15px;height:52px;display:flex;align-items:center;justify-content:space-around}
.calendar-header button:hover {filter:brightness(1.06)}
.calendar-grid {display:grid;grid-template-columns:repeat(7,minmax(0,1fr));grid-auto-rows:minmax(48px,1fr);gap:2px;background:#eae8eb;padding:3px;flex:1;min-height:350px}
.weekday {display:flex;align-items:center;justify-content:center;background:#f0eff1;color:#171519;font-weight:800;font-size:15px}
.day {border:0;color:#fff;background:#5b4961;font-size:17px;border-radius:0;font-variant-numeric:tabular-nums}
.day:hover:not(:disabled) {background:#9d75aa}
.day.outside {background:#908995;color:#cfcad0;cursor:default}
.day.past {background:#928d9a;color:#dad4dd;cursor:not-allowed}
.day.today {box-shadow:inset 0 0 0 2px #d5b7e2}
.day.selected {background:#c36de4;color:#201326;box-shadow:inset 0 0 0 3px #fff;font-weight:900}
.calendar-help {font-size:12px;color:#ede0ef;padding-top:12px;line-height:1.5}
.modal-x {position:absolute;right:-11px;top:-12px;width:34px;height:34px;border-radius:50%;border:0;background:#fff;color:#47374a;font-size:25px;box-shadow:0 1px 7px #2225}
.toast {position:fixed;z-index:200;bottom:88px;right:24px;background:#3a2748;color:#fff;padding:12px 18px;border-radius:12px;box-shadow:0 6px 30px #1f162e55;max-width:min(420px,85vw);font-size:13px}
.toast.error {background:#a82e48}

.full-view {min-height:100vh;background:linear-gradient(145deg,#c879df,#f2e9f5 62%,#b5c3d2);display:grid;place-items:center;padding:20px}
.auth-panel {width:min(420px,100%);background:#fff;border-radius:20px;padding:35px;box-shadow:0 20px 60px #43264d29;display:flex;flex-direction:column;gap:10px}
.auth-brand {font-size:33px;font-weight:850;letter-spacing:-.035em;color:#604363}
.auth-brand span {font-weight:680}
.auth-panel h1 {margin:6px 0 0;font-size:27px}
.auth-panel p {line-height:1.5;font-size:13px;color:#5c5363;margin:2px 0 12px}
.auth-panel p.overline {font-size:10px;letter-spacing:.16em;margin:0;font-weight:800;color:#9a68a9}
.auth-panel label {font-size:12px;font-weight:750;margin-top:7px}
.auth-panel input {height:43px;border:1px solid #c7bbd2;border-radius:9px;padding:8px 12px;min-width:0}
.auth-panel .error-message {color:#b12444;margin:0}
.auth-panel p.auth-note {font-size:11px;text-align:center;margin:6px 0 0}

@media (max-width:1000px) {
  .topbar {padding-left:18px}
  .lang-pill {display:none}
  .board-tools {flex-wrap:wrap}
  .room-board {min-width:1370px}
  .modal-layout {gap:12px;grid-template-columns:1fr 1fr;width:96vw}
  .room-modal,.calendar-modal {padding:20px}
}
@media (max-width:710px) {
  .topbar {height:58px;padding:0 9px 0 14px}
  .brand {font-size:23px}
  .topbar-right {gap:5px}
  .ui-pill {font-size:12px;height:33px;padding:0 9px}
  .account-pill {max-width:105px;line-height:33px}
  .role-pill {display:none}
  .icon-button {min-width:32px;height:32px;font-size:20px}
  .ops-layout {height:calc(100dvh - 112px);min-height:380px}
  .filter-rail {min-width:46px;width:46px}
  .rail-filter {min-height:52px}
  .board-tools {align-items:flex-start;gap:5px;padding:7px}
  .board-controls {width:100%;justify-content:flex-start;flex-wrap:wrap}
  .hotel-clock {display:none}
  .board-scroller {flex:1}
  .room-board {min-width:1320px;gap:12px}
  .floor-row {min-height:52px}
  .bottom-bar {height:54px;min-height:54px;padding:5px 8px 5px 46px;font-size:10px}
  .updated-pill {font-size:11px;padding:8px}
  .legend {font-size:10px}
  .modal-root {padding:6px;align-items:flex-start;overflow:auto}
  .modal-layout {display:flex;flex-direction:column;width:100%;max-height:none;gap:8px}
  .room-modal,.calendar-modal {max-height:none;min-height:0;border-radius:17px;padding:16px}
  .room-modal {gap:10px}
  .modal-headline h2 {font-size:31px}
  .modal-headline .room-subtitle {font-size:19px}
  .calendar-grid {grid-auto-rows:48px;min-height:0;flex:none}
  .calendar-header {gap:10px;margin-bottom:9px}
  .calendar-header button {height:43px;font-size:17px}
  .modal-x {top:2px;right:2px}
}
/* Readable date-step pills and connected vertical building-void segments. */
.calendar-header .calendar-control {background:linear-gradient(110deg,#c867e3,#dda5e7);color:#514055;border-radius:14px;display:flex;align-items:center;justify-content:space-between;min-width:0}
.calendar-header .calendar-control strong {font-size:clamp(16px,1.7vw,22px);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.calendar-header .calendar-control button {background:transparent;min-width:28px;width:30px;height:52px;border-radius:12px;font-size:22px;padding:0}
.calendar-header .calendar-control button:hover {background:#ffffff40}
.floor-row .grid-cell.shaft {box-shadow:0 18px 0 0 var(--closed)}
@media (max-width:710px) {.calendar-header .calendar-control button {height:43px}}

.facility-hint {color:#e8d8eb;font-size:12px;margin:0}

/* Maintenance issues: visible without changing the room floor/stack coordinate. */
.grid-cell.room {position:relative}
.grid-cell.room.aesthetic-flag:not(.dimmed)::after {
  content:'A';position:absolute;right:1px;bottom:1px;min-width:13px;height:13px;
  border-radius:4px;background:#f0ac43;color:#342315;font-size:9px;font-weight:900;
  display:grid;place-items:center;line-height:1;box-shadow:0 0 0 1px #55382130;
}
.swatch-aesthetic {background:#f0ac43}
.blocked-hint {color:#ffdadf;margin:0;font-size:12px;font-weight:700}
.maintenance-heading {display:flex;gap:12px;align-items:center;justify-content:space-between;margin-bottom:9px}
.maintenance-heading h3 {margin:0}
.maintenance-rule {color:#e5d4e7;font-size:11px;line-height:1.5;margin:0 0 12px}
.issues-list {display:flex;flex-direction:column;gap:9px}
.issue-card {background:#ffffff12;border:1px solid #e4d6e437;border-left:4px solid #ecb055;border-radius:10px;padding:10px;overflow-wrap:anywhere}
.issue-card.critical {border-left-color:#ff667d}
.issue-card.resolved {opacity:.83}
.issue-top {display:flex;justify-content:space-between;align-items:center;gap:8px;margin-bottom:7px}
.severity-tag {display:inline-block;border-radius:6px;padding:5px 7px;font-size:10px;font-weight:800;background:#e9b563;color:#3e2b16}
.severity-tag.critical {background:#ffb1b8;color:#5b1730}
.resolved-tag {font-size:10px;background:#badcc6;color:#204332;border-radius:6px;padding:4px 7px;font-weight:750}
.issue-description {font-size:13px;font-weight:750;color:#fff;line-height:1.4}
.issue-meta {font-size:10px;color:#e2cfe7;margin-top:5px}
.issue-resolution {font-size:12px;color:#e9f9e5;margin-top:7px}
.issue-empty {font-size:12px;color:#e2d5e4;margin:5px 0 9px}
.resolved-issues {margin-top:11px;border-top:1px solid #ffffff22;padding-top:9px}
.resolved-issues summary {cursor:pointer;font-size:12px;font-weight:750;margin-bottom:10px}
.inline-form {margin-top:7px}
.inline-form textarea {width:100%;background:#f5eff6;color:#302334;border:1px solid #bbaabd;border-radius:7px;min-height:66px;resize:vertical;padding:9px;font:inherit;font-size:13px}
.switch-issue-note:not([hidden]) {display:flex;flex-direction:column;gap:7px}

.issue-reference {font-size:10px;color:#dfc6e4;letter-spacing:.02em;margin-top:3px}

/* readable state contrast, honest disabled actions, and viewport-bound dialogs. */
:root {
  --ready: #24c379;
  --dirty: #f7cb78;
  --occupied: #2670d8;
  --due: #81cdf8;
  --defective: #b92f52;
  --empty: #cbd6e0;
  --closed: #d3d1d3;
}
html,body {height:100%;overflow:hidden}
#app-view {height:100vh;height:100dvh;min-height:0;display:flex;flex-direction:column;overflow:hidden}
.topbar,.bottom-bar {flex-shrink:0}
.ops-layout {flex:1;min-height:0;height:auto;overflow:hidden}
.filter-rail {min-height:0;overflow-y:auto;overscroll-behavior:contain}
.workspace {min-height:0}
.board-scroller {flex:1;min-height:0;overflow:auto;overscroll-behavior:contain;}
.grid-cell.room.occupied {color:#fff}
.grid-cell.room.occupied .room-state {color:#fff}
.grid-cell.room.dueout {color:#102a4b}
.grid-cell.room.defective {color:#fff}
.grid-cell.room.facility .room-kind {font-size:9px;letter-spacing:-.02em}
.grid-cell.room.critical-flag:not(.dimmed)::before {
  content:'!';position:absolute;left:1px;bottom:1px;width:14px;height:14px;border-radius:4px;
  display:grid;place-items:center;background:#be1f43;color:white;font-size:11px;font-weight:900;
  box-shadow:0 0 0 1px #fff8;
}
.status-chip.occupied {background:var(--occupied);color:#fff}
.status-chip.dueout {background:var(--due);color:#102a4b}
.status-chip.defective {background:var(--defective);color:#fff}
.status-chip.ready {color:#07371e}
.status-chip.dirty {color:#4d3116}
.swatch-occupied,.swatch-dueout,.swatch-ready,.swatch-dirty,.swatch-defective {border-color:#3c35496b}
button:disabled {cursor:not-allowed}
.action-button:disabled,.action-button.primary:disabled,.action-button.secondary:disabled,.action-button.rose:disabled {
  opacity:1;background:#9fa7b1;color:#454e5b;border:1px solid #c2c8cf;
  box-shadow:inset 0 1px 1px #ffffff57;filter:none;
}
.action-button.primary {background:#4bc96c;color:#153b21}
.action-button.primary.stay-action {background:#3787ed;color:white}
.action-button.rose {background:#f29da9;color:#5f1f31}
.action-button.secondary {background:#d0c4d5;color:#30213a}
.blocked-hint {font-size:11px;line-height:1.25;color:#ffe4e5}
.action-note {font-size:11px;color:#dfd3e1;align-self:center}
.detail-facts {grid-template-columns:repeat(4,minmax(0,1fr))}
.sale-state.sellable {color:#7cf1b1}
.sale-state.blocked {color:#ffbfbf}
.room-modal .modal-headline h2 {font-size:clamp(23px,2.8vw,40px)}
.room-modal .room-subtitle {font-size:16px;color:#d7c9d7}
.room-modal,.calendar-modal {scrollbar-color:#a38cac #59435f;overscroll-behavior:contain}
.modal-root {overflow:hidden;padding:16px}
.modal-layout {min-height:0;height:min(760px,calc(100vh - 32px));height:min(760px,calc(100dvh - 32px));max-height:100%;width:min(1120px,96vw);gap:12px;grid-template-columns:minmax(0,1.15fr) minmax(0,.95fr)}
.room-modal,.calendar-modal {min-height:0;max-height:none;height:100%;padding:21px 22px;border-radius:20px}
.room-modal {gap:10px;overflow-y:auto}
.room-actions {flex:0 0 auto}
.modal-section {flex:0 0 auto}
.modal-tabs {display:none}
.maintenance-details {margin-top:7px;background:#ffffff10;border:1px solid #ffffff24;border-radius:9px;padding:8px 10px}
.maintenance-details summary,.activity-details summary {font-size:12px;font-weight:800;cursor:pointer;list-style-position:inside;line-height:1.4}
.maintenance-details[open] summary {margin-bottom:10px}
.maintenance-rule {margin-bottom:4px}
.activity-details {padding-bottom:10px}
.activity-details[open] summary {margin-bottom:10px}
.calendar-modal {min-width:0}
.calendar-header {gap:8px;margin:0 0 12px}
.calendar-header .calendar-control strong {font-size:clamp(14px,1.65vw,20px)}
.calendar-header .calendar-control button {height:44px}
.calendar-grid {min-height:0;flex:1;grid-auto-rows:minmax(0,1fr)}
.day {font-size:clamp(13px,1.2vw,17px)}
.weekday {font-size:13px}
.calendar-help {font-size:11px;padding-top:10px}
.date-picker-toggle {background:#d9a0ed;color:#34203d;border:0;border-radius:8px;padding:9px 11px;font-weight:750;font-size:12px;text-align:center;cursor:pointer}
.date-picker-toggle:hover {filter:brightness(1.07)}
.inline-form {padding:11px}
.inline-form textarea {min-height:52px}
.modal-x {right:7px;top:7px;width:37px;height:37px;z-index:3}
@media (max-width:900px) {
  .modal-root {align-items:stretch;justify-content:center;padding:7px;overflow:hidden}
  .modal-layout {display:flex;flex-direction:column;gap:0;width:min(630px,100%);height:100%;max-height:100%;border-radius:16px;background:var(--purple-dark);overflow:hidden}
  .modal-tabs {display:flex;flex:none;align-items:center;gap:5px;min-height:51px;padding:7px 54px 7px 10px;background:#493750}
  .modal-tabs button {border:1px solid #ffffff30;background:#ffffff18;color:#eee3f0;border-radius:8px;min-height:36px;padding:7px 12px;font-size:13px;font-weight:750}
  .modal-tabs button[aria-pressed="true"] {background:#e3a5f1;color:#312038;border-color:#e3a5f1}
  .modal-layout[data-panel="details"] .calendar-modal {display:none}
  .modal-layout[data-panel="calendar"] .room-modal {display:none}
  .room-modal,.calendar-modal {flex:1;min-height:0;height:auto;max-height:100%;padding:14px;border-radius:0;box-shadow:none;overflow-y:auto}
  .detail-facts {grid-template-columns:repeat(4,minmax(0,1fr))}
  .modal-x {right:9px;top:11px}
  .calendar-grid {min-height:0;grid-auto-rows:minmax(31px,1fr)}
  .calendar-header .calendar-control button {height:41px}
  .calendar-help {font-size:11px}
  .room-modal .modal-headline h2 {font-size:30px}
}
@media (max-width:710px) {
  .ops-layout {min-height:0;height:auto}
  .room-board {gap:9px}
  .bottom-bar {height:48px;min-height:48px}
  .detail-facts {grid-template-columns:repeat(2,minmax(0,1fr))}
  .room-modal,.calendar-modal {padding:13px}
  .calendar-grid {grid-auto-rows:minmax(28px,1fr)}
  .calendar-header {gap:7px}
  .calendar-header .calendar-control strong {font-size:16px}
}
@media (max-height:650px) and (min-width:901px) {
  .modal-layout {height:calc(100dvh - 16px)}
  .modal-root {padding:8px}
  .room-modal,.calendar-modal {padding:12px 14px}
  .modal-headline h2 {font-size:27px}
  .room-modal .room-subtitle {font-size:13px}
  .room-modal {gap:7px}
  .calendar-grid {grid-auto-rows:minmax(0,1fr)}
  .calendar-header {margin-bottom:7px}
}
@media (max-height:550px) {
  .topbar {height:48px}
  .bottom-bar {height:36px;min-height:36px}
  .updated-pill {padding:4px 9px}
  .modal-root {padding:4px}
  .calendar-modal {padding:9px 12px}
  .calendar-help {line-height:1.2}
}
@media (min-width:901px) {.calendar-header {padding-right:46px}}

/* the departure calendar is an action step, never a default room-information panel. */
.modal-layout:not(.date-flow) {
  width:min(640px,96vw);
  grid-template-columns:minmax(0,1fr);
}
.modal-layout:not(.date-flow) .calendar-modal,
.modal-layout:not(.date-flow) .modal-tabs {display:none}
.modal-layout:not(.date-flow) .room-modal {width:100%}
.modal-layout.date-flow {width:min(1120px,96vw);grid-template-columns:minmax(0,1.15fr) minmax(0,.95fr)}
.active-step-label {padding:9px 12px;border-radius:9px;background:#265ca8;color:#fff;font-size:13px;font-weight:800}
.date-step-heading {margin:0 35px 12px 0}
.date-step-heading h3 {font-size:16px;color:#fff;margin:0 0 5px}
.date-step-heading p {font-size:12px;line-height:1.35;color:#e9dbea;margin:0}
.day.current-checkout:not(.selected) {box-shadow:inset 0 0 0 3px #ffc86f}
.calendar-bottom {display:flex;gap:10px;justify-content:space-between;padding-top:10px}
.calendar-bottom .action-button {min-width:120px}
.date-form-hint {font-size:11px!important;color:#d9cbdc!important}
.current-departure {padding:7px;background:#ffffff14;border-radius:7px}
@media (max-width:900px) {
  .modal-layout:not(.date-flow) {width:min(630px,100%)}
  .modal-layout:not(.date-flow) .modal-tabs {display:none}
  .modal-layout.date-flow {width:min(630px,100%);display:flex;flex-direction:column}
  .modal-layout.date-flow .modal-tabs {display:flex}
  .calendar-bottom {flex-shrink:0;padding-top:8px}
}
@media (max-height:580px) {
  .date-step-heading {margin-bottom:6px}
  .date-step-heading h3 {font-size:13px;margin-bottom:2px}
  .date-step-heading p {font-size:10px}
  .calendar-bottom .action-button {min-height:30px}
  .calendar-help {padding-top:6px}
}

/* dedicated desktop front-desk and mobile housekeeping workspaces. */
.calls-open-btn {background:#574064;color:#fff;border:1px solid #ffffff45;border-radius:11px;min-height:37px;padding:8px 11px;font-size:12px;font-weight:780;white-space:nowrap;display:flex;align-items:center;gap:8px}
.calls-open-btn:hover {background:#422d50}
.calls-open-btn strong {background:#2f81db;color:#fff;border-radius:999px;padding:2px 7px;min-width:21px;text-align:center}
.call-request-btn {background:#80c3f4;color:#193b5e}
.call-request-btn:hover:not(:disabled) {background:#9bd3fb}
.guest-service-section .maintenance-rule {margin-bottom:0}
.housekeeping-view {display:none}
.calls-drawer-root {position:fixed;z-index:160;inset:0}
.calls-shade {position:absolute;inset:0;background:#24172c8a}
.calls-drawer {position:absolute;right:0;top:0;bottom:0;width:min(530px,100vw);background:#f8f7fb;box-shadow:-15px 0 55px #33203666;display:flex;flex-direction:column;min-height:0;overflow:hidden}
.calls-drawer-head {flex:none;background:#62496b;color:#fff;padding:23px 62px 17px 24px;position:relative}
.calls-drawer-head h2 {font-size:24px;margin:4px 0 3px}
.calls-drawer-head p {font-size:13px;margin:0;color:#e6d9eb}
.calls-drawer-head #calls-close {position:absolute;right:17px;top:17px;border:0;background:#e2d2e7;color:#35253e;font-size:28px;border-radius:10px;width:40px;height:40px}
.desktop-calls-list {flex:1;min-height:0;overflow:auto;padding:18px;background:#f4f5f9;overscroll-behavior:contain}
.calls-group-heading {font-size:11px;font-weight:900;letter-spacing:.11em;color:#6d6580;margin:12px 0}
.call-card,.clean-card {background:#fff;border:1px solid #dce1eb;border-radius:14px;padding:14px;margin-bottom:11px;box-shadow:0 2px 8px #26324b10;min-width:0}
.call-card-head {display:flex;align-items:flex-start;justify-content:space-between;gap:10px}
.call-card-head>div {display:flex;flex-direction:column;gap:2px}
.call-card-head strong {font-size:18px;color:#292b37}
.call-card-head span:not(.call-state) {font-size:13px;font-weight:700;color:#45556d}
.call-state {font-size:11px;font-weight:850;padding:5px 8px;border-radius:8px;white-space:nowrap}
.call-state.requested {background:#ffdb9b;color:#653c00}
.call-state.acknowledged {background:#dce8fb;color:#164e92}
.call-state.in_progress {background:#c3e0fd;color:#1b477d}
.call-state.completed {background:#c7f1dc;color:#0a5638}
.call-state.canceled {background:#e9e6ec;color:#676373}
.call-note {font-size:14px;color:#2f3445;line-height:1.45;margin:9px 0 7px;overflow-wrap:anywhere}
.call-meta {font-size:11px;color:#667083;margin-top:5px;line-height:1.35}
.call-card-actions {display:flex;gap:8px;margin-top:12px;flex-wrap:wrap}
.call-card-actions:empty {display:none}
.call-card-actions button {border:0;border-radius:9px;padding:11px 14px;font-size:12px;font-weight:850;min-height:42px}
.call-advance {background:#2f78d7;color:#fff}
.call-cancel {background:#ebe0e5;color:#7b3755}
.call-card-actions button:disabled,.clean-complete-btn:disabled {opacity:.42}
.hk-overline {font-size:10px;font-weight:900;letter-spacing:.12em;color:#895caa}
.calls-drawer .hk-overline {color:#ebc4fb}
.hk-empty {padding:24px 15px;text-align:center;background:#fff;border:1px dashed #ced6e1;border-radius:13px;color:#5c6072;font-size:13px}
.hk-empty strong {color:#38475a;font-size:15px}
.hk-empty.error {color:#ae2349;background:#fff2f3}
.hk-empty p {margin:8px 0 0}
.session-warning {z-index:250;position:fixed;inset:0;background:#14131cc0;display:grid;place-items:center;padding:16px}
.session-warning section {max-width:410px;width:100%;background:#fff;border-radius:16px;padding:24px;box-shadow:0 20px 60px #0007}
.session-warning h2 {margin:0 0 9px;color:#412a52}
.session-warning p {font-size:14px;color:#4d5160;line-height:1.5}
.session-warning button {display:block;width:100%;margin-top:10px}
/* Right panel owns the complete departure workflow. The left panel remains visible. */
.modal-layout.date-flow .room-modal {background:#59435f}
.modal-layout.date-flow .room-modal .action-button:disabled {opacity:1;background:#95929b!important;color:#e6e2e8!important;border:1px solid #aeb0b6;box-shadow:inset 0 0 0 1px #ffffff15;cursor:not-allowed}
.modal-layout.date-flow .room-modal .blocked-hint {color:#e8d4f0}
.calendar-modal {overflow-y:auto}
.calendar-panel-intro {margin:0 36px 10px 0;flex:none}
.calendar-panel-intro h3 {font-size:20px;letter-spacing:-.02em;margin:3px 0 2px;color:#fff}
.calendar-panel-intro p {margin:0 0 9px;font-size:12px;color:#eddef2}
.calendar-panel-intro .hk-overline {color:#e6b7fa}
.calendar-room-summary {display:flex;justify-content:space-between;align-items:center;gap:8px;flex-wrap:wrap;border-radius:10px;background:#ffffff14;border:1px solid #ffffff20;padding:8px 9px;font-size:11px;color:#efe2f1}
.calendar-room-summary span {display:flex;gap:5px;align-items:center}
.calendar-room-summary strong {color:#80e9b1}
.calendar-confirm-form {display:flex;flex-direction:column;gap:7px;flex:none;margin-top:10px}
.calendar-chosen {display:flex;align-items:center;justify-content:space-between;gap:12px;border-radius:9px;background:#ffffff14;padding:10px;font-size:13px}
.calendar-chosen label {color:#e0cae6}
.calendar-chosen strong {text-align:right;color:#fff;font-size:13px}
.calendar-ref {font-size:12px;color:#ebdcef;display:flex;flex-direction:column;gap:5px;font-weight:700}
.calendar-ref input {width:100%;height:36px;border:1px solid #dbbfe3;border-radius:8px;background:#fff;color:#2f2636;font-size:13px;padding:7px 9px}
.calendar-modal .calendar-grid {min-height:190px;flex:1 0 195px}
.calendar-modal .calendar-help {margin:0;padding:0;font-size:10.5px;line-height:1.3;color:#e9d8ed}
.calendar-modal .calendar-header {margin:0 0 8px}
.calendar-modal .calendar-bottom {padding:0}
.calendar-modal .calendar-bottom .action-button {min-height:40px}
@media (max-height:720px) and (min-width:901px) {
  .calendar-panel-intro h3 {font-size:16px}
  .calendar-panel-intro {margin-bottom:6px}
  .calendar-panel-intro p {margin-bottom:4px}
  .calendar-room-summary {padding:5px}
  .calendar-chosen {padding:6px}
  .calendar-modal .calendar-grid {min-height:165px;flex:1 0 165px}
  .calendar-ref input {height:31px}
}
@media (max-width:767px) {
  #app-view[data-mode="housekeeping"] .ops-layout,
  #app-view[data-mode="housekeeping"] .bottom-bar {display:none}
  #app-view[data-mode="housekeeping"] .housekeeping-view {flex:1;min-height:0;display:flex;flex-direction:column;background:#f2f5f9;overflow:hidden}
  .topbar {height:62px!important;min-height:62px;padding:0 10px 0 15px}
  .brand {font-size:24px!important}
  .role-pill {display:flex!important;max-width:112px;font-size:11px;border-radius:9px;padding:0 9px;min-width:0}
  .topbar-right {gap:7px}
  .account-pill,.lang-pill,.calls-open-btn {display:none!important}
  .hk-title {padding:18px 16px 9px;display:flex;justify-content:space-between;gap:8px;align-items:flex-start;flex:none}
  .hk-title h1 {font-size:27px;color:#23283e;margin:1px 0 3px;letter-spacing:-.04em}
  .hk-title p {font-size:12px;color:#596476;margin:0;max-width:290px;line-height:1.4}
  .hk-updated {background:#e0edfb;color:#2c557e;font-size:10px;padding:5px 7px;border-radius:7px;white-space:nowrap;margin-top:10px}
  .hk-summary {display:grid;grid-template-columns:1fr 1fr;gap:9px;padding:10px 14px;flex:none}
  .hk-summary div {border-radius:12px;background:#fff;border:1px solid #dce3ef;padding:10px 13px;display:flex;align-items:center;gap:9px}
  .hk-summary strong {font-size:28px;color:#254f80;line-height:1}
  .hk-summary span {font-size:11px;color:#5b6474;line-height:1.2;font-weight:750}
  .hk-tabs {display:flex;gap:6px;padding:3px 14px 10px;flex:none}
  .hk-tabs button {min-height:45px;flex:1;padding:8px 5px;border:1px solid #d3dce8;border-radius:10px;background:#e8edf6;color:#47556c;font-size:12px;font-weight:850}
  .hk-tabs button[aria-pressed="true"] {background:#2f78d7;color:#fff;border-color:#2f78d7}
  .hk-tabs span {margin-left:2px;opacity:.84}
  .hk-list-tools {display:flex;gap:8px;padding:0 14px 9px;flex:none}
  .hk-list-tools label {display:flex;align-items:center;gap:5px;font-size:12px;white-space:nowrap;font-weight:750;color:#434b5e}
  .hk-list-tools select,.hk-list-tools input {height:38px;border:1px solid #cbd5e3;border-radius:9px;background:#fff;padding:6px 9px;min-width:0}
  .hk-list-tools input {flex:1;width:0}
  .hk-list {flex:1;min-height:0;overflow-y:auto;overscroll-behavior:contain;padding:0 14px 12px}
  .hk-bottom-note {font-size:10px;line-height:1.3;color:#677385;padding:9px 15px;background:#e7edf4;flex:none}
  .call-card {margin-bottom:10px;padding:13px}
  .call-card-actions button {min-height:44px;font-size:13px}
  .clean-card {display:flex;justify-content:space-between;align-items:center;gap:12px;padding:14px}
  .clean-card>div {min-width:0}
  .clean-card-top {display:flex;flex-wrap:wrap;align-items:center;gap:6px}
  .clean-card-top strong {font-size:18px;color:#243449}
  .clean-state-tag {font-size:10px;font-weight:850;background:#ffe4ad;color:#68420b;padding:5px 7px;border-radius:7px;white-space:nowrap}
  .clean-card-sub {font-size:11px;color:#626a79;margin-top:4px}
  .clean-complete-btn {flex:none;border:0;border-radius:10px;background:#24aa69;color:white;font-size:12px;font-weight:850;padding:12px 10px;min-height:44px;max-width:105px}
  .critical-reminder {font-size:10px;color:#9c2648;font-weight:800;margin:7px 0 0}
  .toast {bottom:22px;left:14px;right:14px;max-width:none}
  /* There is no front-desk room editor on a phone. */
  .modal-root {display:none!important}
}

.call-stale-warning {font-size:12px;font-weight:850;color:#a1234b;background:#fff0f3;border-radius:8px;padding:8px;margin:8px 0;}
/* Tablet-sized computer windows still keep the left facts and right calendar together. */
@media (min-width:768px) and (max-width:900px) {
  .modal-layout.date-flow {display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);width:calc(100vw - 14px);max-width:none;height:calc(100dvh - 14px);gap:8px;background:transparent;border-radius:0;overflow:visible}
  .modal-layout.date-flow .modal-tabs {display:none}
  .modal-layout.date-flow .room-modal,.modal-layout.date-flow .calendar-modal {display:flex;flex-direction:column;min-width:0;min-height:0;height:100%;border-radius:14px;overflow-y:auto;padding:12px}
  .modal-layout.date-flow .detail-facts {grid-template-columns:repeat(2,minmax(0,1fr))}
  .modal-layout.date-flow .room-modal .modal-headline h2 {font-size:26px}
  .modal-layout.date-flow .calendar-panel-intro {margin-right:28px;margin-bottom:6px}
  .modal-layout.date-flow .calendar-panel-intro h3 {font-size:15px}
  .modal-layout.date-flow .calendar-panel-intro p {font-size:10px;margin-bottom:4px}
  .modal-layout.date-flow .calendar-room-summary {font-size:10px;padding:5px}
  .modal-layout.date-flow .calendar-confirm-form {margin-top:6px;gap:5px}
  .modal-layout.date-flow .calendar-modal .calendar-grid {min-height:170px;flex:1 0 170px}
  .modal-layout.date-flow .calendar-chosen {padding:6px;font-size:11px}
  .modal-layout.date-flow .calendar-ref {font-size:11px}
  .modal-layout.date-flow .calendar-ref input {height:31px}
  .modal-layout.date-flow .calendar-bottom .action-button {min-height:34px}
}


/* responsive readable type, active-use synchronization and explicit manual refresh. */
.refresh-control {display:inline-flex;align-items:center;justify-content:center;gap:6px;min-height:40px;padding:0 11px;border:0;border-radius:11px;background:#58435e;color:#fff;font-size:clamp(13px,1vw,16px);font-weight:800;white-space:nowrap}
.refresh-control:hover:not(:disabled) {background:#392c41}
.refresh-control:disabled {opacity:.65}
.refresh-icon {display:inline-block;font-size:24px;line-height:1}
.refresh-control.is-refreshing .refresh-icon {animation:sync-rotate 1.1s linear infinite}
@keyframes sync-rotate {to {transform:rotate(360deg)}}
@media (prefers-reduced-motion:reduce) {.refresh-control.is-refreshing .refresh-icon {animation:none}}
.updated-pill[data-status="error"],.hk-updated[data-status="error"] {background:#ffe1e6;color:#92233e}
.updated-pill[data-status="offline"],.hk-updated[data-status="offline"] {background:#e5d9e4;color:#753350}
.updated-pill[data-status="paused"],.hk-updated[data-status="paused"] {background:#e1e5ea;color:#515c69}
.updated-pill[data-status="active"],.hk-updated[data-status="active"] {background:#dcf3e5;color:#156344}
.updated-pill[data-status="syncing"],.hk-updated[data-status="syncing"] {background:#d7e9fb;color:#174e87}
@media (min-width:768px) {
  .ui-pill {font-size:clamp(14px,1.05vw,17px)}
  .rail-filter {font-size:clamp(12px,.9vw,15px)}
  .rail-filter small {font-size:clamp(11px,.75vw,13px)}
  .board-heading strong {font-size:clamp(14px,1.05vw,17px)}
  .board-heading span,.hotel-clock {font-size:clamp(12px,.85vw,14px)}
  .board-controls input,.board-controls select {font-size:clamp(13px,.9vw,15px);height:36px}
  .grid-cell.room .number {font-size:clamp(12px,.85vw,13px)}
  .grid-cell.room .room-kind {font-size:11px}
  .grid-cell.room .room-state {font-size:10px}
  .grid-cell.room.facility .room-kind {font-size:10px}
  .legend {font-size:clamp(12px,.8vw,14px)}
  .bottom-bar,.updated-pill {font-size:clamp(12px,.9vw,15px)}
  .detail-meta,.status-chip {font-size:clamp(13px,1vw,15px)}
  .detail-facts small {font-size:clamp(12px,.85vw,14px)}
  .detail-facts strong {font-size:clamp(13px,1vw,16px)}
  .modal-section h3,.inline-form label {font-size:clamp(13px,.95vw,15px)}
  .inline-form input,.inline-form select,.inline-form p,.history-list li {font-size:clamp(13px,.95vw,15px)}
  .warning-pill {font-size:clamp(12px,.85vw,14px)}
  .call-meta {font-size:clamp(12px,.9vw,14px)}
  .calls-group-heading {font-size:clamp(12px,.9vw,15px)}
  .calendar-panel-intro p,.calendar-ref,.calendar-room-summary {font-size:clamp(12px,.95vw,15px)}
  .calendar-modal .calendar-help {font-size:clamp(12px,.85vw,14px)}
}
@media (max-width:767px) {
  .refresh-control {min-height:42px;padding:0 9px;font-size:14px;gap:4px}
  .refresh-icon {font-size:20px}
  .hk-title h1 {font-size:clamp(27px,7vw,36px)}
  .hk-title p {font-size:clamp(13px,3.6vw,16px);line-height:1.45}
  .hk-overline {font-size:12px}
  .hk-updated {font-size:clamp(11px,3vw,13px);white-space:normal;max-width:150px;text-align:right;line-height:1.2}
  .hk-summary strong {font-size:clamp(28px,7.2vw,35px)}
  .hk-summary span {font-size:clamp(12px,3.4vw,15px)}
  .hk-tabs button {font-size:clamp(14px,3.65vw,17px);min-height:48px}
  .hk-list-tools label {font-size:clamp(13px,3.4vw,16px)}
  .hk-list-tools select,.hk-list-tools input {font-size:16px;min-height:42px}
  .call-card-head strong {font-size:clamp(19px,4.8vw,23px)}
  .call-card-head span:not(.call-state) {font-size:clamp(14px,3.7vw,17px)}
  .call-state {font-size:clamp(12px,3.2vw,14px)}
  .call-note,.hk-empty {font-size:clamp(14px,3.7vw,16px)}
  .call-meta {font-size:clamp(12px,3.2vw,14px)}
  .call-card-actions button {font-size:clamp(14px,3.6vw,16px);min-height:46px}
  .clean-card-top strong {font-size:clamp(19px,4.8vw,23px)}
  .clean-state-tag,.clean-card-sub,.critical-reminder {font-size:clamp(12px,3.2vw,14px)}
  .clean-complete-btn {font-size:clamp(13px,3.5vw,16px);min-height:48px}
  .hk-bottom-note {font-size:clamp(12px,3.1vw,14px);line-height:1.4}
  .toast {font-size:15px}
}
@media (max-width:420px) {
  .role-pill {display:none!important} /* Housekeeping mode is already identified in the heading. */
  .topbar {padding-right:10px}
  .hk-title {padding-top:12px}
}


/* nonblocking in-page two-click safeguard for consequential updates. */
button.safety-arming, button.safety-ready {position:relative;overflow:hidden;transition:filter .12s,box-shadow .12s,background .12s}
button.safety-arming {cursor:progress!important;filter:saturate(.6);box-shadow:inset 0 0 0 2px #ffffff88}
button.safety-arming::after {content:'';position:absolute;bottom:0;left:0;width:0;height:5px;background:#fff;animation:safety-fill 1.2s linear forwards;box-shadow:0 0 0 1px #303e5b55}
button.safety-ready {cursor:pointer!important;box-shadow:inset 0 0 0 2px #244e83,0 0 0 2px #fff!important;filter:brightness(1.08)}
button.safety-ready::after {content:'';position:absolute;bottom:0;left:0;right:0;height:5px;background:#244e83}
@keyframes safety-fill {to{width:100%}}
@media (prefers-reduced-motion:reduce){button.safety-arming::after{animation:none;width:100%}}
#login-username, #login-password {font-size:16px}

/* role-first workspace, available on any screen size. */
.language-switch {display:inline-flex; flex:0 0 auto;align-items:center;margin:0}
.language-switch select {height:37px;min-width:59px;background:#e9dff0;color:#2e2636;border:1px solid #ffffff6b;border-radius:15px;font-weight:800;font-size:14px;padding:4px 7px;cursor:pointer}
#app-view[data-mode="housekeeping"] .ops-layout,
#app-view[data-mode="housekeeping"] .bottom-bar {display:none!important}
#app-view[data-mode="housekeeping"] .housekeeping-view {display:flex!important;flex:1;min-height:0;flex-direction:column;background:#f2f5f9;overflow:hidden}
#app-view[data-mode="housekeeping"] .calls-open-btn {display:none!important}
#app-view[data-mode="maintenance"] .calls-open-btn {display:none!important}
#app-view[data-mode="maintenance"] .housekeeping-view {display:none!important}
.issue-kind {font-weight:700;color:#f5caec}
@media (max-width:767px){
  .language-switch {display:inline-flex!important}
  .language-switch select {min-width:50px;height:38px;font-size:14px;padding:4px}
  .topbar-right {gap:6px}
  .hk-title h1 {font-size:clamp(25px,7vw,33px)}
  .hk-summary {flex:none}
  .call-card button, .clean-card button {min-height:47px;font-size:clamp(14px,3.8vw,17px)}
  #app-view[data-mode="housekeeping"] .hk-list {padding-bottom:max(14px,env(safe-area-inset-bottom))}
}
@media (max-width:360px){
  .language-switch select {min-width:44px}
  .topbar-right {gap:4px}
  .topbar .brand {font-size:20px}
}

.mobile-role-notice {margin:8px 14px;padding:10px 12px;border-radius:10px;color:#5d4210;background:#fff0c9;font-size:13px;font-weight:700}
@media (max-width:360px){
  .topbar {padding-left:8px;padding-right:8px;gap:5px}
  #refresh-btn {min-width:39px;width:39px;padding:0;justify-content:center}
  #refresh-btn span:last-child {display:none}
  .topbar-right {gap:4px}
  .language-switch select {min-width:42px;width:42px}
  .topbar .brand {font-size:19px}
}

/* Bilingual call notes: original staff-entered text stays clearly attributed. */
.call-note-language { font-size: clamp(.74rem, 1.4vw, .88rem); opacity: .72; margin: .1rem 0 .45rem; }

/* Keep EN and ES fully visible on very narrow phone headers. */
@media (max-width:360px) {
  .language-switch select {width:48px!important;min-width:48px!important;appearance:none;-webkit-appearance:none;text-align:center;text-align-last:center;padding:0 3px;font-size:14px}
}


/* use the I-beam and blinking caret only where text can be entered.
   Ordinary room labels and status text are display-only, not editable.
   Native focus outlines and keyboard operation are retained. */
body {
  cursor: default;
  caret-color: transparent;
  -webkit-user-select: none;
  user-select: none;
}
input:not([type="checkbox"]):not([type="radio"]),
textarea {
  cursor: text;
  caret-color: auto;
  -webkit-user-select: text;
  user-select: text;
}
button:not(:disabled), a[href], select, summary,
[role="button"], input[type="checkbox"], input[type="radio"] {
  cursor: pointer;
}
button, select, summary, [role="button"] {
  -webkit-user-select: none;
  user-select: none;
}
button:disabled, select:disabled, input:disabled, textarea:disabled {
  cursor: not-allowed;
}
/* Comments and operational history stay selectable for copying and review. */
.call-note, .call-note-language, .issue-description, .issue-resolution,
.history-list, .error-message, .board-error, #toast, .auth-panel code {
  -webkit-user-select: text;
  user-select: text;
}
/* Keyboard users must still be able to locate the active control. */
textarea:focus-visible, summary:focus-visible,
[role="button"]:focus-visible {
  outline: 3px solid #503f70;
  outline-offset: 2px;
}

/* One-page room plan. The site content is never printed; filters cannot hide rooms. */
.print-report {display:none}
.print-board-button {height:31px;padding:0 12px;background:#fff;border:1px solid #5e436c;border-radius:7px;color:#4c3556;font-size:12px;font-weight:800;white-space:nowrap}
.print-board-button:not(:disabled):hover {background:#f4e8f9}
@media print {
  /* US Letter landscape. All 312 fixed room positions must fit one page. */
  @page {size:11in 8.5in; margin:0.25in}
  html, body {width:auto!important;height:auto!important;min-height:0!important;margin:0!important;padding:0!important;background:#fff!important;overflow:visible!important;print-color-adjust:exact;-webkit-print-color-adjust:exact}
  #setup-view,#login-view,#modal-root,#calls-drawer,#session-warning,#toast,#action-safety-status {display:none!important}
  #app-view {display:block!important;position:static!important;min-height:0!important;width:100%!important;overflow:visible!important}
  #app-view > :not(#print-report) {display:none!important}
  #app-view #print-report {display:block!important;width:100%!important;max-width:none!important;max-height:none!important;margin:0!important;padding:0!important;color:#101b29!important;font-family:Arial,Helvetica,sans-serif!important;break-inside:avoid!important;page-break-inside:avoid!important}
  .print-report-header {display:flex;align-items:flex-end;justify-content:space-between;border-bottom:1.4pt solid #24374b;padding-bottom:4pt;margin-bottom:5pt;gap:6pt}
  .print-report-header h1 {font-size:15pt;font-weight:900;letter-spacing:0;margin:0 0 2pt}
  .print-report-header p {font-size:8pt;margin:0}
  .print-report-date {font-size:8pt;font-weight:700;text-align:right;white-space:nowrap}
  .print-report-date small {display:block;font-size:6.5pt;font-weight:400;margin-top:2pt}
  .print-stack-row,.print-floor-row {display:grid;grid-template-columns:repeat(38,minmax(0,1fr));gap:0;width:100%}
  .print-stack-row {height:14pt;margin-bottom:2pt;align-items:stretch}
  .print-stack-label {text-align:center;font-size:6.8pt;font-weight:800;align-self:end;white-space:nowrap}
  .print-floor-grid {display:flex;flex-direction:column;gap:10pt}
  .print-floor-row {height:auto;break-inside:avoid;page-break-inside:avoid;align-items:stretch}
  /* Three equal-height, equal-weight lines: room number, room type, status. */
  .print-cell {min-width:0;aspect-ratio:2 / 3;overflow:hidden;display:grid;grid-template-rows:repeat(3,minmax(0,1fr));justify-items:center;align-items:center;border:0.5pt solid #7f8b98;border-left:0;padding:0.4pt 0}
  .print-cell:first-child {border-left:0.5pt solid #7f8b98}
  .print-empty {background:#e1e1e1;border-color:#dedede}
  .print-room {background:#ffe6b9}
  .print-ready {background:#b5efcd}
  .print-dirty {background:#ffe6b9}
  .print-occupied {background:#bcd8ff}
  .print-dueout {background:#d5e5fc}
  .print-defective {background:#eeb9c1;border-color:#991b35}
  .print-room-number,.print-room-type,.print-room-state {display:block;font-family:"Arial Narrow","Liberation Sans Narrow",Arial,sans-serif;font-size:8.3pt;font-weight:900;line-height:1;letter-spacing:-0.15pt;white-space:nowrap;max-width:none;text-align:center;transform:scaleX(.9);transform-origin:center}
  .print-legend {display:flex;flex-direction:column;gap:2.5pt;margin-top:6pt;padding-top:4pt;border-top:1pt solid #24374b}
  .print-legend-types,.print-legend-status {display:flex;flex-wrap:wrap;align-items:center;gap:5pt;font-size:7.1pt}
  .print-legend strong {font-weight:900;padding-right:2pt}
  .print-legend-types b {font-size:9pt;padding-right:1pt}
  .print-report-note {font-size:6.6pt;color:#394c5c;margin:3pt 0 0}
}

/* Print shortcut in the housekeeping Room cleaning toolbar. */
.hk-print-button {height:42px;min-width:48px;border-radius:9px;border:1px solid #44617e;background:#f0f6ff;color:#1c496d;font:800 12px Arial,sans-serif;padding:0 6px;cursor:pointer;flex:none}
.hk-print-button:disabled {opacity:.45;cursor:not-allowed}
@media (max-width:360px) {.hk-print-button {min-width:44px;padding:0 4px}}
