/* ==========================================================================
   THEME — Variables de couleurs, typographie, ombres, rayons
   ========================================================================== */

:root {
    /* Palette — Thème clair (par défaut) */
    --bg-primary: #f7f8fb;
    --bg-secondary: #ffffff;
    --bg-tertiary: #eef1f6;
    --bg-elevated: #ffffff;

    --surface: #ffffff;
    --surface-hover: #f0f3f9;
    --surface-active: #e4e9f2;

    --border-subtle: #e4e7ec;
    --border-default: #d0d5dd;
    --border-strong: #98a2b3;

    --text-primary: #101828;
    --text-secondary: #475467;
    --text-tertiary: #667085;
    --text-inverse: #ffffff;

    --accent: #6366f1;
    --accent-hover: #4f46e5;
    --accent-soft: #eef2ff;

    --success: #10b981;
    --warning: #f59e0b;
    --danger: #ef4444;
    --danger-soft: #fef2f2;

    /* Typographie */
    --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
                 "Helvetica Neue", Arial, sans-serif;
    --font-mono: "JetBrains Mono", "Fira Code", "Cascadia Code",
                 Consolas, Menlo, monospace;

    --fs-xs: 0.75rem;
    --fs-sm: 0.875rem;
    --fs-md: 1rem;
    --fs-lg: 1.125rem;
    --fs-xl: 1.25rem;

    /* Espacements */
    --sp-1: 0.25rem;
    --sp-2: 0.5rem;
    --sp-3: 0.75rem;
    --sp-4: 1rem;
    --sp-5: 1.25rem;
    --sp-6: 1.5rem;
    --sp-8: 2rem;

    /* Rayons */
    --radius-sm: 6px;
    --radius-md: 8px;
    --radius-lg: 12px;
    --radius-xl: 16px;

    /* Ombres */
    --shadow-xs: 0 1px 2px rgba(16, 24, 40, 0.05);
    --shadow-sm: 0 1px 3px rgba(16, 24, 40, 0.08), 0 1px 2px rgba(16, 24, 40, 0.04);
    --shadow-md: 0 4px 8px -2px rgba(16, 24, 40, 0.1), 0 2px 4px -2px rgba(16, 24, 40, 0.06);
    --shadow-lg: 0 12px 24px -6px rgba(16, 24, 40, 0.12), 0 4px 8px -2px rgba(16, 24, 40, 0.05);

    /* Transitions */
    --t-fast: 120ms cubic-bezier(0.4, 0, 0.2, 1);
    --t-base: 200ms cubic-bezier(0.4, 0, 0.2, 1);
    --t-slow: 300ms cubic-bezier(0.4, 0, 0.2, 1);

    /* Layout */
    --header-height: 64px;
    --footer-height: 36px;
}

/* Thème sombre */
[data-theme="dark"] {
    --bg-primary: #0f1419;
    --bg-secondary: #161b22;
    --bg-tertiary: #1c222b;
    --bg-elevated: #1c222b;

    --surface: #1c222b;
    --surface-hover: #242b35;
    --surface-active: #2c3440;

    --border-subtle: #262d38;
    --border-default: #363d49;
    --border-strong: #4a5260;

    --text-primary: #f0f3f8;
    --text-secondary: #b1bac4;
    --text-tertiary: #8b949e;
    --text-inverse: #0f1419;

    --accent: #818cf8;
    --accent-hover: #a5b4fc;
    --accent-soft: rgba(129, 140, 248, 0.15);

    --danger-soft: rgba(239, 68, 68, 0.12);

    --shadow-xs: 0 1px 2px rgba(0, 0, 0, 0.3);
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.4), 0 1px 2px rgba(0, 0, 0, 0.2);
    --shadow-md: 0 4px 8px -2px rgba(0, 0, 0, 0.4), 0 2px 4px -2px rgba(0, 0, 0, 0.2);
    --shadow-lg: 0 12px 24px -6px rgba(0, 0, 0, 0.5), 0 4px 8px -2px rgba(0, 0, 0, 0.25);
}
