/*
 * Mintweb — Tek Kaynak Tasarım Token'ları
 * --------------------------------------------------------------
 * Bu dosya hem Django admin (Unfold) hem de React blok editörünün
 * tükettiği tek tasarım kaynağıdır. Linear/Notion tarzı minimal
 * estetik için renk, tipografi, boşluk ve gölge token'larını tanımlar.
 *
 * Kural: Hiçbir component dosyası ham renk/değer kullanmaz —
 * yalnızca buradaki CSS variable'lar üzerinden referans verir.
 */

:root {
  color-scheme: light dark;

  /* --- Renkler — Açık tema --------------------------------- */
  --color-bg: #ffffff;
  --color-bg-subtle: #f9fafb;
  --color-bg-muted: #f3f4f6;
  --color-fg: #111827;
  --color-fg-muted: #6b7280;
  --color-fg-subtle: #9ca3af;

  --color-border: #e5e7eb;
  --color-border-strong: #d1d5db;

  --color-primary: #2563eb;
  --color-primary-hover: #1d4ed8;
  --color-primary-active: #1e40af;
  --color-primary-fg: #ffffff;
  --color-primary-subtle: #eff6ff;

  --color-success: #16a34a;
  --color-success-subtle: #dcfce7;
  --color-warning: #f59e0b;
  --color-warning-subtle: #fef3c7;
  --color-danger: #dc2626;
  --color-danger-subtle: #fee2e2;

  --color-focus-ring: rgba(37, 99, 235, 0.35);

  /* --- Tipografi ------------------------------------------- */
  --font-sans:
    "Inter", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;

  --font-size-xs: 0.75rem;
  --font-size-sm: 0.875rem;
  --font-size-base: 1rem;
  --font-size-lg: 1.125rem;
  --font-size-xl: 1.25rem;
  --font-size-2xl: 1.5rem;
  --font-size-3xl: 1.875rem;

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

  --line-height-tight: 1.25;
  --line-height-normal: 1.5;
  --line-height-relaxed: 1.625;

  /* --- Boşluk (4px temelli ölçek) -------------------------- */
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.25rem;
  --space-6: 1.5rem;
  --space-8: 2rem;
  --space-10: 2.5rem;
  --space-12: 3rem;

  /* --- Köşe yarıçapı --------------------------------------- */
  --radius-sm: 0.375rem;
  --radius: 0.5rem;
  --radius-md: 0.5rem;
  --radius-lg: 0.75rem;
  --radius-full: 9999px;

  /* --- Gölgeler -------------------------------------------- */
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.04);
  --shadow: 0 1px 3px rgba(0, 0, 0, 0.06), 0 1px 2px rgba(0, 0, 0, 0.04);
  --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.05), 0 2px 4px rgba(0, 0, 0, 0.04);
  --shadow-lg: 0 10px 15px rgba(0, 0, 0, 0.06), 0 4px 6px rgba(0, 0, 0, 0.04);

  /* --- Geçişler -------------------------------------------- */
  --transition-fast: 200ms ease-in-out;
  --transition: 450ms ease-in-out;
  --transition-slow: 650ms ease-in-out;

  /* --- Z-index --------------------------------------------- */
  --z-dropdown: 1000;
  --z-sticky: 1020;
  --z-modal: 1040;
  --z-popover: 1060;
  --z-tooltip: 1080;
  --z-toast: 1100;
}

@media (prefers-color-scheme: dark) {
  :root {
    --color-bg: #0a0a0a;
    --color-bg-subtle: #111113;
    --color-bg-muted: #1a1a1d;
    --color-fg: #f5f5f5;
    --color-fg-muted: #a1a1aa;
    --color-fg-subtle: #71717a;

    --color-border: #27272a;
    --color-border-strong: #3f3f46;

    --color-primary: #3b82f6;
    --color-primary-hover: #60a5fa;
    --color-primary-active: #2563eb;
    --color-primary-fg: #ffffff;
    --color-primary-subtle: rgba(59, 130, 246, 0.12);

    --color-success: #22c55e;
    --color-success-subtle: rgba(34, 197, 94, 0.12);
    --color-warning: #fbbf24;
    --color-warning-subtle: rgba(251, 191, 36, 0.12);
    --color-danger: #ef4444;
    --color-danger-subtle: rgba(239, 68, 68, 0.12);

    --color-focus-ring: rgba(59, 130, 246, 0.45);

    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.4);
    --shadow: 0 1px 3px rgba(0, 0, 0, 0.5), 0 1px 2px rgba(0, 0, 0, 0.4);
    --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.5), 0 2px 4px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 10px 15px rgba(0, 0, 0, 0.5), 0 4px 6px rgba(0, 0, 0, 0.4);
  }
}
