/* ============================================
   BLOOM AI UNIVERSITY — DESIGN TOKENS
   ============================================
   The single source of truth for the design
   system. Loaded FIRST on every page, before
   styles.css and any page-local styles.

   Rules of use:
   - No page may define its own :root color,
     type, or spacing custom properties.
   - Tokens ending in -deep are the ONLY legal
     variants for text under 24px on light
     backgrounds (WCAG 2.1 AA).
   - --gold and --emerald are decorative /
     dark-background colors. Never body text
     on white.
   ============================================ */
:root {
    /* Primary Brand Colors */
    --navy: #1B3A5F;
    --navy-dark: #152D4A;
    --navy-light: #2A4D73;
    --navy-ink: #10243C;            /* deepest band background (covenant, hero base) */

    /* Accent — Gold (the bloom, the credential) */
    --gold: #FFD700;                /* on navy only (8.8:1) — never text on white */
    --gold-dark: #E6C200;
    --gold-light: #FFE44D;
    --gold-deep: #8C6A00;           /* gold semantics as text/icons on light bg (≥4.5:1) */
    --gold-wash: #FFF9E0;           /* light credential-card tint; pair with --gold-deep text */

    /* Accent — Emerald (growth, recovery, the living system) */
    --emerald: #00C851;             /* decorative / dark-bg only */
    --emerald-dark: #00A844;
    --emerald-light: #33D472;
    --emerald-deep: #007A32;        /* emerald text/icons on light bg (≥4.5:1) */

    /* Accent — Purple (judgment, depth of thought — sparingly) */
    --purple: #8B5CF6;
    --purple-dark: #7C4DDB;
    --purple-light: #A78BFA;
    --purple-deep: #6D3FD8;         /* purple text on light bg */

    /* Accent — Orange (assessment, attention; matches Cultivate LMS) */
    --orange: #E67E22;
    --orange-dark: #D35400;
    --orange-light: #F39C12;
    --orange-deep: #B35F0E;         /* orange text on light bg */

    /* Neutrals */
    --white: #FFFFFF;
    --off-white: #FAFAFA;
    --light-gray: #F3F4F6;
    --mid-gray: #E5E7EB;
    --gray: #6B7280;
    --dark-gray: #4B5563;
    --charcoal: #374151;
    --near-black: #1F2937;

    /* Semantic Colors */
    --success: #00C851;
    --warning: #FFB800;
    --error: #DC2626;
    --info: #3B82F6;

    /* Typography */
    --font-primary: 'Playfair Display', Georgia, serif;
    --font-secondary: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    /* Data/captions: Inter with tabular figures — no third typeface.
       Usage: font-family: var(--font-secondary); font-variant-numeric: tabular-nums; */

    /* Type Scale (Major Second) */
    --text-xs: 0.75rem;
    --text-sm: 0.875rem;
    --text-base: 1rem;
    --text-lg: 1.125rem;
    --text-xl: 1.25rem;
    --text-2xl: 1.5rem;
    --text-3xl: 1.875rem;
    --text-4xl: 2.25rem;
    --text-5xl: 3rem;
    --text-6xl: 3.75rem;
    --text-7xl: 4.5rem;
    --text-display: clamp(2.5rem, 5.5vw, 4.5rem);   /* hero theses */

    /* Spacing Scale */
    --space-1: 0.25rem;
    --space-2: 0.5rem;
    --space-3: 0.75rem;
    --space-4: 1rem;
    --space-5: 1.25rem;
    --space-6: 1.5rem;
    --space-8: 2rem;
    --space-10: 2.5rem;
    --space-12: 3rem;
    --space-16: 4rem;
    --space-20: 5rem;
    --space-24: 6rem;
    --space-32: 8rem;

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

    /* Shadows */
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.07);
    --shadow-lg: 0 10px 15px rgba(0, 0, 0, 0.1);
    --shadow-xl: 0 20px 40px rgba(0, 0, 0, 0.15);
    --shadow-2xl: 0 25px 50px rgba(0, 0, 0, 0.15);
    --shadow-glow-emerald: 0 0 20px rgba(0, 200, 81, 0.3);
    --shadow-glow-purple: 0 0 20px rgba(139, 92, 246, 0.3);
    --shadow-glow-gold: 0 0 20px rgba(255, 215, 0, 0.3);

    /* Transitions & Motion */
    --transition-fast: 150ms ease;
    --transition-base: 300ms ease;
    --transition-slow: 500ms ease;
    --transition-bounce: 500ms cubic-bezier(0.68, -0.55, 0.265, 1.55);
    --motion-draw: 1400ms cubic-bezier(0.65, 0, 0.35, 1);   /* growth-line draw-in */

    /* Journey stage colors (Seed -> Radiant) — a colored maturation,
       used by the Bloom Wheel, journey spines, tier accents, etc. */
    --stage-seed: #00C851;       /* emerald — germination */
    --stage-grow: #2DD4A7;       /* teal-emerald — early growth */
    --stage-flourish: #8B5CF6;   /* purple — depth of thought */
    --stage-thrive: #E67E22;     /* orange — full strength */
    --stage-radiant: #FFD700;    /* gold — the bloom, the credential */

    /* Growth line (signature element) */
    --growthline-stroke: var(--emerald);
    --growthline-stroke-navy: rgba(255, 215, 0, 0.55);       /* gold-tint variant on navy */
    --growthline-band: rgba(0, 200, 81, 0.10);
    --growthline-band-navy: rgba(255, 215, 0, 0.07);

    /* Z-Index Scale */
    --z-dropdown: 100;
    --z-sticky: 200;
    --z-fixed: 300;
    --z-modal-backdrop: 400;
    --z-modal: 500;
    --z-tooltip: 600;
    --z-toast: 700;
    --z-mobile-nav: 999;

    /* Container */
    --container-max: 1200px;
    --container-padding: 1.5rem;
}

@media (max-width: 1024px) {
    :root { --container-padding: 1.25rem; }
}

@media (max-width: 768px) {
    :root { --container-padding: 1rem; }
}

/* ============================================
   REDUCED MOTION — global guard
   Components must ALSO render a complete static
   state; this guard is the backstop, not the plan.
   ============================================ */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}
