@import url('https://fonts.googleapis.com/css2?family=Fraunces:ital,opsz,wght@0,9..144,300..700;1,9..144,300..700&family=DM+Sans:ital,opsz,wght@0,9..40,400..700;1,9..40,400..700&family=JetBrains+Mono:wght@400;500&display=swap');

:root {
  /* ── shadcn base tokens ───────────────────────────────────────── */
  --background: oklch(0.975 0.002 220);
  --foreground: oklch(0.14 0.006 230);
  --card: oklch(0.995 0.001 220);
  --card-foreground: oklch(0.14 0.006 230);
  --popover: oklch(0.995 0.001 220);
  --popover-foreground: oklch(0.14 0.006 230);
  --primary: oklch(0.525 0.09 195);
  --primary-foreground: oklch(0.985 0.005 200);
  --secondary: oklch(0.93 0.004 225);
  --secondary-foreground: oklch(0.22 0.006 230);
  --muted: oklch(0.94 0.003 225);
  --muted-foreground: oklch(0.5 0.01 230);
  --accent: oklch(0.93 0.006 215);
  --accent-foreground: oklch(0.22 0.006 230);
  --destructive: oklch(0.56 0.21 25);
  --destructive-foreground: oklch(0.985 0 0);
  --border: oklch(0.87 0.004 225);
  --input: oklch(0.87 0.004 225);
  --ring: oklch(0.525 0.09 195);
  --success: oklch(0.6 0.1 185);
  --warning: oklch(0.72 0.14 70);
  --chart-1: oklch(0.58 0.11 195);
  --chart-2: oklch(0.72 0.09 200);
  --chart-3: oklch(0.3 0.008 230);
  --chart-4: oklch(0.55 0.01 230);
  --chart-5: oklch(0.78 0.006 225);
  --sidebar: oklch(0.1 0.005 230);
  --sidebar-foreground: oklch(0.94 0.003 225);
  --sidebar-primary: oklch(0.68 0.1 195);
  --sidebar-primary-foreground: oklch(0.12 0.006 230);
  --sidebar-accent: oklch(0.27 0.007 230);
  --sidebar-accent-foreground: oklch(1 0 0);
  --sidebar-border: oklch(1 0 0 / 10%);
  --sidebar-ring: oklch(0.68 0.1 195);

  /* ── surface hierarchy ────────────────────────────────────────── */
  --background-secondary: oklch(0.94 0.004 225);
  --surface-hover:   color-mix(in srgb, var(--foreground) 5%,  var(--background));
  --surface-active:  color-mix(in srgb, var(--foreground) 9%, var(--background));
  --surface-elevated: oklch(1 0 0);

  /* ── border hierarchy ─────────────────────────────────────────── */
  --border-subtle: oklch(0.94 0.003 225);
  --border-muted: oklch(0.92 0.003 225);
  --border-strong: oklch(0.78 0.006 225);

  /* ── text hierarchy ───────────────────────────────────────────── */
  --foreground-secondary: oklch(0.38 0.008 230);

  /* ── primary depth (hover/tint states for brand colour) ─────── */
  --primary-hover: color-mix(in srgb, var(--primary) 88%, var(--foreground));
  --primary-muted: color-mix(in srgb, var(--primary) 16%, var(--background));
  --primary-soft:  color-mix(in srgb, var(--primary) 9%,  var(--background));
  --primary-tint:  color-mix(in srgb, var(--primary) 5%,  var(--background));

  /* ── focus ring (alpha-blended, for soft ring style) ────────── */
  --focus-ring: oklch(0.53 0.1 195 / 0.4);

  /* ── error (form validation — distinct from destructive) ─────── */
  --error: oklch(0.56 0.21 25);
  --error-foreground: oklch(0.985 0 0);

  /* ── radius ───────────────────────────────────────────────────── */
  --radius: 0.25rem;
  --radius-none: 0rem;
  --radius-sm: 0.125rem;
  --radius-lg: 0.375rem;
  --radius-xl: 0.5rem;
  --radius-full: 9999px;

  /* ── typography ───────────────────────────────────────────────── */
  --font-display: Fraunces, 'DM Serif Display', Georgia, serif;
  --font-sans: 'DM Sans', ui-sans-serif, system-ui, sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, monospace;
  --font-weight-display: 400;
  --line-height-display: 1.05;
  --tracking-display: -0.015em;
  --font-weight-body: 400;
  --line-height-body: 1.55;
  --tracking-body: 0em;
  --font-weight-mono: 400;

  /* ── shadows ──────────────────────────────────────────────────── */
  --shadow-sm: 0 1px 2px rgba(10, 14, 16, 0.06);
  --shadow-md: 0 4px 14px rgba(10, 14, 16, 0.1);
  --shadow-lg: 0 16px 40px rgba(10, 14, 16, 0.16);

  /* ── motion ───────────────────────────────────────────────────── */
  --duration-fast: 100ms;
  --duration-normal: 200ms;
  --duration-slow: 320ms;
  --ease-standard: cubic-bezier(0.4, 0, 0.2, 1);
  --ease-accelerate: cubic-bezier(0.4, 0, 1, 1);
  --ease-decelerate: cubic-bezier(0, 0, 0.2, 1);

  /* ── spacing ──────────────────────────────────────────────────── */
  --spacing-base: 0.25rem;
}

.dark {
  /* ── shadcn base tokens ───────────────────────────────────────── */
  --background: oklch(0.085 0.004 230);
  --foreground: oklch(0.97 0.003 220);
  --card: oklch(0.155 0.006 230);
  --card-foreground: oklch(0.97 0.003 220);
  --popover: oklch(0.155 0.006 230);
  --popover-foreground: oklch(0.97 0.003 220);
  --primary: oklch(0.72 0.1 195);
  --primary-foreground: oklch(0.12 0.006 230);
  --secondary: oklch(0.24 0.006 230);
  --secondary-foreground: oklch(0.97 0.003 220);
  --muted: oklch(0.23 0.006 230);
  --muted-foreground: oklch(0.7 0.008 230);
  --accent: oklch(0.25 0.008 215);
  --accent-foreground: oklch(0.97 0.003 220);
  --destructive: oklch(0.68 0.19 22);
  --destructive-foreground: oklch(0.985 0 0);
  --border: oklch(1 0 0 / 12%);
  --input: oklch(1 0 0 / 16%);
  --ring: oklch(0.72 0.1 195);
  --success: oklch(0.74 0.1 185);
  --warning: oklch(0.8 0.14 75);
  --chart-1: oklch(0.76 0.11 195);
  --chart-2: oklch(0.6 0.1 200);
  --chart-3: oklch(0.85 0.004 225);
  --chart-4: oklch(0.6 0.008 230);
  --chart-5: oklch(0.38 0.008 230);
  --sidebar: oklch(0.07 0.004 230);
  --sidebar-foreground: oklch(0.94 0.003 225);
  --sidebar-primary: oklch(0.72 0.1 195);
  --sidebar-primary-foreground: oklch(0.12 0.006 230);
  --sidebar-accent: oklch(0.24 0.007 230);
  --sidebar-accent-foreground: oklch(1 0 0);
  --sidebar-border: oklch(1 0 0 / 10%);
  --sidebar-ring: oklch(0.72 0.1 195);

  /* ── surface hierarchy ────────────────────────────────────────── */
  --background-secondary: oklch(0.145 0.005 230);
  --surface-elevated: oklch(0.23 0.006 230);

  /* ── border hierarchy ─────────────────────────────────────────── */
  --border-subtle: oklch(1 0 0 / 7%);
  --border-muted: oklch(1 0 0 / 10%);
  --border-strong: oklch(1 0 0 / 28%);

  /* ── text hierarchy ───────────────────────────────────────────── */
  --foreground-secondary: oklch(0.78 0.006 225);

  /* ── primary depth ────────────────────────────────────────────── */
  --primary-tint: color-mix(in srgb, var(--primary) 7%, var(--background));

  /* ── focus ring ───────────────────────────────────────────────── */
  --focus-ring: oklch(0.72 0.1 195 / 0.45);

  /* ── error ────────────────────────────────────────────────────── */
  --error: oklch(0.68 0.19 22);
  --error-foreground: oklch(0.985 0 0);
}
