/* Hermes Flight Recorder console — shared shell.
 *
 * Design tokens and the common chrome (header, nav, buttons, panels, stats,
 * tables) used by every console page. Page-specific styles — the timeline
 * strip, the drawer, the analytics charts — stay inline in each page. */

:root {
  --bg: #0d0d0f; --surface: #111113; --line: #232326; --line-soft: #1c1c1f;
  --line-faint: #17171a; --edge: #2c2c30; --text: #d9d6cc; --bright: #f0ede4;
  --warm: #a5a299; --sess: #b5b1a4; --mut: #77746b; --dim: #57544d;
  --model: oklch(78% 0.14 80); --tool: oklch(76% 0.13 165); --sub: oklch(74% 0.13 310);
  --cron: oklch(72% 0.1 245); --red: oklch(66% 0.21 27); --redt: oklch(72% 0.19 27);
  --mono: "IBM Plex Mono", ui-monospace, Menlo, monospace;
  --display: "Space Grotesk", system-ui, sans-serif;
}
@keyframes frPulse { 0%, 100% { opacity: 0.3; } 50% { opacity: 0.95; } }

* { box-sizing: border-box; }
html, body { height: 100%; }
body { margin: 0; background: var(--bg); color: var(--text); font-family: var(--mono); font-size: 13px; -webkit-font-smoothing: antialiased; }
::selection { background: oklch(78% 0.14 80 / 0.35); }
a { color: inherit; text-decoration: none; }

.wrap { min-width: 1180px; max-width: 1720px; margin: 0 auto; padding: 18px 28px 18px; min-height: 100vh; display: flex; flex-direction: column; }

/* Header + breadcrumb nav ------------------------------------------------- */
.head { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; padding-bottom: 16px; border-bottom: 1px solid var(--line); }
.head-left { min-width: 0; }
.brand { display: inline-block; font-family: var(--display); font-weight: 700; font-size: 18px; letter-spacing: 0.14em; color: var(--bright); }
a.brand:hover { color: #fff; }
.crumbs { display: flex; align-items: center; gap: 8px; margin-top: 7px; font-size: 12px; color: var(--mut); }
.crumbs a:hover { color: var(--text); }
.crumbs .sep { color: var(--dim); }
.crumbs .here { color: var(--bright); font-weight: 600; }
.tabs { display: inline-flex; border: 1px solid var(--edge); margin-left: 6px; }
.tabs a { padding: 4px 11px; font-size: 11px; letter-spacing: 0.05em; color: var(--mut); border-left: 1px solid var(--edge); }
.tabs a:first-child { border-left: 0; }
.tabs a:hover { color: var(--text); }
.tabs a.on { background: var(--bg); color: var(--bright); }
.health { color: var(--dim); font-size: 11.5px; margin-left: 4px; }

.head-right { display: flex; align-items: center; gap: 14px; font-size: 12.5px; }
.stats { display: flex; gap: 16px; color: var(--warm); }
.stats span { white-space: nowrap; }
.stats b { color: var(--bright); font-weight: 600; }
.stats .cost { color: var(--model); }
.findings { padding: 6px 11px; border: 1px solid var(--edge); background: none; color: var(--mut); font-weight: 600; letter-spacing: 0.06em; }
.findings.hit { border-color: oklch(66% 0.21 27 / 0.6); background: oklch(66% 0.21 27 / 0.12); color: var(--redt); }
.live { display: flex; align-items: center; gap: 7px; background: var(--surface); border: 1px solid var(--edge); color: var(--mut); font-size: 12px; font-weight: 600; letter-spacing: 0.08em; padding: 7px 13px; }
.live .d { width: 7px; height: 7px; border-radius: 50%; background: var(--tool); animation: frPulse 1.8s infinite; }

/* Buttons ----------------------------------------------------------------- */
.mini-btn { background: none; border: 1px solid var(--edge); color: var(--mut); font-family: var(--mono); font-size: 11px; letter-spacing: 0.05em; padding: 6px 10px; cursor: pointer; }
.mini-btn:hover { color: var(--text); }

/* Panels + tables --------------------------------------------------------- */
.panel { background: var(--surface); border: 1px solid var(--line); }
.panel .ph { display: flex; align-items: baseline; gap: 14px; padding: 12px 16px 10px; border-bottom: 1px solid var(--line-soft); flex-wrap: wrap; }
.panel .ph .id { font-family: var(--display); font-weight: 700; font-size: 16px; color: var(--bright); }
.panel .ph .m { font-size: 12px; color: var(--mut); }
.panel .ph .m.warm { color: var(--warm); }
.empty { padding: 40px; text-align: center; color: var(--mut); }
.empty code { color: var(--warm); }
.banner { padding: 13px 16px; border: 1px dashed var(--edge); color: var(--mut); font-size: 12px; }
.banner b { color: var(--text); }

table { width: 100%; border-collapse: collapse; }
thead th { font-size: 10.5px; letter-spacing: 0.1em; color: var(--dim); text-align: left; font-weight: 400; padding: 11px 14px 7px; border-bottom: 1px solid var(--line-soft); }
th.r, td.r { text-align: right; }
td { font-size: 12px; padding: 6px 14px; border-bottom: 1px solid var(--line-faint); color: var(--warm); }

.chip { display: inline-flex; align-items: center; gap: 6px; color: var(--warm); font-variant-numeric: tabular-nums; }
.chip .dot { width: 8px; height: 8px; border-radius: 50%; flex: none; }

/* Help bubble + floating tooltip ------------------------------------------ */
.help { position: relative; display: inline-flex; align-items: center; justify-content: center; width: 16px; height: 16px; border: 1px solid var(--edge); border-radius: 50%; color: var(--mut); font-size: 11px; cursor: help; user-select: none; align-self: center; }
.help:hover, .help:focus { color: var(--bright); border-color: var(--mut); outline: none; }
.help .caphelp { display: none; position: absolute; top: 22px; right: 0; z-index: 30; width: 340px; padding: 10px 12px; background: var(--bg); border: 1px solid var(--edge); color: var(--mut); font-size: 11.5px; line-height: 1.5; box-shadow: 0 6px 24px rgba(0,0,0,.45); }
.help:hover .caphelp, .help:focus .caphelp { display: block; }
.tip { position: fixed; z-index: 50; display: none; pointer-events: none; max-width: 340px; background: #17171b; border: 1px solid var(--edge); padding: 8px 11px; font-size: 11.5px; color: var(--text); line-height: 1.5; box-shadow: 0 8px 24px rgba(0,0,0,0.6); }
.tip .d { color: var(--dim); }
