/* The headquarters: the map takes the whole window and the interface floats over it, as in the approved mock-up. */
.workspace { position: relative; height: 100dvh; overflow: hidden; }
.office { position: relative; height: 100%; }

.hq-stage { position: absolute; inset: 0; overflow: hidden; background: var(--bg-canvas); }
.hq-canvas { display: block; width: 100%; height: 100%; image-rendering: pixelated; touch-action: none; }
.hq-meter { position: absolute; right: var(--space-6); bottom: var(--space-6); padding: var(--space-2) var(--space-4); border: 1px solid var(--border-strong); border-radius: var(--radius-md); background: var(--bg-overlay); color: var(--text); font: 400 12px var(--font-mono); }
.hq-labels, .hq-tags { position: absolute; inset: 0; overflow: hidden; pointer-events: none; }
.hq-tags { isolation: isolate; --tag-max-width: 132px; --thought-paper: var(--balloon-paper); --thought-ink: var(--balloon-ink); --thought-lift: 40px; }
.area-label { position: absolute; transform: translate(-50%, -100%); padding: 1px 6px; border-radius: var(--radius-md); background: var(--bg-overlay); color: var(--text); font: 600 10px/1.4 var(--font-sans); white-space: nowrap; }
.area-label.is-free-island { color: var(--muted); }
.name-tag.is-figurant { padding: 1px 6px; color: var(--muted); font-size: 10px; cursor: default; pointer-events: none; }
.hq-stage:focus-visible { outline: 2px solid var(--focus); outline-offset: -2px; }
.hq-instructions, .sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.name-tag.is-followed { z-index: 3; border-color: var(--focus); box-shadow: 0 0 0 1px var(--focus); }

/* From afar a tag is only its status dot, or the dot and the name of whoever needs you; hovering or focusing brings it back whole. */
.hq-tags .name-tag, .hq-labels .name-tag { touch-action: none; }
.name-tag[data-detail="dot"], .name-tag[data-detail="name"] { gap: var(--space-2); padding: 3px; box-shadow: none; }
.name-tag[data-detail="name"] { z-index: 2; padding: 1px 6px 1px 4px; }
.name-tag[data-detail="dot"] > span, .name-tag[data-detail="name"] small { display: none; }
.name-tag[data-detail="dot"]:is(:hover, :focus-visible), .name-tag[data-detail="name"]:is(:hover, :focus-visible) { z-index: 4; gap: var(--space-3); padding: 2px 8px 3px 7px; box-shadow: var(--shadow-tag); }
.name-tag[data-detail="dot"]:is(:hover, :focus-visible) > span { display: grid; }
.name-tag[data-detail="name"]:is(:hover, :focus-visible) small { display: block; }
.name-tag.is-figurant[data-detail="dot"] { display: none; }
.hq-tags .thought.is-compact { --thought-lift: 18px; padding: 0 5px 1px; font-size: 10px; line-height: 1.1; }
.hq-labels[data-detail="compact"] :is(.area-label.is-area, .area-label.is-free-island, .area-label-detail, .name-tag.reserved) { display: none; }
.hq-labels[data-detail="compact"] .area-label { padding: 0 4px; font-size: 9px; opacity: 0.85; }

/* Floating panels. The layer lets the map take every press that does not land on a panel. */
.hq-hud { --hq-gap: var(--space-6); --hq-left-width: 220px; --hq-capsule-height: 40px; --hq-capsule-width: 268px; --hq-search-height: 34px; position: absolute; inset: 0; z-index: 2; pointer-events: none; font-size: 13px; }
.hq-hud > * { pointer-events: auto; }
.hq-panel { border: 1px solid var(--border-strong); border-radius: var(--radius-lg); background: var(--bg-floating); box-shadow: var(--shadow-popover); }
.hq-heading { margin: var(--space-3) var(--space-4) var(--space-1); color: var(--muted); font-size: 10px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; }
.hq-empty { margin: 0; color: var(--muted); font-size: 12px; }
.hq-hint { margin: var(--space-3) var(--space-4) 0; color: var(--subtle); font-size: 11px; }
.hq-figure { color: var(--text); font: 600 12px var(--font-mono); }
.hq-figure.is-high, .hq-figure.is-warning { color: var(--warning); }

.hq-capsule { position: absolute; left: var(--hq-gap); top: var(--hq-gap); min-width: var(--hq-capsule-width); max-width: calc(100vw - var(--hq-gap) * 2); height: var(--hq-capsule-height); box-sizing: border-box; display: flex; align-items: center; gap: 10px; padding: 0 var(--space-5); }
.hq-brand-mark { display: grid; grid-template-columns: repeat(2, 6px); gap: 2px; }
.hq-brand-mark i { width: 6px; height: 6px; background: var(--accent); }
.hq-brand-mark i:nth-child(2) { background: var(--info); }
.hq-brand-mark i:nth-child(3) { background: var(--success); }
.hq-brand-mark i:nth-child(4) { background: var(--warning); }
.hq-brand { flex: 1; margin: 0; font-size: 13px; font-weight: 600; white-space: nowrap; }
.hq-connection { display: inline-flex; align-items: center; gap: var(--space-3); min-width: 0; color: var(--muted); font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hq-dot { flex: none; width: 6px; height: 6px; border-radius: var(--radius-full); background: var(--muted); }
.hq-dot[data-tone="live"] { background: var(--success); }
.hq-dot[data-tone="demo"] { background: var(--info); }
.hq-dot[data-tone="pending"] { background: var(--warning); }
.hq-dot[data-tone="off"] { background: var(--danger); }

.hq-accounts { position: absolute; right: var(--hq-gap); top: var(--hq-gap); display: flex; align-items: center; gap: var(--space-5); padding: var(--space-4) 10px; }
.hq-account-list { display: flex; align-items: center; gap: var(--space-5); margin: 0; padding: 0; list-style: none; }
.hq-account { display: flex; align-items: center; gap: var(--space-4); }
.hq-account + .hq-account { padding-left: var(--space-5); border-left: 1px solid var(--border-strong); }
.hq-ring { --used: 0%; display: grid; place-items: center; width: 34px; height: 34px; border-radius: var(--radius-full); background: conic-gradient(var(--success) 0 var(--used), var(--border-strong) var(--used) 100%); }
.hq-ring.is-high { background: conic-gradient(var(--warning) 0 var(--used), var(--border-strong) var(--used) 100%); }
.hq-ring > span { display: grid; place-items: center; width: 26px; height: 26px; border-radius: var(--radius-full); background: var(--bg-surface); font-size: 11px; font-weight: 700; }
.hq-account-text { display: grid; font-size: 11px; line-height: 1.3; }
.hq-account-text > b { font-size: 12px; }
.hq-meters { color: var(--muted); white-space: nowrap; }
.hq-meters .hq-figure { font-size: 11px; }

.hq-search-button { all: unset; pointer-events: auto; position: absolute; left: var(--hq-gap); top: calc(var(--hq-gap) + var(--hq-capsule-height) + var(--space-4)); box-sizing: border-box; display: flex; align-items: center; gap: var(--space-4); width: var(--hq-capsule-width); height: var(--hq-search-height); padding: 0 10px; border: 1px solid var(--border-strong); border-radius: var(--radius-lg); background: var(--bg-floating); box-shadow: var(--shadow-popover); color: var(--muted); font-size: 12px; cursor: pointer; }
.hq-search-button:hover { color: var(--text); background: var(--bg-overlay); }
.hq-search-button:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
.hq-search-label { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hq-search-button kbd, .hq-search-field kbd { padding: 0 5px; border: 1px solid var(--border-strong); border-radius: var(--radius-sm); color: var(--muted); font: 11px var(--font-mono); }

.hq-search { width: min(560px, calc(100vw - var(--space-6) * 2)); max-height: min(560px, calc(100dvh - 96px)); margin: 72px auto auto; padding: 0; overflow: hidden; border: 1px solid var(--border-strong); border-radius: var(--radius-lg); background: var(--bg-floating-strong); color: var(--text); box-shadow: var(--shadow-dialog); font-size: 13px; }
.hq-search[open] { display: flex; }
.hq-search::backdrop { background: var(--scrim); }
.hq-search-box { display: flex; flex: 1; flex-direction: column; min-height: 0; }
.hq-search-field { display: flex; align-items: center; gap: var(--space-4); padding: var(--space-5) 14px; border-bottom: 1px solid var(--border); color: var(--muted); }
.hq-search-field input { flex: 1; min-width: 0; padding: 0; border: 0; outline: 0; background: transparent; color: var(--text); font: 14px var(--font-sans); }
.hq-search-list { flex: 1; min-height: 0; padding: var(--space-3); overflow-y: auto; }
.hq-search-section + .hq-search-section { margin-top: var(--space-3); }
.hq-search-group { padding: var(--space-3) var(--space-4) var(--space-2); color: var(--muted); font-size: 10px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; }
.hq-search-option { display: flex; align-items: center; gap: var(--space-4); min-height: 32px; padding: var(--space-2) var(--space-4); border-radius: var(--radius-md); cursor: pointer; }
.hq-search-option.is-active { background: var(--bg-selected); box-shadow: inset 2px 0 0 var(--accent); }
.hq-search-main { flex: none; max-width: 50%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hq-search-detail { flex: 1; min-width: 0; overflow: hidden; color: var(--muted); font-size: 12px; text-align: right; text-overflow: ellipsis; white-space: nowrap; }
.hq-search-empty { padding: var(--space-6); }
.hq-search-help { margin: 0; padding: var(--space-4) 14px; border-top: 1px solid var(--border); color: var(--subtle); font-size: 11px; }

.hq-rooms { position: absolute; left: var(--hq-gap); top: calc(var(--hq-gap) * 2 + var(--hq-capsule-height) + var(--space-4) + var(--hq-search-height)); width: var(--hq-left-width); box-sizing: border-box; max-height: calc(100dvh - var(--hq-capsule-height) - var(--hq-search-height) - 330px); overflow-y: auto; display: flex; flex-direction: column; gap: var(--space-1); padding: var(--space-4); font-size: 12px; }
.hq-room-list { display: flex; flex-direction: column; gap: var(--space-1); margin: 0; padding: 0; list-style: none; }
.hq-room { all: unset; box-sizing: border-box; display: flex; align-items: center; gap: var(--space-4); width: 100%; min-height: 30px; padding: 0 var(--space-4); border: 1px solid transparent; border-radius: var(--radius-md); color: var(--text); font-size: 12px; cursor: pointer; }
.hq-room:hover { background: var(--bg-hover); }
.hq-room:focus-visible { outline: 2px solid var(--focus); outline-offset: 1px; }
.hq-room.is-whole { font-weight: 600; }
.hq-room[aria-current="true"] { background: var(--bg-selected); box-shadow: inset 2px 0 0 var(--accent); }
.hq-room.is-urgent { border-color: var(--warning-border); background: var(--warning-bg); }
.hq-room-name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hq-swatch { flex: none; width: 10px; height: 10px; border-radius: 3px; background: var(--swatch); box-shadow: inset 0 0 0 2px var(--swatch-edge); }
.hq-swatch.is-whole { background: var(--accent); box-shadow: none; }
.hq-chip { flex: none; font-size: 11px; white-space: nowrap; }
.hq-chip.is-empty { color: var(--subtle); }
.hq-count { flex: none; color: var(--muted); font: 11px var(--font-mono); }

.hq-legend { position: absolute; left: var(--hq-gap); bottom: var(--hq-gap); width: var(--hq-left-width); box-sizing: border-box; padding: 10px var(--space-5); font-size: 12px; }
.hq-legend .hq-heading { margin: 0 0 var(--space-2); }
.hq-legend-list { display: grid; gap: var(--space-1); margin: 0; padding: 0; list-style: none; }
.hq-glyph { display: inline-block; width: 1.4em; }

.hq-day { position: absolute; left: calc(var(--hq-gap) * 2 + var(--hq-left-width)); bottom: var(--hq-gap); width: min(600px, calc(100vw - var(--hq-left-width) - 220px)); box-sizing: border-box; display: flex; flex-direction: column; gap: var(--space-4); padding: 10px 14px; }
.hq-day-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: var(--space-2) var(--space-6); color: var(--muted); font-size: 12px; }
.hq-day-title { margin: 0; color: var(--text); font-size: 12px; font-weight: 700; }
.hq-day .hq-day-title + .hq-empty { margin-top: var(--space-2); }
.hq-bars { position: relative; display: grid; grid-template-columns: repeat(var(--hours), minmax(0, 1fr)); align-items: end; gap: 3px; height: 34px; }
.hq-bar { height: max(4%, calc(var(--level) * 100%)); border-radius: 2px; background: var(--success); }
.hq-bar.is-marked { box-shadow: inset 0 3px 0 var(--warning); }
.hq-bar.is-now { background: var(--accent); }
.hq-bar.is-ahead { height: 4%; background: var(--border-strong); }
.hq-now { position: absolute; left: var(--at); top: -4px; bottom: 0; width: 2px; background: var(--text); }
.hq-axis { position: relative; height: 14px; color: var(--subtle); font: 10px var(--font-mono); }
.hq-axis > span { position: absolute; left: var(--at); white-space: nowrap; }
.hq-axis > span.is-now { translate: -50% 0; color: var(--muted); }
.hq-axis > span:last-child:not(.is-now) { translate: -100% 0; }

.hq-camera { --minimap-width: 132px; position: absolute; bottom: var(--hq-gap); left: calc(var(--hq-gap) * 3 + var(--hq-left-width) + min(600px, calc(100vw - var(--hq-left-width) - 220px))); display: flex; flex-direction: column; gap: var(--space-3); width: calc(var(--minimap-width) + var(--space-4) * 2 + 2px); box-sizing: border-box; padding: var(--space-4); }
.hq-minimap { display: block; width: var(--minimap-width); height: 84px; border-radius: var(--radius-md); cursor: crosshair; touch-action: none; image-rendering: pixelated; }
.hq-camera-buttons { display: flex; gap: var(--space-2); }
.hq-following { display: grid; gap: var(--space-2); padding-top: var(--space-3); border-top: 1px solid var(--border); font-size: 11px; }
.hq-following[hidden] { display: none; }
.hq-following-text { overflow: hidden; color: var(--muted); text-overflow: ellipsis; white-space: nowrap; }
.hq-following-text b { color: var(--text); }
.hq-following .btn:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
.hq-camera-button { all: unset; box-sizing: border-box; display: grid; flex: 1; place-items: center; height: 28px; border: 1px solid var(--border-strong); border-radius: var(--radius-md); background: var(--bg-raised); color: var(--text); cursor: pointer; }
.hq-camera-button:hover { background: var(--bg-hover); }
.hq-camera-button:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }

/* Who needs you: the most urgent request, centered on top as in the mock-up. */
.hq-alert { position: absolute; z-index: 1; left: 50%; top: var(--hq-gap); translate: -50% 0; width: min(560px, calc(100vw - var(--hq-gap) * 2)); box-sizing: border-box; display: flex; flex-direction: column; gap: var(--space-4); padding: 10px var(--space-5); border: 1px solid var(--warning-edge); border-radius: var(--radius-lg); background: var(--warning-surface); box-shadow: var(--shadow-popover); }
.hq-alert[hidden] { display: none; }
.hq-alert:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
.hq-alert-head { display: flex; align-items: center; gap: var(--space-4); }
.hq-alert-mark { display: grid; place-items: center; flex: none; width: 20px; height: 20px; border-radius: var(--radius-full); background: var(--warning); color: var(--balloon-ink); font-size: 12px; font-weight: 800; }
.hq-alert-title { flex: 1; min-width: 0; margin: 0; }
.hq-muted { color: var(--muted); }
.hq-alert-meta { flex: none; color: var(--muted); font: 11px var(--font-mono); white-space: nowrap; }
.hq-alert-steps { display: flex; gap: var(--space-1); }
.hq-step { all: unset; box-sizing: border-box; display: grid; place-items: center; width: 24px; height: 24px; border: 1px solid var(--border-strong); border-radius: var(--radius-md); background: var(--bg-raised); color: var(--text); cursor: pointer; }
.hq-step:disabled { color: var(--subtle); cursor: default; }
.hq-step:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
.hq-alert-body { position: relative; display: flex; flex-direction: column; gap: var(--space-3); }
.hq-alert-row { display: flex; align-items: center; gap: var(--space-4); }
.hq-command { flex: 1; min-width: 0; overflow-x: auto; padding: 5px var(--space-4); border-radius: var(--radius-md); background: var(--bg-canvas); font: 12px var(--font-mono); white-space: pre; }
.hq-prompt { color: var(--success); }
.hq-alert-what { flex: 1; min-width: 0; margin: 0; }
.hq-alert-summary { margin: 0; color: var(--muted); font-size: 12px; }
.hq-alert kbd { margin-left: var(--space-2); color: inherit; opacity: 0.7; font: 10px var(--font-mono); }
.hq-alert .pending-error { margin: 0; color: var(--danger); font-size: 12px; }

/* Pairing and old-hooks notices: under the top row, and in the middle of the map while this browser is not paired. */
.hq-notice { position: absolute; left: 50%; top: calc(var(--hq-gap) * 2 + var(--hq-capsule-height)); translate: -50% 0; width: min(560px, calc(100vw - var(--hq-gap) * 2)); box-sizing: border-box; padding: 10px var(--space-5); border-color: var(--warning-edge); font-size: 12px; }
.hq-notice[hidden] { display: none; }
.hq-notice.is-blocking { top: 50%; translate: -50% -50%; padding: 0; }
.hq-notice .notice { padding: 0; border: 0; background: none; }
.hq-notice .empty-state { padding: var(--space-8); }
.hq-notice .command { white-space: pre-wrap; overflow-wrap: anywhere; }

/* The agent's drawer, on the right as in the mock-up; the grip on its left edge drags the width and a double click resets it. */
.hq-hud { --hq-drawer-top: 80px; }
.hq-drawer { position: absolute; z-index: 3; right: var(--hq-gap); top: var(--hq-drawer-top); bottom: var(--hq-gap); width: min(var(--panel-width), calc(100vw - var(--hq-gap) * 2)); box-sizing: border-box; display: flex; background: var(--bg-floating-strong); box-shadow: var(--shadow-dialog); }
.hq-drawer[hidden] { display: none; }
.hq-drawer .hq-sheet { flex: 1; min-width: 0; max-height: none; }
.hq-drawer-resizer { display: block; left: calc(var(--space-6) * -1 + 2px); }
.hq-drawer-resizer::before { content: ""; position: absolute; top: 50%; left: 50%; width: 4px; height: 40px; translate: -50% -50%; border-radius: var(--radius-full); background: var(--border-control); }
.hq-drawer-resizer:hover::before, .hq-drawer-resizer:focus-visible::before, .is-resizing-panel .hq-drawer-resizer::before { background: var(--accent); }
.hq-drawer-resizer:focus-visible { outline: 2px solid var(--focus); outline-offset: -4px; border-radius: var(--radius-md); }
.hq-drawer-head { justify-content: space-between; padding: var(--space-5); }
.hq-drawer-head .icon-btn:focus-visible, .hq-drawer .pane .icon-btn:focus-visible { outline: 2px solid var(--focus); outline-offset: 1px; }
.hq-drawer-body { flex: 1; gap: 10px; padding: var(--space-5); }
.hq-drawer-status { display: flex; align-items: flex-start; gap: var(--space-4); margin: 0; padding: var(--space-4) 10px; border-radius: var(--radius-md); background: var(--bg-raised); line-height: 1.4; }
.hq-drawer-glyph { flex: none; width: 1em; text-align: center; }
.hq-drawer-when { display: block; color: var(--muted); font-size: 12px; }
.hq-drawer-actions { display: flex; gap: var(--space-3); }
.hq-drawer-actions .btn { flex: 1; height: 30px; }
.hq-drawer-actions .btn[aria-pressed="true"] { border-color: var(--accent); background: var(--bg-selected); color: var(--text); }
.hq-drawer-actions .btn[aria-pressed="true"]::before { content: "●"; color: var(--accent); font-size: 9px; }
.hq-drawer-actions .btn:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
.hq-drawer .pane { flex: 1 0 220px; }
.hq-drawer .pane-body { flex: 1; max-height: none; }
.hq-drawer .composer textarea { min-height: 56px; }
.hq-drawer-note { margin: 0; font-size: 12px; }
.hq-drawer .pending-card { margin: 0; }
.hq-drawer-head .sheet-identity > .hq-swatch { width: 18px; height: 18px; border-radius: var(--radius-sm); box-shadow: inset 0 0 0 3px var(--swatch-edge); }
.hq-island-part { display: grid; gap: var(--space-3); min-width: 0; margin: 0; padding: 0; border: 0; }
.hq-island-part .hq-heading { margin: 0; padding: 0; }
.hq-island-team { display: grid; gap: var(--space-1); max-height: 40dvh; margin: 0; padding: 0; overflow-y: auto; list-style: none; }
.hq-member { all: unset; box-sizing: border-box; display: flex; align-items: center; gap: var(--space-4); width: 100%; min-height: 32px; padding: var(--space-2) var(--space-4); border-radius: var(--radius-md); font-size: 12px; cursor: pointer; }
.hq-member:hover { background: var(--bg-hover); }
.hq-member:focus-visible { outline: 2px solid var(--focus); outline-offset: -2px; }
.hq-member-name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hq-member-status { flex: none; color: var(--muted); font-size: 11px; }
.hq-member-queue { flex: none; padding: 0 var(--space-3); border: 1px solid var(--border-strong); border-radius: var(--radius-sm); color: var(--info); font: 11px var(--font-mono); white-space: nowrap; }
.hq-island-day { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: var(--space-4); margin: 0; padding: var(--space-4) 10px; border-radius: var(--radius-md); background: var(--bg-raised); }
.hq-island-day > div { display: grid; gap: var(--space-1); min-width: 0; }
.hq-island-day dt { color: var(--muted); font-size: 11px; }
.hq-island-day dd { margin: 0; }
.hq-theme-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-2); }
.hq-theme { position: relative; display: flex; align-items: center; gap: var(--space-4); min-height: 30px; padding: 0 var(--space-4); border: 1px solid var(--border-strong); border-radius: var(--radius-md); background: var(--bg-raised); font-size: 12px; cursor: pointer; }
.hq-theme:hover { background: var(--bg-hover); }
.hq-theme > input { position: absolute; opacity: 0; pointer-events: none; }
.hq-theme:has(> input:checked) { border-color: var(--accent); background: var(--bg-selected); }
.hq-theme:has(> input:checked)::after { content: "✓"; margin-left: auto; color: var(--accent); }
.hq-theme:has(> input:focus-visible) { outline: 2px solid var(--focus); outline-offset: 1px; }
.hq-alert-foot { display: flex; align-items: center; justify-content: space-between; gap: var(--space-4); }
.hq-alert-foot .btn-ghost { margin-left: auto; }
.hq-alert-foot .btn:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }

/* Phone-only pieces: the request count in the top bar and the bottom sheet with the panels. */
.hq-requests-button, .hq-sheet-toggle, .hq-sheet-panel { display: none; }

/* On a phone the map takes the screen: a compact top bar, the request card at the bottom when there is one, and the room list,
   the day, the accounts and the legend in a bottom sheet with tabs. Pinch and drag replace the camera buttons and the minimap. */
@media (max-width: 719px) {
  .hq-hud { --hq-gap: var(--space-4); --hq-capsule-height: 44px; --hq-toggle-height: 44px; }
  .hq-drawer { inset: 0; width: auto; border-radius: 0; background: var(--bg-surface); }
  .hq-drawer-resizer { display: none; }
  .hq-hud > :is(.hq-search-button, .hq-camera, .hq-rooms, .hq-legend, .hq-day, .hq-accounts) { display: none; }

  .hq-capsule { right: var(--hq-gap); min-width: 0; gap: var(--space-4); padding: 0 var(--space-3) 0 var(--space-5); }
  .hq-brand { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; }
  .hq-connection { flex: none; max-width: 40vw; }
  .hq-requests-button { all: unset; box-sizing: border-box; display: inline-flex; flex: none; align-items: center; gap: var(--space-3); min-height: 36px; padding: 0 10px; border: 1px solid var(--warning-border); border-radius: var(--radius-md); background: var(--warning-bg); color: var(--text); font-size: 12px; font-weight: 600; cursor: pointer; }
  .hq-requests-button b { color: var(--warning); font-family: var(--font-mono); }
  .hq-requests-button[aria-disabled="true"] { border-color: var(--border-strong); background: transparent; color: var(--muted); cursor: default; }
  .hq-requests-button[aria-disabled="true"] b { color: var(--muted); }
  .hq-requests-button:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }

  .hq-alert { top: auto; left: var(--hq-gap); right: var(--hq-gap); bottom: calc(var(--hq-gap) * 2 + var(--hq-toggle-height)); width: auto; translate: none; gap: var(--space-3); padding: var(--space-4) 10px; }
  .hq-alert-head { flex-wrap: wrap; gap: var(--space-2) var(--space-4); }
  .hq-alert-title { flex-basis: calc(100% - 28px); font-size: 12px; }
  .hq-alert-meta { flex: 1; font-size: 10px; }
  .hq-alert-summary { display: none; }
  .hq-alert .hq-command { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .hq-alert-row .btn { min-height: 36px; }

  .hq-sheet-toggle { all: unset; pointer-events: auto; position: absolute; left: var(--hq-gap); right: var(--hq-gap); bottom: var(--hq-gap); box-sizing: border-box; display: flex; align-items: center; justify-content: center; gap: var(--space-4); height: var(--hq-toggle-height); border: 1px solid var(--border-strong); border-radius: var(--radius-lg); background: var(--bg-floating); box-shadow: var(--shadow-popover); color: var(--text); font-size: 13px; font-weight: 600; cursor: pointer; }
  .hq-sheet-toggle:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
  .hq-sheet-toggle-grip { width: 18px; height: 3px; border-radius: var(--radius-full); background: var(--border-control); box-shadow: 0 -5px 0 var(--border-control); }

  .hq-sheet-panel { position: absolute; z-index: 2; left: 0; right: 0; bottom: 0; display: flex; flex-direction: column; height: min(72dvh, 560px); border: 1px solid var(--border-strong); border-bottom: 0; border-radius: 16px 16px 0 0; background: var(--bg-surface); box-shadow: var(--shadow-dialog); transition: translate var(--duration-fast) var(--easing-standard); }
  .hq-sheet-panel[hidden] { display: none; }
  .hq-sheet-panel.is-dragging { transition: none; }
  .hq-sheet-grip { display: grid; place-items: center; height: 24px; touch-action: none; cursor: grab; }
  .hq-sheet-grip > span { width: 40px; height: 4px; border-radius: var(--radius-full); background: var(--border-control); }
  .hq-sheet-head { display: flex; align-items: center; gap: var(--space-4); padding: 0 var(--space-4) var(--space-4) var(--space-5); border-bottom: 1px solid var(--border); }
  .hq-sheet-tabs { display: flex; flex: 1; gap: var(--space-2); overflow-x: auto; }
  .hq-sheet-tabs [role="tab"] { all: unset; box-sizing: border-box; display: grid; place-items: center; min-height: 36px; padding: 0 var(--space-5); border-radius: var(--radius-md); color: var(--muted); font-size: 13px; font-weight: 600; cursor: pointer; }
  .hq-sheet-tabs [role="tab"][aria-selected="true"] { background: var(--bg-selected); color: var(--text); box-shadow: inset 0 -2px 0 var(--accent); }
  .hq-sheet-tabs [role="tab"]:focus-visible, .hq-sheet-head .icon-btn:focus-visible { outline: 2px solid var(--focus); outline-offset: 1px; }
  .hq-sheet-head .icon-btn { width: 36px; height: 36px; }
  .hq-sheet-body { flex: 1; min-height: 0; padding: var(--space-4); overflow-y: auto; }
  .hq-sheet-body[hidden] { display: none; }
  .hq-sheet-body:focus-visible { outline: 2px solid var(--focus); outline-offset: -2px; }
  .hq-sheet-body > .hq-panel { position: static; width: auto; max-height: none; border: 0; background: transparent; box-shadow: none; }
  .hq-sheet-body > .hq-rooms { padding: 0; }
  .hq-sheet-body > .hq-day { padding: var(--space-4) var(--space-8) var(--space-4) var(--space-4); }
  .hq-sheet-body .hq-room { min-height: 40px; }
  .hq-sheet-body > .hq-accounts { flex-direction: column; align-items: stretch; padding: var(--space-4); }
  .hq-sheet-body .hq-account-list { flex-direction: column; align-items: stretch; gap: var(--space-5); }
  .hq-sheet-body .hq-account + .hq-account { padding-left: 0; padding-top: var(--space-5); border-left: 0; border-top: 1px solid var(--border-strong); }
  .hq-sheet-body .hq-accounts .btn { height: 40px; }
}
