/* ═══════════════════════════════════════════════════════════════
   DESIGN TOKENS — Dubai Flea Market Intelligence v2
   Single source of truth for all CSS custom properties.
   Import order: main.css → design-tokens.css → everything else
   ═══════════════════════════════════════════════════════════════ */

:root {
  /* ── Colour: Page backgrounds ──────────────────── */
  --bg:           #F9FAFB;
  --surface:      #FFFFFF;
  --dark:         #060D1A;
  --dark-surface: #0D1A2E;
  --dark-border:  rgba(255, 255, 255, 0.07);

  /* ── Colour: Text ──────────────────────────────── */
  --text:         #0A1628;
  --muted:        #64748B;
  --placeholder:  #94A3B8;
  --text-invert:  #FFFFFF;

  /* ── Colour: Gold accent ───────────────────────── */
  --gold:         #D4A843;
  --gold-bright:  #F0C048;
  --gold-tint:    #FBF6E9;
  --gold-border:  rgba(212, 168, 67, 0.28);
  --gold-glow:    rgba(212, 168, 67, 0.15);

  /* ── Colour: Status ────────────────────────────── */
  --green:        #10B981;
  --green-tint:   rgba(16, 185, 129, 0.10);
  --green-border: rgba(16, 185, 129, 0.25);
  --cyan:         #0EA5E9;
  --red:          #F43F5E;

  /* ── Colour: Dark-section helpers ─────────────── */
  --dark-muted:   rgba(255, 255, 255, 0.50);
  --dark-text:    rgba(255, 255, 255, 0.85);

  /* ── Typography ────────────────────────────────── */
  --font-display: 'Plus Jakarta Sans', 'Inter', system-ui, sans-serif;
  --font-body:    'Inter', 'Plus Jakarta Sans', system-ui, sans-serif;
  --font-mono:    'JetBrains Mono', 'Fira Code', ui-monospace, monospace;

  /* ── Border radius ─────────────────────────────── */
  --radius-sm:    6px;
  --radius-md:    12px;
  --radius-lg:    18px;
  --radius-xl:    24px;
  --radius-full:  9999px;

  /* ── Shadows ───────────────────────────────────── */
  --shadow-sm:    0 1px 3px rgba(6, 13, 26, 0.08),  0 1px 2px  rgba(6, 13, 26, 0.05);
  --shadow-md:    0 4px 16px rgba(6, 13, 26, 0.10), 0 2px 6px  rgba(6, 13, 26, 0.06);
  --shadow-lg:    0 12px 40px rgba(6, 13, 26, 0.14), 0 4px 12px rgba(6, 13, 26, 0.08);
  --shadow-xl:    0 24px 60px rgba(6, 13, 26, 0.18), 0 8px 20px rgba(6, 13, 26, 0.10);
  --shadow-gold:  0 8px 32px rgba(212, 168, 67, 0.28);

  /* ── Transitions ───────────────────────────────── */
  --transition-fast:   120ms ease;
  --transition-base:   200ms ease;
  --transition-slow:   320ms ease;
  --transition-card:   240ms ease;

  /* ── Z-index ───────────────────────────────────── */
  --z-header:  50;
  --z-modal:   100;
  --z-toast:   200;
}

/* ── Base resets on top of Tailwind ────────────────── */
*, *::before, *::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  background-color: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 0.9375rem;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ── Gradient text utility ─────────────────────────── */
.gradient-text {
  background: linear-gradient(112deg, var(--gold) 0%, var(--gold-bright) 45%, var(--gold) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ── Selection colour ──────────────────────────────── */
::selection {
  background-color: rgba(212, 168, 67, 0.25);
  color: var(--text);
}

/* ── Scrollbar (Webkit) ────────────────────────────── */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: rgba(100, 116, 139, 0.35); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: rgba(100, 116, 139, 0.6); }

/* ── Focus ring ────────────────────────────────────── */
:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 2px;
  border-radius: var(--radius-sm);
}
