/* VigiDoc Dashboard - presentation only.
   Element ids come from index.html and class names from the view modules
   under views/; the controller never sets styles. Every colour, spacing,
   radius and motion value is a token below (design-system/MASTER.md).
   Layout: dark navigation rail (computer list) + light content pane
   (fleet overview or one computer's detail). */

:root {
  /* content pane */
  --color-bg: #f3f5f9;
  --color-surface: #ffffff;
  --color-surface-muted: #f8fafc;
  --color-surface-subtle: #eef2f7;
  --color-text: #0f172a;
  --color-text-muted: #475569;
  --color-text-subtle: #64748b;
  --color-border: #e2e8f0;
  --color-border-strong: #cbd5e1;
  --color-primary: #1e40af;
  --color-primary-hover: #1e3a8a;
  --color-primary-soft: #dbeafe;
  --color-on-primary: #ffffff;
  --color-ring: #2563eb;
  --color-overlay: rgba(15, 23, 42, 0.55);
  --color-mark: #fde68a;
  /* semantic tones: text on tint, tint, border, solid (icon on white) */
  --tone-success-text: #166534;
  --tone-success-bg: #dcfce7;
  --tone-success-border: #86efac;
  --tone-success-solid: #15803d;
  --tone-danger-text: #991b1b;
  --tone-danger-bg: #fee2e2;
  --tone-danger-border: #fca5a5;
  --tone-danger-solid: #dc2626;
  --tone-warning-text: #92400e;
  --tone-warning-bg: #fef3c7;
  --tone-warning-border: #fcd34d;
  --tone-warning-solid: #b45309;
  --tone-neutral-text: #334155;
  --tone-neutral-bg: #e2e8f0;
  --tone-neutral-border: #cbd5e1;
  --tone-neutral-solid: #64748b;
  --tone-muted-text: #475569;
  --tone-muted-bg: #f1f5f9;
  --tone-muted-border: #cbd5e1;
  --tone-muted-solid: #64748b;
  --tone-accent-text: #92400e;
  --tone-accent-bg: #fef3c7;
  /* module identity (icon + tint); status colours stay red/green/amber */
  --module-usb: #0369a1;
  --module-usb-bg: #e0f2fe;
  --module-usb-light: #7dd3fc;
  --module-outlook: #6d28d9;
  --module-outlook-bg: #ede9fe;
  --module-outlook-light: #c4b5fd;
  --module-browser: #0f766e;
  --module-browser-bg: #ccfbf1;
  --module-browser-light: #5eead4;
  --module-webmail: #a21caf;
  --module-webmail-bg: #fae8ff;
  --module-webmail-light: #f0abfc;
  --module-attachments: #9a3412;
  --module-attachments-bg: #ffedd5;
  --module-attachments-light: #fdba74;
  /* dark navigation rail */
  --rail-bg: #0f172a;
  --rail-surface: #1e293b;
  --rail-border: #1e293b;
  --rail-hover: #1e293b;
  --rail-selected: #1e3a8a;
  --rail-text: #f1f5f9;
  --rail-text-muted: #94a3b8;
  --rail-text-on-selected: #bfdbfe;
  --rail-danger: #fca5a5;
  --rail-warning: #fcd34d;
  --rail-off: #64748b;
  --rail-ring: #93c5fd;
  /* type */
  --font-sans: Inter, 'Segoe UI', -apple-system, BlinkMacSystemFont, Roboto, system-ui, sans-serif;
  --font-mono: 'Cascadia Mono', Consolas, 'Segoe UI Mono', ui-monospace, monospace;
  --text-xs: 10px;
  --text-sm: 11px;
  --text-md: 12px;
  --text-base: 13px;
  --text-lg: 14px;
  --text-xl: 16px;
  --text-2xl: 20px;
  --text-3xl: 24px;
  --line-height: 1.5;
  /* spacing (dense dashboard scale) */
  --space-xs: 4px;
  --space-sm: 8px;
  --space-md: 12px;
  --space-lg: 16px;
  --space-xl: 20px;
  --space-2xl: 24px;
  --space-3xl: 32px;
  /* shape, elevation, motion */
  --radius-sm: 4px;
  --radius-md: 6px;
  --radius-lg: 10px;
  --radius-xl: 14px;
  --shadow-sm: 0 1px 2px rgba(15, 23, 42, 0.06);
  --shadow-md: 0 4px 12px rgba(15, 23, 42, 0.08);
  --shadow-lg: 0 16px 40px rgba(15, 23, 42, 0.25);
  --duration-fast: 150ms;
  --duration-base: 220ms;
  --ease-standard: cubic-bezier(0.2, 0, 0, 1);
  --control-height: 32px;
  --rail-width: 320px;
}

/* ---------- base ---------- */
* { box-sizing: border-box; }
html, body { height: 100%; }
body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: var(--text-base);
  line-height: var(--line-height);
  background: var(--color-bg);
  color: var(--color-text);
  overflow: hidden;
}
#app { display: flex; height: 100vh; }
button, input { font-family: inherit; font-size: inherit; touch-action: manipulation; }
h1, h2, h3, h4, p { margin: 0; }
ul { margin: 0; padding: 0; list-style: none; }
:focus-visible { outline: 2px solid var(--color-ring); outline-offset: 2px; }
#rail :focus-visible { outline-color: var(--rail-ring); }
.hidden { display: none !important; }
.visually-hidden {
  position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.mono { font-family: var(--font-mono); font-size: 0.95em; }
.wrap { overflow-wrap: anywhere; }
.muted { color: var(--color-text-subtle); }
.sep { color: var(--color-text-subtle); margin: 0 5px; }
.icon { flex: none; }
.icon.flip { transform: rotate(180deg); }
mark { background: var(--color-mark); color: inherit; border-radius: 2px; padding: 0 1px; }
.fatal-error { color: var(--tone-danger-text); padding: var(--space-md); }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition-duration: 0.01ms !important; animation-duration: 0.01ms !important; scroll-behavior: auto !important; }
}

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 6px;
  min-height: var(--control-height); padding: 6px 12px;
  border-radius: var(--radius-md); border: 1px solid var(--color-border-strong);
  background: var(--color-surface); color: var(--color-text);
  cursor: pointer; font-size: var(--text-base); font-weight: 500; white-space: nowrap;
  transition: background-color var(--duration-fast) var(--ease-standard), border-color var(--duration-fast) var(--ease-standard);
}
.btn:hover { background: var(--color-surface-subtle); }
.btn:disabled { opacity: 0.5; cursor: not-allowed; }
.btn-primary { background: var(--color-primary); border-color: var(--color-primary); color: var(--color-on-primary); }
.btn-primary:hover { background: var(--color-primary-hover); border-color: var(--color-primary-hover); }
.btn-ghost { border-color: transparent; background: transparent; color: var(--color-text-muted); }
.btn-ghost:hover { background: var(--color-surface-subtle); color: var(--color-text); }
.btn-sm { min-height: 28px; padding: 4px 10px; font-size: var(--text-md); }
.icon-btn {
  display: inline-flex; align-items: center; justify-content: center;
  width: 28px; height: 28px; padding: 0; border: 0; border-radius: var(--radius-md);
  background: transparent; color: var(--color-text-subtle); cursor: pointer;
  transition: background-color var(--duration-fast) var(--ease-standard);
}
.icon-btn:hover { background: var(--color-surface-subtle); color: var(--color-text); }
.link-btn {
  display: inline-flex; align-items: center; gap: 4px; padding: 0; border: 0; background: none;
  color: var(--color-primary); cursor: pointer; font: inherit; text-decoration: underline; text-underline-offset: 2px;
  overflow-wrap: anywhere; text-align: left;
}
.link-btn:hover { color: var(--color-primary-hover); }

/* ---------- pills, flags, chips ---------- */
.pill {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 2px 8px; border-radius: 999px; border: 1px solid transparent;
  font-size: var(--text-md); font-weight: 600; line-height: 1.4; white-space: nowrap;
}
.pill-sm { padding: 1px 6px; font-size: var(--text-sm); }
.pill-lg { padding: 5px 12px; font-size: var(--text-base); }
.pill.tone-success { color: var(--tone-success-text); background: var(--tone-success-bg); border-color: var(--tone-success-border); }
.pill.tone-danger { color: var(--tone-danger-text); background: var(--tone-danger-bg); border-color: var(--tone-danger-border); }
.pill.tone-warning { color: var(--tone-warning-text); background: var(--tone-warning-bg); border-color: var(--tone-warning-border); }
.pill.tone-neutral { color: var(--tone-neutral-text); background: var(--tone-neutral-bg); border-color: var(--tone-neutral-border); }
.pill.tone-muted { color: var(--tone-muted-text); background: var(--tone-muted-bg); border-color: var(--tone-muted-border); border-style: dashed; font-weight: 500; }
.flag {
  display: inline-flex; align-items: center; gap: 3px; padding: 1px 6px; border-radius: var(--radius-sm);
  font-size: var(--text-xs); font-weight: 700; letter-spacing: 0.04em; margin-right: 6px; vertical-align: middle;
}
.flag-alert { background: var(--tone-danger-bg); color: var(--tone-danger-text); }
.flag-new { background: var(--tone-accent-bg); color: var(--tone-accent-text); }
.flag-warn { background: var(--tone-warning-bg); color: var(--tone-warning-text); }
.keyword-chips { display: inline-flex; flex-wrap: wrap; gap: 4px; vertical-align: middle; }
.keyword-chip {
  display: inline-block; padding: 1px 7px; border-radius: 999px;
  background: var(--tone-danger-bg); color: var(--tone-danger-text); font-size: var(--text-sm); font-weight: 600;
}
.ext-badge {
  display: inline-block; padding: 0 6px; border-radius: var(--radius-sm);
  font-size: var(--text-xs); font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase;
  background: var(--tone-neutral-bg); color: var(--tone-neutral-text);
}
.ext-badge.kind-pdf { background: #fee2e2; color: #991b1b; }
.ext-badge.kind-word { background: #dbeafe; color: #1e40af; }
.ext-badge.kind-excel { background: #dcfce7; color: #166534; }
.ext-badge.kind-image { background: #ede9fe; color: #5b21b6; }
.ext-badge.kind-archive { background: #fef3c7; color: #92400e; }
.source-chip {
  display: inline-flex; align-items: center; gap: 4px; padding: 1px 7px; border-radius: var(--radius-sm);
  font-size: var(--text-sm); font-weight: 500; max-width: 100%; overflow-wrap: anywhere;
}
.source-chip.module-usb { background: var(--module-usb-bg); color: var(--module-usb); }
.source-chip.module-outlook { background: var(--module-outlook-bg); color: var(--module-outlook); }
.source-chip.module-webmail { background: var(--module-webmail-bg); color: var(--module-webmail); }

/* module identity */
.module-label { display: inline-flex; align-items: center; gap: 5px; font-weight: 600; }
.module-label.module-usb, .module-usb .module-glyph { color: var(--module-usb); }
.module-label.module-outlook, .module-outlook .module-glyph { color: var(--module-outlook); }
.module-label.module-browser, .module-browser .module-glyph { color: var(--module-browser); }
.module-label.module-webmail, .module-webmail .module-glyph { color: var(--module-webmail); }
.module-label.module-attachments, .module-attachments .module-glyph { color: var(--module-attachments); }
.module-glyph {
  display: inline-flex; align-items: center; justify-content: center; flex: none;
  width: 36px; height: 36px; border-radius: var(--radius-lg);
}
.module-glyph.module-usb { background: var(--module-usb-bg); color: var(--module-usb); }
.module-glyph.module-outlook { background: var(--module-outlook-bg); color: var(--module-outlook); }
.module-glyph.module-browser { background: var(--module-browser-bg); color: var(--module-browser); }
.module-glyph.module-webmail { background: var(--module-webmail-bg); color: var(--module-webmail); }
.module-glyph.module-attachments { background: var(--module-attachments-bg); color: var(--module-attachments); }

/* ---------- rail ---------- */
#rail {
  width: var(--rail-width); min-width: 280px; flex: none;
  background: var(--rail-bg); color: var(--rail-text);
  display: flex; flex-direction: column; border-right: 1px solid var(--rail-border);
}
.rail-header { padding: var(--space-lg) var(--space-md) var(--space-sm); display: flex; flex-direction: column; gap: 10px; }
.brand { display: flex; align-items: center; gap: 10px; padding: 0 var(--space-xs) var(--space-xs); }
.brand-mark {
  display: inline-flex; align-items: center; justify-content: center; width: 36px; height: 36px;
  border-radius: var(--radius-lg); background: var(--color-primary); color: var(--color-on-primary);
}
.brand h1 { font-size: var(--text-lg); font-weight: 700; letter-spacing: 0.02em; line-height: 1.2; }
.brand-sub { font-size: var(--text-sm); color: var(--rail-text-muted); }
.rail-nav {
  display: flex; align-items: center; gap: 8px; width: 100%; min-height: 36px; padding: 6px 10px;
  border: 1px solid transparent; border-radius: var(--radius-md); background: transparent; color: var(--rail-text);
  cursor: pointer; font-weight: 600; text-align: left;
  transition: background-color var(--duration-fast) var(--ease-standard);
}
.rail-nav:hover { background: var(--rail-hover); }
.rail-nav[aria-current="page"] { background: var(--rail-selected); }
.rail-count { margin-left: auto; font-size: var(--text-sm); font-weight: 500; color: var(--rail-text-muted); }
.rail-nav[aria-current="page"] .rail-count { color: var(--rail-text-on-selected); }
.search-wrap { position: relative; }
.search-icon { position: absolute; left: 10px; top: 50%; transform: translateY(-50%); color: var(--rail-text-muted); pointer-events: none; }
.search-wrap input {
  width: 100%; min-height: var(--control-height); padding: 6px 10px 6px 32px;
  border-radius: var(--radius-md); border: 1px solid var(--rail-surface);
  background: var(--rail-surface); color: var(--rail-text);
}
.search-wrap input::placeholder { color: var(--rail-text-muted); }
.segmented { display: flex; gap: 2px; padding: 2px; border-radius: var(--radius-md); background: var(--rail-surface); }
.segmented button {
  flex: 1; min-height: 26px; padding: 2px 6px; border: 0; border-radius: var(--radius-sm);
  background: transparent; color: var(--rail-text-muted); font-size: var(--text-md); font-weight: 600; cursor: pointer;
  transition: background-color var(--duration-fast) var(--ease-standard), color var(--duration-fast) var(--ease-standard);
}
.segmented button:hover { color: var(--rail-text); }
.segmented button[aria-pressed="true"] { background: var(--rail-bg); color: var(--rail-text); }
.computer-list { flex: 1; overflow-y: auto; padding: var(--space-xs) var(--space-sm) var(--space-sm); }
.list-notice { display: flex; gap: 8px; align-items: flex-start; padding: var(--space-md); color: var(--rail-text-muted); line-height: 1.45; overflow-wrap: anywhere; }
.list-notice.error { color: var(--rail-danger); }
.computer-item {
  display: flex; gap: 10px; align-items: flex-start; width: 100%; text-align: left;
  padding: 10px; margin-bottom: 4px; border-radius: var(--radius-lg);
  background: transparent; border: 1px solid transparent; color: inherit; cursor: pointer;
  transition: background-color var(--duration-fast) var(--ease-standard);
}
.computer-item:hover { background: var(--rail-hover); }
.computer-item[aria-current="true"] { background: var(--rail-selected); }
.ci-icon { display: inline-flex; color: var(--rail-text-muted); margin-top: 1px; position: relative; }
.computer-item.status-alert .ci-icon { color: var(--rail-danger); }
.computer-item.status-silent .ci-icon { color: var(--rail-warning); }
.ci-silent { color: var(--rail-warning); font-weight: 600; }
.computer-item.status-clean .ci-icon { color: var(--module-browser-light); }
.ci-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.ci-row { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.ci-name { font-weight: 600; font-size: var(--text-base); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ci-meta { font-size: var(--text-sm); color: var(--rail-text-muted); display: flex; align-items: center; }
.computer-item[aria-current="true"] .ci-meta, .computer-item[aria-current="true"] .sep { color: var(--rail-text-on-selected); }
.module-dots { display: flex; gap: 6px; margin-top: 2px; }
.module-dot {
  display: inline-flex; align-items: center; gap: 3px; padding: 2px 5px; border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.06); font-size: var(--text-xs); font-weight: 600;
}
.module-dot.is-off { color: var(--rail-off); background: transparent; }
.module-dot.is-off .icon { opacity: 0.7; }
.module-dot.module-usb.is-on { color: var(--module-usb-light); }
.module-dot.module-outlook.is-on { color: var(--module-outlook-light); }
.module-dot.module-browser.is-on { color: var(--module-browser-light); }
.module-dot.module-webmail.is-on { color: var(--module-webmail-light); }
.module-dot.module-attachments.is-on { color: var(--module-attachments-light); }
.module-dot.is-alert { color: var(--rail-danger); background: rgba(220, 38, 38, 0.2); }
.module-dot.is-silent { color: var(--rail-warning); background: rgba(251, 191, 36, 0.18); }
.rail-footer { padding: var(--space-sm) var(--space-md) var(--space-md); border-top: 1px solid var(--rail-surface); display: flex; flex-direction: column; gap: 8px; }
.path-bar { display: flex; align-items: center; gap: 6px; font-size: var(--text-sm); color: var(--rail-text-muted); min-width: 0; }
.path-text { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; direction: rtl; text-align: left; }
.watch-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--rail-off); flex: none; }
.watch-dot.on { background: var(--tone-success-solid); box-shadow: 0 0 0 3px rgba(22, 163, 74, 0.25); }
.rail-actions { display: flex; gap: 6px; }
.rail-btn {
  flex: 1; display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  min-height: var(--control-height); padding: 6px 10px; border: 0; border-radius: var(--radius-md);
  background: var(--rail-surface); color: var(--rail-text); cursor: pointer; font-size: var(--text-md); font-weight: 600;
  transition: background-color var(--duration-fast) var(--ease-standard);
}
.rail-btn:hover { background: #334155; }

/* ---------- main pane ---------- */
#main { flex: 1; min-width: 0; overflow-y: auto; scroll-behavior: smooth; }
#main:focus { outline: none; }
.overview, .detail-content { padding: var(--space-2xl) var(--space-3xl) 56px; max-width: 1480px; }
.page-header { display: flex; justify-content: space-between; align-items: flex-start; gap: var(--space-lg); margin-bottom: var(--space-xl); }
.page-header h2, .detail-title h2 { font-size: var(--text-3xl); font-weight: 700; letter-spacing: -0.01em; line-height: 1.2; overflow-wrap: anywhere; }
.page-subtitle { color: var(--color-text-muted); margin-top: 4px; overflow-wrap: anywhere; }
.page-actions { display: flex; gap: 8px; flex: none; }
.loading-note { color: var(--color-text-muted); padding: var(--space-xl) 0; }

/* stat tiles */
.stat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: var(--space-md); margin-bottom: var(--space-2xl); }
.stat-grid.compact { grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: var(--space-sm); margin-bottom: var(--space-lg); }
.stat-tile {
  display: flex; flex-direction: column; gap: 2px; padding: 12px 14px;
  background: var(--color-surface); border: 1px solid var(--color-border); border-radius: var(--radius-lg); min-width: 0;
}
.stat-grid.compact .stat-tile { background: var(--color-surface-muted); padding: 10px 12px; }
.stat-value { font-size: var(--text-2xl); font-weight: 700; font-variant-numeric: tabular-nums; line-height: 1.2; overflow-wrap: anywhere; }
.stat-grid.compact .stat-value { font-size: var(--text-xl); }
.stat-label { font-size: var(--text-md); color: var(--color-text-muted); font-weight: 500; }
.stat-hint { font-size: var(--text-sm); color: var(--color-text-subtle); }
.stat-tile.tone-danger .stat-value { color: var(--tone-danger-text); }
.stat-tile.tone-success .stat-value { color: var(--tone-success-text); }
.stat-tile.tone-warning .stat-value { color: var(--tone-warning-text); }
.stat-tile.tone-accent .stat-value { color: var(--tone-accent-text); }

/* fleet grid */
.fleet-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: var(--space-lg); }
.fleet-card {
  /* align-items: stretch overrides the button default (flex-start) so the module grid and the footer span the card */
  display: flex; flex-direction: column; align-items: stretch; gap: 12px; padding: 16px; text-align: left;
  background: var(--color-surface); border: 1px solid var(--color-border); border-left: 4px solid var(--color-border-strong);
  border-radius: var(--radius-lg); color: inherit; cursor: pointer; box-shadow: var(--shadow-sm);
  transition: box-shadow var(--duration-fast) var(--ease-standard), transform var(--duration-fast) var(--ease-standard), border-color var(--duration-fast) var(--ease-standard);
}
.fleet-card:hover { box-shadow: var(--shadow-md); border-color: var(--color-border-strong); transform: translateY(-1px); }
.fleet-card.status-alert { border-left-color: var(--tone-danger-solid); }
.fleet-card.status-clean { border-left-color: var(--tone-success-solid); }
.fleet-card.status-warning, .fleet-card.status-encrypted, .fleet-card.status-silent { border-left-color: var(--tone-warning-solid); }
.fc-silent { color: var(--tone-warning-text); font-weight: 600; }
.fc-head { display: flex; align-items: flex-start; gap: 10px; }
.fc-icon { display: inline-flex; color: var(--color-text-muted); margin-top: 2px; }
.fc-title { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.fc-name { font-size: var(--text-xl); font-weight: 700; overflow-wrap: anywhere; }
.fc-meta { font-size: var(--text-md); color: var(--color-text-subtle); display: flex; flex-wrap: wrap; align-items: center; }
.fc-modules { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px; }
.fc-module {
  display: flex; flex-direction: column; gap: 2px; padding: 8px 10px; border-radius: var(--radius-md);
  background: var(--color-surface-muted); border: 1px solid var(--color-border); font-size: var(--text-sm); min-width: 0;
}
.fc-module.is-off { color: var(--color-text-subtle); border-style: dashed; background: transparent; }
.fc-module.is-on.module-usb { background: var(--module-usb-bg); color: var(--module-usb); border-color: transparent; }
.fc-module.is-on.module-outlook { background: var(--module-outlook-bg); color: var(--module-outlook); border-color: transparent; }
.fc-module.is-on.module-browser { background: var(--module-browser-bg); color: var(--module-browser); border-color: transparent; }
.fc-module.is-on.module-webmail { background: var(--module-webmail-bg); color: var(--module-webmail); border-color: transparent; }
.fc-module.is-alert { background: var(--tone-danger-bg); color: var(--tone-danger-text); border-color: var(--tone-danger-border); }
.fc-module.is-silent { background: var(--tone-warning-bg); color: var(--tone-warning-text); border-color: var(--tone-warning-border); }
.fc-module-name { font-weight: 700; display: flex; align-items: center; gap: 4px; }
.fc-module-figure { font-weight: 500; overflow-wrap: anywhere; }
.fc-foot { display: flex; justify-content: space-between; align-items: center; font-size: var(--text-md); color: var(--color-text-muted); }
.fc-att { display: inline-flex; align-items: center; gap: 5px; }
.fc-open { display: inline-flex; align-items: center; gap: 4px; color: var(--color-primary); font-weight: 600; }
.fc-hint { color: var(--color-text-muted); font-size: var(--text-md); }

/* empty states */
.empty-state {
  display: flex; flex-direction: column; align-items: center; text-align: center; gap: 6px;
  padding: var(--space-3xl) var(--space-xl); color: var(--color-text-muted);
  background: var(--color-surface); border: 1px dashed var(--color-border-strong); border-radius: var(--radius-lg);
}
.section-body .empty-state { padding: var(--space-xl); background: var(--color-surface-muted); border-color: var(--color-border); }
.empty-icon { display: inline-flex; color: var(--color-text-subtle); margin-bottom: 4px; }
.empty-state.tone-danger .empty-icon { color: var(--tone-danger-solid); }
.empty-title { font-weight: 600; color: var(--color-text); font-size: var(--text-lg); }
.empty-text { max-width: 560px; overflow-wrap: anywhere; }
.empty-state .btn { margin-top: var(--space-sm); }

/* ---------- detail ---------- */
.detail-header {
  position: sticky; top: 0; z-index: 5;
  padding: var(--space-md) var(--space-3xl) var(--space-lg);
  background: var(--color-surface); border-bottom: 1px solid var(--color-border);
}
.detail-top { display: flex; align-items: center; justify-content: space-between; gap: var(--space-md); margin-bottom: 6px; }
.detail-status { font-size: var(--text-md); color: var(--color-text-muted); overflow-wrap: anywhere; text-align: right; }
.detail-title-row { display: flex; align-items: flex-start; gap: var(--space-md); }
.detail-icon {
  display: inline-flex; align-items: center; justify-content: center; flex: none;
  width: 44px; height: 44px; border-radius: var(--radius-lg); background: var(--color-surface-subtle); color: var(--color-text-muted);
}
.detail-title { flex: 1; min-width: 0; }
.detail-meta { display: flex; flex-wrap: wrap; align-items: center; margin-top: 4px; font-size: var(--text-md); color: var(--color-text-muted); }
.detail-silent { color: var(--tone-warning-text); font-weight: 600; }
.uid-chip { display: inline-flex; align-items: center; gap: 2px; padding: 1px 2px 1px 8px; border-radius: var(--radius-md); background: var(--color-surface-subtle); max-width: 100%; }
.uid-chip .mono { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 320px; }
.detail-actions { display: flex; align-items: center; gap: var(--space-md); flex: none; }

/* archived periods (DecryptTool --archive): picker in the header, note above the content */
.period-picker { display: inline-flex; align-items: center; gap: 6px; color: var(--color-text-muted); }
.period-select {
  min-height: var(--control-height); padding: 4px 8px; max-width: 260px;
  border-radius: var(--radius-md); border: 1px solid var(--color-border-strong);
  background: var(--color-surface); color: var(--color-text); font: inherit; font-size: var(--text-base); cursor: pointer;
}
.period-select:hover { background: var(--color-surface-subtle); }
.period-select:focus-visible { outline: 2px solid var(--color-ring); outline-offset: 1px; }
.period-banner {
  display: flex; align-items: center; gap: 10px; padding: 8px 14px; margin-bottom: var(--space-lg);
  border: 1px solid var(--tone-neutral-border); border-radius: var(--radius-md);
  background: var(--tone-muted-bg); color: var(--tone-neutral-text); font-size: var(--text-md);
}
/* records the decrypt runs could not decrypt (detail.js renderUndecryptableNote) */
.decrypt-note {
  display: flex; align-items: flex-start; gap: 10px; padding: 8px 14px; margin-bottom: var(--space-lg);
  border: 1px solid var(--tone-warning-border); border-radius: var(--radius-md);
  background: var(--tone-warning-bg); color: var(--tone-warning-text); font-size: var(--text-md);
  overflow-wrap: anywhere;
}
.decrypt-note svg { flex: none; margin-top: 2px; }

/* module strip */
.module-strip { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: var(--space-md); margin-bottom: var(--space-xl); }
.module-tile {
  display: flex; flex-direction: column; gap: 6px; padding: 14px; text-align: left; color: inherit;
  background: var(--color-surface); border: 1px solid var(--color-border); border-top: 3px solid var(--color-border-strong);
  border-radius: var(--radius-lg); cursor: pointer; box-shadow: var(--shadow-sm);
  transition: box-shadow var(--duration-fast) var(--ease-standard), transform var(--duration-fast) var(--ease-standard);
}
.module-tile:hover { box-shadow: var(--shadow-md); transform: translateY(-1px); }
.module-tile.module-usb { border-top-color: var(--module-usb); }
.module-tile.module-outlook { border-top-color: var(--module-outlook); }
.module-tile.module-browser { border-top-color: var(--module-browser); }
.module-tile.module-webmail { border-top-color: var(--module-webmail); }
.module-tile.module-attachments { border-top-color: var(--module-attachments); }
.module-tile.status-absent { border-top-style: dashed; background: var(--color-surface-muted); }
.mt-head { display: flex; align-items: center; gap: 8px; }
.mt-status { display: flex; }
.mt-head .module-glyph { width: 30px; height: 30px; border-radius: var(--radius-md); }
.mt-name { font-weight: 700; font-size: var(--text-lg); flex: 1; min-width: 0; }
.mt-desc { font-size: var(--text-md); color: var(--color-text-muted); line-height: 1.4; }
.mt-facts { display: flex; flex-wrap: wrap; gap: 4px 10px; font-size: var(--text-md); font-weight: 600; margin-top: auto; }
.mt-facts .muted { font-weight: 500; }
.mt-last { font-size: var(--text-sm); color: var(--color-text-subtle); overflow-wrap: anywhere; }

/* alert summary */
.alert-summary {
  background: var(--tone-danger-bg); border: 1px solid var(--tone-danger-border); border-left: 4px solid var(--tone-danger-solid);
  border-radius: var(--radius-lg); padding: var(--space-md) var(--space-lg); margin-bottom: var(--space-xl); color: var(--tone-danger-text);
}
.as-head { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 10px; margin-bottom: 8px; }
.as-head h3 { font-size: var(--text-lg); font-weight: 700; }
.as-list { display: flex; flex-direction: column; gap: 4px; }
.as-list li { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; font-size: var(--text-md); }
.as-list .link-btn { color: inherit; }
.as-list .module-label { min-width: 70px; }
.as-path { overflow-wrap: anywhere; color: var(--color-text); }
.alert-summary .muted { color: var(--tone-danger-text); opacity: 0.8; }

/* sections */
.module-section {
  background: var(--color-surface); border: 1px solid var(--color-border); border-radius: var(--radius-lg);
  margin-bottom: var(--space-xl); scroll-margin-top: 120px; box-shadow: var(--shadow-sm);
}
.section-header { display: flex; align-items: center; gap: var(--space-md); padding: var(--space-md) var(--space-lg); border-bottom: 1px solid var(--color-border); }
.section-heading { flex: 1; min-width: 0; }
.section-header h3 { font-size: var(--text-xl); font-weight: 700; }
.section-header h3:focus { outline: none; }
.section-description { font-size: var(--text-md); color: var(--color-text-muted); }
.section-side { display: flex; align-items: center; gap: 8px; flex: none; }
.section-body { padding: var(--space-lg); }
.section-note { font-size: var(--text-md); margin-top: var(--space-md); }
.kv { display: flex; gap: 10px; font-size: var(--text-md); margin-bottom: var(--space-md); }
.kv-label { color: var(--color-text-muted); font-weight: 600; flex: none; }
.inline-error, .inline-warning { display: flex; align-items: center; gap: 4px; font-size: var(--text-md); margin: var(--space-sm) 0; }
.inline-error { color: var(--tone-danger-text); }
.inline-warning { color: var(--tone-warning-text); background: var(--tone-warning-bg); border: 1px solid var(--tone-warning-border); border-radius: var(--radius-md); padding: 6px 10px; margin-bottom: var(--space-md); }
.alert-list { margin-top: var(--space-md); }
.alert-list h4 { font-size: var(--text-md); text-transform: uppercase; letter-spacing: 0.05em; color: var(--tone-danger-text); margin-bottom: 6px; }
.alert-list li { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; padding: 6px 10px; border-radius: var(--radius-md); background: var(--tone-danger-bg); margin-bottom: 4px; font-size: var(--text-md); }
.disclosure { margin-top: var(--space-md); }
.disclosure summary { cursor: pointer; color: var(--color-primary); font-weight: 600; font-size: var(--text-md); }

/* tables */
.table-wrap { overflow-x: auto; }
.data-table, .file-table, .lines-table { width: 100%; border-collapse: collapse; font-size: var(--text-md); }
.data-table th, .file-table th { text-align: left; font-weight: 600; color: var(--color-text-muted); padding: 6px 10px; border-bottom: 1px solid var(--color-border); font-size: var(--text-sm); text-transform: uppercase; letter-spacing: 0.04em; white-space: nowrap; }
.data-table td, .file-table td, .lines-table td, .lines-table th { padding: 7px 10px; border-bottom: 1px solid var(--color-border); vertical-align: top; overflow-wrap: anywhere; }
.data-table tbody tr:last-child td, .file-table tbody tr:last-child td { border-bottom: 0; }
.lines-table th { text-align: left; font-weight: 500; color: var(--color-text-subtle); white-space: nowrap; width: 160px; }
.row-alert td { background: var(--tone-danger-bg); }
.row-new td { background: #fffbeb; }
.row-alert.row-new td { background: var(--tone-danger-bg); }
.col-flags { width: 90px; white-space: nowrap; }
.col-hash { color: var(--color-text-subtle); white-space: nowrap; width: 260px; }
.col-index { width: 32px; }
.col-sent { white-space: nowrap; }
.col-subject { min-width: 200px; font-weight: 500; }
.col-subject .keyword-chips { margin-left: 6px; }

/* webmail */
.col-file { min-width: 180px; font-weight: 500; }
.col-file .keyword-chips { margin-left: 6px; }
.col-account { min-width: 140px; }
.col-to { min-width: 210px; }
.col-size { white-space: nowrap; }
.col-upload, .col-mail { white-space: nowrap; }
.wm-reason { display: block; margin-top: 2px; font-size: var(--text-sm); white-space: normal; overflow-wrap: anywhere; }
.wm-external { color: var(--tone-warning-text); }
.wm-coverage { margin-bottom: var(--space-md); }
.wm-info { display: flex; align-items: center; gap: 6px; }
.wm-coverage-table th[scope="row"] { font-weight: 600; text-align: left; white-space: nowrap; }
.wm-subtitle { font-size: var(--text-md); font-weight: 700; text-transform: uppercase; letter-spacing: 0.05em; color: var(--color-text-muted); margin: var(--space-lg) 0 6px; }

/* USB sessions */
.usb-session { border: 1px solid var(--color-border); border-radius: var(--radius-lg); margin-bottom: var(--space-md); overflow: hidden; }
.usb-session.has-alert { border-color: var(--tone-danger-border); }
.us-head { display: flex; align-items: center; gap: 10px; padding: 10px 12px; background: var(--color-surface-muted); border-bottom: 1px solid var(--color-border); }
.usb-session.has-alert .us-head { background: var(--tone-danger-bg); }
.us-icon { display: inline-flex; color: var(--module-usb); }
.us-title { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.us-title strong { font-size: var(--text-lg); overflow-wrap: anywhere; }
.us-meta { font-size: var(--text-sm); color: var(--color-text-muted); overflow-wrap: anywhere; }
.us-counts { font-size: var(--text-md); font-weight: 600; color: var(--color-text-muted); white-space: nowrap; }
.us-counts.tone-danger { color: var(--tone-danger-text); }
.us-empty { padding: 10px 12px; font-size: var(--text-md); }
.usb-session .inline-error { padding: 0 12px 8px; }

/* ---------- attachments ---------- */
.att-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: var(--space-md); }
.att-card {
  display: flex; flex-direction: column; background: var(--color-surface); border: 1px solid var(--color-border);
  border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow-sm);
  transition: box-shadow var(--duration-fast) var(--ease-standard), outline-color var(--duration-base) var(--ease-standard);
}
.att-card:hover { box-shadow: var(--shadow-md); }
.att-card.status-alert { border-color: var(--tone-danger-border); }
.att-card.is-highlighted { outline: 3px solid var(--color-ring); outline-offset: 2px; }
.att-preview {
  position: relative; display: block; width: 100%; padding: 0; border: 0; border-bottom: 1px solid var(--color-border);
  background: var(--color-surface-subtle); cursor: zoom-in; text-align: left;
}
.att-preview:focus-visible { outline-offset: -3px; }
.thumb { position: relative; aspect-ratio: 4 / 3; display: flex; align-items: center; justify-content: center; overflow: hidden; color: var(--color-text-subtle); }
.thumb-label { position: absolute; left: 0; right: 0; bottom: 8px; text-align: center; font-size: var(--text-sm); color: var(--color-text-muted); }
.thumb-tag {
  position: absolute; top: 8px; left: 8px; padding: 1px 6px; border-radius: var(--radius-sm);
  background: rgba(15, 23, 42, 0.72); color: #fff; font-size: var(--text-xs); font-weight: 700; letter-spacing: 0.04em;
}
.thumb-loading { flex-direction: column; gap: 6px; background: linear-gradient(90deg, var(--color-surface-subtle) 25%, var(--color-surface-muted) 50%, var(--color-surface-subtle) 75%); background-size: 200% 100%; animation: shimmer 1.4s linear infinite; }
@keyframes shimmer { from { background-position: 200% 0; } to { background-position: -200% 0; } }
.thumb-image img { width: 100%; height: 100%; object-fit: cover; display: block; }
.thumb-generic { flex-direction: column; gap: 6px; }
.sheet {
  width: 66%; height: 86%; margin-top: 10%; background: #fff; border-radius: 2px 2px 0 0;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.18), 0 8px 18px rgba(15, 23, 42, 0.12);
  padding: 9px 8px; overflow: hidden; position: relative; text-align: left;
}
.sheet::before { content: ''; position: absolute; left: 0; right: 0; top: 0; height: 3px; background: var(--color-border-strong); }
.sheet.kind-pdf::before { background: #dc2626; }
.sheet.kind-word::before { background: #2563eb; }
.sheet.kind-excel::before { background: #15803d; }
.sheet.kind-excel { background-image: linear-gradient(var(--color-border) 1px, transparent 1px), linear-gradient(90deg, var(--color-border) 1px, transparent 1px); background-size: 100% 9px, 26px 100%; background-position: 0 8px, 0 0; }
.sheet-text { font-size: 6px; line-height: 1.45; color: #1e293b; white-space: pre-wrap; overflow-wrap: anywhere; font-family: var(--font-sans); }
.sheet-text mark { background: var(--color-mark); }
.sheet-list ul { display: flex; flex-direction: column; gap: 2px; }
.sheet-list li { display: flex; align-items: center; gap: 3px; font-size: 6.5px; color: #1e293b; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sheet-list .muted { font-size: 6.5px; }
.status-badge {
  position: absolute; right: 8px; bottom: 8px; width: 24px; height: 24px; border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center; color: #fff;
  box-shadow: 0 0 0 2px var(--color-surface), var(--shadow-sm);
}
.status-badge.tone-success { background: var(--tone-success-solid); }
.status-badge.tone-danger { background: var(--tone-danger-solid); }
.status-badge.tone-warning { background: var(--tone-warning-solid); }
.status-badge.tone-neutral { background: var(--tone-neutral-solid); }
.status-badge.tone-muted { background: var(--tone-muted-solid); }
.att-body { display: flex; flex-direction: column; gap: 6px; padding: 10px 12px 12px; }
.att-name { font-weight: 600; overflow-wrap: anywhere; line-height: 1.3; }
.att-meta { display: flex; align-items: center; flex-wrap: wrap; font-size: var(--text-sm); color: var(--color-text-subtle); }
.att-meta .sep { margin: 0 4px; }
.att-sources { display: flex; flex-wrap: wrap; gap: 4px; font-size: var(--text-sm); }
.att-actions { display: flex; gap: 6px; margin-top: 4px; }

/* ---------- dialogs ---------- */
.overlay { position: fixed; inset: 0; background: var(--color-overlay); display: flex; align-items: center; justify-content: center; z-index: 100; padding: var(--space-xl); }
.dialog {
  display: flex; flex-direction: column; background: var(--color-surface); border-radius: var(--radius-xl);
  box-shadow: var(--shadow-lg); width: 560px; max-width: 100%; max-height: 100%; overflow: hidden;
}
.dialog.quicklook { width: 960px; height: min(760px, 100%); }
.dialog-head { display: flex; align-items: flex-start; justify-content: space-between; gap: var(--space-md); padding: var(--space-lg) var(--space-xl); border-bottom: 1px solid var(--color-border); }
.dialog-head h2 { font-size: var(--text-xl); font-weight: 700; }
.dialog-body { padding: var(--space-lg) var(--space-xl); overflow-y: auto; flex: 1; min-height: 0; }
.dialog-foot { display: flex; align-items: center; justify-content: space-between; gap: var(--space-md); padding: var(--space-md) var(--space-xl); border-top: 1px solid var(--color-border); background: var(--color-surface-muted); }
.dialog-foot .path { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: var(--text-sm); }
.dialog-actions { display: flex; gap: 8px; flex: none; }
.ql-title-wrap { min-width: 0; flex: 1; }
.ql-title { overflow-wrap: anywhere; }
.ql-meta { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; font-size: var(--text-md); color: var(--color-text-muted); margin-top: 4px; }
.ql-sources { font-size: var(--text-md); margin-top: 2px; }
.ql-text-wrap { height: 100%; }
.ql-text {
  margin: 0; padding: var(--space-lg); background: var(--color-surface-muted); border: 1px solid var(--color-border); border-radius: var(--radius-md);
  font-family: var(--font-sans); font-size: var(--text-base); line-height: 1.6; white-space: pre-wrap; overflow-wrap: anywhere;
}
.ql-image { display: flex; align-items: center; justify-content: center; height: 100%; }
.ql-image img { max-width: 100%; max-height: 100%; object-fit: contain; border-radius: var(--radius-md); }
.ql-archive li { display: flex; align-items: center; gap: 8px; padding: 6px 0; border-bottom: 1px solid var(--color-border); font-size: var(--text-md); }
.ql-archive li .mono { flex: 1; overflow-wrap: anywhere; }
.ql-none { display: flex; flex-direction: column; align-items: center; gap: 10px; padding: var(--space-3xl); color: var(--color-text-muted); text-align: center; }

/* settings form */
.form fieldset { border: 1px solid var(--color-border); border-radius: var(--radius-lg); padding: var(--space-md) var(--space-lg) var(--space-lg); margin: 0 0 var(--space-lg); }
.form legend { padding: 0 6px; font-weight: 700; font-size: var(--text-md); text-transform: uppercase; letter-spacing: 0.05em; color: var(--color-text-muted); }
.form label { display: block; font-size: var(--text-md); font-weight: 600; color: var(--color-text-muted); margin: var(--space-md) 0 4px; }
.form input {
  width: 100%; min-height: var(--control-height); padding: 6px 10px; border: 1px solid var(--color-border-strong);
  border-radius: var(--radius-md); color: var(--color-text); background: var(--color-surface);
}
.form input:focus { border-color: var(--color-ring); }
.form .help { font-size: var(--text-sm); color: var(--color-text-subtle); margin-top: 4px; line-height: 1.45; }
.form .help code { font-family: var(--font-mono); }
.form .input-row { display: flex; gap: var(--space-sm); }
.form .input-row input { flex: 1; min-width: 0; }
.form .field-row { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-md); }
.form .keyword-chips { margin-top: 8px; min-height: 22px; font-size: var(--text-sm); }

/* ---------- toasts ---------- */
.toasts { position: fixed; right: var(--space-xl); bottom: var(--space-xl); display: flex; flex-direction: column; gap: 8px; width: 380px; max-width: calc(100vw - 40px); z-index: 90; }
.toast {
  display: flex; gap: 10px; align-items: flex-start; padding: 12px 12px 12px 14px;
  background: var(--color-surface); border: 1px solid var(--color-border); border-left: 4px solid var(--tone-neutral-solid);
  border-radius: var(--radius-lg); box-shadow: var(--shadow-lg); animation: toast-in var(--duration-base) var(--ease-standard);
}
@keyframes toast-in { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.toast.tone-danger { border-left-color: var(--tone-danger-solid); }
.toast.tone-success { border-left-color: var(--tone-success-solid); }
.toast.tone-warning { border-left-color: var(--tone-warning-solid); }
.toast-icon { display: inline-flex; margin-top: 1px; color: var(--tone-neutral-solid); }
.toast.tone-danger .toast-icon { color: var(--tone-danger-solid); }
.toast.tone-success .toast-icon { color: var(--tone-success-solid); }
.toast.tone-warning .toast-icon { color: var(--tone-warning-solid); }
.toast-body { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 4px; font-size: var(--text-md); }
.toast-body strong { font-size: var(--text-base); }
.toast-body p { color: var(--color-text-muted); overflow-wrap: anywhere; }
.toast-actions { display: flex; gap: 6px; margin-top: 4px; }

/* ---------- narrow windows (900px minimum) ---------- */
@media (max-width: 1100px) {
  :root { --rail-width: 280px; }
  .overview, .detail-content { padding: var(--space-lg) var(--space-lg) 48px; }
  .detail-header { padding: var(--space-md) var(--space-lg); }
  .detail-title-row { flex-wrap: wrap; }
  .detail-actions { width: 100%; justify-content: space-between; }
  .fc-modules { grid-template-columns: 1fr; }
}

/* ---------- license (offline activation) ---------- */
.dialog.license { width: 680px; }
.dialog-head .help { font-size: var(--text-sm); color: var(--color-text-subtle); margin-top: 2px; }
.form textarea {
  width: 100%; min-height: 150px; padding: 8px 10px; border: 1px solid var(--color-border-strong); border-radius: var(--radius-md);
  color: var(--color-text); background: var(--color-surface); font-family: var(--font-mono); font-size: var(--text-md); line-height: 1.4; resize: vertical;
}
.form textarea:focus { border-color: var(--color-ring); }
.form .input-row .help { flex: 1; margin-top: 6px; }
.license-status { border: 1px solid var(--color-border); border-radius: var(--radius-lg); padding: var(--space-md) var(--space-lg); margin-bottom: var(--space-lg); background: var(--color-surface-muted); }
.license-status.state-valid { border-color: var(--tone-success-border); }
.license-status.state-grace { border-color: var(--tone-warning-border); }
.license-status.state-expired, .license-status.state-invalid, .license-status.state-wrong-machine, .license-status.state-not-yet-valid { border-color: var(--tone-danger-border); }
.ls-head { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 12px; margin-bottom: var(--space-sm); }
.ls-reason { color: var(--color-text-muted); font-size: var(--text-md); overflow-wrap: anywhere; }
.license-facts { display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: 4px 16px; font-size: var(--text-md); }
.lf-label { color: var(--color-text-muted); font-weight: 600; }
.lf-value { overflow-wrap: anywhere; }
.lf-value.lf-warn { color: var(--tone-danger-text); font-weight: 600; }
.request-block {
  margin: var(--space-sm) 0; padding: var(--space-sm) var(--space-md); background: var(--color-surface-muted); border: 1px solid var(--color-border);
  border-radius: var(--radius-md); font-size: var(--text-sm); line-height: 1.4; white-space: pre-wrap; overflow-wrap: anywhere; user-select: all;
}
.license-gate { display: flex; flex-direction: column; gap: var(--space-lg); max-width: 760px; margin: 0 auto; }
.license-gate .license-status { margin-bottom: 0; background: var(--color-surface); }
.license-banner { display: flex; align-items: center; gap: 10px; padding: 8px 14px; margin-bottom: var(--space-lg); border: 1px solid; border-radius: var(--radius-md); font-size: var(--text-md); font-weight: 500; }
.license-banner.tone-warning { background: var(--tone-warning-bg); border-color: var(--tone-warning-border); color: var(--tone-warning-text); }
.license-banner.tone-danger { background: var(--tone-danger-bg); border-color: var(--tone-danger-border); color: var(--tone-danger-text); }
.lb-text { flex: 1; min-width: 0; overflow-wrap: anywhere; }