/* ========================================
   Variables — Design tokens (wireframe)
   Light & Dark mode via data-theme attribute
   ======================================== */

:root {
  /* ---- Spacing scale ---- */
  --space-xs: 0.5rem;    /* 8px */
  --space-sm: 1rem;      /* 16px */
  --space-md: 2rem;      /* 32px */
  --space-lg: 4rem;      /* 64px */
  --space-xl: 6rem;      /* 96px */
  --space-2xl: 8rem;     /* 128px */

  /* ---- Typography ---- */
  --font-heading: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --font-body: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'SFMono-Regular', 'SF Mono', ui-monospace, 'Cascadia Code', 'Roboto Mono', Menlo, Consolas, monospace;

  /* ---- Type scale (fluid with clamp) ---- */
  --text-xs: clamp(0.75rem, 0.7rem + 0.25vw, 0.875rem);
  --text-sm: clamp(0.875rem, 0.8rem + 0.35vw, 1rem);
  --text-base: clamp(1rem, 0.9rem + 0.5vw, 1.125rem);
  --text-lg: clamp(1.125rem, 1rem + 0.6vw, 1.375rem);
  --text-xl: clamp(1.25rem, 1rem + 1.2vw, 1.75rem);
  --text-2xl: clamp(1.75rem, 1.2rem + 2.5vw, 2.75rem);
  --text-3xl: clamp(2.25rem, 1.5rem + 3.5vw, 4rem);
  --text-4xl: clamp(3rem, 2rem + 5vw, 6rem);

  /* ---- Layout ---- */
  --container-max: 1200px;
  --container-padding: var(--space-sm);
  --nav-height: 56px;

  /* ---- Transitions ---- */
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --duration-fast: 200ms;
  --duration-normal: 400ms;
  --duration-slow: 600ms;

  /* ---- Border radius ---- */
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 16px;
  --radius-pill: 100px;
}

/* ---- Light theme (default) ---- */

[data-theme="light"] {
  --color-bg: #ffffff;
  --color-bg-alt: #f5f5f5;
  --color-surface: #e8e8e8;
  --color-text: #1a1a1a;
  --color-text-secondary: #666666;
  --color-text-muted: #999999;
  --color-accent: #333333;
  --color-accent-green: #3D5951;
  --color-border: #dddddd;
  --color-overlay: rgba(0, 0, 0, 0.6);
  --color-placeholder: #d0d0d0;

  /* Nav pill specific */
  --nav-bg: rgba(20, 20, 20, 0.45);
  --nav-text: #e0e0e0;
  --nav-text-hover: #ffffff;
  --nav-divider: rgba(255, 255, 255, 0.12);
  --nav-home-bg: #ffffff;
  --nav-home-icon: #1a1a1a;
}

/* ---- Dark theme ---- */

[data-theme="dark"] {
  --color-bg: #0e0e0e;
  --color-bg-alt: #161616;
  --color-surface: #222222;
  --color-text: #eeeeee;
  --color-text-secondary: #aaaaaa;
  --color-text-muted: #666666;
  --color-accent: #dddddd;
  --color-accent-green: #3D5951;
  --color-border: #2a2a2a;
  --color-overlay: rgba(0, 0, 0, 0.7);
  --color-placeholder: #2a2a2a;

  /* Nav pill specific */
  --nav-bg: rgba(20, 20, 20, 0.45);
  --nav-text: #aaaaaa;
  --nav-text-hover: #ffffff;
  --nav-divider: rgba(255, 255, 255, 0.1);
  --nav-home-bg: #ffffff;
  --nav-home-icon: #0e0e0e;
}
