/*
 * Playhead Design Tokens
 * 
 * Shared theme for all Playhead UIs:
 *   - Plugin WebView (src/ui/web/)
 *   - DSP Lab (tools/dsp-lab/web/)
 *   - Dev Tools (tools/dev-tools/public/)
 * 
 * Usage: @import or <link> this file, then use var(--token-name)
 * For dark mode: add class="dark" to <html> or <body>
 */

/* ============================================================================
   Light Mode (default)
   ============================================================================ */
:root {
  /* Core colors */
  --background: #ffffff;
  --foreground: #0a0a0a;
  
  /* Card/Panel surfaces */
  --card: #ffffff;
  --card-foreground: #0a0a0a;
  
  /* Popover/Dropdown surfaces */
  --popover: #ffffff;
  --popover-foreground: #0a0a0a;
  
  /* Brand colors (gold) */
  --primary: #ab8d66;
  --primary-foreground: #fafafa;
  --secondary: #ab8d66;
  --secondary-foreground: #ffffff;
  
  /* Muted/subtle elements */
  --muted: #f5f5f5;
  --muted-foreground: #737373;
  
  /* Accent (hover states, highlights) */
  --accent: #f5f5f5;
  --accent-foreground: #171717;
  
  /* Semantic colors */
  --destructive: #7f342a;
  --destructive-foreground: #ffffff;
  --success: #4D723D;
  --success-foreground: #ffffff;
  --info: #5dade2;
  --info-foreground: #171717;
  --warning: #fbbf24;
  --warning-foreground: #171717;
  
  /* Borders and inputs */
  --border: #e5e5e5;
  --input: #e5e5e5;
  --ring: #a1a1a1;
  
  /* Chart/visualization colors (gold gradient) */
  --chart-1: #ab8d66;
  --chart-2: #9e7f57;
  --chart-3: #917550;
  --chart-4: #765f41;
  --chart-5: #5c4a33;
  
  /* Sidebar */
  --sidebar: #fafafa;
  --sidebar-background: #fafafa;
  --sidebar-foreground: #0a0a0a;
  --sidebar-primary: #171717;
  --sidebar-primary-foreground: #fafafa;
  --sidebar-accent: #f5f5f5;
  --sidebar-accent-foreground: #171717;
  --sidebar-border: #e5e5e5;
  --sidebar-ring: #a1a1a1;

  /* Typography */
  --font-sans: Inter, ui-sans-serif, system-ui, sans-serif;
  --font-serif: ui-serif, Georgia, Cambria, "Times New Roman", Times, serif;
  --font-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
  
  /* Spacing & Radius */
  --radius: 0.5rem;
  --radius-sm: calc(var(--radius) - 4px);
  --radius-md: calc(var(--radius) - 2px);
  --radius-lg: var(--radius);
  --radius-xl: calc(var(--radius) + 4px);
  --spacing: 0.22rem;
  --tracking-normal: 0em;
  
  /* Shadows */
  --shadow-2xs: 0 1px 3px 0px hsl(0 0% 0% / 0.05);
  --shadow-xs: 0 1px 3px 0px hsl(0 0% 0% / 0.05);
  --shadow-sm: 0 1px 3px 0px hsl(0 0% 0% / 0.10), 0 1px 2px -1px hsl(0 0% 0% / 0.10);
  --shadow: 0 1px 3px 0px hsl(0 0% 0% / 0.10), 0 1px 2px -1px hsl(0 0% 0% / 0.10);
  --shadow-md: 0 1px 3px 0px hsl(0 0% 0% / 0.10), 0 2px 4px -1px hsl(0 0% 0% / 0.10);
  --shadow-lg: 0 1px 3px 0px hsl(0 0% 0% / 0.10), 0 4px 6px -1px hsl(0 0% 0% / 0.10);
  --shadow-xl: 0 1px 3px 0px hsl(0 0% 0% / 0.10), 0 8px 10px -1px hsl(0 0% 0% / 0.10);
  --shadow-2xl: 0 1px 3px 0px hsl(0 0% 0% / 0.25);

  /* Shadow decomposition (for programmatic access) */
  --shadow-x: 0;
  --shadow-y: 1px;
  --shadow-blur: 3px;
  --shadow-spread: 0px;
  --shadow-opacity: 0.1;
  --shadow-color: hsl(0 0% 0%);
}

/* ============================================================================
   Dark Mode
   Add class="dark" to <html> or <body> to activate
   ============================================================================ */
.dark {
  /* Core colors */
  --background: #0a0a0a;
  --foreground: #dad5ce;
  
  /* Card/Panel surfaces */
  --card: #171717;
  --card-foreground: #dad5ce;
  
  /* Popover/Dropdown surfaces */
  --popover: #262626;
  --popover-foreground: #dad5ce;
  
  /* Brand colors (gold) */
  --primary: #ab8d66;
  --primary-foreground: #171717;
  --secondary: #ab8d66;
  --secondary-foreground: #000000;
  
  /* Muted/subtle elements */
  --muted: #141414;
  --muted-foreground: #a5a19c;
  
  /* Accent (hover states, highlights) */
  --accent: #292929;
  --accent-foreground: #fafafa;
  
  /* Semantic colors */
  --destructive: #7f342a;
  --destructive-foreground: #fafafa;
  --success: #4D723D;
  --success-foreground: #ffffff;
  --info: #5dade2;
  --info-foreground: #171717;
  --warning: #fbbf24;
  --warning-foreground: #171717;
  
  /* Borders and inputs */
  --border: #282828;
  --input: #343434;
  --ring: #737373;
  
  /* Chart/visualization colors (gold gradient, lighter chart-5 for dark bg readability) */
  --chart-1: #ab8d66;
  --chart-2: #9e7f57;
  --chart-3: #917550;
  --chart-4: #765f41;
  --chart-5: #ba9a8e;

  /* Sidebar */
  --sidebar: #171717;
  --sidebar-background: #171717;
  --sidebar-foreground: #fafafa;
  --sidebar-primary: #ab8d66;
  --sidebar-primary-foreground: #fafafa;
  --sidebar-accent: #262626;
  --sidebar-accent-foreground: #fafafa;
  --sidebar-border: #282828;
  --sidebar-ring: #525252;
}
