/* ============================================================
   WASIL Admin v2 — design tokens
   Single source of truth for color, type, spacing, radii, shadows.
   Light + dark via [data-theme] on <html>. Every component reads
   from these vars; never hard-code colors.
============================================================ */

:root,
[data-theme="light"] {
  /* Surface */
  --bg:           #fafafa;
  --bg-elevated:  #ffffff;
  --bg-subtle:    #f5f5f5;
  --bg-muted:     #f0f0f0;
  --border:       #e8e8e8;
  --border-strong:#d4d4d4;

  /* Foreground */
  --fg:           #0a0a0a;
  --fg-muted:     #6b6b6b;
  --fg-subtle:    #9a9a9a;

  /* Brand — WASIL purple */
  --accent:       #7806FE;
  --accent-fg:    #ffffff;
  --accent-soft:  rgba(120, 6, 254, 0.08);
  --accent-hover: #6a05dd;

  /* Status */
  --success: #16a34a;  --success-soft: rgba(22, 163, 74, 0.10);
  --warning: #f59e0b;  --warning-soft: rgba(245, 158, 11, 0.10);
  --danger:  #dc2626;  --danger-soft:  rgba(220, 38, 38, 0.10);
  --info:    #0ea5e9;  --info-soft:    rgba(14, 165, 233, 0.10);

  /* Type */
  --font-sans: 'Outfit', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, monospace;

  /* Type scale */
  --text-xs:   11px;
  --text-sm:   13px;
  --text-base: 14px;
  --text-md:   15px;
  --text-lg:   17px;
  --text-xl:   20px;
  --text-2xl:  24px;
  --text-3xl:  32px;

  /* Spacing — 4px grid */
  --space-1:  4px;
  --space-2:  8px;
  --space-3:  12px;
  --space-4:  16px;
  --space-5:  20px;
  --space-6:  24px;
  --space-8:  32px;
  --space-10: 40px;
  --space-12: 48px;
  --space-16: 64px;

  /* Radii */
  --radius-sm: 4px;
  --radius-md: 6px;
  --radius-lg: 10px;
  --radius-xl: 14px;
  --radius-2xl: 20px;

  /* Shadows */
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.04);
  --shadow-md: 0 2px 8px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.10);

  /* Layout */
  --sidebar-w: 240px;
  --sidebar-w-collapsed: 64px;
  --topbar-h:  56px;
}

[data-theme="dark"] {
  --bg:           #0a0a0a;
  --bg-elevated:  #141414;
  --bg-subtle:    #1c1c1c;
  --bg-muted:     #232323;
  --border:       #2a2a2a;
  --border-strong:#3a3a3a;

  --fg:           #f5f5f5;
  --fg-muted:     #a3a3a3;
  --fg-subtle:    #6b6b6b;

  --accent:       #9333ea;
  --accent-fg:    #ffffff;
  --accent-soft:  rgba(147, 51, 234, 0.16);
  --accent-hover: #a855f7;

  --success-soft: rgba(22, 163, 74, 0.18);
  --warning-soft: rgba(245, 158, 11, 0.18);
  --danger-soft:  rgba(220, 38, 38, 0.18);
  --info-soft:    rgba(14, 165, 233, 0.18);

  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.30);
  --shadow-md: 0 2px 8px rgba(0, 0, 0, 0.40);
  --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.55);
}
