/* Cherkun Ops v2 design tokens and light/dark themes. */

:root {
  --ops-radius: 2px;
  --ops-control: 44px;
  --ops-space-1: 4px;
  --ops-space-2: 8px;
  --ops-space-3: 12px;
  --ops-space-4: 16px;
  --ops-space-5: 20px;
  --ops-space-6: 24px;
  --ops-space-8: 32px;
  --font-ui: "Segoe UI Variable Text", "Segoe UI Variable", Inter, "SF Pro Text", "Segoe UI", ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  --font-display: "Segoe UI Variable Display", "Segoe UI Variable", Inter, "SF Pro Display", "Segoe UI", ui-sans-serif, system-ui, sans-serif;
  --ops-font: var(--font-ui);
  --ops-display: var(--font-display);
  --ops-mono: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
}

body.executive-ui:not(.ui-lab-shell) {
  --ops-bg: #f3f3ef;
  --ops-surface: #ffffff;
  --ops-surface-2: #eaeae5;
  --ops-ink: #171719;
  --ops-muted: #686866;
  --ops-line: #cfcfca;
  --ops-line-strong: #a9a9a3;
  --ops-accent: #5b4cf0;
  --ops-accent-rgb: 91, 76, 240;
  --ops-ready: #08704c;
  --ops-warning: #8f4d00;
  --ops-critical: #b62e33;
  /* Keep legacy modules on the same accessible semantic palette. */
  --ui-bg: var(--ops-bg);
  --ui-surface: var(--ops-surface);
  --ui-surface-2: var(--ops-surface-2);
  --ui-ink: var(--ops-ink);
  --ui-muted: var(--ops-muted);
  --ui-line: var(--ops-line);
  --ui-accent: var(--ops-accent);
  --ui-accent-rgb: var(--ops-accent-rgb);
  --ui-ready: var(--ops-ready);
  --ui-warning: var(--ops-warning);
  --ui-critical: var(--ops-critical);
  --text: var(--ops-ink);
  --muted: var(--ops-muted);
  --border: var(--ops-line);
  --bg: var(--ops-bg);
  --panel: var(--ops-surface);
  --surface: var(--ops-surface);
  --accent: var(--ops-accent);
  --warn: var(--ops-warning);
  --warning: var(--ops-warning);
  --ok: var(--ops-ready);
  --success: var(--ops-ready);
  --bad: var(--ops-critical);
  --danger: var(--ops-critical);
  background: var(--ops-bg);
  color: var(--ops-ink);
  font-family: var(--ops-font);
  font-kerning: normal;
  font-synthesis: none;
  font-optical-sizing: auto;
  text-rendering: optimizeLegibility;
}

body.executive-ui:not(.ui-lab-shell) :where(
  .metric-value, .kpi-value, .ops-metric strong, .review-metric strong,
  .progress-value, .leaderboard-score, td[data-number]
) {
  font-variant-numeric: tabular-nums lining-nums;
}

body.executive-ui[data-ui-theme="dark"]:not(.ui-lab-shell) {
  --ops-bg: #101012;
  --ops-surface: #18181b;
  --ops-surface-2: #222226;
  --ops-ink: #f4f4ef;
  --ops-muted: #a4a4a0;
  --ops-line: #34343a;
  --ops-line-strong: #55555c;
  --ops-accent: #958cff;
  --ops-accent-rgb: 149, 140, 255;
  --ops-ready: #36cd92;
  --ops-warning: #ffb64d;
  --ops-critical: #ff6e74;
}
