/* Stencil Fonts */
@import url('https://fonts.googleapis.com/css2?family=DM+Serif+Display&family=Inter:wght@400;500;600;700&display=swap');
/* /Stencil Fonts */

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

:root {
  /* ── shadcn base tokens ───────────────────────────────────────── */
  --background: oklch(1 0 0);
  --foreground: oklch(0.21 0 0);
  --card: oklch(1 0 0);
  --card-foreground: oklch(0.21 0 0);
  --popover: oklch(1 0 0);
  --popover-foreground: oklch(0.21 0 0);
  --primary: oklch(0.56 0.2 350);
  --primary-foreground: oklch(0.99 0 0);
  --secondary: oklch(0.955 0.008 290);
  --secondary-foreground: oklch(0.27 0.09 292);
  --muted: oklch(0.96 0.007 290);
  --muted-foreground: oklch(0.5 0.02 290);
  --accent: oklch(0.96 0.012 340);
  --accent-foreground: oklch(0.27 0.09 292);
  --destructive: oklch(0.55 0.2 27);
  --destructive-foreground: oklch(0.98 0.008 84);
  --border: oklch(0.27 0.09 292);
  --input: oklch(0.85 0.018 290);
  --ring: oklch(0.56 0.2 350);
  --success: oklch(0.55 0.13 150);
  --warning: oklch(0.72 0.15 68);
  --chart-1: oklch(0.56 0.2 350);
  --chart-2: oklch(0.55 0.13 150);
  --chart-3: oklch(0.72 0.15 68);
  --chart-4: oklch(0.27 0.09 292);
  --chart-5: oklch(0.6 0.14 320);
  --sidebar: oklch(0.975 0.006 290);
  --sidebar-foreground: oklch(0.21 0 0);
  --sidebar-primary: oklch(0.56 0.2 350);
  --sidebar-primary-foreground: oklch(0.99 0 0);
  --sidebar-accent: oklch(0.955 0.008 290);
  --sidebar-accent-foreground: oklch(0.27 0.09 292);
  --sidebar-border: oklch(0.91 0.012 290);
  --sidebar-ring: oklch(0.56 0.2 350);

  /* ── surface hierarchy ────────────────────────────────────────── */
  --background-secondary: oklch(0.975 0.006 290);
  --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.93 0.01 290);
  --border-muted: oklch(0.895 0.014 290);
  --border-strong: oklch(0.72 0.03 290);

  /* ── text hierarchy ───────────────────────────────────────────── */
  --foreground-secondary: oklch(0.4 0.02 290);

  /* ── primary depth (hover/tint states for brand color) ─────── */
  --primary-hover: color-mix(in srgb, var(--primary) 88%, black);
  --primary-muted: color-mix(in srgb, var(--primary) 15%, var(--background));
  --primary-soft:  color-mix(in srgb, var(--primary) 8%,  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.56 0.2 350 / 0.35);

  /* ── error (form validation — distinct from destructive) ─────── */
  --error: oklch(0.55 0.2 27);
  --error-foreground: oklch(0.98 0.008 84);

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

  /* ── typography ───────────────────────────────────────────────── */
  --font-display: Fraunces, ui-serif, Georgia, serif;
  --font-sans: Geist, ui-sans-serif, system-ui, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, monospace;
  --font-weight-display: 600;
  --line-height-display: 1.05;
  --tracking-display: -0.02em;
  --font-weight-body: 400;
  --line-height-body: 1.55;
  --tracking-body: 0em;
  --font-weight-mono: 400;

  /* ── shadows ──────────────────────────────────────────────────── */
  --shadow-sm: 0 1px 2px rgba(35, 19, 75, 0.05);
  --shadow-md: 0 6px 20px rgba(35, 19, 75, 0.08);
  --shadow-lg: 0 18px 44px rgba(35, 19, 75, 0.12);

  /* ── motion ───────────────────────────────────────────────────── */
  --duration-fast: 100ms;
  --duration-normal: 200ms;
  --duration-slow: 300ms;
  --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.19 0.012 50);
  --foreground: oklch(0.95 0.008 84);
  --card: oklch(0.235 0.013 48);
  --card-foreground: oklch(0.95 0.008 84);
  --popover: oklch(0.235 0.013 48);
  --popover-foreground: oklch(0.95 0.008 84);
  --primary: oklch(0.62 0.155 26);
  --primary-foreground: oklch(0.16 0.012 48);
  --secondary: oklch(0.3 0.013 48);
  --secondary-foreground: oklch(0.95 0.008 84);
  --muted: oklch(0.3 0.013 48);
  --muted-foreground: oklch(0.68 0.012 60);
  --accent: oklch(0.3 0.013 48);
  --accent-foreground: oklch(0.95 0.008 84);
  --destructive: oklch(0.65 0.19 27);
  --destructive-foreground: oklch(0.98 0.008 84);
  --border: oklch(1 0 0 / 11%);
  --input: oklch(1 0 0 / 15%);
  --ring: oklch(0.62 0.155 26);
  --success: oklch(0.68 0.14 150);
  --warning: oklch(0.8 0.15 70);
  --chart-1: oklch(0.62 0.155 26);
  --chart-2: oklch(0.68 0.14 150);
  --chart-3: oklch(0.8 0.15 70);
  --chart-4: oklch(0.62 0.12 250);
  --chart-5: oklch(0.7 0.14 320);
  --sidebar: oklch(0.22 0.012 48);
  --sidebar-foreground: oklch(0.95 0.008 84);
  --sidebar-primary: oklch(0.62 0.155 26);
  --sidebar-primary-foreground: oklch(0.16 0.012 48);
  --sidebar-accent: oklch(0.3 0.013 48);
  --sidebar-accent-foreground: oklch(0.95 0.008 84);
  --sidebar-border: oklch(1 0 0 / 11%);
  --sidebar-ring: oklch(0.62 0.155 26);

  /* ── surface hierarchy ────────────────────────────────────────── */
  --background-secondary: oklch(0.22 0.012 48);
  --surface-hover:   color-mix(in srgb, var(--foreground) 6%,  var(--background));
  --surface-active:  color-mix(in srgb, var(--foreground) 10%, var(--background));
  --surface-elevated: oklch(0.27 0.013 48);

  /* ── border hierarchy ─────────────────────────────────────────── */
  --border-subtle: oklch(1 0 0 / 6%);
  --border-muted: oklch(1 0 0 / 9%);
  --border-strong: oklch(1 0 0 / 20%);

  /* ── text hierarchy ───────────────────────────────────────────── */
  --foreground-secondary: oklch(0.74 0.01 60);

  /* ── primary depth ────────────────────────────────────────────── */
  --primary-hover: color-mix(in srgb, var(--primary) 88%, white);
  --primary-muted: color-mix(in srgb, var(--primary) 22%, var(--background));
  --primary-soft:  color-mix(in srgb, var(--primary) 12%, var(--background));
  --primary-tint:  color-mix(in srgb, var(--primary) 8%, var(--background));

  /* ── focus ring ───────────────────────────────────────────────── */
  --focus-ring: oklch(0.62 0.155 26 / 0.45);

  /* ── error ────────────────────────────────────────────────────── */
  --error: oklch(0.65 0.19 27);
  --error-foreground: oklch(0.98 0.008 84);
}

/* Stencil Tweaks */
:root:not(.dark) {
  --background: #fffafa;
  --foreground: #181818;
  --card: #fffafa;
  --primary: #c62a8c;
  --border: #23134b;
  --ring: #e7e7ee;
  --primary-hover: #68075b;
  --muted-foreground: #181818;
}
:root {
  --foreground-secondary: #181818;
  --radius: 0.25rem;
  --radius-sm: 0.125rem;
  --radius-lg: 0.375rem;
  --radius-xl: 0.5rem;
  --font-display: 'DM Serif Display', serif;
  --font-sans: 'Inter', sans-serif;
  --spacing-base: 0.3rem;
}
/* /Stencil Tweaks */