/* HR-LAB HQ shell. Light and Dark share one geometry; only colour tokens change. */
:root {
  --bg: #f6f1e8;
  --panel: rgba(255, 252, 247, 0.86);
  --panel-solid: #fffcf7;
  --card: rgba(255, 255, 255, 0.62);
  --row: rgba(255, 255, 255, 0.58);
  --row-hover: rgba(255, 255, 255, 0.95);
  --bubble: #f1e9dc;
  --line: rgba(151, 137, 118, 0.24);
  --line-soft: rgba(151, 137, 118, 0.14);
  --text: #443f38;
  --muted: #665f55;
  --strong: #2d2822;
  --accent: #9b7d5e;
  --accent-soft: rgba(155, 125, 94, 0.14);
  --primary-bg: #463b30;
  --primary-text: #fffaf2;
  --focus: #164bdc;
  --badge-bg: #fde8d5;
  --badge-text: #9a4a12;
  --shadow: 0 18px 48px rgba(68, 54, 36, 0.16);
  --mark-start: #cbbba5;
  --mark-end: #aa9a84;
  --font: "Noto Sans Thai", "Leelawadee UI", Tahoma, sans-serif;
  --font-en: Manrope, "Noto Sans Thai", "Segoe UI", sans-serif;
  --guide-w: 372px;
  --gap: 16px;
  color-scheme: light;
}

:root[data-theme="dark"] {
  --bg: #050b16;
  --panel: rgba(8, 18, 32, 0.84);
  --panel-solid: #0a1626;
  --card: rgba(16, 32, 54, 0.62);
  --row: rgba(15, 31, 52, 0.62);
  --row-hover: rgba(25, 48, 76, 0.9);
  --bubble: #10233a;
  --line: rgba(99, 160, 210, 0.24);
  --line-soft: rgba(99, 160, 210, 0.14);
  --text: #dce9f6;
  --muted: #a7bacb;
  --strong: #f7fbff;
  --accent: #e2bf86;
  --accent-soft: rgba(226, 191, 134, 0.14);
  --primary-bg: #e2bf86;
  --primary-text: #1b140b;
  --focus: #73d5ff;
  --badge-bg: rgba(224, 123, 57, 0.2);
  --badge-text: #ffc59a;
  --shadow: 0 18px 48px rgba(0, 0, 0, 0.45);
  color-scheme: dark;
}

* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; overflow: hidden; }
body {
  background: var(--bg);
  color: var(--text);
  font: 15px/1.55 var(--font);
  -webkit-font-smoothing: antialiased;
  transition: background-color 0.3s ease, color 0.3s ease;
}
a { color: inherit; }
button { font: inherit; color: inherit; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }
.hq-nowrap { white-space: nowrap; }
.hq-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.hq-ico { width: 20px; height: 20px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

/* ----- canvas & overlays ----- */
.hq-canvas { position: fixed; inset: 0; width: 100%; height: 100%; display: block; touch-action: none; cursor: grab; outline: none; }
.hq-canvas.is-dragging { cursor: grabbing; }
.hq-canvas.is-pointing { cursor: pointer; }
.hq-pins { position: fixed; inset: 0; pointer-events: none; z-index: 10; overflow: hidden; }

.hq-panel {
  background: var(--panel);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  -webkit-backdrop-filter: blur(16px) saturate(1.2);
  backdrop-filter: blur(16px) saturate(1.2);
  transition: background-color 0.3s ease, border-color 0.3s ease, color 0.3s ease;
}

/* ----- top bar ----- */
.hq-top { position: fixed; top: var(--gap); left: var(--gap); right: var(--gap); z-index: 20; display: flex; align-items: center; gap: 10px; pointer-events: none; }
.hq-top > * { pointer-events: auto; }
.hq-brand { display: inline-flex; align-items: center; gap: 14px; min-height: 52px; padding: 6px 18px; border-radius: 999px; text-decoration: none; }
.hq-brand__text { padding-left: 14px; border-left: 1px solid var(--line); }
.hq-brand strong { display: block; font: 800 11.5px/1.2 var(--font-en); letter-spacing: 0.2em; color: var(--accent); }
.hq-brand small { display: block; font-size: 12px; color: var(--muted); white-space: nowrap; }
/* Wordmark: both variants share one box so Light/Dark keep the same geometry. */
.hq-logo { display: inline-grid; flex: none; }
.hq-logo__img { grid-area: 1 / 1; display: block; width: auto; height: 24px; }
:root[data-theme="dark"] .hq-logo__img--light, :root:not([data-theme="dark"]) .hq-logo__img--dark { visibility: hidden; }
.hq-logo--boot .hq-logo__img { width: min(340px, 72vw); height: auto; }
.hq-crumbs { display: inline-flex; align-items: center; gap: 4px; min-width: 0; min-height: 44px; padding: 4px 14px; border-radius: 999px; font-size: 13px; color: var(--muted); white-space: nowrap; }
.hq-crumbs a { text-decoration: none; padding: 6px 4px; }
.hq-crumbs a:hover { color: var(--strong); }
.hq-crumbs strong { overflow: hidden; text-overflow: ellipsis; color: var(--strong); font-weight: 600; }
/* Room pages on mid-size screens: the breadcrumb already says where you are. */
@media (max-width: 1100px) {
  [data-page="room"] .hq-brand small { display: none; }
}
.hq-crumbs .hq-ico { width: 14px; height: 14px; transform: rotate(-90deg); opacity: 0.6; }
.hq-tools { margin-left: auto; display: flex; gap: 8px; }
.hq-icon-btn { display: inline-grid; place-items: center; width: 44px; height: 44px; padding: 0; border-radius: 999px; border: 1px solid var(--line); background: var(--panel); cursor: pointer; transition: background-color 0.2s ease, border-color 0.2s ease, color 0.3s ease; }
.hq-icon-btn:hover { border-color: var(--accent); }
.hq-top .hq-icon-btn { box-shadow: var(--shadow); -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px); }
.hq-lang { font: 700 13px var(--font-en); letter-spacing: 0.04em; }
:root[data-theme="light"] #hqTheme { color: #8d6b43; }
:root[data-theme="dark"] #hqTheme { color: #31b9ff; }

/* ----- helper panel ----- */
.hq-guide { position: fixed; z-index: 15; left: var(--gap); top: 84px; bottom: var(--gap); width: var(--guide-w); display: flex; flex-direction: column; border-radius: 24px; overflow: hidden; }
.hq-guide__head { display: flex; align-items: center; gap: 12px; padding: 14px 12px 10px 14px; }
.hq-avatar { display: grid; place-items: center; width: 46px; height: 46px; flex: none; border-radius: 50%; color: #fff; background: linear-gradient(135deg, var(--mark-start), var(--mark-end)); box-shadow: inset 0 0 0 1px rgba(151, 137, 118, 0.2); }
.hq-avatar .hq-ico { width: 24px; height: 24px; stroke-width: 1.9; }
.hq-avatar { overflow: hidden; }
.hq-bank { display: block; width: 100%; height: 100%; }
.hq-guide__who { min-width: 0; flex: 1; }
.hq-guide__who strong { display: block; font-size: 15px; font-weight: 600; color: var(--strong); }
.hq-guide__who small { display: block; font-size: 12.5px; color: var(--muted); line-height: 1.4; }
.hq-guide__toggle { flex: none; background: transparent; box-shadow: none; }
.hq-guide__toggle .hq-ico { transform: rotate(180deg); transition: transform 0.25s ease; }
.hq-guide.is-collapsed .hq-guide__toggle .hq-ico { transform: rotate(0deg); }
.hq-guide__body { position: relative; flex: 1; overflow-y: auto; overscroll-behavior: contain; padding: 2px 16px 18px; scrollbar-width: thin; scrollbar-color: var(--line) transparent; }
.hq-guide.is-collapsed { bottom: auto; }
.hq-guide.is-collapsed .hq-guide__body { display: none; }

.hq-bubble { margin: 0 0 12px; padding: 12px 14px; border-radius: 6px 18px 18px 18px; background: var(--bubble); font-size: 14px; line-height: 1.65; color: var(--text); }
.hq-ask__field { display: flex; align-items: center; gap: 10px; height: 52px; padding: 0 18px; border-radius: 999px; border: 1px solid var(--line); background: var(--row); color: var(--muted); transition: border-color 0.2s ease, background-color 0.3s ease; }
.hq-ask__field:focus-within { border-color: var(--focus); box-shadow: 0 0 0 3px color-mix(in srgb, var(--focus) 18%, transparent); }
.hq-ask input { flex: 1; min-width: 0; border: 0; outline: 0; background: transparent; color: var(--strong); font: 15px var(--font); transition: color 0.3s ease; }
.hq-ask input::placeholder { color: var(--muted); opacity: 0.85; }
.hq-label { margin: 18px 2px 8px; font: 700 11px/1.2 var(--font-en); letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted); }
.hq-empty { margin: 12px 4px 0; font-size: 13.5px; color: var(--muted); }
.hq-results:empty { display: none; }
.hq-guide.is-focused .hq-quick { display: none; }

.hq-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.hq-chip { display: inline-flex; align-items: center; gap: 7px; min-height: 44px; padding: 0 15px 0 12px; border-radius: 999px; border: 1px solid var(--line); background: var(--row); font-size: 13.5px; text-decoration: none; transition: border-color 0.2s ease, background-color 0.2s ease; }
.hq-chip .hq-ico { width: 18px; height: 18px; color: var(--room, var(--accent)); }
.hq-chip:hover { border-color: var(--room, var(--accent)); background: var(--row-hover); }

.hq-list { display: grid; gap: 6px; }
.hq-row { display: flex; align-items: center; gap: 12px; width: 100%; min-height: 52px; padding: 9px 12px; border-radius: 14px; border: 1px solid var(--line-soft); background: var(--row); text-align: left; text-decoration: none; cursor: pointer; transition: border-color 0.2s ease, background-color 0.2s ease, transform 0.2s ease; }
.hq-row:hover { border-color: var(--room, var(--accent)); background: var(--row-hover); transform: translateX(2px); }
.hq-row__icon { display: grid; place-items: center; width: 36px; height: 36px; flex: none; border-radius: 11px; color: var(--room, var(--accent)); background: color-mix(in srgb, var(--room, var(--accent)) 16%, transparent); }
.hq-row__text { min-width: 0; flex: 1; }
.hq-row__text strong { display: block; font-size: 14px; font-weight: 600; line-height: 1.4; color: var(--strong); }
.hq-row__text small { display: block; font-size: 12px; line-height: 1.45; color: var(--muted); }
.hq-row__go { width: 18px; height: 18px; color: var(--muted); }
.hq-row__num { display: grid; place-items: center; width: 28px; height: 28px; flex: none; border-radius: 50%; font: 700 12px var(--font-en); color: var(--primary-text); background: var(--primary-bg); }
.hq-row--object.is-active { border-color: var(--room, var(--accent)); background: var(--row-hover); }
.hq-badge { display: inline-block; margin-left: 8px; padding: 1px 8px; border-radius: 999px; font: 600 11px/1.6 var(--font); font-style: normal; vertical-align: 2px; color: var(--badge-text); background: var(--badge-bg); }

.hq-directory { display: grid; gap: 8px; }
.hq-floor { border: 1px solid var(--line-soft); border-radius: 18px; padding: 4px; background: color-mix(in srgb, var(--row) 55%, transparent); transition: border-color 0.2s ease; }
.hq-floor.is-active { border-color: var(--accent); }
.hq-floor__head { display: flex; align-items: center; gap: 12px; width: 100%; min-height: 54px; padding: 8px; border: 0; border-radius: 14px; background: transparent; text-align: left; cursor: pointer; }
.hq-floor__head:hover { background: var(--accent-soft); }
.hq-floor__num { display: grid; place-items: center; width: 36px; height: 36px; flex: none; border-radius: 11px; font: 800 15px var(--font-en); color: var(--primary-text); background: var(--primary-bg); }
.hq-floor__num--lg { width: 46px; height: 46px; border-radius: 14px; font-size: 19px; }
.hq-floor__text strong { display: block; font-size: 14.5px; font-weight: 600; color: var(--strong); }
.hq-floor__text small { display: block; font-size: 12px; color: var(--muted); line-height: 1.4; }
.hq-floor__rooms { display: grid; gap: 4px; padding: 0 4px 4px; }
.hq-floor__rooms .hq-row { min-height: 46px; padding: 6px 10px; background: transparent; }
.hq-floor__rooms .hq-row__icon { width: 30px; height: 30px; border-radius: 9px; }
.hq-floor__rooms .hq-row__icon .hq-ico { width: 18px; height: 18px; }

.hq-card { margin: 4px 0 2px; padding: 16px; border-radius: 20px; border: 1px solid var(--line-soft); border-top: 3px solid var(--room, var(--accent)); background: var(--card); }
.hq-card h2 { margin: 2px 0 6px; font-size: 19px; font-weight: 600; line-height: 1.35; color: var(--strong); }
.hq-card p { margin: 0 0 12px; font-size: 14px; line-height: 1.7; color: var(--muted); }
.hq-card small { font-size: 12px; color: var(--muted); }
.hq-card__top { display: flex; align-items: flex-start; gap: 12px; margin-bottom: 8px; }
.hq-card__icon { display: grid; place-items: center; width: 46px; height: 46px; flex: none; border-radius: 14px; color: var(--room, var(--accent)); background: color-mix(in srgb, var(--room, var(--accent)) 16%, transparent); }
.hq-card__icon .hq-ico { width: 24px; height: 24px; }
.hq-card .hq-list { margin-top: 4px; }
.hq-card--object h2 { margin-top: 10px; }

.hq-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 6px; }
.hq-btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 0 18px; border-radius: 999px; border: 1px solid var(--line); background: var(--row); font-size: 14px; font-weight: 600; text-decoration: none; cursor: pointer; transition: background-color 0.2s ease, border-color 0.2s ease, color 0.3s ease; }
.hq-btn:hover { border-color: var(--accent); background: var(--row-hover); }
.hq-btn .hq-ico { width: 18px; height: 18px; }
.hq-btn--primary { border-color: transparent; color: var(--primary-text); background: var(--primary-bg); }
.hq-btn--primary:hover { border-color: transparent; background: var(--primary-bg); filter: brightness(1.1); }
.hq-btn--block { width: 100%; margin-top: 16px; }
.hq-back { display: inline-flex; align-items: center; gap: 6px; min-height: 40px; margin: 6px 0 4px; padding: 0 10px 0 4px; border: 0; border-radius: 999px; background: transparent; color: var(--muted); font-size: 13px; cursor: pointer; }
.hq-back:hover { color: var(--strong); background: var(--accent-soft); }
.hq-back .hq-ico { width: 16px; height: 16px; }
.hq-foot { margin: 20px 4px 0; font-size: 12px; line-height: 1.6; color: var(--muted); }
.hq-foot a { color: var(--muted); }
.hq-foot a:hover { color: var(--strong); }

/* ----- dialog (e.g. the construction site) ----- */
.hq-dialog { position: fixed; inset: 0; z-index: 40; display: grid; place-items: center; padding: var(--gap); background: color-mix(in srgb, var(--bg) 46%, transparent); opacity: 0; transition: opacity 0.2s ease; }
.hq-dialog.is-open { opacity: 1; }
.hq-dialog__card { width: min(420px, 100%); padding: 24px 22px 20px; border-radius: 24px; text-align: center; transform: translateY(8px); transition: transform 0.2s ease; }
.hq-dialog.is-open .hq-dialog__card { transform: none; }
.hq-dialog__icon { display: inline-grid; place-items: center; width: 56px; height: 56px; border-radius: 18px; color: #9a4a12; background: #fde8d5; }
:root[data-theme="dark"] .hq-dialog__icon { color: #ffc59a; background: rgba(224, 123, 57, 0.2); }
.hq-dialog__icon .hq-ico { width: 28px; height: 28px; }
.hq-dialog h2 { margin: 14px 0 8px; font-size: 21px; font-weight: 600; color: var(--strong); }
.hq-dialog p { margin: 0 0 16px; font-size: 14.5px; line-height: 1.7; color: var(--muted); }
.hq-dialog .hq-actions { justify-content: center; }

/* ----- HUD tags (floors, rooms), object pins & tooltip -----
   Small, thin and lit like an instrument read-out, so they label the building
   without covering it. Both themes share one geometry. */
:root {
  --hud-bg: rgba(255, 253, 249, 0.86);
  --hud-line: rgba(22, 75, 220, 0.3);
  --hud-accent: #1f5fe0;
  --hud-faint: rgba(31, 95, 224, 0.12);
  --hud-text: #2d2822;
  --hud-glow: rgba(31, 95, 224, 0.28);
}
:root[data-theme="dark"] {
  --hud-bg: rgba(5, 14, 27, 0.8);
  --hud-line: rgba(49, 185, 255, 0.4);
  --hud-accent: #31b9ff;
  --hud-faint: rgba(49, 185, 255, 0.14);
  --hud-text: #e8f3ff;
  --hud-glow: rgba(49, 185, 255, 0.45);
}
.hq-pin { position: absolute; left: 0; top: 0; padding: 0; border: 0; background: none; color: var(--hud-text); white-space: nowrap; cursor: pointer; pointer-events: auto; transition: opacity 0.2s ease, visibility 0.2s; will-change: transform; }
.hq-pin::after { content: ""; position: absolute; inset: -10px -4px; } /* 44px touch target around a small tag */
.hq-pin:focus-visible { outline: none; }
.hq-pin.is-off { opacity: 0; visibility: hidden; pointer-events: none; }

.hq-tag { display: flex; align-items: center; }
.hq-tag.is-left { flex-direction: row-reverse; translate: calc(-100% + 4px) -50%; }
.hq-tag.is-right { translate: -4px -50%; }
.hq-tag__dot { position: relative; flex: none; width: 8px; height: 8px; border-radius: 50%; background: var(--hud-accent); box-shadow: 0 0 0 2px var(--hud-faint), 0 0 10px var(--hud-glow); }
.hq-tag__dot::after { content: ""; position: absolute; inset: -5px; border: 1px solid var(--hud-accent); border-radius: 50%; opacity: 0; animation: hqPing 2.8s ease-out infinite; }
.hq-tag__line { flex: none; width: 22px; height: 1px; }
.hq-tag.is-left .hq-tag__line { background: linear-gradient(90deg, var(--hud-faint), var(--hud-accent)); }
.hq-tag.is-right .hq-tag__line { background: linear-gradient(90deg, var(--hud-accent), var(--hud-faint)); }
.hq-tag__body { position: relative; display: flex; align-items: center; height: 24px; border: 1px solid var(--hud-line); border-radius: 3px; background: var(--hud-bg); box-shadow: 0 4px 14px rgba(0, 0, 0, 0.12); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); transition: border-color 0.2s ease, box-shadow 0.2s ease, background-color 0.3s ease; }
.hq-tag__body::before { content: ""; position: absolute; top: -1px; left: -1px; width: 6px; height: 6px; border-top: 2px solid var(--hud-accent); border-left: 2px solid var(--hud-accent); border-radius: 3px 0 0 0; }
.hq-tag__num { align-self: stretch; display: grid; place-items: center; padding: 0 7px; border-right: 1px solid var(--hud-line); font: 800 11px/1 var(--font-en); letter-spacing: 0.08em; font-variant-numeric: tabular-nums; color: var(--hud-accent); background: var(--hud-faint); }
.hq-tag__name { padding: 0 9px 0 8px; font-size: 11.5px; font-weight: 600; line-height: 1; }
.hq-tag.is-compact .hq-tag__name { display: none; }
.hq-tag.is-compact:hover .hq-tag__name, .hq-tag.is-compact:focus-visible .hq-tag__name { display: inline; }
.hq-tag:hover .hq-tag__body, .hq-tag.is-hover .hq-tag__body, .hq-tag:focus-visible .hq-tag__body { border-color: var(--hud-accent); box-shadow: 0 0 0 1px var(--hud-accent), 0 0 18px var(--hud-glow); }

.hq-tag--room { flex-direction: column; translate: -50% calc(-100% + 4px); }
.hq-tag--room .hq-tag__line { width: 1px; height: 14px; background: linear-gradient(180deg, transparent, var(--room)); }
.hq-tag--annex .hq-tag__line { height: calc(14px + var(--lift, 0px)); }
.hq-tag--bank .hq-tag__line { height: 10px; }
.hq-tag--bank .hq-tag__dot { width: 6px; height: 6px; }
.hq-tag--room .hq-tag__dot { background: var(--room); box-shadow: 0 0 0 2px color-mix(in srgb, var(--room) 25%, transparent), 0 0 10px color-mix(in srgb, var(--room) 60%, transparent); }
.hq-tag--room .hq-tag__dot::after { border-color: var(--room); }
.hq-tag--room .hq-tag__body { padding-left: 7px; border-left: 3px solid var(--room); }
.hq-tag--room .hq-tag__body::before { display: none; }
.hq-tag--room .hq-ico { width: 14px; height: 14px; color: var(--room); }
.hq-tag--room .hq-tag__name { padding: 0 9px 0 6px; }
.hq-tag--room:hover .hq-tag__body, .hq-tag--room:focus-visible .hq-tag__body, .hq-tag--room.is-selected .hq-tag__body { border-color: var(--room); box-shadow: 0 0 0 1px var(--room), 0 0 18px color-mix(in srgb, var(--room) 50%, transparent); }

.hq-pin--object { display: inline-flex; align-items: center; gap: 6px; translate: -13px -50%; }
.hq-pin--object > span:first-child { display: grid; place-items: center; width: 26px; height: 26px; border: 1.5px solid var(--room); border-radius: 50%; font: 800 11px/1 var(--font-en); color: var(--hud-text); background: var(--hud-bg); box-shadow: 0 0 12px color-mix(in srgb, var(--room) 45%, transparent); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); transition: background-color 0.2s ease, color 0.2s ease, box-shadow 0.2s ease; }
.hq-pin--object .hq-pin__label { display: none; align-items: center; height: 24px; padding: 0 10px; border: 1px solid var(--hud-line); border-left: 3px solid var(--room); border-radius: 3px; font: 600 11.5px/1 var(--font); background: var(--hud-bg); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); }
.hq-pin--object:hover .hq-pin__label, .hq-pin--object:focus-visible .hq-pin__label, .hq-pin--object.is-selected .hq-pin__label { display: inline-flex; }
.hq-pin--object:hover > span:first-child, .hq-pin--object:focus-visible > span:first-child { box-shadow: 0 0 0 3px color-mix(in srgb, var(--room) 30%, transparent), 0 0 16px var(--room); }
.hq-pin--object.is-selected > span:first-child { color: #fff; background: var(--room); box-shadow: 0 0 0 3px color-mix(in srgb, var(--room) 30%, transparent), 0 0 16px var(--room); }

.hq-tip { position: fixed; left: 0; top: 0; z-index: 30; max-width: 260px; padding: 7px 11px 7px 10px; border-radius: 4px; border-left: 3px solid var(--hud-accent); background: var(--hud-bg); pointer-events: none; font-size: 12px; }
.hq-tip strong { display: block; font-weight: 600; color: var(--strong); }
.hq-tip small { display: block; color: var(--muted); font-size: 11.5px; }
@keyframes hqPing { 0% { transform: scale(0.6); opacity: 0.9; } 70% { transform: scale(1.7); opacity: 0; } 100% { opacity: 0; } }

.hq-hint { position: fixed; z-index: 12; right: var(--gap); bottom: var(--gap); display: flex; align-items: center; gap: 10px; padding: 5px 5px 5px 16px; border-radius: 999px; font-size: 12.5px; color: var(--muted); }
.hq-hint .hq-icon-btn { width: 40px; height: 40px; background: var(--row); }
.hq-hint.is-quiet { padding: 5px; }
.hq-hint.is-quiet span { display: none; }
.hq-no3d-note { position: fixed; z-index: 12; right: var(--gap); top: 84px; max-width: 340px; margin: 0; padding: 14px 16px; border-radius: 16px; font-size: 14px; }
.hq-no3d .hq-canvas, .hq-no3d .hq-hint, .hq-no3d .hq-pins { display: none; }

/* ----- transition owner & boot ----- */
.hq-veil { position: fixed; inset: 0; z-index: 50; display: grid; place-items: center; background: var(--bg); opacity: 0; visibility: hidden; transition: opacity 0.2s ease, visibility 0.2s; }
.hq-veil.is-active { opacity: 1; visibility: visible; }
.hq-veil__line, .hq-boot__line { width: min(260px, 60vw); height: 2px; overflow: hidden; border-radius: 999px; background: var(--line); }
.hq-veil__line i, .hq-boot__line i { display: block; width: 45%; height: 100%; background: linear-gradient(90deg, transparent, var(--accent), transparent); animation: hqLine 0.9s cubic-bezier(0.4, 0, 0.2, 1) infinite; }
.hq-veil:not(.is-leaving) .hq-veil__line { visibility: hidden; }
.hq-boot { position: fixed; inset: 0; z-index: 60; display: none; place-items: center; align-content: center; gap: 26px; background: var(--bg); transition: opacity 0.4s ease; }
.hq-booting .hq-boot { display: grid; }
.hq-ready .hq-boot { opacity: 0; pointer-events: none; }
.hq-boot p { margin: -8px 0 0; font: 700 13px var(--font-en); letter-spacing: 0.18em; color: var(--muted); text-align: center; }
@keyframes hqLine { from { transform: translateX(-110%); } to { transform: translateX(230%); } }

/* ----- phones: helper becomes a bottom sheet ----- */
@media (max-width: 760px) {
  :root { --gap: 10px; }
  .hq-brand { min-height: 46px; padding: 4px 12px; gap: 8px; min-width: 0; }
  .hq-logo__img { height: 17px; }
  .hq-brand__text { padding-left: 8px; }
  .hq-brand strong { font-size: 9.5px; letter-spacing: 0.12em; }
  .hq-tools { gap: 6px; flex: none; }
  .hq-brand small { display: none; }
  .hq-crumbs { min-width: 0; padding: 4px 14px; }
  .hq-crumbs a, .hq-crumbs .hq-ico { display: none; }
  .hq-crumbs strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  [data-page="room"] .hq-brand { padding-right: 6px; }
  [data-page="room"] .hq-brand__text { display: none; }
  .hq-guide { left: 0; right: 0; top: auto; bottom: 0; width: auto; max-height: min(74svh, 640px); border-radius: 24px 24px 0 0; border-bottom: 0; padding-bottom: env(safe-area-inset-bottom); }
  .hq-guide::before { content: ""; position: absolute; top: 7px; left: 50%; width: 40px; height: 4px; margin-left: -20px; border-radius: 999px; background: var(--line); }
  .hq-guide__head { padding-top: 18px; }
  .hq-guide.is-collapsed { bottom: 0; }
  .hq-guide.is-collapsed .hq-guide__body { display: block; overflow: visible; padding-bottom: 14px; }
  .hq-guide.is-collapsed .hq-guide__body > :not(.hq-ask) { display: none; }
  .hq-guide__who small { display: none; }
  .hq-hint { right: var(--gap); top: 66px; bottom: auto; padding: 0; background: transparent; border: 0; box-shadow: none; -webkit-backdrop-filter: none; backdrop-filter: none; }
  .hq-hint span { display: none; }
  .hq-hint .hq-icon-btn { width: 44px; height: 44px; background: var(--panel); box-shadow: var(--shadow); }
  .hq-no3d-note { left: var(--gap); right: var(--gap); top: 66px; max-width: none; }
}

@media (max-width: 340px) {
  .hq-brand__text { display: none; }
}

/* ----- HRcade mini-games (assets/js/arcade.js) -----
   A panel over the room in the same HUD language as the tags; one geometry for both themes. */
:root { --good: #23865a; --good-bg: rgba(35, 134, 90, 0.12); --bad: #c2412f; --bad-bg: rgba(194, 65, 47, 0.1); }
:root[data-theme="dark"] { --good: #5fd39b; --good-bg: rgba(95, 211, 155, 0.14); --bad: #ff8a78; --bad-bg: rgba(255, 138, 120, 0.12); }
.hq-game { position: fixed; inset: 0; z-index: 45; display: grid; place-items: center; padding: var(--gap); background: color-mix(in srgb, var(--bg) 52%, transparent); opacity: 0; transition: opacity 0.2s ease; }
.hq-game.is-open { opacity: 1; }
.hq-game__card { display: flex; flex-direction: column; width: min(560px, 100%); max-height: min(740px, calc(100dvh - 2 * var(--gap))); border-radius: 22px; overflow: hidden; transform: translateY(8px); transition: transform 0.2s ease; }
.hq-game.is-open .hq-game__card { transform: none; }
.hq-game__head { display: flex; align-items: center; gap: 8px; padding: 12px 12px 12px 18px; border-bottom: 1px solid var(--line-soft); }
.hq-game__head h2 { flex: 1; min-width: 0; margin: 0; font-size: 17px; font-weight: 600; color: var(--strong); }
.hq-game__head [data-back] { margin-left: -6px; }
.hq-game__body { flex: 1; min-height: 0; overflow: auto; padding: 16px 18px 20px; }
.hq-game__intro { margin: 0 0 14px; font-size: 14px; line-height: 1.65; color: var(--muted); }
.hq-game__foot { margin: 16px 0 0; font-size: 13px; line-height: 1.6; color: var(--muted); }
.hq-game__foot a { font-weight: 600; color: var(--text); }
.hq-game__foot .hq-ico { width: 14px; height: 14px; vertical-align: -2px; }
.hq-games { display: grid; gap: 10px; }
.hq-gamecard { position: relative; display: flex; align-items: center; gap: 14px; width: 100%; padding: 14px; border: 1px solid var(--line); border-left: 3px solid var(--room); border-radius: 6px; background: var(--row); color: var(--text); text-align: left; cursor: pointer; transition: background-color 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease; }
.hq-gamecard:hover, .hq-gamecard:focus-visible { border-color: var(--room); background: var(--row-hover); box-shadow: 0 0 0 1px var(--room), 0 0 18px color-mix(in srgb, var(--room) 35%, transparent); outline: none; }
.hq-gamecard__icon { display: grid; place-items: center; flex: none; width: 44px; height: 44px; border-radius: 12px; color: var(--room); background: color-mix(in srgb, var(--room) 16%, transparent); }
.hq-gamecard__icon .hq-ico { width: 22px; height: 22px; }
.hq-gamecard__text { flex: 1; min-width: 0; }
.hq-gamecard__text strong { display: block; font-size: 15px; font-weight: 600; color: var(--strong); }
.hq-gamecard__text small { display: block; margin-top: 2px; font-size: 12.5px; line-height: 1.5; color: var(--muted); }
.hq-gamecard__text em { display: inline-block; margin-top: 6px; padding: 1px 8px; border-radius: 3px; font: 600 11px/1.6 var(--font); font-style: normal; color: var(--hud-accent); background: var(--hud-faint); }
.hq-gamecard__play { display: inline-flex; align-items: center; gap: 4px; flex: none; font-size: 13px; font-weight: 600; color: var(--room); }
.hq-gamecard__play .hq-ico { width: 16px; height: 16px; }
.hq-game__meta { display: flex; justify-content: space-between; gap: 12px; margin-bottom: 10px; font: 700 12px/1.4 var(--font-en); letter-spacing: 0.04em; color: var(--hud-accent); font-variant-numeric: tabular-nums; }
.hq-timer { height: 4px; margin-bottom: 14px; border-radius: 4px; background: var(--hud-faint); overflow: hidden; }
.hq-timer span { display: block; height: 100%; width: 100%; background: var(--hud-accent); transform-origin: left; }
.hq-timer span.is-running { animation: hqTimer 20s linear forwards; }
@keyframes hqTimer { to { transform: scaleX(0); } }
.hq-game__q { margin: 0 0 14px; font-size: 17px; font-weight: 600; line-height: 1.6; color: var(--strong); }
.hq-game__q--card { padding: 14px 16px; border: 1px dashed var(--line); border-radius: 6px; background: var(--card); font-size: 16px; }
.hq-choices { display: grid; gap: 8px; }
.hq-choice { display: flex; align-items: center; gap: 12px; width: 100%; min-height: 48px; padding: 10px 14px; border: 1px solid var(--line); border-radius: 6px; background: var(--row); color: var(--text); font-size: 15px; font-weight: 600; text-align: left; cursor: pointer; transition: background-color 0.2s ease, border-color 0.2s ease; }
.hq-choice:hover:not(:disabled), .hq-choice:focus-visible { border-color: var(--hud-accent); background: var(--row-hover); outline: none; }
.hq-choice:disabled { cursor: default; opacity: 0.62; }
.hq-choice.is-correct { opacity: 1; border-color: var(--good); background: var(--good-bg); color: var(--good); }
.hq-choice.is-wrong { opacity: 1; border-color: var(--bad); background: var(--bad-bg); color: var(--bad); }
.hq-choice--room .hq-ico { flex: none; width: 22px; height: 22px; color: var(--room); }
.hq-choice--room span { display: grid; }
.hq-choice--room small { font-size: 12px; font-weight: 500; color: var(--muted); }
.hq-feedback:empty { display: none; }
.hq-feedback { margin-top: 14px; }
.hq-feedback__box { padding: 12px 14px; border-left: 3px solid; border-radius: 4px; font-size: 14px; line-height: 1.6; }
.hq-feedback__box.is-good { border-color: var(--good); background: var(--good-bg); }
.hq-feedback__box.is-bad { border-color: var(--bad); background: var(--bad-bg); }
.hq-feedback__box strong { color: var(--strong); }
.hq-feedback__box p { margin: 4px 0 6px; color: var(--text); }
.hq-feedback__box a { font-size: 13px; font-weight: 600; color: var(--text); }
.hq-feedback__box a .hq-ico { width: 14px; height: 14px; vertical-align: -2px; }
.hq-feedback .hq-btn--block { margin-top: 12px; }
.hq-memory { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.hq-mcard { position: relative; aspect-ratio: 1 / 1.08; padding: 0; border: 1px solid var(--line); border-radius: 8px; background: var(--row); cursor: pointer; overflow: hidden; transition: border-color 0.2s ease, box-shadow 0.2s ease; }
.hq-mcard:hover, .hq-mcard:focus-visible { border-color: var(--hud-accent); outline: none; }
.hq-mcard__back, .hq-mcard__face { position: absolute; inset: 0; display: grid; place-items: center; transition: opacity 0.2s ease, transform 0.2s ease; }
.hq-mcard__back { background: repeating-linear-gradient(45deg, var(--hud-faint) 0 6px, transparent 6px 12px); }
.hq-mcard__back::after { content: ""; width: 34%; aspect-ratio: 1; border: 1px solid var(--hud-line); border-radius: 50%; }
.hq-mcard__face { opacity: 0; transform: scale(0.8); color: var(--room); background: color-mix(in srgb, var(--room) 14%, var(--panel-solid)); }
.hq-mcard__face .hq-ico { width: 42%; height: 42%; }
.hq-mcard.is-up .hq-mcard__face { opacity: 1; transform: none; }
.hq-mcard.is-up .hq-mcard__back { opacity: 0; }
.hq-mcard.is-done { border-color: var(--room); box-shadow: 0 0 0 1px var(--room); cursor: default; }
.hq-memory__note { min-height: 24px; margin: 12px 0 0; font-size: 14px; font-weight: 600; color: var(--good); }
.hq-catch { position: relative; }
.hq-catch canvas { display: block; width: 100%; height: 330px; border: 1px solid var(--line); border-radius: 10px; background: var(--card); touch-action: none; cursor: none; }
.hq-catch canvas:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
.hq-catch__start { position: absolute; inset: 0; display: grid; place-content: center; justify-items: center; gap: 14px; padding: 20px; border-radius: 10px; text-align: center; background: color-mix(in srgb, var(--panel-solid) 84%, transparent); }
.hq-catch__start[hidden] { display: none; }
.hq-catch__start p { max-width: 380px; margin: 0; font-size: 14px; line-height: 1.65; color: var(--text); }
.hq-game__meta [data-lives] { color: var(--bad); letter-spacing: 0.12em; }
.hq-result { display: grid; justify-items: center; gap: 6px; padding: 16px 0 6px; text-align: center; }
.hq-result__big { font: 800 40px/1.1 var(--font-en); color: var(--hud-accent); font-variant-numeric: tabular-nums; }
.hq-result__line { margin: 0; font-size: 16px; font-weight: 600; color: var(--strong); }
.hq-result__cheer { margin: 0; font-size: 14px; color: var(--muted); }
.hq-result__best { margin: 6px 0 10px; font-size: 13px; color: var(--muted); }
.hq-result__best em { padding: 1px 8px; border-radius: 3px; font-style: normal; font-weight: 700; color: var(--good); background: var(--good-bg); }
.hq-result .hq-actions { justify-content: center; }
@media (max-width: 520px) {
  .hq-game { padding: 10px; }
  .hq-game__card { max-height: calc(100dvh - 20px); border-radius: 18px; }
  .hq-game__body { padding: 14px 14px 18px; }
  .hq-memory { grid-template-columns: repeat(3, 1fr); }
  .hq-catch canvas { height: min(330px, 46dvh); }
  .hq-gamecard__play { display: none; }
}

/* ----- lift (assets/js/lift.js): floor panel, doors between floors, B1 keypad -----
   Buttons read like a real lift panel (round metal keys, lit ring on the current floor);
   the floor read-out stays an amber-on-black display in both themes, like the hardware. */
.hq-hint .hq-lift-btn { order: 0; }
.hq-liftpanel { position: fixed; z-index: 26; right: var(--gap); bottom: 76px; width: 272px; padding: 10px; border-radius: 20px; opacity: 0; transform: translateY(6px); transition: opacity 0.18s ease, transform 0.18s ease; }
.hq-liftpanel.is-open { opacity: 1; transform: none; }
.hq-liftpanel[hidden] { display: none; }
.hq-liftpanel__screen { display: flex; align-items: center; gap: 12px; margin-bottom: 10px; padding: 8px 8px 8px 10px; border-radius: 13px; color: #e8f3ff; background: #0d1622; }
.hq-liftpanel__num { display: grid; place-items: center; min-width: 48px; height: 44px; padding: 0 6px; border-radius: 8px; font: 800 24px/1 var(--font-en); color: #ffb454; background: #04080f; text-shadow: 0 0 10px rgba(255, 180, 84, 0.6); font-variant-numeric: tabular-nums; }
.hq-liftpanel__screen strong { display: block; font-size: 14px; font-weight: 600; }
.hq-liftpanel__screen small { display: block; font-size: 12px; color: #9fb4c8; }
.hq-liftpanel__screen .hq-icon-btn { flex: none; margin-left: auto; width: 36px; height: 36px; color: #e8f3ff; border-color: rgba(255, 255, 255, 0.16); background: transparent; }
.hq-liftpanel__stops { display: grid; grid-template-columns: minmax(0, 1fr); gap: 6px; }
.hq-stop { display: flex; align-items: center; gap: 12px; width: 100%; min-height: 48px; padding: 5px 12px 5px 5px; border: 1px solid var(--line); border-radius: 999px; background: var(--row); color: var(--text); text-align: left; cursor: pointer; transition: border-color 0.2s ease, background-color 0.2s ease; }
.hq-stop:hover, .hq-stop:focus-visible { border-color: var(--hud-accent); background: var(--row-hover); outline: none; }
.hq-stop__key { display: grid; place-items: center; flex: none; width: 38px; height: 38px; border-radius: 50%; font: 800 14px/1 var(--font-en); color: #2d2822; background: radial-gradient(circle at 35% 30%, #ffffff, #d7dcdf 60%, #b8bfc3); box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.7), 0 1px 3px rgba(0, 0, 0, 0.25); transition: box-shadow 0.2s ease; }
:root[data-theme="dark"] .hq-stop__key { color: #e8f3ff; background: radial-gradient(circle at 35% 30%, #56677a, #2c3644 65%, #222a35); box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.12), 0 1px 3px rgba(0, 0, 0, 0.4); }
.hq-stop:hover .hq-stop__key, .hq-stop:focus-visible .hq-stop__key, .hq-stop.is-here .hq-stop__key { box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.5), 0 0 0 2px var(--hud-accent), 0 0 14px var(--hud-glow); }
.hq-stop.is-here { border-color: var(--hud-accent); cursor: default; }
.hq-stop__text { flex: 1; min-width: 0; }
.hq-stop__text strong { display: block; font-size: 13.5px; font-weight: 600; color: var(--strong); }
.hq-stop__text small { display: flex; align-items: center; gap: 4px; font-size: 11.5px; color: var(--muted); }
.hq-stop__text small .hq-ico { width: 13px; height: 13px; }
.hq-liftpanel__back { margin: 0 0 8px; }
.hq-stop--room .hq-stop__key { color: var(--room); }
.hq-stop--room .hq-stop__key .hq-ico { width: 18px; height: 18px; }
.hq-stop--room .hq-stop__text small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hq-stop.is-locked .hq-stop__key { color: #ff8a78; background: radial-gradient(circle at 35% 30%, #4a4f55, #2a2e33 70%); }
.hq-stop.is-locked small { color: var(--bad); }

.hq-lift { position: fixed; inset: 0; z-index: 60; visibility: hidden; pointer-events: none; }
.hq-lift.is-on { visibility: visible; pointer-events: auto; }
.hq-lift__door { position: absolute; top: 0; bottom: 0; width: 50.5%; background:
  repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.07) 0 2px, transparent 2px 6px),
  linear-gradient(90deg, #aeb5b9, #e2e6e8 38%, #cfd5d8 72%, #aab1b5); transition: transform 0.42s cubic-bezier(0.6, 0, 0.2, 1); }
:root[data-theme="dark"] .hq-lift__door { background:
  repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.04) 0 2px, transparent 2px 6px),
  linear-gradient(90deg, #1d2530, #3a4654 38%, #2f3a48 72%, #1b222c); }
.hq-lift__door--l { left: 0; transform: translateX(-101%); box-shadow: inset -2px 0 0 rgba(0, 0, 0, 0.25); }
.hq-lift__door--r { right: 0; transform: translateX(101%); box-shadow: inset 2px 0 0 rgba(0, 0, 0, 0.25); }
.hq-lift.is-closed .hq-lift__door { transform: none; }
.hq-lift__screen { position: absolute; top: 14%; left: 50%; display: flex; align-items: center; justify-content: center; gap: 12px; min-width: 116px; padding: 10px 18px; border-radius: 10px; font: 800 34px/1 var(--font-en); color: #ffb454; background: #04080f; box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.2), 0 10px 30px rgba(0, 0, 0, 0.35); text-shadow: 0 0 12px rgba(255, 180, 84, 0.6); translate: -50% 0; opacity: 0; transition: opacity 0.2s ease 0.2s; font-variant-numeric: tabular-nums; }
.hq-lift.is-closed .hq-lift__screen { opacity: 1; }
.hq-lift__arrow { font-size: 20px; }
.hq-lift__arrow:empty { display: none; }

.hq-keypad-wrap { position: fixed; inset: 0; z-index: 70; display: grid; place-items: center; padding: var(--gap); background: rgba(3, 7, 14, 0.42); opacity: 0; transition: opacity 0.2s ease; }
.hq-keypad-wrap.is-open { opacity: 1; }
.hq-keypad { width: min(340px, 100%); padding: 18px; border-radius: 22px; }
.hq-keypad__head { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; }
.hq-keypad__lock { display: grid; place-items: center; flex: none; width: 44px; height: 44px; border-radius: 12px; color: var(--bad); background: var(--bad-bg); }
.hq-keypad__lock .hq-ico { width: 22px; height: 22px; }
.hq-keypad__head em { display: block; font: 700 11px/1.5 var(--font-en); font-style: normal; letter-spacing: 0.12em; text-transform: uppercase; color: var(--bad); }
.hq-keypad__head strong { display: block; font-size: 16px; font-weight: 600; color: var(--strong); }
.hq-keypad__screen { position: relative; margin-bottom: 14px; padding: 18px 14px 12px; border-radius: 14px; text-align: center; background: #04080f; }
.hq-keypad__led { position: absolute; top: 10px; right: 12px; width: 8px; height: 8px; border-radius: 50%; background: #31b9ff; box-shadow: 0 0 8px #31b9ff; }
.hq-keypad[data-state="checking"] .hq-keypad__led { background: #ffb454; box-shadow: 0 0 8px #ffb454; animation: hqBlink 0.3s infinite alternate; }
.hq-keypad[data-state="denied"] .hq-keypad__led { background: #ff5a4f; box-shadow: 0 0 10px #ff5a4f; }
.hq-keypad__dots { display: flex; justify-content: center; gap: 10px; margin-bottom: 10px; }
.hq-keypad__dots i { width: 12px; height: 12px; border: 1.5px solid rgba(232, 243, 255, 0.5); border-radius: 50%; transition: background-color 0.15s ease; }
.hq-keypad__dots i.is-on { border-color: #e8f3ff; background: #e8f3ff; }
.hq-keypad[data-state="denied"] .hq-keypad__dots i { border-color: #ff5a4f; background: #ff5a4f; }
.hq-keypad[data-state="denied"] .hq-keypad__screen { animation: hqShake 0.4s ease; }
.hq-keypad__status { min-height: 20px; margin: 0; font: 600 13px/1.5 var(--font); color: #9fb4c8; }
.hq-keypad[data-state="denied"] .hq-keypad__status { color: #ff8a78; }
.hq-keypad__keys { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.hq-keypad__keys button { min-height: 52px; border: 1px solid var(--line); border-radius: 14px; font: 700 20px/1 var(--font-en); color: var(--strong); background: var(--row); cursor: pointer; transition: border-color 0.2s ease, background-color 0.2s ease; }
.hq-keypad__keys button:hover, .hq-keypad__keys button:focus-visible { border-color: var(--hud-accent); background: var(--row-hover); outline: none; }
.hq-keypad__keys button:active { transform: translateY(1px); }
.hq-keypad__keys .hq-ico { width: 20px; height: 20px; }
.hq-keypad__keys .hq-keypad__exit { color: var(--muted); }
.hq-keypad__note { margin: 14px 0 0; font-size: 12.5px; line-height: 1.6; text-align: center; color: var(--muted); }
@keyframes hqShake { 0%, 100% { transform: none; } 20% { transform: translateX(-6px); } 40% { transform: translateX(6px); } 60% { transform: translateX(-4px); } 80% { transform: translateX(4px); } }
@keyframes hqBlink { to { opacity: 0.35; } }

/* B1 in the directory and search: present, but locked */
.hq-floor--locked { border-style: dashed; }
.hq-floor--locked .hq-floor__num { font-size: 12.5px; color: #ff8a78; background: #2f3438; }
.hq-floor__lock { margin-left: auto; color: var(--muted); }
.hq-floor__lock .hq-ico { width: 16px; height: 16px; }
.hq-badge--lock { color: var(--bad); background: var(--bad-bg); }

@media (max-width: 760px) {
  .hq-liftpanel { top: 122px; bottom: auto; width: min(272px, calc(100vw - 2 * var(--gap))); }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition-duration: 0s !important; animation-duration: 0s !important; }
}

/* Library: quiet shelf markers, using the exterior building's sign language. */
.hq-tag--library { --hud-accent: var(--room); min-width: 28px; min-height: 32px; z-index: 1; }
.hq-tag--library .hq-tag__dot { width: 6px; height: 6px; box-shadow: 0 0 0 2px var(--hud-bg); }
.hq-tag--library .hq-tag__dot::after { animation: none; }
.hq-tag--library .hq-tag__line, .hq-tag--library .hq-tag__body { display: none; }
.hq-tag--library:hover, .hq-tag--library:focus-visible, .hq-tag--library.is-selected { z-index: 5; }
.hq-tag--library:hover .hq-tag__line, .hq-tag--library:focus-visible .hq-tag__line, .hq-tag--library.is-selected .hq-tag__line { display: block; width: 16px; }
.hq-tag--library:hover .hq-tag__body, .hq-tag--library:focus-visible .hq-tag__body, .hq-tag--library.is-selected .hq-tag__body { display: flex; }
.hq-tag--library .hq-tag__name { max-width: 230px; white-space: normal; line-height: 1.35; }
.hq-tag--library .hq-tag__body { height: auto; min-height: 28px; padding-block: 4px; }
