/* ─────────────────────────────────────────────────────
   Atlas — Design Tokens
   Single source of truth for colors, spacing, shadows,
   typography, transitions, and z-index.

   Breakpoint reference (cannot be CSS vars):
     sm:  640px
     md:  768px
     lg:  992px
     xl: 1200px
   ───────────────────────────────────────────────────── */

:root {
  /* ── Primary palette ─────────────────────────────── */
  --ynk-primary: #3b00ff;
  --ynk-primary-hover: #2f00cc;
  --ynk-primary-light: #f0ecff;
  --ynk-primary-subtle: rgba(59, 0, 255, 0.08);

  /* ── Semantic colors ─────────────────────────────── */
  --ynk-success: #16a34a;
  --ynk-success-light: #f0fdf4;
  --ynk-success-border: #bbf7d0;
  --ynk-success-text: #15803d;

  --ynk-warning: #f59e0b;
  --ynk-warning-light: #fffbeb;
  --ynk-warning-border: #fde68a;
  --ynk-warning-text: #b45309;

  --ynk-danger: #dc2626;
  --ynk-danger-light: #fef2f2;
  --ynk-danger-border: #fecaca;
  --ynk-danger-text: #b91c1c;

  --ynk-info: #2563eb;
  --ynk-info-light: #eff6ff;
  --ynk-info-border: #bfdbfe;
  --ynk-info-text: #1d4ed8;

  /* ── Surface & text ──────────────────────────────── */
  --ynk-bg: #ffffff;
  --ynk-surface: #ffffff;
  --ynk-surface-secondary: #f8fafc;
  --ynk-surface-hover: #f3f4f6;
  --ynk-surface-active: #eef2f7;
  --ynk-border: #dce3ef;
  --ynk-border-light: #e5e7eb;
  --ynk-border-heavy: #d1d5db;
  --ynk-text: #111827;
  --ynk-text-secondary: #374151;
  --ynk-text-muted: #4b5563;
  --ynk-text-subtle: #6b7280;
  --ynk-text-faint: #64748b;

  /* ── Disabled states ─────────────────────────────── */
  --ynk-disabled-bg: #e5e7eb;
  --ynk-disabled-text: #6b7280;
  --ynk-disabled-border: #d1d5db;

  /* ── Overlay ─────────────────────────────────────── */
  --ynk-overlay: rgba(0, 0, 0, 0.35);
  --ynk-tooltip-bg: #1e293b;
  --ynk-tooltip-text: #ffffff;

  /* ── Spacing scale (4px base) ────────────────────── */
  --ynk-space-1: 0.25rem;   /*  4px */
  --ynk-space-2: 0.5rem;    /*  8px */
  --ynk-space-3: 0.75rem;   /* 12px */
  --ynk-space-4: 1rem;      /* 16px */
  --ynk-space-5: 1.25rem;   /* 20px */
  --ynk-space-6: 1.5rem;    /* 24px */
  --ynk-space-8: 2rem;      /* 32px */
  --ynk-space-10: 2.5rem;   /* 40px */
  --ynk-space-12: 3rem;     /* 48px */
  --ynk-space-16: 4rem;     /* 64px */

  /* ── Typography scale ────────────────────────────── */
  --ynk-font: "Sora", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    "Helvetica Neue", Arial, sans-serif;

  --ynk-text-2xs: 0.6875rem;  /* 11px — badges, micro-labels */
  --ynk-text-xs: 0.75rem;     /* 12px — captions, table headers */
  --ynk-text-sm: 0.8125rem;   /* 13px — compact tables, small labels */
  --ynk-text-base: 0.875rem;  /* 14px — body default */
  --ynk-text-md: 0.95rem;     /* 15px — subtitles, nav links */
  --ynk-text-lg: 1.15rem;     /* 18px — section headings */
  --ynk-text-xl: 1.35rem;     /* 22px — page titles (mobile) */
  --ynk-text-2xl: 1.6rem;     /* 26px — page titles (desktop) */

  --ynk-font-normal: 400;
  --ynk-font-medium: 500;
  --ynk-font-semibold: 600;
  --ynk-font-bold: 700;

  --ynk-leading-tight: 1.2;
  --ynk-leading-normal: 1.5;
  --ynk-leading-relaxed: 1.6;

  /* ── Border radius scale ─────────────────────────── */
  --ynk-radius-sm: 6px;
  --ynk-radius-md: 10px;
  --ynk-radius-lg: 12px;
  --ynk-radius-xl: 18px;
  --ynk-radius-pill: 999px;

  /* ── Shadows ─────────────────────────────────────── */
  --ynk-shadow-xs: 0 1px 2px rgba(15, 23, 42, 0.04);
  --ynk-shadow-sm: 0 1px 3px rgba(15, 23, 42, 0.06);
  --ynk-shadow-md: 0 4px 10px rgba(15, 23, 42, 0.05);
  --ynk-shadow-lg: 0 8px 20px rgba(15, 23, 42, 0.06);
  --ynk-shadow-xl: 0 12px 24px rgba(15, 23, 42, 0.08);
  --ynk-shadow-brand-bar: 0 6px 16px rgba(15, 23, 42, 0.08);
  --ynk-shadow-dropdown: 0 8px 24px rgba(0, 0, 0, 0.12);
  --ynk-shadow-elevated: 0 18px 40px rgba(15, 23, 42, 0.16);
  --ynk-shadow-primary: 0 10px 20px rgba(76, 29, 255, 0.18);
  --ynk-shadow-focus-ring: 0 0 0 3px rgba(59, 0, 255, 0.25);

  /* ── Transitions ─────────────────────────────────── */
  --ynk-duration-fast: 120ms;
  --ynk-duration-base: 200ms;
  --ynk-duration-slow: 300ms;
  --ynk-ease-default: ease;
  --ynk-ease-out: cubic-bezier(0.4, 0, 0.2, 1);

  /* ── Z-index scale ───────────────────────────────── */
  --ynk-z-base: 1;
  --ynk-z-dropdown: 100;
  --ynk-z-sticky: 200;
  --ynk-z-sidebar: 300;
  --ynk-z-header: 400;
  --ynk-z-overlay: 500;
  --ynk-z-modal: 600;
  --ynk-z-toast: 700;
}
