/**
 * AfriPay Platform Design Tokens
 * Single source of truth for typography, color, spacing, and radii.
 */

:root {
  /* Typography */
  --font-heading: "Outfit", sans-serif;
  --font-body: "Poppins", sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;

  --font-size-base: 14px;
  --font-size-sm: 12px;
  --font-size-md: 13px;
  --font-size-lg: 16px;

  --font-weight-body: 400;
  --font-weight-medium: 500;
  --font-weight-semibold: 600;
  --font-weight-bold: 700;
  --font-weight-heading: 600;

  /* Type scale — use weight + size together, avoid 800/extra-bold in UI */
  --text-page-title: 18px;
  --text-section-title: 15px;
  --text-widget-label: 13px;
  --text-caption: 12px;
  --text-micro: 11px;
  --text-display: 30px;
  --text-display-sm: 22px;
  --text-stat: 24px;
  --text-stat-sm: 20px;

  --line-height-body: 1.5;
  --line-height-heading: 1.3;
  --line-height-relaxed: 1.65;

  --heading-1: 40px;
  --heading-2: 28px;
  --heading-3: 24px;
  --heading-4: 18px;
  --heading-5: 16px;
  --heading-6: 14px;

  /* Surfaces */
  --surface: #ffffff;
  --surface-page: #f1f5f9;
  --surface-sidebar: #f8fafc;
  --surface-muted: #f8fafc;

  /* Text */
  --text-primary: #0f172a;
  --text-muted: #64748b;
  --text-subtle: #94a3b8;

  /* Borders */
  --border-subtle: #e2e8f0;
  --border-light: #f1f5f9;
  --border-input: rgba(153, 153, 153, 0.27);

  /* Radii */
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 14px;
  --radius-pill: 999px;

  /* Shadows */
  --shadow-sm: 0 1px 3px rgba(15, 23, 42, 0.06);
  --shadow-md: 0 8px 24px rgba(15, 23, 42, 0.06);
  --shadow-hover: 0 12px 22px rgba(15, 23, 42, 0.08);
  --shadow-btn: 0 10px 20px rgba(0, 0, 0, 0.15);

  /* Focus */
  --focus-ring: 0 0 0 3px color-mix(in srgb, var(--primary-color, #000) 18%, transparent);

  /* Primary tints (overridden per-portal via inline :root) */
  --primary-muted: color-mix(in srgb, var(--primary-color, #000) 12%, transparent);
  --primary-soft: color-mix(in srgb, var(--primary-color, #000) 8%, white);
  --primary-border: color-mix(in srgb, var(--primary-color, #000) 22%, transparent);

  /* Layout (merchant dashboard) */
  --sidebar-width: 220px;
  --sidebar-collapsed-width: 52px;
  --sidebar-gutter: 12px;
  --dashboard-side-width: 340px;
  --dashboard-grid-gap: 16px;

  /* Chart */
  --chart-received: #16a34a;
  --chart-withdrawn: #dc2626;

  /* Controls */
  --control-height: 42px;
  --control-padding-x: 14px;
  --control-font-size: 14px;
  --btn-padding-y: 10px;
  --btn-padding-x: 20px;
  --btn-font-size: 14px;
  --btn-font-weight: 600;
  --btn-radius: var(--radius-sm);
}

@media (max-width: 991px) {
  :root {
    --heading-1: 32px;
    --heading-2: 24px;
    --heading-3: 20px;
  }
}

@media (max-width: 575px) {
  :root {
    --heading-1: 28px;
    --heading-2: 22px;
    --heading-3: 18px;
    --heading-4: 16px;
    --heading-5: 14px;
  }
}
