@import url('https://fonts.googleapis.com/css2?family=Archivo:wdth,wght@62..125,400..800&family=JetBrains+Mono:wght@400;700&display=swap');

/* ══════════════════════════════════════════════════════════════════════
   CRATE DESIGN SYSTEM v02 — "BOOTH"
   Dark-first: Booth (dark) is :root and canonical. Daylight is opt-in via
   the .light class (mandatory for print/PDF).
   ══════════════════════════════════════════════════════════════════════ */

/* ── BOOTH (dark, canonical) ──────────────────────────────────────────── */
:root {
  /* ── typography ────────────────────────────────────────────── */
  --font-display: 'Archivo', system-ui, sans-serif;   /* wdth 116-125 @ 800 */
  --font-sans: 'Archivo', system-ui, sans-serif;       /* wdth 100 @ 400-600 */
  --font-mono: 'JetBrains Mono', ui-monospace, monospace;
  --tracking-display: -0.025em;
  --line-height-display: 1.05;
  --font-weight-display: 800;
  --font-weight-body: 400;
  --line-height-body: 1.6;
  --tracking-body: 0em;
  --font-weight-mono: 400;

  /* ── ground ladder (cool-neutral, not blue) ────────────────── */
  --background: #0A0A0C;          /* obsidian — page ground */
  --foreground: #EDEDF0;          /* 16.9:1 on obsidian */
  --card: #1A1A1F;                /* raised — cards, inputs, rows */
  --card-foreground: #EDEDF0;
  --popover: #121215;             /* surface — panels, sheets */
  --popover-foreground: #EDEDF0;
  --muted: #060608;               /* sunk — table heads, column wells */
  --muted-foreground: #85858F;    /* 4.75:1 on raised — the floor */
  --border: rgba(237,237,240,0.11);
  --input: rgba(237,237,240,0.18);
  --ring: #00E5FF;

  /* ── signal set — one colour, one job, no overlap ──────────── */
  --primary: #00E5FF;             /* Cue — actions/focus ONLY, never status */
  --primary-foreground: #0A0A0C;  /* 12.86:1 — near-black NOT white on fills */
  --secondary: color-mix(in srgb, #EDEDF0 8%, #0A0A0C);
  --secondary-foreground: #EDEDF0;
  --accent: color-mix(in srgb, #EDEDF0 8%, #0A0A0C);
  --accent-foreground: #EDEDF0;
  --destructive: #FB7185;         /* Clip — critical/destructive */
  --destructive-foreground: #0A0A0C;

  /* DJ-specific signal layer */
  --signal-go: #CCFF00;           /* booked, paid, Saturday sold — the reward */
  --signal-go-foreground: #0A0A0C;
  --signal-late: #FBBF24;         /* your move, overdue */
  --signal-late-foreground: #0A0A0C;
  --signal-critical: #FB7185;     /* 48h+ unanswered, payment overdue, clash */
  --signal-critical-foreground: #0A0A0C;
  --signal-quiet: #94A3B8;        /* their move — nothing needed from you */
  --signal-quiet-foreground: #0A0A0C;
  --signal-live: #D948EF;         /* playing today — ONE use only */
  --signal-live-foreground: #0A0A0C;
  --signal-foreground: #0A0A0C;   /* label on any bright fill */

  /* ── surface hierarchy (depth via value steps — NO card shadows) ─ */
  --background-secondary: #060608;
  --surface-hover: color-mix(in srgb, #EDEDF0 6%, #0A0A0C);
  --surface-active: color-mix(in srgb, #EDEDF0 10%, #0A0A0C);
  --surface-elevated: #121215;

  --border-subtle: rgba(237,237,240,0.07);
  --border-muted: rgba(237,237,240,0.11);
  --border-strong: rgba(237,237,240,0.22);

  --foreground-secondary: #A0A0AB;  /* 7.64:1 on obsidian */

  --primary-hover: color-mix(in srgb, #00E5FF 85%, #ffffff);
  --primary-muted: color-mix(in srgb, #00E5FF 20%, #0A0A0C);
  --primary-soft: color-mix(in srgb, #00E5FF 10%, #0A0A0C);
  --primary-tint: color-mix(in srgb, #00E5FF 6%, #0A0A0C);

  --focus-ring: color-mix(in srgb, #00E5FF 40%, transparent);
  --error: #FB7185;
  --error-foreground: #0A0A0C;

  /* ── sidebar (sunk — sits darker than page ground) ─────────── */
  --sidebar: #060608;
  --sidebar-foreground: #EDEDF0;
  --sidebar-primary: #00E5FF;
  --sidebar-primary-foreground: #0A0A0C;
  --sidebar-accent: color-mix(in srgb, #EDEDF0 8%, #060608);
  --sidebar-accent-foreground: #EDEDF0;
  --sidebar-border: rgba(237,237,240,0.11);
  --sidebar-ring: #00E5FF;

  /* ── shape — instrument-grade, not consumer-soft ───────────── */
  --radius-sm: 3px;    /* badges, meter segments, pipeline cards, focus ring */
  --radius: 6px;       /* buttons, inputs, cards, rows — the default */
  --radius-lg: 10px;   /* panels, modals, sheets */
  --radius-xl: 12px;
  --radius-full: 9999px;  /* status dots, avatars, toggle only */
  --radius-none: 0;

  /* ── shadows — modals/dropdowns only; cards use value + hairlines ─ */
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.5);
  --shadow-md: 0 4px 16px rgba(0,0,0,0.55);
  --shadow-lg: 0 16px 40px rgba(0,0,0,0.65);
  --shadow-card: none;   /* cards never carry shadow on dark */
  --shadow-lift: none;
  --glow-cue: 0 0 22px -6px color-mix(in srgb, #00E5FF 70%, transparent);

  /* ── motion ────────────────────────────────────────────────── */
  --duration-fast: 120ms;
  --duration-normal: 180ms;
  --duration-slow: 280ms;
  --ease-standard: cubic-bezier(0.4, 0, 0.2, 1);
  --ease-accelerate: cubic-bezier(0.4, 0, 1, 1);
  --ease-decelerate: cubic-bezier(0, 0, 0.2, 1);

  /* ── success/warning aliases ───────────────────────────────── */
  --success: #CCFF00;
  --warning: #FBBF24;

  /* ── spacing ───────────────────────────────────────────────── */
  --spacing-base: 0.25rem;
}

/* ── DAYLIGHT (light, opt-in; mandatory for print/PDF) ────────────────── */
.light {
  --background: #F7F7F8;
  --foreground: #111114;
  --card: #FFFFFF;
  --card-foreground: #111114;
  --popover: #FFFFFF;
  --popover-foreground: #111114;
  --muted: #EFEFF1;
  --muted-foreground: #6B6B78;
  --border: rgba(17,17,20,0.13);
  --input: rgba(17,17,20,0.22);
  --primary: #0E7490;
  --primary-foreground: #FFFFFF;
  --ring: #0E7490;

  --signal-go: #3F6212;
  --signal-go-foreground: #FFFFFF;
  --signal-late: #B45309;
  --signal-late-foreground: #FFFFFF;
  --signal-critical: #BE123C;
  --signal-critical-foreground: #FFFFFF;
  --signal-quiet: #5A6472;
  --signal-quiet-foreground: #FFFFFF;
  --signal-live: #A21CAF;
  --signal-live-foreground: #FFFFFF;
  --signal-foreground: #FFFFFF;
  --destructive: #BE123C;
  --destructive-foreground: #FFFFFF;

  /* derived surfaces re-based to the light ground */
  --secondary: color-mix(in srgb, #111114 5%, #F7F7F8);
  --secondary-foreground: #111114;
  --accent: color-mix(in srgb, #111114 5%, #F7F7F8);
  --accent-foreground: #111114;
  --background-secondary: #EFEFF1;
  --surface-hover: color-mix(in srgb, #111114 5%, #F7F7F8);
  --surface-active: color-mix(in srgb, #111114 9%, #F7F7F8);
  --surface-elevated: #FFFFFF;
  --border-subtle: rgba(17,17,20,0.07);
  --border-muted: rgba(17,17,20,0.11);
  --border-strong: rgba(17,17,20,0.22);
  --foreground-secondary: #45454E;
  --primary-hover: color-mix(in srgb, #0E7490 85%, #000000);
  --primary-muted: color-mix(in srgb, #0E7490 20%, #F7F7F8);
  --primary-soft: color-mix(in srgb, #0E7490 10%, #F7F7F8);
  --primary-tint: color-mix(in srgb, #0E7490 6%, #F7F7F8);
  --focus-ring: color-mix(in srgb, #0E7490 40%, transparent);

  --sidebar: #EFEFF1;
  --sidebar-foreground: #111114;
  --sidebar-primary: #0E7490;
  --sidebar-primary-foreground: #FFFFFF;
  --sidebar-accent: color-mix(in srgb, #111114 5%, #EFEFF1);
  --sidebar-accent-foreground: #111114;
  --sidebar-border: rgba(17,17,20,0.13);
  --sidebar-ring: #0E7490;

  --glow-cue: 0 0 0 3px color-mix(in srgb, #0E7490 22%, transparent);
  --shadow-card: 0 1px 2px rgba(0,0,0,0.06);
  --success: #3F6212;
  --warning: #B45309;
  --error: #BE123C;
  --error-foreground: #FFFFFF;
}
