:root {
  /* Colors - Dark theme (default) */
  --color-background: #0d0d0d;
  --color-surface: #141414;
  --color-surface-raised: #1d1d1d;
  --color-surface-elevated: #262626;
  /* Subtle surface (footer rows, muted areas) */
  --color-surface-subtle: var(--color-surface-raised);
  --color-surface-hover: rgba(255, 255, 255, 0.05);
  
  /* Border colors */
  --color-border: rgba(255, 255, 255, 0.1);
  --color-border-light: rgba(255, 255, 255, 0.05);
  --color-border-hover: rgba(255, 255, 255, 0.2);
  --color-border-subtle: rgba(255, 255, 255, 0.08);
  
  /* Typography colors */
  --color-text: rgba(255, 255, 255, 0.95);
  --color-text-muted: rgba(255, 255, 255, 0.7);
  --color-text-subtle: rgba(255, 255, 255, 0.5);
  /* Back-compat alias */
  --color-text-secondary: var(--color-text-muted);
  --color-text-emphasis: rgba(255, 255, 255, 0.98);
  
  /* Status colors */
  --color-primary: #7c3aed;
  --color-primary-hover: #6d28d9;
  --color-primary-surface: rgba(124, 58, 237, 0.1);
  --color-primary-border: rgba(124, 58, 237, 0.3);
  
  --color-success: #16a34a;
  --color-success-surface: rgba(22, 163, 74, 0.1);
  --color-success-50: rgba(22, 163, 74, 0.05);
  --color-success-200: rgba(22, 163, 74, 0.2);
  --color-success-700: #15803d;
  
  --color-error: #dc2626;
  --color-error-surface: rgba(220, 38, 38, 0.1);
  --color-error-50: rgba(220, 38, 38, 0.05);
  --color-error-200: rgba(220, 38, 38, 0.2);
  --color-error-700: #b91c1c;

  --color-warning: #f59e0b;
  --color-warning-surface: rgba(245, 158, 11, 0.1);
  --color-warning-700: #b45309;

  /* Badge color variants for mode/status badges */
  --color-green-100: rgba(22, 163, 74, 0.1);
  --color-green-800: #15803d;
  --color-blue-100: rgba(59, 130, 246, 0.1);
  --color-blue-800: #1e40af;
  --color-purple-100: rgba(124, 58, 237, 0.1);
  --color-purple-800: #5b21b6;
  --color-gray-100: rgba(128, 128, 128, 0.1);
  --color-gray-600: #737373;

  /* Utility color aliases */
  --color-danger: var(--color-error);
  --color-danger-surface: var(--color-error-surface);
  --color-danger-700: var(--color-error-700);

  /* Overlay colors */
  --color-overlay: rgba(0, 0, 0, 0.5);
  --color-overlay-light: rgba(0, 0, 0, 0.3);

  /* Gradient colors for icons */
  --gradient-persona: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  --gradient-memory: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
  --gradient-context: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
  --gradient-stats: linear-gradient(135deg, #43e97b 0%, #38f9d7 100%);
  --gradient-status: linear-gradient(135deg, #fa709a 0%, #fee140 100%);

  /* Typography scale */
  --text-xs: 0.75rem;    /* 12px */
  --text-sm: 0.875rem;   /* 14px */
  --text-base: 1rem;     /* 16px */
  --text-lg: 1.125rem;   /* 18px */
  --text-xl: 1.25rem;    /* 20px */
  --text-2xl: 1.5rem;    /* 24px */

  /* Font weights */
  --font-normal: 400;
  --font-medium: 500;
  --font-semibold: 600;
  --font-bold: 700;

  /* Line heights */
  --leading-normal: 1.5;
  --leading-relaxed: 1.625;
  --leading-loose: 2;

  /* Spacing scale (unchanged) */
  --spacing-xs: 0.25rem;
  --spacing-sm: 0.5rem;
  --spacing-md: 0.75rem;
  --spacing-lg: 1rem;
  --spacing-xl: 1.5rem;
  --spacing-2xl: 2rem;

  /* Border radius */
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --radius-full: 9999px;

  /* Breakpoints */
  --breakpoint-mobile: 768px;
  --breakpoint-tablet: 1200px;
  
  /* Layout */
  --nav-width: 240px;
  --sidebar-width: 300px;
  --header-height: 48px;
  
  /* Z-index scale */
  --z-header: 10;
  --z-modal: 50;
  --z-tooltip: 40;
  --z-dropdown: 30;

  /* Message specific */
  --message-max-width: 85%;
  
  /* Shadow colors */
  --shadow-color: rgba(0, 0, 0, 0.2);
  --shadow-color-strong: rgba(0, 0, 0, 0.3);

  /* Shadow tokens */
  --shadow-sm: 0 1px 2px var(--shadow-color);
  --shadow-md: 0 4px 8px var(--shadow-color);
  --shadow-lg: 0 12px 24px var(--shadow-color-strong);
}

/* Light theme overrides */
html[data-theme="light"] {
  --color-background: #ffffff;
  --color-surface: #f8f8f8;
  --color-surface-raised: #f1f1f1;
  --color-surface-elevated: #e8e8e8;
  --color-surface-subtle: var(--color-surface);
  --color-surface-hover: rgba(0, 0, 0, 0.05);
  
  --color-border: rgba(0, 0, 0, 0.1);
  --color-border-light: rgba(0, 0, 0, 0.05);
  --color-border-hover: rgba(0, 0, 0, 0.15);
  --color-border-subtle: rgba(0, 0, 0, 0.08);
  
  --color-text: rgba(0, 0, 0, 0.9);
  --color-text-muted: rgba(0, 0, 0, 0.7);
  --color-text-subtle: rgba(0, 0, 0, 0.5);
  --color-text-secondary: var(--color-text-muted);
  --color-text-emphasis: rgba(0, 0, 0, 0.92);
  
  --shadow-color: rgba(0, 0, 0, 0.1);
  --shadow-color-strong: rgba(0, 0, 0, 0.15);
  --shadow-sm: 0 1px 2px var(--shadow-color);
  --shadow-md: 0 4px 8px var(--shadow-color);
  --shadow-lg: 0 12px 24px var(--shadow-color-strong);
  
  /* Status colors remain the same, but surfaces are adjusted */
  --color-primary-surface: rgba(124, 58, 237, 0.08);
  --color-primary-border: rgba(124, 58, 237, 0.25);
  --color-success-surface: rgba(22, 163, 74, 0.08);
  --color-error-surface: rgba(220, 38, 38, 0.08);
  --color-warning-surface: rgba(245, 158, 11, 0.08);

  /* Overlay colors for light theme */
  --color-overlay: rgba(0, 0, 0, 0.3);
  --color-overlay-light: rgba(0, 0, 0, 0.15);
}

/* Support for older theme class approach - for backwards compatibility */
.theme-light {
  --color-background: #ffffff;
  --color-surface: #f8f8f8;
  --color-surface-raised: #f1f1f1;
  --color-surface-elevated: #e8e8e8;
  --color-surface-subtle: var(--color-surface);
  --color-surface-hover: rgba(0, 0, 0, 0.05);
  
  --color-border: rgba(0, 0, 0, 0.1);
  --color-border-light: rgba(0, 0, 0, 0.05);
  --color-border-hover: rgba(0, 0, 0, 0.15);
  --color-border-subtle: rgba(0, 0, 0, 0.08);
  
  --color-text: rgba(0, 0, 0, 0.9);
  --color-text-muted: rgba(0, 0, 0, 0.7);
  --color-text-subtle: rgba(0, 0, 0, 0.5);
  --color-text-secondary: var(--color-text-muted);
  --color-text-emphasis: rgba(0, 0, 0, 0.92);
  
  --shadow-color: rgba(0, 0, 0, 0.1);
  --shadow-color-strong: rgba(0, 0, 0, 0.15);
  --shadow-sm: 0 1px 2px var(--shadow-color);
  --shadow-md: 0 4px 8px var(--shadow-color);
  --shadow-lg: 0 12px 24px var(--shadow-color-strong);
  
  /* Status colors remain the same, but surfaces are adjusted */
  --color-primary-surface: rgba(124, 58, 237, 0.08);
  --color-primary-border: rgba(124, 58, 237, 0.25);
  --color-success-surface: rgba(22, 163, 74, 0.08);
  --color-error-surface: rgba(220, 38, 38, 0.08);
}

/* Dark theme explicit class (for forced dark mode) */
.theme-dark {
  /* Same as root variables */
} 