/* BOFH99 — shared design system
   Tone: Dieter Rams functional restraint. Warm chalk paper, black ink,
   Braun orange used sparingly. Every product in the suite inherits from here. */

:root {
  /* ── Paper palette ─────────────────────────────────────── */
  --paper: #f4efe4;      /* app background */
  --chalk: #faf6ec;      /* panels, topbars */
  --card: #fdfaf2;       /* elevated surfaces */
  --ink: #141414;
  --ink-2: #2a2a28;
  --steel: #6a6a66;
  --steel-2: #a39f93;
  --rule: #e4dfd2;
  --rule-strong: #1a1a1a;

  /* ── Signals (used sparingly — Braun restraint) ────────── */
  --orange: #d9531e;       /* THE accent */
  --orange-ink: #b8411a;
  --green: #4f6b3a;        /* ok */
  --red: #a63a22;          /* down */
  --amber: #c38a1a;        /* degraded */

  /* ── Type ──────────────────────────────────────────────── */
  --ui: "Inter Tight", "Inter", "Helvetica Neue", Helvetica, Arial, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
  --display: "Inter Tight", sans-serif;
  --hand: "Caveat", "Brush Script MT", cursive;

  /* ── Metrics ───────────────────────────────────────────── */
  --hair: 1px solid var(--rule);
  --hair-strong: 1px solid var(--rule-strong);
  --radius: 0px;          /* we do corners */
  --pad-1: 8px;
  --pad-2: 12px;
  --pad-3: 18px;
  --pad-4: 24px;
  --pad-5: 36px;
  --pad-6: 56px;
}

[data-theme="dark"] {
  --paper: #141412;
  --chalk: #1a1a18;
  --card: #1f1e1b;
  --ink: #efe9d8;
  --ink-2: #d3cdbe;
  --steel: #9b988f;
  --steel-2: #6a6a66;
  --rule: #2e2d29;
  --rule-strong: #efe9d8;
}

[data-theme="white"] {
  --paper: #f4efe4;
  --chalk: #faf6ec;
  --card: #fdfaf2;
  --rule: #e4dfd2;
}

* { box-sizing: border-box; }
html, body {
  margin: 0; padding: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--ui);
  font-size: 14px;
  line-height: 1.4;
  -webkit-font-smoothing: antialiased;
  font-feature-settings: "ss01","cv11";
}
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; padding: 0; }
a { color: inherit; text-decoration: none; }

/* ── Type utilities ──────────────────────────────────────── */
.kicker {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--steel);
  font-weight: 500;
}
.kicker--ink { color: var(--ink); }
.mono { font-family: var(--mono); font-variant-numeric: tabular-nums; }
.display {
  font-family: var(--display);
  font-weight: 500;
  letter-spacing: -0.03em;
  line-height: 1.04;
}

/* ── Buttons ─────────────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 7px 14px;
  border: var(--hair-strong);
  background: var(--chalk);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: -0.005em;
  cursor: pointer;
  transition: background 80ms;
}
.btn:hover { background: var(--paper); }
.btn--accent {
  background: var(--orange);
  color: #fff;
  border-color: var(--orange);
}
.btn--accent:hover { background: var(--orange-ink); border-color: var(--orange-ink); }
.btn--ghost { border-color: var(--rule); }
.btn--lg { padding: 10px 18px; font-size: 14px; }
/* Inside a button, the keycap is just a subtle monospace glyph — the
   border/background treatment is for standalone use in help text. */
.btn .kbd {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.04em;
  color: inherit;
  opacity: 0.55;
  padding: 0;
  border: 0;
  background: transparent;
  margin-left: 2px;
}
.btn:hover .kbd { opacity: 0.85; }

/* ── Chips (filled Braun squares) ────────────────────────── */
.chip {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: var(--mono); font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase;
}
.chip::before {
  content: ""; width: 10px; height: 10px;
  background: currentColor; display: inline-block;
}
.chip.ok { color: var(--green); }
.chip.down { color: var(--red); }
.chip.degraded { color: var(--amber); }
.chip.paused { color: var(--steel-2); }
.chip.maint { color: var(--orange); }

/* ── Card / panel ────────────────────────────────────────── */
.card { background: var(--card); border: var(--hair); }
.card-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 12px 16px; border-bottom: var(--hair);
}
.card-body { padding: 16px; }

/* ── Scrollbars ──────────────────────────────────────────── */
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-thumb { background: var(--rule); }
::-webkit-scrollbar-thumb:hover { background: var(--steel-2); }
::-webkit-scrollbar-track { background: transparent; }

/* ── Layout helpers ──────────────────────────────────────── */
.row { display: flex; align-items: center; gap: 12px; }
.row--sb { justify-content: space-between; }
.col { display: flex; flex-direction: column; gap: 12px; }
