/* Kleto Ops dashboard. MOBILE FIRST: base rules target a phone (single column,
   >=44px tap targets, comfortable spacing); min-width media queries progressively
   enhance to tablet and desktop. Committed to the platform brand tokens (same
   palette as the analytics digest). Barely-rounded 4px corners, never pills.
   Buildless, no dependencies. */
/* Kleto brand typeface: self-hosted Space Grotesk variable, so the preferred
   stylistic alternates (ss02, ss03, ss04) survive — Google Fonts strips them.
   Space Mono is the brand mono, reserved for code/mono contexts. */
@font-face {
  font-family: 'Space Grotesk';
  src: url('/fonts/SpaceGrotesk-Variable.woff2?v=8e085aa4') format('woff2');
  font-weight: 300 700;
  font-display: swap;
}
/* Space Mono: the brand mono (menu tree, code/mono contexts). Self-hosted. */
@font-face {
  font-family: 'Space Mono';
  src: url('/fonts/SpaceMono-400.woff2?v=a748973d') format('woff2');
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: 'Space Mono';
  src: url('/fonts/SpaceMono-700.woff2?v=97f6df05') format('woff2');
  font-weight: 700;
  font-display: swap;
}
:root {
  /* Gen 2 (docs/DESIGN-SYSTEM.md): defense-tech grammar on the OLED ground. */
  --bg: #000000;
  --card: #0A0B09;   /* olive-lean dark (instrument pass 3) */
  --panel: #111310;
  --border: #21231C;
  --text: #F5F5F7;
  /* Warm gray ramp (anchor grammar: warm, never blue-gray). */
  --dim: #9A968D;
  --faint: #6C6A63;
  /* Interaction accent: Epirus yellow (owner verdict 2026-08-02, superseding
     the monochrome pick). Hi-vis against the OLED ground; status amber
     --warn stays reserved for warnings and must remain distinct. */
  --accent: #FFD748;
  --accent-tint: rgba(255, 215, 72, 0.08);
  /* Dataviz series are NOT UI accent: charts keep a legible blue family. */
  --data-1: #3392F4; /* inside the dark lightness band (OKLCH L <= 0.67), validated */
  --data-2: #64D2FF;
  /* Result palette: every color in the UI maps to a metric outcome. */
  --up: #3FE84D;    /* healthy / on-target: phosphor green (instrument pass 3) */
  --warn: #FF9F0A;  /* watch / degraded */
  --down: #FF453A;  /* critical / not collecting */
  --radius: 4px;
  --tap: 44px;
  /* House motion pair (line draws / wipes vs micro-transitions). */
  --ease-out: cubic-bezier(0.215, 0.61, 0.355, 1);
  --ease-inout: cubic-bezier(0.645, 0.045, 0.355, 1);
  --ease-settle: cubic-bezier(0.16, 1, 0.3, 1); /* the gauge entrance signature */
  --display: 'Space Grotesk', -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
  --body: 'Space Grotesk', -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
  --mono: 'Space Mono', ui-monospace, SFMono-Regular, Menlo, monospace;
}

* { box-sizing: border-box; }
/* Mobile touch hygiene. Keep pinch zoom, drop the browser double-tap-to-zoom
   gesture and its 300ms click delay, and remove the grey/blue tap-highlight flash.
   A 16px input floor on mobile stops iOS Safari zooming the page on field focus. */
html { -webkit-text-size-adjust: 100%; touch-action: manipulation; -webkit-tap-highlight-color: transparent; }
a, button, input, textarea, select, label, summary,
[role="button"], [tabindex] { -webkit-tap-highlight-color: transparent; }
@media (max-width: 800px) {
  input, textarea, select { font-size: max(16px, 1em); }
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--body);
  /* Preferred Kleto glyph alternates (the "certain versions of certain letters"). */
  font-feature-settings: "ss02", "ss03", "ss04";
  -webkit-font-smoothing: antialiased;
}
[hidden] { display: none !important; }

/* ── Login (base: full-width on a phone) ───────────────────────────────── */
.login { min-height: 100svh; display: grid; place-items: center; padding: 20px; }
.login__card {
  width: 100%; max-width: 400px;
  background: var(--card); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 24px;
}
.login__mark, .topbar__mark { font-family: var(--display); font-weight: 700; letter-spacing: -0.02em; margin: 0; }
.login__mark { font-size: 26px; }
.login__mark span, .topbar__mark span { color: var(--accent); }
.login__sub { color: var(--dim); font-size: 14px; margin: 6px 0 24px; }
.login__msg { min-height: 18px; font-size: 13px; margin: 14px 0 0; color: var(--warn); }
.login__msg[data-ok] { color: var(--up); }

.field { margin: 0 0 16px; }
.field label {
  display: block; font-family: var(--mono); font-size: 10px; font-weight: 400;
  text-transform: uppercase; letter-spacing: 0.08em; color: var(--faint); margin: 0 0 6px;
}
.field__hint { font-size: 12px; color: var(--dim); margin: 6px 0 0; }
input {
  width: 100%; min-height: var(--tap); padding: 11px 12px; font-size: 16px; /* 16px avoids iOS zoom */
  font-family: var(--body); color: var(--text); background: var(--panel);
  border: 1px solid var(--border); border-radius: var(--radius); outline: none;
}
input:focus { border-color: var(--accent); }

.btn {
  width: 100%; min-height: var(--tap); padding: 11px 14px; font-size: 13px; font-weight: 700; cursor: pointer;
  color: var(--text); background: transparent; border: 1px solid var(--dim);
  border-radius: var(--radius); font-family: var(--mono);
  text-transform: uppercase; letter-spacing: 0.08em;
}
.btn:hover { color: var(--accent); border-color: var(--accent); }
.btn:disabled { opacity: 0.5; cursor: default; }
.btn--ghost {
  width: auto; min-height: 36px; color: var(--dim); background: transparent; border-color: var(--border);
}
.btn--ghost:hover { color: var(--text); filter: none; }

/* ── Chrome: compact frosted glass header + hamburger folder menu ────────── */
/* .chrome wraps the header AND the drop-down menu so the pair stays pinned as
   one glass unit while content scrolls beneath. */
.chrome { position: sticky; top: 0; z-index: 20; }
.topbar {
  display: flex; align-items: center; gap: 12px;
  padding: 8px 14px; position: relative;
  background: rgba(8, 9, 11, 0.62);
  -webkit-backdrop-filter: blur(22px) saturate(180%);
  backdrop-filter: blur(22px) saturate(180%);
  border-bottom: 1px solid rgba(255, 255, 255, 0.07);
}
/* Fallback for engines without backdrop-filter: fall back to a solid dark bar. */
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .topbar, .menu { background: #0A0B0D; }
}
/* Brand: KLETO always caps, Pulse tight against it, TM superscript. */
.topbar__mark {
  display: inline-flex; align-items: baseline; font-size: 15px; font-weight: 700;
  letter-spacing: 0.01em; color: var(--text); text-decoration: none;
}
.topbar__mark span { color: var(--accent); }
.topbar__mark .tm, .login__mark .tm { font-size: 8px; color: var(--dim); margin-left: 1px; align-self: flex-start; line-height: 2; }
/* Brand emblem: the KLETOPulse mark, monochrome via currentColor at the warm-gray
   dim tone so it reads as a quiet lockup and never competes with the yellow Pulse.
   Sized to the wordmark cap height and pinned to the text baseline row. */
.topbar__logo {
  width: 17px; height: 17px; flex: 0 0 auto; align-self: center;
  margin-right: 8px; color: var(--dim);
}
/* The live dot: a gentle heartbeat, signalling active monitoring. Sits between the
   emblem and the wordmark so the emblem + name + pulse read as one lockup. */
.topbar__live {
  content: ''; width: 7px; height: 7px; border-radius: 50%; flex: 0 0 auto; align-self: center;
  margin-right: 8px; background: var(--up);
  box-shadow: 0 0 0 0 rgba(63, 232, 77, 0.5); animation: pulse-dot 2.6s ease-out infinite;
}
@keyframes pulse-dot {
  0% { box-shadow: 0 0 0 0 rgba(63, 232, 77, 0.45); }
  70% { box-shadow: 0 0 0 6px rgba(63, 232, 77, 0); }
  100% { box-shadow: 0 0 0 0 rgba(63, 232, 77, 0); }
}
@media (prefers-reduced-motion: reduce) { .topbar__live { animation: none; } }
.topbar__stamp { margin-left: auto; display: none; font-size: 11px; color: var(--dim); font-variant-numeric: tabular-nums; }

/* Hamburger: three thin technical lines, no box. */
.menubtn {
  display: inline-flex; flex-direction: column; justify-content: center; gap: 4px;
  width: 34px; height: 34px; padding: 8px; background: transparent; border: 0; cursor: pointer;
}
.menubtn span { display: block; width: 18px; height: 1.5px; background: var(--dim); transition: transform .18s var(--ease-inout), opacity .18s var(--ease-inout), background .18s var(--ease-inout); }
.menubtn:hover span { background: var(--text); }
.menubtn[aria-expanded="true"] span:nth-child(1) { transform: translateY(5.5px) rotate(45deg); background: var(--text); }
.menubtn[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.menubtn[aria-expanded="true"] span:nth-child(3) { transform: translateY(-5.5px) rotate(-45deg); background: var(--text); }

/* The menu: same glass, Space Mono, a directory tree. */
.menu {
  position: absolute; left: 0; right: 0; top: 100%;
  background: rgba(8, 9, 11, 0.72);
  -webkit-backdrop-filter: blur(22px) saturate(180%);
  backdrop-filter: blur(22px) saturate(180%);
  border-bottom: 1px solid rgba(255, 255, 255, 0.07);
  box-shadow: 0 22px 40px -18px rgba(0, 0, 0, 0.8);
  padding: 12px 18px 16px;
  font-family: var(--mono); font-size: 12.5px; line-height: 1.9;
  animation: menu-in .14s var(--ease-out);
}
@keyframes menu-in { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .menu { animation: none; } }
.menu__root { margin: 0 0 2px; color: var(--dim); font-size: 11px; letter-spacing: 0.02em; }
.menu__tree, .menu__sub { list-style: none; margin: 0; padding: 0; }
.menu__glyph { color: #494D55; white-space: pre; user-select: none; }
.menu__link {
  display: inline-block; color: var(--text); text-decoration: none; cursor: pointer;
  background: transparent; border: 0; padding: 2px 6px; margin: 0;
  font: inherit; border-radius: 3px;
}
.menu__link:hover { color: var(--accent); background: var(--accent-tint); }
.menu__link--on { color: var(--accent); }
.menu__link--on::after { content: ' *'; color: var(--dim); }
.menu__dir {
  display: inline-block; color: var(--warn); background: transparent; border: 0; cursor: pointer;
  font: inherit; padding: 2px 6px; border-radius: 3px;
}
.menu__dir::after { content: ' ▸'; color: var(--dim); font-size: 10px; }
.menu__dir--open::after { content: ' ▾'; }
.menu__dir:hover { background: rgba(255, 159, 10, 0.08); }
.menu__logout { color: var(--down); }
.menu__logout:hover { color: var(--down); background: rgba(255, 69, 58, 0.08); }
.menu__ext { color: var(--dim); text-decoration: none; padding: 2px 5px; border-radius: 3px; }
.menu__ext:hover { color: var(--accent); background: var(--accent-tint); }

/* External "open live site" link (cards + detail title): mono ↗, until DNS these
   point at the sslip hosts; new tab, never triggers the card drill-down. */
.card__ext {
  font-family: var(--mono); font-size: 12px; font-weight: 700; text-decoration: none;
  color: var(--dim); padding: 2px 6px; border: 1px solid var(--border); border-radius: 4px;
  vertical-align: middle; flex: 0 0 auto;
}
.card__ext:hover { color: var(--accent); border-color: var(--accent); }
.wrap { padding: 16px; }
.section-title {
  font-family: var(--display); font-size: 12px; font-weight: 600; text-transform: uppercase;
  letter-spacing: 0.06em; color: var(--dim); margin: 26px 0 10px;
}

/* ── KPI tiles (base: 2-up on a phone) ─────────────────────────────────── */
.kpis { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.tile {
  background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); padding: 14px;
}
.tile__label {
  font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.06em;
  color: var(--dim); margin: 0 0 8px;
}
.tile__value {
  /* 1.25 strut: Space Mono's ascent+descent exceed a line-height:1 box, and
     the skeleton's middle-aligned shimmer exceeded it DIFFERENTLY (0.56px).
     One explicit strut tall enough for both keeps hydration at zero shift. */
  font-family: var(--mono); font-size: 24px; line-height: 1.25; font-weight: 700;
  font-variant-numeric: tabular-nums; margin: 0;
}

/* Detail KPI tile states (approved stat-tile card): one delta line under the
   value; a dormant tile dims value and delta because a zero on a pre launch
   site is not a failure. The sparkline is shape only and stays --data-1. */
.tile__delta {
  font-family: var(--mono); font-size: 10.5px; color: var(--dim); margin: 4px 0 0;
  font-variant-numeric: tabular-nums slashed-zero;
}
.tile__delta .pos { color: var(--up); }
.tile__delta .neg { color: var(--down); }
.tile__spark { display: block; margin-top: 8px; }
.tile--dormant .tile__value, .tile--dormant .tile__delta { color: var(--faint); }

/* ── Per-site cards (base: single column) ──────────────────────────────── */
.grid { display: grid; grid-template-columns: 1fr; gap: 10px; }
.card {
  position: relative; overflow: hidden;
  background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); padding: 16px;
}
/* Metric-driven color lives in the DATA, not the chrome (owner verdict
   2026-08-02): the gauge arc, score badge and status chips carry the band;
   the old left edge + tint fought the hover treatment and is retired. */
.card__head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin: 0 0 4px; }
/* Site names always render lowercase (iTrain -> itrain, Uruguide -> uruguide).
   The name is a min-width:0 flex row: the text span truncates with an ellipsis
   and the ↗ external link stays pinned inside the card, however long the host. */
.card__name { font-family: var(--mono); font-size: 14.5px; font-weight: 700; margin: 0; text-transform: lowercase; }
.card__name, .detail__name { display: flex; align-items: center; gap: 6px; min-width: 0; }
.card__name-txt { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
#detail .detail__name { text-transform: lowercase; }

/* health badge: the numeric score, colored by band */
.health {
  display: inline-flex; align-items: baseline; gap: 5px; padding: 3px 8px;
  border: 1px solid var(--border); border-radius: var(--radius);
  font-family: var(--display); font-weight: 700; font-variant-numeric: tabular-nums; white-space: nowrap;
}
.health__score { font-size: 14px; }
.health--ok { color: var(--up); } .health--warn { color: var(--warn); } .health--down { color: var(--down); }
.health--none { color: var(--dim); }

.card__sub { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; margin: 0 0 14px; font-size: 12px; }
.chip { color: var(--dim); font-variant-numeric: tabular-nums; }
.chip .up { color: var(--up); } .chip .warn { color: var(--warn); } .chip .down { color: var(--down); }

.metrics { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px 8px; }
.metric__k {
  font-size: 10px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.05em;
  color: var(--dim); margin: 0 0 3px;
}
.metric__v {
  font-family: var(--display); font-size: 18px; font-weight: 700; font-variant-numeric: tabular-nums; margin: 0;
}
.metric__v small { font-size: 12px; color: var(--dim); font-weight: 600; }
.status--ok { color: var(--up); } .status--warn { color: var(--warn); } .status--down { color: var(--down); }

.foot { color: var(--dim); font-size: 12px; margin: 26px 0 8px; }
.empty { color: var(--dim); font-size: 14px; padding: 24px 0; }

/* ── Loading: an abstract accent comet-ring. Lean, theme-colored, elegant. ── */
.boot { min-height: 100svh; display: grid; place-items: center; }
.loading {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 16px; padding: 56px 0;
}
.loading__label {
  font-size: 11px; font-weight: 600; letter-spacing: 0.16em; text-transform: uppercase; color: var(--dim);
}
.spinner { position: relative; width: 42px; height: 42px; display: inline-block; }
/* faint full track for depth */
.spinner::before {
  content: ''; position: absolute; inset: 0; border-radius: 50%; border: 2px solid var(--border);
}
/* rotating accent arc with a gradient comet tail, masked to a thin annulus */
.spinner::after {
  content: ''; position: absolute; inset: 0; border-radius: 50%;
  background: conic-gradient(from 90deg,
    rgba(51, 153, 255, 0) 0deg,
    rgba(51, 153, 255, 0.12) 130deg,
    var(--accent) 320deg,
    var(--accent) 360deg);
  -webkit-mask: radial-gradient(farthest-side, transparent calc(100% - 2px), #000 calc(100% - 2px));
  mask: radial-gradient(farthest-side, transparent calc(100% - 2px), #000 calc(100% - 2px));
  /* transform-only rotation, promoted to its own compositor layer, so there is
     no per-frame repaint and the spin stays perfectly fluid. */
  will-change: transform;
  animation: kspin 0.9s linear infinite;
}
@keyframes kspin { from { transform: rotate(0deg); } to { transform: rotate(360deg); } }
/* Respect reduced motion: slow, gentle, never removed entirely. */
@media (prefers-reduced-motion: reduce) { .spinner::after { animation-duration: 2.6s; } }

/* ── Enhancements for larger viewports ─────────────────────────────────── */
@media (min-width: 480px) {
  .topbar__stamp { display: inline; }
}
@media (min-width: 700px) {
  .wrap { max-width: 1120px; margin: 0 auto; padding: 24px; }
  .topbar { padding: 8px 24px; } /* wider gutters only; the bar stays compact */
  .kpis { grid-template-columns: repeat(4, 1fr); gap: 12px; }
  .tile { padding: 16px; }
  .tile__value { font-size: 30px; }
  .grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .card { padding: 18px; }
  .metric__v { font-size: 19px; }
}
@media (min-width: 1000px) {
  .grid { grid-template-columns: repeat(3, 1fr); }
}
/* Large desktop + 4K: use the extra width instead of a narrow centered column,
   so wide monitors read as intentional rather than empty. */
@media (min-width: 1600px) {
  .wrap { max-width: 1480px; }
  .grid { grid-template-columns: repeat(4, 1fr); }
  .tile__value { font-size: 32px; }
}
@media (min-width: 2400px) {
  .wrap { max-width: 2040px; padding: 32px; }
  .grid { grid-template-columns: repeat(5, 1fr); gap: 16px; }
  .kpis--cmd { grid-template-columns: repeat(8, 1fr); }
}

/* ── Clickable summary cards ────────────────────────────────────────────── */
.card--link { cursor: pointer; transition: border-color .15s var(--ease-inout), background .15s var(--ease-inout), transform .15s var(--ease-inout); }
.card--link:hover, .card--link:focus-visible { outline: none; background: #0d0f12; transform: translateY(-1px); }

/* ── Detail (drill-down) view ───────────────────────────────────────────── */
.backlink { color: var(--dim); text-decoration: none; font-size: 14px; font-weight: 600; }
.backlink:hover { color: var(--text); }
.detail__head { margin: 4px 0 18px; }
.detail__name { font-family: var(--mono); font-size: 21px; font-weight: 700; letter-spacing: -0.01em; margin: 0; }
.detail__meta { color: var(--dim); font-size: 13px; margin: 4px 0 0; }

.panel {
  background: var(--card); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 16px; margin: 0 0 12px;
}
.panel__title {
  font-family: var(--mono); font-size: 11.5px; font-weight: 700; margin: 0 0 12px;
  text-transform: uppercase; letter-spacing: 0.08em;
  display: flex; align-items: baseline; justify-content: space-between; gap: 10px;
}
.panel__sub { font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: .06em; color: var(--dim); }
.grid--2 { display: grid; grid-template-columns: 1fr; gap: 12px; margin: 0 0 12px; }
@media (min-width: 760px) { .grid--2 { grid-template-columns: repeat(2, 1fr); } }

/* charts */
.chartbox { position: relative; }
.chart { width: 100%; height: auto; display: block; touch-action: none; }
/* Designed empty state for a zero-signal chart window (priority doc section 9):
   a quiet COLLECTING micro label over one plain phrase, sized by charts.js to
   the height the plot would occupy. Never a fabricated axis. */
.chart-empty {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 6px; text-align: center;
}
.chart-empty__k {
  font-family: var(--mono); font-size: 10px; font-weight: 700;
  letter-spacing: 0.08em; text-transform: uppercase; color: var(--faint);
}
.chart-empty__t { font-family: var(--mono); font-size: 12px; color: var(--dim); }
.chart-tip {
  position: absolute; top: 2px; pointer-events: none; background: var(--panel);
  border: 1px solid var(--border); border-radius: var(--radius); padding: 4px 8px; font-size: 12px;
  display: flex; flex-direction: column; white-space: nowrap; z-index: 2;
}
.chart-tip__v { font-family: var(--display); font-weight: 700; font-variant-numeric: tabular-nums; }
.chart-tip__u { color: var(--dim); font-weight: 400; font-size: 11px; }
.chart-tip__x { color: var(--dim); font-size: 11px; }

/* ranked lists */
.ranks { display: flex; flex-direction: column; gap: 8px; }
.rank { display: grid; grid-template-columns: 1fr 90px auto; align-items: center; gap: 10px; }
.rank__label { font-size: 13px; color: var(--text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rank__bar { height: 6px; background: var(--panel); border-radius: 2px; overflow: hidden; }
.rank__bar > span { display: block; height: 100%; background: var(--data-1); opacity: .7; }
.rank__v { font-size: 12px; font-weight: 600; color: var(--dim); font-variant-numeric: tabular-nums; text-align: right; }
/* Two line ranked rows at phone width (approved data-table card): label and
   value share the first line, the track takes the full second line, so long
   labels never collide with a 54px bar stub. */
@media (max-width: 699px) {
  .rank {
    grid-template-columns: minmax(0, 1fr) auto;
    grid-template-areas: 'label value' 'bar bar';
    gap: 5px 8px;
  }
  .rank__label { grid-area: label; }
  .rank__v { grid-area: value; color: var(--text); }
  .rank__bar { grid-area: bar; height: 3px; }
}

/* health breakdown bars */
.hbars { display: flex; flex-direction: column; gap: 10px; }
.hbar { display: grid; grid-template-columns: 140px 1fr 34px; align-items: center; gap: 10px; }
/* One line always: the label never wraps its weight to a second line (rows kept
   to one shared height so the bars align); a too-narrow column ellipsizes. */
.hbar__k { font-size: 12px; color: var(--text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hbar__k small { color: var(--dim); font-weight: 600; margin-left: 4px; }
.hbar__track { height: 7px; background: var(--panel); border-radius: 2px; overflow: hidden; }
.hbar__fill { display: block; height: 100%; background: var(--data-1); }
.hbar__fill.status--ok { background: var(--up); }
.hbar__fill.status--warn { background: var(--warn); }
.hbar__fill.status--down { background: var(--down); }
.hbar__fill.status--none { background: var(--border); }
.hbar__v { font-size: 12px; font-weight: 700; color: var(--text); text-align: right; font-variant-numeric: tabular-nums; }
/* axis subheading inside the Breakdown panel: Readiness then Traction. Tracked
   caps whisper the group; the small tail carries its grade or gate note. */
.hbar__group { font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: .06em; color: var(--dim); margin: 4px 0 -2px; }
.hbar__group:first-child { margin-top: 0; }
.hbar__group small { text-transform: none; letter-spacing: 0; font-weight: 700; color: var(--text); margin-left: 6px; }
/* Phone: the label column must still hold "Performance 50%" on ONE line (92px
   wrapped some weights and not others, so the bars misaligned vertically). */
@media (max-width: 460px) { .hbar { grid-template-columns: 120px 1fr 30px; } }

/* Key value rows (approved card components/data-table.html): string valued
   metrics leave the stat grid. One metric per full width line under hairline
   separators; the value truncates with an ellipsis, never wraps mid string. */
.kv { display: flex; flex-direction: column; }
.kv__row {
  display: flex; justify-content: space-between; align-items: baseline; gap: 12px;
  padding: 7px 0; border-top: 1px solid var(--panel);
}
.kv__row:first-child { border-top: 0; padding-top: 0; }
.kv__row:last-child { padding-bottom: 0; }
.kv__k {
  font-family: var(--mono); font-size: 10px; letter-spacing: 0.08em;
  text-transform: uppercase; color: var(--faint); flex: none;
}
.kv__v {
  font-family: var(--mono); font-size: 12px; text-align: right; min-width: 0;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  font-variant-numeric: tabular-nums slashed-zero;
}
.kv__mut { color: var(--faint); }

/* stat grid (reuses metric__k/__v). Mobile first: 2-up at phone width so
   labels hold one line and a four stat panel closes 2x2 with no orphan cell;
   an odd straggler spans its row. Three columns return at tablet width. */
.statgrid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px 8px; }
.statgrid > :nth-child(odd):last-child { grid-column: 1 / -1; }
@media (min-width: 700px) {
  .statgrid { grid-template-columns: repeat(3, 1fr); }
  .statgrid > :nth-child(odd):last-child { grid-column: auto; }
}
.muted { color: var(--dim); font-size: 13px; }

/* Lighthouse panel: a scores row over a core-web-vitals row, each group under a
   tracked-caps subheading; each vital carries a plain-language sublabel beneath
   its readout (.metric__sub). Reuses the .statgrid grammar, no new metric box. */
.lh { display: flex; flex-direction: column; gap: 12px; }
.lh-group__head {
  font-size: 10.5px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.06em;
  color: var(--dim); margin: 4px 0 -4px;
}
.lh-group__head:first-child { margin-top: 0; }
.metric__sub { font-size: 10px; font-weight: 500; color: var(--dim); margin: 3px 0 0; letter-spacing: 0.01em; }

/* ── Icons (owned inline SVG) ───────────────────────────────────────────── */
.ico { width: 15px; height: 15px; flex: 0 0 auto; display: inline-block; vertical-align: -2px; }
.tile__label { display: flex; align-items: center; gap: 6px; }
.tile__label .ico { opacity: .65; }
/* Revenue tile: the MRR/ARR toggle shares the VALUE row, so the label row keeps
   the standard single-line height and every tile in a row holds one value
   baseline. If a long figure leaves no room, the toggle wraps BELOW the value
   (the baseline never moves). Compact segs so the toggle fits the value strut. */
.tile__value--rev { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 2px 8px; }
.tile__value--rev .segtoggle { flex: 0 0 auto; }
.tile__value--rev .seg { padding: 2px 5px; font-size: 9.5px; letter-spacing: 0.04em; }
.panel__title { align-items: center; }
.panel__t { display: inline-flex; align-items: center; gap: 7px; min-width: 0; }
.panel__t .ico { color: var(--dim); }
.section-title { display: flex; align-items: center; gap: 7px; }
.section-title .ico { color: var(--dim); width: 14px; height: 14px; }

/* ── Vertical rhythm fix: consistent 12px between the KPI row and what
   follows (was flush against the health panel / uneven before the Sites list). */
.kpis { margin: 0 0 12px; }
.section-title { margin-top: 14px; }
.detail__head { margin: 4px 0 14px; }

/* health component with no data: penalized (0) and flagged as a warning */
.hbar--missing .hbar__track { background: rgba(255, 159, 10, 0.12); }

/* ── MICRO label layer (gen 2): the defining anchor element. Space Mono,
   tracked caps, warm faint gray; values answer in tabular slashed-zero
   figures. Labels whisper, numbers testify. ─────────────────────────────── */
.tile__label, .metric__k, .panel__sub, .section-title, .loading__label {
  font-family: var(--mono); text-transform: uppercase; font-variant-caps: normal;
  letter-spacing: 0.08em; color: var(--faint); font-weight: 400;
}
.tile__label { font-size: 10.5px; }
.metric__k { font-size: 10.5px; }
.metric__v { font-family: var(--mono); font-size: 17px; font-weight: 700; font-variant-numeric: tabular-nums slashed-zero; }
.metric__v small { font-size: 13px; }
.tile__value, .odometer, .rank__v, .hbar__v, .topbar__stamp {
  font-variant-numeric: tabular-nums slashed-zero;
}
.panel__sub { font-size: 10.5px; }
.section-title { font-size: 11px; }
.rank__label { font-size: 14px; }
.rank__v { font-size: 13px; }
.hbar__k { font-size: 13px; }
.hbar__k small { font-size: 12px; }
.hbar__v { font-size: 13px; }
.chip { font-size: 13px; }
.detail__meta { font-size: 13px; }

/* ── Hero: business health as the CORE metric, an odometer-style gauge ──── */
.hero {
  display: flex; align-items: center; gap: 20px;
  background: var(--card); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 20px; margin: 0 0 12px;
}
.hero__gauge { position: relative; width: 118px; height: 118px; flex: 0 0 auto; }
.hero__gauge svg { width: 100%; height: 100%; transform: rotate(-90deg); display: block; }
/* Pulse aura: the house motif. A band-colored halo breathes behind the arc,
   slow and quiet (a resting heartbeat, not an alert). One flourish per surface. */
.gauge__halo {
  position: absolute; inset: -12%; border-radius: 50%; pointer-events: none;
  background: radial-gradient(circle, var(--halo) 0%, transparent 62%);
  filter: blur(8px);
  animation: kpulse 2.6s ease-in-out infinite;
}
@keyframes kpulse {
  0%, 100% { transform: scale(0.94); opacity: 0.16; }
  50% { transform: scale(1.08); opacity: 0.38; }
}
@media (prefers-reduced-motion: reduce) { .gauge__halo { animation: none; opacity: 0.2; } }
/* While the menu sheet is open its glass backdrop sits over the hero: hold the
   breathing halos dark so the glow cannot bleed through as a smudge. */
body:has(.menu:not([hidden])) .gauge__halo,
body:has(.menu:not([hidden])) .srv-beacon::before { visibility: hidden; }
/* Desaturate the gauge (arc + score) while the menu is open: CSS grayscale overrides
   the arc's inline SVG drop-shadow glow AND turns the one saturated element on the page
   gray, so it blends into the frosted backdrop instead of bleeding a green haze. The
   gauge sits behind the sheet, so this is invisible to the reader. */
body:has(.menu:not([hidden])) .gauge__arc,
body:has(.menu:not([hidden])) .gauge__score { filter: grayscale(1); opacity: 0.45; }
/* arc + number sit above the halo */
.hero__gauge svg, .card__gauge svg { position: relative; z-index: 1; }
.hero__num, .card__gnum { z-index: 2; }
.gauge__track { fill: none; stroke: var(--panel); stroke-width: 9; }
.gauge__arc {
  fill: none; stroke-width: 9; stroke-linecap: butt; will-change: stroke-dashoffset;
  transition: stroke-dashoffset 1.2s var(--ease-settle);
}

/* rolling-digit odometer (the score reels; sized by its gauge context) */
.odometer {
  display: inline-flex; height: 1em; line-height: 1;
  font-family: var(--mono); font-weight: 700;
  letter-spacing: -0.01em; font-variant-numeric: tabular-nums;
}
/* Score-first gauge center: the NUMBER is the primary read, its reels lit by a
   gradient in the band color; /100 sits under it as the quiet denom. */
.gauge__score {
  display: flex; flex-direction: column; align-items: center; color: var(--text);
  /* Rolls in on hydration, timed to land with the odometer reels (first reel
     1150ms, +220ms per column ~= 1370ms) on the same settle curve. One-shot
     entrance motion deliberately ignores prefers-reduced-motion (owner
     direction 2026-08-02); only looping motion honors it. */
  animation: kscorein 1370ms var(--ease-settle) both;
}
/* The band gradient must clip per DIGIT (.odo-n): background-clip: text does
   not paint through the transformed reel, so a container-level clip renders the
   rolling digits invisible. The .odometer color covers the pre-roll "0". */
.gauge__score .odometer { color: var(--g); }
.gauge__score .odo-n {
  background: linear-gradient(165deg, #FFFFFF 5%, var(--g) 85%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
@keyframes kscorein {
  0% { opacity: 0; transform: translateY(0.22em) scale(0.8); filter: blur(5px); }
  55% { opacity: 1; filter: blur(0); }
  100% { opacity: 1; transform: none; filter: none; }
}
/* platform.css (shared base) flattens ALL animation/transition durations to
   0.001ms with !important under prefers-reduced-motion. Correct for the public
   sites; on the owner console the one-shot gauge entrance is the product
   signature and always plays (owner direction 2026-08-02). app.css loads after
   platform.css, so these same-importance re-asserts win by order. Looping
   motion (shimmer, halo, spinner) stays governed by the global rule. */
@media (prefers-reduced-motion: reduce) {
  .gauge__score { animation-duration: 1370ms !important; }
  .gauge__arc { transition-duration: 1.2s !important; }
}
.gauge__denom { color: var(--dim); font-weight: 600; margin-top: 3px; }
.hero__num .odometer { font-size: 38px; font-weight: 700; }
.hero__num .gauge__denom { font-size: 13px; }
.card__gnum .odometer { font-size: 21px; font-weight: 700; }
.card__gnum .gauge__denom { font-size: 9.5px; margin-top: 2px; }
.odo-col { display: inline-block; height: 1em; overflow: hidden; }
.odo-reel { display: flex; flex-direction: column; will-change: transform; }
.odo-n { height: 1em; display: flex; align-items: center; justify-content: center; }
.hero__num { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.hero__meta { min-width: 0; }
.hero__label { font-family: var(--mono); font-size: 12.5px; font-weight: 700; margin: 0 0 4px; text-transform: uppercase; letter-spacing: 0.09em; }
.hero__sub { color: var(--dim); font-size: 13px; margin: 0; }
.hero__trend { font-size: 14px; font-weight: 600; margin: 10px 0 0; font-variant-numeric: tabular-nums; }
@media (max-width: 420px) {
  .hero { gap: 14px; padding: 16px; }
  /* Four-decimal uptime (owner rule) in mono needs narrower value type at
     phone width; precision wins, the size flexes. */
  .tile__value { font-size: 19px; }
  .metric__v { font-size: 14px; }
  .hero__gauge { width: 100px; height: 100px; }
  .hero__num .odometer { font-size: 32px; }
}

/* ── Card odometer gauge: health is the PRIMARY card metric ─────────────── */
.card__top { display: flex; align-items: center; gap: 14px; margin: 0 0 14px; }
.card__gauge { position: relative; width: 78px; height: 78px; flex: 0 0 auto; }
.card__gauge svg { width: 100%; height: 100%; transform: rotate(-90deg); display: block; }
.card__gnum { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.card__id { min-width: 0; flex: 1; }
.card__id .card__name { font-size: 17px; }
.card__chips { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px; margin-top: 7px; }

/* ── Per-card async loading: every card loads in on its own spinner ──────── */
.card__gauge--skel { display: flex; align-items: center; justify-content: center; }
.card__gauge--skel .spinner { width: 44px; height: 44px; }
.hero__gauge.card__gauge--skel { display: flex; align-items: center; justify-content: center; }
/* Loading placeholder. The ONE rule for zero-shift skeletons (see the JS skel()
   helper): a value placeholder is an inline shimmer 0.8em tall placed INSIDE the
   real typed element (.metric__v, .tile__value, .card__name, .card__gnum). The real
   element's own font-size / line-height governs the row height, so the placeholder
   can never change it. To add one, wrap the value in skel('<width>'); nothing else. */
.skel {
  display: inline-block; height: 0.8em; vertical-align: middle; width: 4em; border-radius: 4px;
  background: linear-gradient(90deg, var(--panel) 25%, var(--border) 37%, var(--panel) 63%);
  background-size: 400% 100%; animation: kshimmer 1.4s ease infinite;
}
.skel--chip { width: 5.5em; height: 0.85em; } /* standalone chip, beside the gauge (does not affect card height) */
@keyframes kshimmer { 0% { background-position: 100% 0; } 100% { background-position: -100% 0; } }
@media (prefers-reduced-motion: reduce) { .skel { animation: none; opacity: 0.6; } }

/* ── Central command panel: the portfolio odometer + aggregate KPIs ──────── */
/* The command panel owns #totals entirely, so drop the base .kpis grid here and
   let the panel stack: a roomy full-width hero above the aggregate KPI grid. */
#totals { display: block; }
.hero--cmd { background: linear-gradient(180deg, var(--card), var(--panel)); margin-bottom: 12px; }
.hero--cmd .hero__meta { flex: 1; }
.kpis--cmd { margin: 0; }
/* No orphan holes in the aggregate KPI grid. Phone (2-up): an odd count would
   strand a lone half-width tile, so the straggler spans the row. Desktop
   (4-up): a 3-tile remainder row closes flush by spanning its last tile, and a
   nine-tile grid (the stats page) factors perfectly three-by-three instead. */
.kpis--cmd > .tile:nth-child(odd):last-child { grid-column: 1 / -1; }
@media (min-width: 700px) {
  .kpis--cmd > .tile:nth-child(odd):last-child { grid-column: auto; }
  .kpis--cmd > .tile:nth-child(4n+3):last-child { grid-column: span 2; }
  .kpis--cmd:has(> .tile:first-child:nth-last-child(9)) { grid-template-columns: repeat(3, 1fr); }
}
/* The stats page reuses the command panel look; its #totals is the same block. */
#stats-totals { display: block; margin: 0 0 12px; }

/* ── Statistics page ────────────────────────────────────────────────────── */
.stats__head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; margin: 8px 0 16px; }
.stats__head .detail__name { margin: 0; }
.stats__head .ranges { margin: 0; }
.chart-loading { display: flex; align-items: center; justify-content: center; min-height: 130px; }

/* ── Stock-style range selector ─────────────────────────────────────────── */
.ranges { display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 14px; }
.range {
  min-height: 34px; padding: 5px 14px; font-size: 12px; font-weight: 700; letter-spacing: 0.06em;
  font-family: var(--mono); color: var(--dim); background: var(--card);
  border: 1px solid var(--border); border-radius: var(--radius); cursor: pointer;
}
.range:hover { color: var(--text); }
.range--on { color: var(--accent); border-color: var(--accent); background: var(--accent-tint); }

/* Detail range selector (approved detail-mobile card): one row of six equal
   joined segments that cannot wrap at 320. The active segment reads as an
   accent underline inside the shared frame, never a pill. */
.ranges--seg {
  display: grid; grid-template-columns: repeat(6, 1fr); gap: 0;
  border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden;
  max-width: 440px;
}
.ranges--seg .range {
  min-height: 38px; padding: 8px 0; border: 0; border-left: 1px solid var(--border);
  border-radius: 0; background: transparent; letter-spacing: 0.04em;
}
.ranges--seg .range:first-child { border-left: 0; }
.ranges--seg .range--on {
  color: var(--accent); background: var(--card);
  box-shadow: inset 0 -2px 0 var(--accent);
}

/* MRR/ARR segmented toggle in a tile label. Matches the top nav segmented control:
   compact, barely rounded, no pills. Flipping it swaps the value text in place. */
.segtoggle {
  display: inline-flex; gap: 2px; padding: 2px; margin-left: auto; vertical-align: middle;
  background: var(--panel); border: 1px solid var(--border); border-radius: 4px;
}
.seg {
  font-family: var(--mono); font-size: 11px; font-weight: 400; letter-spacing: 0.06em;
  color: var(--faint); background: transparent; border: 0; border-radius: 3px;
  padding: 5px 11px; min-height: 0; cursor: pointer; text-transform: uppercase;
}
.seg:hover { color: var(--text); }
.seg--on { color: var(--text); background: var(--card); box-shadow: 0 1px 2px rgba(0, 0, 0, 0.35); }

/* ── Gen 2 Epirus pass: chart text is a mono readout; controls are bordered
   transparent mono caps (the Epirus button grammar). ─────────────────────── */
.chart text { font-family: var(--mono); }


/* ── Gauge bezel: tachometer graduation hierarchy (majors at tens, mids at
   fives, minors between), and a square-cut sweep that starts ON tick zero. */
.gauge__ticks line { stroke: var(--border); stroke-width: 0.75; }
.gauge__ticks line.mid { stroke: var(--faint); stroke-width: 1; }
.gauge__ticks line.major { stroke: var(--dim); stroke-width: 1.4; }

/* ── Section grammar (priority doc section 9 + the rhythm card): the detail
   page renders its panels inside four named groups. The 32px boundary is the
   spacing ladder step the old page lacked; 12px stays the interval within one
   group and nothing else changes size. Eyebrows carry the group number and
   name, so per panel numbering retires on this page (defect 1: 01/ to 22/ was
   noise). ─────────────────────────────────────────────────────────────────── */
.sect { margin: 32px 0 0; }
.sect:first-of-type { margin-top: 24px; } /* hero block to first section */
.sect > :last-child { margin-bottom: 0; }
.sect__eyebrow { display: flex; align-items: baseline; gap: 8px; margin: 0 0 12px; }
.sect__n { font-family: var(--mono); font-size: 10px; color: var(--faint); }
.sect__k {
  font-family: var(--mono); font-size: 11px; font-weight: 700;
  letter-spacing: 0.1em; text-transform: uppercase; color: var(--dim);
}
.sect__rule { flex: 1; height: 1px; background: var(--border); align-self: center; }
#detail .panel__t::before { content: none; }
#detail .ranges--seg { margin: 0; }

/* Dormant rollup (priority doc section 9): group members with no data in the
   window collapse to one honest COLLECTING line, expandable on tap (one
   disclosure level). Dashed hairline; dim, never alarmed. */
.dormant { border: 1px dashed var(--border); border-radius: var(--radius); margin: 0 0 12px; }
.dormant__line {
  display: flex; align-items: center; gap: 8px; width: 100%; min-height: var(--tap);
  padding: 12px 16px; background: transparent; border: 0; cursor: pointer;
  text-align: left; color: inherit;
}
.dormant__k {
  font-family: var(--mono); font-size: 10px; font-weight: 700;
  letter-spacing: 0.08em; text-transform: uppercase; color: var(--faint); flex: none;
}
.dormant__list {
  font-family: var(--mono); font-size: 12px; color: var(--dim);
  min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.dormant__chev { margin-left: auto; color: var(--faint); font-family: var(--mono); font-size: 12px; flex: none; }
.dormant__panels { padding: 0 12px 12px; }
.dormant__panels .panel { margin: 0 0 8px; }
.dormant__panels .panel:last-child { margin-bottom: 0; }

/* ── Numbered section eyebrows (instrument pass 4): 01 / SITES ──────────── */
.wrap { counter-reset: sec; }
.section-title::before, .panel__t::before {
  counter-increment: sec;
  content: counter(sec, decimal-leading-zero) " / ";
  color: var(--faint); letter-spacing: 0.06em; white-space: pre;
}

/* ── Boot sequence (instrument pass 6): panels and cards power on staggered;
   panels get a hairline top draw that fades once landed. ────────────────── */
@keyframes kboot { from { opacity: 0; } to { opacity: 1; } }
.panel, .card { animation: kboot 360ms var(--ease-out) both; }
.card:nth-child(2), .panel:nth-of-type(2) { animation-delay: 45ms; }
.card:nth-child(3), .panel:nth-of-type(3) { animation-delay: 90ms; }
.card:nth-child(4), .panel:nth-of-type(4) { animation-delay: 135ms; }
.card:nth-child(5), .panel:nth-of-type(5) { animation-delay: 180ms; }
.card:nth-child(6), .panel:nth-of-type(6) { animation-delay: 225ms; }
.card:nth-child(7), .panel:nth-of-type(7) { animation-delay: 270ms; }
.card:nth-child(n+8), .panel:nth-of-type(n+8) { animation-delay: 315ms; }
.panel { position: relative; }
.panel::after {
  content: ''; position: absolute; top: -1px; left: 0; right: 0; height: 1px;
  background: var(--faint); transform: scaleX(0); transform-origin: 0 0;
  animation: kdraw 560ms var(--ease-out) 120ms both; pointer-events: none;
}
@keyframes kdraw {
  0% { transform: scaleX(0); opacity: 1; }
  65% { transform: scaleX(1); opacity: 1; }
  100% { transform: scaleX(1); opacity: 0; }
}

/* ── Corner registration ticks on interactive cards (instrument pass 8) ─── */
.card--link::after {
  content: ''; position: absolute; inset: 0; pointer-events: none; opacity: 0;
  /* Registration ticks DRAW out of the corners (the house draw motion),
     rather than fading in place. */
  transition: opacity .12s var(--ease-inout), background-size .2s var(--ease-out);
  background-image:
    linear-gradient(var(--accent), var(--accent)), linear-gradient(var(--accent), var(--accent)),
    linear-gradient(var(--accent), var(--accent)), linear-gradient(var(--accent), var(--accent)),
    linear-gradient(var(--accent), var(--accent)), linear-gradient(var(--accent), var(--accent)),
    linear-gradient(var(--accent), var(--accent)), linear-gradient(var(--accent), var(--accent));
  background-position: 0 0, 0 0, 100% 0, 100% 0, 0 100%, 0 100%, 100% 100%, 100% 100%;
  background-size: 0 1px, 1px 0, 0 1px, 1px 0, 0 1px, 1px 0, 0 1px, 1px 0;
  background-repeat: no-repeat;
}
.card--link:hover::after, .card--link:focus-visible::after {
  opacity: 1;
  background-size: 10px 1px, 1px 10px, 10px 1px, 1px 10px, 10px 1px, 1px 10px, 10px 1px, 1px 10px;
}

/* ── Tooltips: how each number is collected (owner request 2026-08-02) ──── */
[data-tip] { cursor: help; text-decoration: underline dotted; text-decoration-color: var(--faint); text-underline-offset: 3px; }
.tip {
  position: fixed; z-index: 60; padding: 8px 10px; pointer-events: none;
  background: rgba(10, 11, 9, 0.94);
  -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
  border: 1px solid var(--border); border-radius: var(--radius);
  font-family: var(--mono); font-size: 10.5px; line-height: 1.6;
  letter-spacing: 0.02em; text-transform: none; color: var(--dim);
}

/* ── Mobile dock (owner direction 2026-08-02): a floating bottom nav replaces
   the hamburger at phone width; thumb reach beats a top corner. Same glass,
   hairline, 4px, mono caps grammar. Desktop keeps the folder-tree menu. ──── */
.dock { display: none; }
@media (max-width: 699px) {
  .menubtn { display: none; }
  .dock {
    position: fixed; left: 10px; right: 10px;
    bottom: 10px; bottom: calc(10px + env(safe-area-inset-bottom));
    z-index: 30; display: grid; grid-template-columns: repeat(4, 1fr); gap: 4px;
    padding: 5px;
    background: rgba(8, 9, 11, 0.72);
    -webkit-backdrop-filter: blur(22px) saturate(180%);
    backdrop-filter: blur(22px) saturate(180%);
    border: 1px solid var(--border); border-radius: var(--radius);
  }
  .dock__item {
    display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px;
    min-height: var(--tap); padding: 6px 4px; background: transparent; border: 0;
    border-radius: 3px; cursor: pointer; text-decoration: none;
    font-family: var(--mono); font-size: 9px; font-weight: 400;
    text-transform: uppercase; letter-spacing: 0.08em; color: var(--faint);
  }
  .dock__item .ico { width: 16px; height: 16px; }
  .dock__item--on { color: var(--accent); }
  .dock__item:active { background: var(--accent-tint); }
  /* Content never hides under the dock. */
  .wrap { padding-bottom: 96px; padding-bottom: calc(96px + env(safe-area-inset-bottom)); }
  /* The site menu opens as a bottom sheet above the dock. */
  .menu {
    position: fixed; top: auto; left: 10px; right: 10px;
    bottom: 74px; bottom: calc(74px + env(safe-area-inset-bottom));
    border: 1px solid var(--border); border-radius: var(--radius);
  }
}

/* ── Dock selection animation (owner direction 2026-08-02, Instagram-style):
   a glass glow plate SLIDES between tabs on the settle curve, and the tapped
   glyph pops with a quick spring. The pop is the dock's sanctioned flourish
   and the one owner-approved exception to "nothing springy". One-shot motion
   policy applies: durations re-assert over the global reduce-motion flatten. */
.dock { position: fixed; }
.dock__glow {
  position: absolute; top: 5px; bottom: 5px; left: 5px;
  width: calc((100% - 22px) / 4); /* inner width minus 3 grid gaps + padding, quarters */
  background: var(--accent-tint);
  border: 1px solid rgba(255, 215, 72, 0.25);
  border-radius: 3px; pointer-events: none;
  transition: transform 320ms var(--ease-settle);
}
.dock__item { position: relative; }
@keyframes kdockpop {
  0% { transform: scale(1); }
  35% { transform: scale(0.8); }
  70% { transform: scale(1.12); }
  100% { transform: scale(1); }
}
.dock__item--pop .ico { animation: kdockpop 360ms var(--ease-settle); }
@media (prefers-reduced-motion: reduce) {
  .dock__glow { transition-duration: 320ms !important; }
  .dock__item--pop .ico { animation-duration: 360ms !important; }
}

/* ── Campaigns (QR + owned links, specs/qr-campaign-links.md Q2) ──────────────
   Reuses the house grammar: panel shell, statgrid, range buttons, mono readouts,
   4px corners, no pills, status colors reserved for outcome. Mobile-first: rows
   and bundles stack by default and become aligned tables at >= 760px. */

/* Overview card: a compact four-stat statgrid, never a second command panel. */
.statgrid--4 { grid-template-columns: repeat(2, 1fr); }
@media (min-width: 700px) { .statgrid--4 { grid-template-columns: repeat(4, 1fr); } }
/* Cells may shrink below the Top link's intrinsic width, so a long slug
   truncates inside its own column instead of stretching the track. */
.statgrid--4 > div { min-width: 0; }
.cmp__toplink {
  font-family: var(--mono); font-size: 15px; font-weight: 700; color: var(--accent);
  /* Long slugs truncate like their sibling .cmp__slug instead of wrapping. */
  display: inline-block; max-width: 100%; white-space: nowrap; overflow: hidden;
  text-overflow: ellipsis; vertical-align: bottom;
}

/* Designed empty state: the terminal prompt grammar the folder menu speaks. */
.cmp__empty { padding: 22px 2px 6px; }
.cmp__empty-line { font-family: var(--mono); font-size: 14px; color: var(--dim); margin: 0 0 8px; }
.cmp__empty-hint {
  font-family: var(--mono); font-size: 12px; color: var(--accent); margin: 0;
  background: var(--accent-tint); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 8px 10px; display: inline-block;
}

/* Detail section body: scope + window bar, chart, links table, bundles. */
.cmp__body { display: block; }
.cmp__bar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; margin: 0 0 12px; }
/* Many scope chips: a horizontal scroll strip on mobile beats a tall wrap. */
.cmp__scopes {
  display: flex; gap: 6px; overflow-x: auto; -webkit-overflow-scrolling: touch;
  scrollbar-width: none; padding-bottom: 2px; max-width: 100%;
}
.cmp__scopes::-webkit-scrollbar { display: none; }
.ranges--cmp { margin: 0; flex: 0 0 auto; }
.range--sm { min-height: 28px; padding: 3px 9px; font-size: 11px; letter-spacing: 0.04em; white-space: nowrap; flex: 0 0 auto; }
.cmp__chart { min-height: 150px; margin: 0 0 14px; }

/* Links table. Mobile-first: each row is a stacked block with the numbers on the
   right and the retarget affordance pinned; a header row appears only >= 760px. */
.cmp__table { display: block; }
.cmp__head {
  display: none;
  font-family: var(--mono); font-size: 10px; font-weight: 700; letter-spacing: 0.08em;
  text-transform: uppercase; color: var(--faint);
  padding: 0 4px 8px; border-bottom: 1px solid var(--border);
}
/* Header cells stay uniform: the numeric column headings keep the header's own
   faint caps voice (only .cmp__num's right alignment carries through). */
.cmp__head .cmp__num { font-size: inherit; font-weight: inherit; color: inherit; }
.cmp__rowwrap { border-bottom: 1px solid var(--border); }
.cmp__row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  grid-template-areas:
    "slug   n7      dest"
    "title  ntotal  dest"
    "dims   last    dest";
  column-gap: 12px; row-gap: 3px; align-items: center;
  padding: 12px 4px; cursor: pointer;
  transition: background .12s var(--ease-inout);
}
.cmp__row:hover, .cmp__row:focus-visible { background: var(--panel); outline: none; }
.cmp__row[aria-expanded="true"] { background: var(--panel); box-shadow: inset 2px 0 0 var(--accent); }
.cmp__row--off { opacity: 0.5; }

.cmp__slug { grid-area: slug; font-family: var(--mono); font-size: 13.5px; font-weight: 700; color: var(--text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cmp__title { grid-area: title; font-size: 13px; color: var(--dim); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cmp__dims { grid-area: dims; font-family: var(--mono); font-size: 11px; color: var(--faint); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cmp__num { font-family: var(--mono); font-size: 14px; font-weight: 700; font-variant-numeric: tabular-nums; color: var(--text); text-align: right; }
.cmp__n7 { grid-area: n7; }
.cmp__ntotal { grid-area: ntotal; color: var(--dim); }
.cmp__last { grid-area: last; font-family: var(--mono); font-size: 11px; color: var(--dim); text-align: right; white-space: nowrap; }
.cmp__dest { grid-area: dest; align-self: center; justify-self: end; }
.cmp__dot { font-size: 9px; color: var(--faint); margin-right: 6px; vertical-align: 1px; }
.cmp__dot.up { color: var(--up); }
/* Mobile field captions, so the stacked numbers are never ambiguous. */
.cmp__n7::before { content: '7d'; }
.cmp__ntotal::before { content: 'all'; }
.cmp__last::before { content: 'seen '; }
.cmp__n7::before, .cmp__ntotal::before {
  font-size: 9px; font-weight: 700; letter-spacing: 0.06em; color: var(--faint);
  margin-right: 6px; text-transform: uppercase;
}

@media (min-width: 760px) {
  .cmp__head, .cmp__row {
    grid-template-columns: minmax(96px, 1.1fr) minmax(80px, 1.5fr) minmax(96px, 1.2fr) 52px 60px 62px 34px;
    grid-template-areas: "slug title dims n7 ntotal last dest";
    align-items: center;
  }
  .cmp__head { display: grid; column-gap: 12px; }
  .cmp__row { row-gap: 0; padding: 11px 4px; }
  .cmp__title, .cmp__dims { font-size: 12.5px; }
  .cmp__last { text-align: left; }
  .cmp__num { font-size: 13px; }
  .cmp__n7::before, .cmp__ntotal::before, .cmp__last::before { content: none; }
}

/* Expandable per-scan bundles: the full visitor read, legible at a glance. */
.cmp__bundles {
  display: block; background: var(--panel); border-top: 1px solid var(--border);
  padding: 8px 4px 12px;
}
.cmp__bundles[hidden] { display: none; }
.bundle {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-areas:
    "who   t"
    "flow  out";
  column-gap: 12px; row-gap: 2px; align-items: baseline;
  padding: 8px 8px; border-radius: var(--radius);
}
.bundle + .bundle { border-top: 1px solid var(--border); }
.bundle--head { display: none; }
.bundle--conv { box-shadow: inset 2px 0 0 var(--up); }
.bundle__t { grid-area: t; font-family: var(--mono); font-size: 11px; color: var(--dim); text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; }
.bundle__who { grid-area: who; font-family: var(--mono); font-size: 12px; color: var(--text); overflow: hidden; text-overflow: ellipsis; }
.bundle__flow { grid-area: flow; font-size: 12.5px; color: var(--dim); overflow: hidden; text-overflow: ellipsis; }
.bundle__out { grid-area: out; text-align: right; }
.cmp__conv { font-family: var(--mono); font-size: 11px; font-weight: 700; letter-spacing: 0.04em; color: var(--up); text-transform: uppercase; }
.cmp__conv::before { content: '● '; font-size: 9px; }
.cmp__none { color: var(--faint); font-style: italic; }

@media (min-width: 760px) {
  .bundle {
    grid-template-columns: 116px minmax(150px, 1.3fr) minmax(140px, 1.6fr) auto;
    grid-template-areas: "t who flow out";
    column-gap: 14px; align-items: center;
  }
  .bundle--head {
    display: grid;
    font-family: var(--mono); font-size: 10px; font-weight: 700; letter-spacing: 0.08em;
    text-transform: uppercase; color: var(--faint); padding: 4px 8px;
  }
  .bundle__t { text-align: left; }
}

/* ── Server health page (spec specs/vps-health-monitoring.md section 6) ───────
   The VPS itself as a first class Kleto Pulse surface. Reuses the house grammar:
   the .hero and .panel shells, mono micro labels, tabular readouts, 4px corners,
   no pills, and the reserved status colours (ok/warn/down) for every metric.
   Mobile first: single column, stacked rows becoming aligned tables at >= 600px. */

/* Reserved status dot: colour lives in the DATA, the same rule as the site cards. */
.srv-dot { font-size: 9px; margin-right: 7px; vertical-align: 1px; }
.srv-dot.status--none { color: var(--faint); }

/* ── Header: worst of status beacon + non OK count + trend sparkline ──────── */
.srv-hero { align-items: center; }
.srv-beacon {
  position: relative; width: 96px; height: 96px; flex: 0 0 auto;
  display: flex; align-items: center; justify-content: center;
  border-radius: 50%; border: 1px solid var(--border);
}
.srv-beacon__ring {
  position: absolute; inset: 8px; border-radius: 50%;
  border: 2px solid currentColor; opacity: 0.9;
}
/* A slow band coloured halo breathes behind the ring: the Pulse motif, one
   flourish, quiet like a resting heartbeat (matches the gauge halo cadence). */
.srv-beacon::before {
  content: ''; position: absolute; inset: -6%; border-radius: 50%; pointer-events: none;
  background: radial-gradient(circle, currentColor 0%, transparent 62%);
  opacity: 0.16; filter: blur(9px); animation: kpulse 2.8s ease-in-out infinite;
}
@media (prefers-reduced-motion: reduce) { .srv-beacon::before { animation: none; } }
.srv-beacon__word {
  position: relative; z-index: 1; font-family: var(--mono); font-weight: 700;
  font-size: 15px; letter-spacing: 0.06em; color: currentColor;
}
.srv-beacon--ok { color: var(--up); }
.srv-beacon--warn { color: var(--warn); }
.srv-beacon--down { color: var(--down); }
.srv-beacon--none { color: var(--dim); }
.srv-score { display: flex; align-items: center; gap: 12px; margin: 12px 0 0; }
.srv-score__spark { display: inline-flex; width: 132px; height: 34px; }
.srv-spark { width: 132px; height: 34px; display: block; overflow: visible; }
.srv-score__val {
  font-family: var(--mono); font-size: 21px; font-weight: 700; color: var(--text);
  font-variant-numeric: tabular-nums slashed-zero;
}
.srv-score__val small { font-size: 12px; color: var(--dim); font-weight: 600; }

/* ── Resource cards (USE): CPU, Memory, Disk, Network ─────────────────────── */
.srv-resgrid { display: grid; grid-template-columns: 1fr; gap: 12px; margin: 0 0 12px; }
/* Natural card heights: a shorter card never stretches to a taller sibling and
   opens a void in the middle. Ragged bottoms read cleaner than internal gaps. */
@media (min-width: 720px) { .srv-resgrid { grid-template-columns: repeat(2, 1fr); align-items: start; } }
.srv-res { margin: 0; display: flex; flex-direction: column; }
.srv-res .panel__title { margin-bottom: 14px; }

.srv-res__lead { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 14px 18px; margin: 0 0 14px; }
.srv-primary { display: flex; flex-direction: column; gap: 3px; flex: 0 0 auto; }
.srv-primary__v { font-family: var(--mono); font-size: 34px; font-weight: 700; line-height: 1; font-variant-numeric: tabular-nums slashed-zero; }
.srv-primary__v small { font-size: 16px; color: var(--dim); font-weight: 600; margin-left: 1px; }
.srv-primary__k { font-family: var(--mono); font-size: 10px; text-transform: uppercase; letter-spacing: 0.08em; color: var(--faint); }

/* Saturation meter: the leading signal, sits directly under the live value. */
.srv-meter { flex: 1 1 150px; min-width: 150px; }
.srv-meter__top { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; margin: 0 0 5px; }
.srv-meter__k { font-family: var(--mono); font-size: 9.5px; text-transform: uppercase; letter-spacing: 0.08em; color: var(--faint); }
.srv-meter__v { font-family: var(--mono); font-size: 13px; font-weight: 700; font-variant-numeric: tabular-nums slashed-zero; }
.srv-meter__v small { font-size: 10px; color: var(--dim); font-weight: 600; }
.srv-meter__track { position: relative; height: 8px; background: var(--panel); border: 1px solid var(--border); border-radius: 2px; overflow: hidden; }
.srv-meter__fill { position: absolute; left: 0; top: 0; bottom: 0; border-radius: 1px; }
.srv-meter__fill.status--ok { background: var(--up); }
.srv-meter__fill.status--warn { background: var(--warn); }
.srv-meter__fill.status--down { background: var(--down); }
.srv-meter__fill.status--none { background: var(--border); }
.srv-meter__tick { position: absolute; top: -1px; bottom: -1px; width: 1.5px; transform: translateX(-0.75px); z-index: 2; }
.srv-meter__tick--warn { background: var(--warn); opacity: 0.7; }
.srv-meter__tick--crit { background: var(--down); opacity: 0.7; }

/* Secondary readouts: a compact statgrid, the same metric__k/__v tone. */
.srv-subs { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px 8px; margin: 0 0 14px; }
.srv-subs--4 { grid-template-columns: repeat(2, 1fr); }
.srv-ro__k { font-family: var(--mono); font-size: 9.5px; text-transform: uppercase; letter-spacing: 0.07em; color: var(--faint); margin: 0 0 2px; white-space: nowrap; }
.srv-ro__v { font-family: var(--mono); font-size: 15px; font-weight: 700; font-variant-numeric: tabular-nums slashed-zero; }
.srv-ro__v small { font-size: 11px; color: var(--dim); font-weight: 600; }

/* Memory: swap + OOM pulled out as an emphasised pair (the incident metrics). */
.srv-emph { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; margin: 0 0 14px; }
.srv-emph__cell { background: var(--panel); border: 1px solid var(--border); border-radius: var(--radius); padding: 10px 12px; }
.srv-emph__k { font-family: var(--mono); font-size: 9.5px; text-transform: uppercase; letter-spacing: 0.08em; color: var(--faint); margin: 0 0 4px; }
.srv-emph__v { font-family: var(--mono); font-size: 21px; font-weight: 700; font-variant-numeric: tabular-nums slashed-zero; }
.srv-emph__v small { font-size: 12px; color: var(--dim); font-weight: 600; }

/* Disk: one block per mount, each its own usage meter. */
.srv-mounts { display: flex; flex-direction: column; gap: 14px; margin: 0 0 14px; }
.srv-mount__head { display: flex; align-items: baseline; gap: 8px; margin: 0 0 7px; }
.srv-mount__name { font-family: var(--mono); font-size: 13px; font-weight: 700; color: var(--text); }
.srv-mount__free { font-family: var(--mono); font-size: 15px; font-weight: 700; margin-left: auto; font-variant-numeric: tabular-nums slashed-zero; }
.srv-mount__free small { font-size: 11px; color: var(--dim); }
.srv-mount__freek { font-family: var(--mono); font-size: 9px; text-transform: uppercase; letter-spacing: 0.08em; color: var(--faint); }

/* Card toolbar: an optional metric/mount selector on the left, window on the right. */
.srv-toolbar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; margin: 4px 0 12px; }
.ranges--srv { margin: 0; flex: 0 0 auto; gap: 5px; }
.srv-metricsel { flex: 1 1 auto; }
.srv-chart { min-height: 150px; }

/* ── Wide cards (containers) + paired cards (platform / endpoints) ────────── */
.srv-wide { margin: 0 0 12px; }
.srv-pair { align-items: start; }

/* Containers table: mobile stacked with captions, aligned grid at >= 600px. */
.srv-tbl { display: block; }
.srv-tbl__head {
  display: none; font-family: var(--mono); font-size: 10px; font-weight: 700;
  letter-spacing: 0.08em; text-transform: uppercase; color: var(--faint);
  padding: 0 4px 8px; border-bottom: 1px solid var(--border);
}
.srv-tbl__head .srv-tbl__n { text-align: right; }
.srv-tbl__row {
  display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px 12px;
  padding: 12px 4px; border-bottom: 1px solid var(--border); align-items: baseline;
}
.srv-tbl__row:last-child { border-bottom: 0; }
.srv-tbl__svc { grid-column: 1 / -1; font-family: var(--mono); font-size: 13.5px; font-weight: 700; color: var(--text); min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.srv-tbl__n { font-family: var(--mono); font-size: 14px; font-weight: 700; font-variant-numeric: tabular-nums slashed-zero; text-align: left; color: var(--text); }
.srv-tbl__n::before {
  content: attr(data-k) '  '; font-size: 9px; font-weight: 700; letter-spacing: 0.06em;
  color: var(--faint); text-transform: uppercase;
}
@media (min-width: 600px) {
  /* SERVICE takes the larger share (compose names like personal-platform-api-1
     wrapped to 2-3 lines around ~700px); the four numeric columns are short. */
  .srv-tbl__head, .srv-tbl__row {
    grid-template-columns: minmax(0, 3fr) repeat(4, minmax(52px, 1fr));
    gap: 12px; align-items: center;
  }
  .srv-tbl__head { display: grid; }
  .srv-tbl__svc { grid-column: auto; }
  .srv-tbl__n { text-align: right; font-size: 13px; }
  .srv-tbl__n::before { content: none; }
}

/* Platform: a compact readout grid; backup age carries the loudest colour. */
.srv-plat { margin: 0; }
.srv-pgrid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px 10px; }
@media (min-width: 420px) { .srv-pgrid { grid-template-columns: repeat(3, 1fr); } }
.srv-pcell__k { font-family: var(--mono); font-size: 9.5px; text-transform: uppercase; letter-spacing: 0.07em; color: var(--faint); margin: 0 0 3px; }
.srv-pcell__v { font-family: var(--mono); font-size: 17px; font-weight: 700; font-variant-numeric: tabular-nums slashed-zero; margin: 0; }
.srv-pcell__v small { font-size: 11px; color: var(--dim); font-weight: 600; }

/* Endpoints + certs: two labelled mini tables. */
.srv-ep { margin: 0; }
.srv-ep__cap { font-family: var(--mono); font-size: 9.5px; text-transform: uppercase; letter-spacing: 0.08em; color: var(--faint); margin: 4px 0 6px; }
.srv-ep__cap + .srv-ep__grid { margin-bottom: 12px; }
.srv-ep__grid { display: flex; flex-direction: column; }
.srv-ep__row {
  display: grid; grid-template-columns: 1fr auto auto; gap: 10px 14px; align-items: baseline;
  padding: 8px 2px; border-bottom: 1px solid var(--border);
}
.srv-ep__row:last-child { border-bottom: 0; }
.srv-ep__row--cert { grid-template-columns: 1fr auto; }
.srv-ep__name { font-family: var(--mono); font-size: 13px; font-weight: 700; color: var(--text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.srv-ep__status, .srv-ep__lat, .srv-ep__cert { font-family: var(--mono); font-size: 13px; font-weight: 700; font-variant-numeric: tabular-nums slashed-zero; text-align: right; }
.srv-ep__lat, .srv-ep__cert { color: var(--dim); }
.srv-ep__status small, .srv-ep__lat small, .srv-ep__cert small { font-size: 10px; color: var(--dim); }

/* ── Incidents strip: what broke and when, one glance ─────────────────────── */
.srv-inc { margin: 0 0 12px; }
.srv-inc__list { display: flex; flex-direction: column; }
.srv-inc__row {
  display: grid; grid-template-columns: max-content minmax(0, 1fr) max-content;
  grid-template-areas: "state what when" "note note note";
  gap: 3px 12px; align-items: baseline;
  padding: 12px 2px; border-bottom: 1px solid var(--border);
}
.srv-inc__row:last-child { border-bottom: 0; }
.srv-inc__row--active { box-shadow: inset 2px 0 0 currentColor; padding-left: 10px; }
.srv-inc__row--active .srv-inc__state.status--warn { color: var(--warn); }
.srv-inc__state { grid-area: state; font-family: var(--mono); font-size: 11px; font-weight: 700; letter-spacing: 0.06em; white-space: nowrap; }
/* The title truncates on one line (mid-token hyphen breaks at phone width left
   dangling hyphens and ragged row heights); the row's title attr has the rest. */
.srv-inc__what { grid-area: what; min-width: 0; font-family: var(--mono); font-size: 13px; font-weight: 700; color: var(--text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.srv-inc__scope { color: var(--dim); font-weight: 400; margin-left: 6px; }
.srv-inc__note { grid-area: note; min-width: 0; font-size: 12.5px; color: var(--dim); overflow-wrap: anywhere; }
.srv-inc__when { grid-area: when; font-family: var(--mono); font-size: 11px; color: var(--dim); text-align: right; white-space: nowrap; display: flex; flex-direction: column; font-variant-numeric: tabular-nums; }
.srv-inc__when small { font-size: 10px; color: var(--faint); }
@media (min-width: 760px) {
  .srv-inc__row {
    grid-template-columns: 96px minmax(160px, 1.2fr) 1fr max-content;
    grid-template-areas: "state what note when";
    align-items: baseline; padding: 11px 2px;
  }
  .srv-inc__when { flex-direction: row; gap: 8px; align-items: baseline; }
}

/* Designed empty + cold states: the terminal grammar the folder menu speaks. */
.srv-cold { margin: 0 0 12px; }
.srv-empty { padding: 22px 2px 8px; }
.srv-empty__line { font-family: var(--mono); font-size: 14px; color: var(--dim); margin: 0 0 8px; }
.srv-empty__hint {
  font-family: var(--mono); font-size: 12px; color: var(--accent); margin: 0;
  background: var(--accent-tint); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 8px 10px; display: inline-block;
}

/* Numbered eyebrow reset: the Server page counts its own sections from 01. */
#server .wrap { counter-reset: sec; }

/* Portfolio campaigns page (clicked from the overview card). Reuses the
   section table grammar; only the page shell + card affordance are new. */
.cmp-ov--link { cursor: pointer; }
.cmp-ov--link:hover .panel { border-color: var(--accent, #FDC500); }
.cmp-page__summary { margin-bottom: var(--space-lg, 1.5rem); }
.cmp-page__summary .metric__v { font-size: 1.5rem; }
.cmp-group { margin-bottom: var(--space-md, 1rem); }
.cmp__camptag { opacity: 0.6; font-size: 0.85em; }

/* Live activity view (near-live fleet feed, polled every 5s). */
.live { max-width: 820px; margin: 0 auto; }
.live__head { margin-bottom: var(--space-lg, 1.5rem); }
.live__title { display: flex; align-items: center; gap: 0.5rem; font-size: 1.4rem; margin: 0 0 0.25rem; }
.live__pulse { width: 10px; height: 10px; border-radius: 50%; background: var(--up, #30D158); box-shadow: 0 0 0 0 rgba(48,209,88,0.6); animation: live-pulse 2s infinite; }
@keyframes live-pulse { 0% { box-shadow: 0 0 0 0 rgba(48,209,88,0.5); } 70% { box-shadow: 0 0 0 8px rgba(48,209,88,0); } 100% { box-shadow: 0 0 0 0 rgba(48,209,88,0); } }
@media (prefers-reduced-motion: reduce) { .live__pulse { animation: none; } }
.live__sub { color: var(--text-subtle, #9A9AA1); font-size: 0.9rem; margin: 0; }
.live__active { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-bottom: var(--space-lg, 1.5rem); }
.live__chip { padding: 0.25rem 0.6rem; border: 1px solid var(--border-strong, #1F2228); border-radius: 999px; font-size: 0.85rem; }
.live__chip b { color: var(--accent, #3392F4); }
.live__quiet { color: var(--text-subtle, #9A9AA1); font-size: 0.9rem; }
.live__feed { display: flex; flex-direction: column; }
.live__row { display: grid; grid-template-columns: 4.5rem 7rem 1fr auto; gap: 0.75rem; align-items: baseline; padding: 0.5rem 0; border-bottom: 1px solid var(--border, #14161a); font-size: 0.9rem; }
.live__t { color: var(--text-subtle, #9A9AA1); font-variant-numeric: tabular-nums; }
.live__site { font-weight: 600; }
.live__path { color: var(--text-primary, #F5F5F7); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.live__meta { color: var(--text-subtle, #9A9AA1); font-size: 0.8rem; text-align: right; }
.live__evtype { margin-left: 0.4rem; padding: 0 0.35rem; border-radius: 4px; background: var(--accent-soft, rgba(51,146,244,0.18)); font-size: 0.75rem; }
.live__band { display: inline-block; width: 8px; height: 8px; border-radius: 50%; }
.live__row--new { animation: live-fade 0.6s ease; }
@keyframes live-fade { from { background: var(--accent-soft, rgba(51,146,244,0.14)); } to { background: transparent; } }
@media (max-width: 560px) { .live__row { grid-template-columns: 4rem 1fr; } .live__meta, .live__site { grid-column: 2; text-align: left; } }
