@import "tailwindcss" source(none);
@source "../src";
@import "tw-animate-css";

@custom-variant dark (&:is(.dark *));

@theme inline {
  --radius-sm: calc(var(--radius) - 4px);
  --radius-md: calc(var(--radius) - 2px);
  --radius-lg: var(--radius);
  --radius-xl: calc(var(--radius) + 4px);
  --radius-2xl: calc(var(--radius) + 8px);
  --radius-3xl: calc(var(--radius) + 12px);

  --color-background: var(--background);
  --color-foreground: var(--foreground);
  --color-card: var(--card);
  --color-card-foreground: var(--card-foreground);
  --color-popover: var(--popover);
  --color-popover-foreground: var(--popover-foreground);
  --color-primary: var(--primary);
  --color-primary-foreground: var(--primary-foreground);
  --color-secondary: var(--secondary);
  --color-secondary-foreground: var(--secondary-foreground);
  --color-muted: var(--muted);
  --color-muted-foreground: var(--muted-foreground);
  --color-accent: var(--accent);
  --color-accent-foreground: var(--accent-foreground);
  --color-destructive: var(--destructive);
  --color-destructive-foreground: var(--destructive-foreground);
  --color-border: var(--border);
  --color-input: var(--input);
  --color-ring: var(--ring);
  --color-tomato: var(--tomato);
  --color-tomato-foreground: var(--tomato-foreground);
  --color-leaf: var(--leaf);
  --color-cream: var(--cream);
  --color-ink: var(--ink);

  --font-display: "Fraunces", Georgia, serif;
  --font-sans: "Inter", system-ui, sans-serif;

  --shadow-soft: 0 1px 2px oklch(0.2 0.02 145 / 0.04), 0 8px 24px oklch(0.2 0.02 145 / 0.06);
  --shadow-lift: 0 2px 6px oklch(0.2 0.02 145 / 0.06), 0 24px 48px -12px oklch(0.2 0.02 145 / 0.18);
}

:root {
  --radius: 0.75rem;

  /* Editorial agri palette */
  --cream: oklch(0.985 0.012 85);
  --ink: oklch(0.22 0.03 145);

  --background: oklch(0.985 0.012 85);
  --foreground: oklch(0.22 0.03 145);

  --card: oklch(1 0 0);
  --card-foreground: oklch(0.22 0.03 145);

  --popover: oklch(1 0 0);
  --popover-foreground: oklch(0.22 0.03 145);

  /* Primary = deep forest leaf green */
  --primary: oklch(0.42 0.09 150);
  --primary-foreground: oklch(0.985 0.012 85);

  --secondary: oklch(0.94 0.02 90);
  --secondary-foreground: oklch(0.22 0.03 145);

  --muted: oklch(0.95 0.015 90);
  --muted-foreground: oklch(0.45 0.02 145);

  --accent: oklch(0.92 0.04 100);
  --accent-foreground: oklch(0.22 0.03 145);

  /* Tomato red accent */
  --tomato: oklch(0.62 0.21 27);
  --tomato-foreground: oklch(0.985 0.012 85);

  --leaf: oklch(0.55 0.13 145);

  --destructive: oklch(0.55 0.22 27);
  --destructive-foreground: oklch(0.985 0.012 85);

  --border: oklch(0.9 0.015 90);
  --input: oklch(0.9 0.015 90);
  --ring: oklch(0.42 0.09 150);
}

@layer base {
  * {
    border-color: var(--color-border);
  }
  html {
    font-family: var(--font-sans);
    -webkit-font-smoothing: antialiased;
  }
  body {
    background-color: var(--color-background);
    color: var(--color-foreground);
  }
  h1, h2, h3, h4, .font-display {
    font-family: var(--font-display);
    font-feature-settings: "ss01", "ss02";
    letter-spacing: -0.02em;
  }
}

@layer utilities {
  .container-editorial {
    width: 100%;
    max-width: 1280px;
    margin-inline: auto;
    padding-inline: 1.25rem;
  }
  @media (min-width: 768px) {
    .container-editorial { padding-inline: 2.5rem; }
  }
  .text-balance { text-wrap: balance; }
  .shadow-soft { box-shadow: var(--shadow-soft); }
  .shadow-lift { box-shadow: var(--shadow-lift); }
}
