/* Global dark-mode: update base CSS custom properties so every component that
   reads var(--color-text) / var(--color-bg) etc. gets dark-mode values on ALL
   pages, not just single.php (where single.css used to define these). */
body.dark-mode {
  background-color: #000000;
  --color-text: rgba(255, 255, 255, 0.92);
  --color-text-muted: rgba(255, 255, 255, 0.55);
  --color-text-light: rgba(255, 255, 255, 0.38);
  --color-border: rgba(255, 255, 255, 0.1);
  --color-bg: #111827;
  --color-bg-alt: rgba(255, 255, 255, 0.05);
}

:root {
  /* ── Colors ─────────────────────────────────── */
  --color-primary: #2563eb;
  --color-primary-dark: #1d4ed8;
  --color-secondary: #1e40af;
  --color-accent: #f59e0b;
  --color-accent-dark: #d97706;
  --color-success: #16a34a;
  --color-danger: #dc2626;

  --color-text: #111827;
  --color-text-muted: #6b7280;
  --color-text-light: #9ca3af;
  --color-text-white: #ffffff;

  --color-bg: #ffffff;
  --color-bg-alt: #f9fafb;
  --color-bg-dark: #111827;
  --color-border: #e5e7eb;
  --color-border-dark: #d1d5db;

  /* ── Typography ─────────────────────────────── */
  --font-primary:
    "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-secondary: "Inter", sans-serif;

  --font-size-xs: 0.75rem; /* 12px */
  --font-size-sm: 0.875rem; /* 14px */
  --font-size-base: 1rem; /* 16px */
  --font-size-md: 1.125rem; /* 18px */
  --font-size-lg: 1.25rem; /* 20px */
  --font-size-xl: 1.5rem; /* 24px */
  --font-size-2xl: 1.875rem; /* 30px */
  --font-size-3xl: 2.25rem; /* 36px */
  --font-size-4xl: 3rem; /* 48px */

  --font-weight-normal: 400;
  --font-weight-medium: 500;
  --font-weight-semi: 600;
  --font-weight-bold: 700;
  --font-weight-black: 900;

  --line-height-tight: 1.2;
  --line-height-base: 1.6;
  --line-height-loose: 1.8;

  /* ── Spacing ────────────────────────────────── */
  --spacing-1: 4px;
  --spacing-2: 8px;
  --spacing-3: 12px;
  --spacing-4: 16px;
  --spacing-5: 20px;
  --spacing-6: 24px;
  --spacing-8: 32px;
  --spacing-10: 40px;
  --spacing-12: 48px;
  --spacing-16: 64px;
  --spacing-20: 80px;
  --spacing-24: 96px;
  --spacing-32: 128px;

  /* ── Layout ─────────────────────────────────── */
  --container-max: 1280px;
  --container-padding: var(--spacing-6);

  /* ── Border radius ──────────────────────────── */
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --radius-xl: 16px;
  --radius-2xl: 24px;
  --radius-full: 9999px;

  /* ── Shadows ────────────────────────────────── */
  --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
  --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
  --shadow-lg:
    0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
  --shadow-xl:
    0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1);

  /* ── Transitions ────────────────────────────── */
  --transition-fast: 0.15s ease;
  --transition-base: 0.25s ease;
  --transition-slow: 0.4s ease;

  /* ── Z-index ────────────────────────────────── */
  --z-base: 1;
  --z-dropdown: 100;
  --z-sticky: 200;
  --z-modal: 300;
  --z-toast: 400;
}
