/* =========================================================
   Little Learners Path — Design Tokens (Task 14 + Task 23D)
   Single source for public + Admin shared variables.
   Brand CMS may override --brand-primary / --brand-secondary on <html>.

   Public: --brand-*, --primary*, --secondary, --accent, --pastel-*, --tint-*,
           --bg, --surface*, --text*, --border, --shadow-*, --radius-*,
           --space-*, --font-*, --transition*, --max-width, --focus-ring, --status-*
   Admin:  --admin-* (shell/panel); status pills reuse --status-*
   Dark readiness (unused until theme toggle): --*-inverse
========================================================= */

:root {
    /* Brand anchors (overridable) — coral + sky */
    --brand-primary: #ff4d4d;
    --brand-secondary: #0ea5e9;
    --primary: var(--brand-primary);
    --primary-dark: #e63636;
    --primary-soft: #fff1ef;
    --secondary: var(--brand-secondary);
    --secondary-soft: #eaf6fc;
    --accent: #f0c14a;
    --accent-soft: #fff8e6;

    /* Pastel palette (Task 23D) — soft accents, not full-bleed fills */
    --pastel-coral: #ff7a7a;
    --pastel-sky: #5bb8e8;
    --pastel-mint: #6fbf9a;
    --pastel-sunshine: #f0c14a;
    --pastel-peach: #f0a878;
    --pastel-lavender: #a78bc9;
    --pastel-cream: #f7f2ea;

    /* Soft section / badge tints (readable with --text) */
    --tint-coral: #fff1ef;
    --tint-sky: #eaf6fc;
    --tint-mint: #eaf7f1;
    --tint-sunshine: #fff8e6;
    --tint-peach: #fff0e6;
    --tint-lavender: #f3effa;

    /* Ink on pastel accents (badges / chips) */
    --ink-coral: #c62828;
    --ink-sky: #0369a1;
    --ink-mint: #1b6b4a;
    --ink-sunshine: #9a6700;
    --ink-peach: #9a4b1c;
    --ink-lavender: #5b3d8a;

    /* Surfaces — warm cream paper + white cards */
    --bg: var(--pastel-cream);
    --surface: #ffffff;
    --surface-muted: #efeae3;
    --white: #ffffff;

    /* Text — accessible dark ink */
    --text: #1a2332;
    --text-muted: #5b6575;
    --light-text: var(--text-muted);

    /* Borders & elevation */
    --border: rgba(26, 35, 50, 0.08);
    --border-strong: rgba(26, 35, 50, 0.14);
    --shadow-sm: 0 4px 12px rgba(26, 35, 50, 0.05);
    --shadow-md: 0 10px 28px rgba(26, 35, 50, 0.08);
    --shadow-lg: 0 18px 40px rgba(26, 35, 50, 0.12);
    --shadow-hover: 0 14px 32px rgba(255, 77, 77, 0.16);

    /* Radius */
    --radius-sm: 12px;
    --radius-md: 16px;
    --radius-lg: 24px;
    --radius-pill: 999px;

    /* Spacing scale */
    --space-1: 4px;
    --space-2: 8px;
    --space-3: 12px;
    --space-4: 16px;
    --space-5: 24px;
    --space-6: 32px;
    --space-7: 48px;
    --space-8: 64px;

    /* Typography — single brand family (Nunito already loaded in layouts) */
    --font-family: "Nunito", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    --font-family-display: var(--font-family);

    --font-weight-regular: 400;
    --font-weight-medium: 600;
    --font-weight-semibold: 700;
    --font-weight-bold: 800;

    /* Scale (rem) — restrained, readable early-learning UI */
    --font-size-xs: 0.75rem;                                    /* captions / meta */
    --font-size-sm: 0.875rem;                                   /* secondary / small */
    --font-size-body: 1.0625rem;                                /* ~17px body */
    --font-size-md: 1.125rem;                                   /* lead / intro */
    --font-size-lg: 1.25rem;                                    /* large body / CTA text */
    --font-size-h3: clamp(1.15rem, 1.6vw + 0.75rem, 1.35rem);   /* card / subsection */
    --font-size-h2: clamp(1.45rem, 2vw + 0.7rem, 1.85rem);      /* section titles */
    --font-size-h1: clamp(1.7rem, 2.4vw + 0.75rem, 2.35rem);    /* page titles */
    --font-size-display: clamp(1.95rem, 3.2vw + 0.6rem, 2.75rem); /* hero only */

    /* Legacy aliases used across site.css / admin.css */
    --font-size-small: var(--font-size-sm);

    --line-height-tight: 1.2;
    --line-height-heading: 1.28;
    --line-height-body: 1.65;
    --line-height-relaxed: 1.75;

    --letter-spacing-tight: -0.02em;
    --letter-spacing-normal: 0;
    --letter-spacing-wide: 0.04em;

    --content-measure: 65ch;

    /* Admin (same family, slightly denser) */
    --admin-font-size-body: 0.9375rem;
    --admin-font-size-nav: 0.9rem;
    --admin-font-size-label: 0.8rem;
    --admin-font-size-title: clamp(1.35rem, 1.5vw + 0.8rem, 1.7rem);
    --admin-font-size-stat: 1.5rem;

    /* Motion */
    --transition-fast: 150ms ease;
    --transition: 250ms ease;
    --transition-slow: 350ms ease;

    /* Layout */
    --max-width: 1200px;
    --admin-max-width: 1360px;
    --header-height: 76px;

    /* Focus */
    --focus-ring: 0 0 0 3px rgba(255, 77, 77, 0.35);

    /* Status */
    --status-success: #0a7a32;
    --status-success-bg: #e8f7ee;
    --status-warning: #b45309;
    --status-warning-bg: #fff7ed;
    --status-danger: #b00020;
    --status-danger-bg: #fdecee;
    --status-info: #0369a1;
    --status-info-bg: #e0f2fe;
    --status-draft: #64748b;
    --status-draft-bg: #f1f5f9;
    --status-published: #0a7a32;
    --status-published-bg: #e8f7ee;
    --status-archived: #7c3aed;
    --status-archived-bg: #f3e8ff;

    /* Admin shell — refined glass */
    --admin-bg: #e8eef8;
    --admin-bg-glow: radial-gradient(ellipse 80% 50% at 0% 0%, rgba(255, 77, 77, 0.08), transparent 55%),
        radial-gradient(ellipse 70% 45% at 100% 0%, rgba(14, 165, 233, 0.1), transparent 50%),
        linear-gradient(160deg, #eef3fa 0%, #e4ebf6 100%);
    --admin-sidebar-bg: rgba(255, 255, 255, 0.72);
    --admin-sidebar-solid: rgba(255, 255, 255, 0.94);
    --admin-topbar-bg: rgba(255, 255, 255, 0.78);
    --admin-panel: rgba(255, 255, 255, 0.86);
    --admin-panel-solid: #ffffff;
    --admin-border: rgba(26, 35, 50, 0.1);
    --admin-glass-border: rgba(255, 255, 255, 0.55);
    --admin-text: #1a2332;
    --admin-muted: #5b6575;
    --admin-sidebar-width: 260px;
    --admin-blur: 16px;

    /* Dark-mode readiness (unused aliases — no toggle in Task 14) */
    --bg-inverse: #0f172a;
    --surface-inverse: #1e293b;
    --text-inverse: #f8fafc;
    --border-inverse: rgba(248, 250, 252, 0.12);
}
