/* GENERATED FILE - DO NOT EDIT.
 * Copied from akc/public/themes/tokens.css by scripts/sync-creds-manager.sh.
 * Edit the source and re-run that script; --check fails on a stale copy.
 */
/*
 * Agent K — Design Tokens (single source of truth)
 *
 * Every color, radius, spacing, and type-scale variable for the chat UI lives
 * here. index.html no longer defines [data-theme] blocks inline — it links
 * this file (served with ?v=<AKC_ASSET_VER> cache-busting, base-path rewritten
 * by sendIndexWithBase in akc/server/src/index.ts).
 *
 * Load order (must hold):
 *   1. themes/tokens.css        ← this file (defaults for both modes)
 *   2. inline <style> in index.html (component styles consuming the vars)
 *   3. /client/theme.css        ← optional per-workspace preset override,
 *      appended at runtime by the branding loader; later link wins.
 *
 * Rules:
 *   - New UI code must consume tokens, not raw hex/rgba. Status pills use the
 *     --success/--warning/--danger/--info pairs below.
 *   - Both mode blocks MUST define the same set of variables.
 *   - Values in the "Core palette" section are the long-standing production
 *     values — do not tweak them casually; presets override at runtime.
 */

/* ── Light mode (warm, not pure white) ─────────────────────────────── */
[data-theme="light"] {
  /* Core palette (pre-existing vars — values unchanged) */
  --primary: #1B2A4A; --accent: #3B82F6; --agent: #8B5CF6;
  --warning: #F59E0B; --error: #EF4444;
  --bg: #FBF8F2; --bg-chat: #FDFBF6;
  --msg-user-bubble: #EDE5D4;
  --panel: #FDFBF6; --panel-hover: #F5F0E5;
  --sidebar-bg: #FCF9F0; /* one-step-richer than chat bg #FDFBF6 — minimal contrast */
  --border: #F0EADB; --text: #1E293B;
  --text-secondary: #64748B;
  --msg-user: #E8E1D6; --msg-claude: #FAF8F5;
  --input-bg: #FDFBF6; --input-placeholder: #94A3B8;
  --code-bg: #EDE9E3; --code-border: #D6D0C6;
  --scrollbar: #C4BDB3;
  --login-gradient: linear-gradient(135deg, #EDE9E3 0%, #F0EDE8 50%, #E8E4DE 100%);
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.06);
  --shadow-md: 0 4px 24px rgba(0,0,0,0.08);
  --btn-send-bg: #1B2A4A; --btn-send-hover: #243B5E;
  --btn-send-disabled-bg: #C4BDB3; --btn-send-disabled-text: #94A3B8;
  --focus-ring: rgba(59,130,246,0.15);
  --sidebar-w: 248px;
  --font: 'Inter', system-ui, -apple-system, sans-serif;
  --pixel-font: 'Press Start 2P', monospace;
  --kitchen-bg: #C4A484; --kitchen-floor: #8B7355;
  --kitchen-wall: #E8D5B7; --kitchen-accent: #FF6B35;
  --station-bg: #D4B896; --dish-glow: #FFD700;
  --kitchen-counter: #6B4226; --kitchen-text: #2A1810;

  /* Semantic status (new — use these instead of raw hex/rgba in UI code) */
  --success: #16A34A;             --success-bg: rgba(34,197,94,0.15);
  --warning-strong: #D97706;      --warning-bg: rgba(245,158,11,0.16);
  --danger: #DC2626;              --danger-bg: rgba(239,68,68,0.14);
  --info: #2563EB;                --info-bg: rgba(59,130,246,0.14);
  --neutral: #64748B;             --neutral-bg: rgba(148,163,184,0.16);
  --presence-online: #22C55E;     --presence-busy: var(--warning);
  --agent-blend: #EC4899;         /* the pink the agent purple is mixed toward in the spinner blades and the working bar */
  /* The live-status sweep: a silver glint passing over the working line and
     the fan-out's live rows. Neutral on purpose (it used to be the accent
     blue), and a PAIR per theme: on cream, white is no sweep at all, so the
     light glint is a pale slate over a mid slate, and dark is white over silver. */
  --shimmer-base: #475569;        --shimmer-glint: #CBD5E1;

  /* Roles that are the same colour in both themes (Track C token pass). Each
     was a literal that already rendered identically in light and dark; naming
     it says what the colour is FOR instead of what it happens to be. */
  --on-accent: #FFFFFF;           /* text/icon on a saturated fill: accent, send button, avatar palette, status colours */
  --paper: #FFFFFF;               /* a rendered document's page (PDF/DOCX/XLSX preview): white paper in dark mode too */
  --panel-warm-tint: rgba(120,90,40,0.025); /* the hero-card wash layered over --panel (design-system.md) */
  --overlay-soft: rgba(127,127,127,0.10); --overlay: rgba(127,127,127,0.12); --overlay-strong: rgba(127,127,127,0.18); /* neutral wash that reads on any surface */
  --ink-4: rgba(0,0,0,0.04); --ink-5: rgba(0,0,0,0.05); --ink-6: rgba(0,0,0,0.06); --ink-7: rgba(0,0,0,0.07); --ink-8: rgba(0,0,0,0.08); --ink-12: rgba(0,0,0,0.12); /* black at alpha, for theme-blind shadows and hover washes; --shadow-sm/md are the theme-aware ones */
  --scrim: rgba(0,0,0,0.6);       /* modal backdrop */

  /* Type + mono (new) */
  --font-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  --fs-xs: 11px; --fs-sm: 12px; --fs-md: 13px; --fs-lg: 15px; --fs-xl: 20px;

  /* Radius scale (new) */
  --radius-sm: 6px; --radius-md: 8px; --radius-lg: 12px; --radius-xl: 16px; --radius-pill: 999px;

  /* Spacing scale (new) */
  --space-1: 4px; --space-2: 8px; --space-3: 12px; --space-4: 16px; --space-5: 20px; --space-6: 24px;
}

/* ── Dark mode (navy, not black) ───────────────────────────────────── */
[data-theme="dark"] {
  /* Core palette (pre-existing vars — values unchanged) */
  --primary: #93B4E8; --accent: #60A5FA; --agent: #A78BFA;
  --warning: #FBBF24; --error: #F87171;
  --bg: #0F1A2E; --bg-chat: #162036;
  --msg-user-bubble: #243150;
  --sidebar-bg: #0C1426;
  --panel: #162036; --panel-hover: #1C2A46;
  --border: #1E2A44; --text: #E2E8F0;
  --text-secondary: #94A3B8;
  --msg-user: #1C2A46; --msg-claude: #162036;
  --input-bg: #1C2A46; --input-placeholder: #64748B;
  --code-bg: #1C2A46; --code-border: #253352;
  --scrollbar: #253352;
  --login-gradient: linear-gradient(135deg, #0F1A2E 0%, #162036 50%, #0B1526 100%);
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.3);
  --shadow-md: 0 4px 24px rgba(0,0,0,0.4);
  --btn-send-bg: #3B82F6; --btn-send-hover: #2563EB;
  --btn-send-disabled-bg: #253352; --btn-send-disabled-text: #475569;
  --focus-ring: rgba(96,165,250,0.25);
  --sidebar-w: 248px;
  --font: 'Inter', system-ui, -apple-system, sans-serif;
  --pixel-font: 'Press Start 2P', monospace;
  --kitchen-bg: #1A0F0A; --kitchen-floor: #0E0805;
  --kitchen-wall: #2A1810; --kitchen-accent: #FF8C5A;
  --station-bg: #3D2817; --dish-glow: #FFD700;
  --kitchen-counter: #4A2C17; --kitchen-text: #E8D5B7;

  /* Semantic status (new) */
  --success: #4ADE80;             --success-bg: rgba(74,222,128,0.16);
  --warning-strong: #FBBF24;      --warning-bg: rgba(251,191,36,0.16);
  --danger: #F87171;              --danger-bg: rgba(248,113,113,0.16);
  --info: #60A5FA;                --info-bg: rgba(96,165,250,0.16);
  --neutral: #94A3B8;             --neutral-bg: rgba(148,163,184,0.14);
  --presence-online: #22C55E;     --presence-busy: var(--warning);
  --agent-blend: #EC4899;         /* the pink the agent purple is mixed toward in the spinner blades and the working bar */
  --shimmer-base: #94A3B8;        --shimmer-glint: #FFFFFF;   /* silver text, white glint (see the light block) */

  /* Roles that are the same colour in both themes (Track C token pass). Each
     was a literal that already rendered identically in light and dark; naming
     it says what the colour is FOR instead of what it happens to be. */
  --on-accent: #FFFFFF;           /* text/icon on a saturated fill: accent, send button, avatar palette, status colours */
  --paper: #FFFFFF;               /* a rendered document's page (PDF/DOCX/XLSX preview): white paper in dark mode too */
  --panel-warm-tint: rgba(120,90,40,0.025); /* the hero-card wash layered over --panel (design-system.md) */
  --overlay-soft: rgba(127,127,127,0.10); --overlay: rgba(127,127,127,0.12); --overlay-strong: rgba(127,127,127,0.18); /* neutral wash that reads on any surface */
  --ink-4: rgba(0,0,0,0.04); --ink-5: rgba(0,0,0,0.05); --ink-6: rgba(0,0,0,0.06); --ink-7: rgba(0,0,0,0.07); --ink-8: rgba(0,0,0,0.08); --ink-12: rgba(0,0,0,0.12); /* black at alpha, for theme-blind shadows and hover washes; --shadow-sm/md are the theme-aware ones */
  --scrim: rgba(0,0,0,0.6);       /* modal backdrop */

  /* Type + mono (new) */
  --font-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  --fs-xs: 11px; --fs-sm: 12px; --fs-md: 13px; --fs-lg: 15px; --fs-xl: 20px;

  /* Radius scale (new) */
  --radius-sm: 6px; --radius-md: 8px; --radius-lg: 12px; --radius-xl: 16px; --radius-pill: 999px;

  /* Spacing scale (new) */
  --space-1: 4px; --space-2: 8px; --space-3: 12px; --space-4: 16px; --space-5: 20px; --space-6: 24px;
}

/* Responsive token overrides stay in this unlayered sheet. A declaration in a
   layered component sheet cannot override a normal unlayered declaration,
   regardless of specificity or source order. */
@media (max-width: 768px) {
  [data-theme="light"], [data-theme="dark"] { --sidebar-w: 240px; }
}
