/* =============================================================
   Sylva × Claude DS — Foundation tokens
   Cream canvas + coral accent + serif display.
   ============================================================= */

@import url("https://fonts.googleapis.com/css2?family=Inter:ital,wght@0,300;0,400;0,500;0,600;0,700;1,400;1,500&family=JetBrains+Mono:wght@400;500&family=Noto+Sans+Thai:wght@300;400;500;600;700&display=swap");

:root {
  /* ===== Color (Claude DS tokens only — pine green primary per Sylva brand) ===== */
  --color-primary: #2d6a4f;            /* deep pine green — the brand voltage */
  --color-primary-active: #1f4d38;     /* press / hover-darker */
  --color-primary-disabled: #e6dfd8;
  --color-accent-teal: #5db8a6;
  --color-accent-amber: #e8a55a;

  --color-canvas: #faf9f5;
  --color-surface-soft: #f5f0e8;
  --color-surface-card: #efe9de;
  --color-surface-cream-strong: #e8e0d2;
  --color-surface-dark: #181715;
  --color-surface-dark-elevated: #252320;
  --color-surface-dark-soft: #1f1e1b;
  --color-hairline: #e6dfd8;
  --color-hairline-soft: #ebe6df;

  --color-ink: #141413;
  --color-body-strong: #252523;
  --color-body: #3d3d3a;
  --color-muted: #6c6a64;
  --color-muted-soft: #8e8b82;
  --color-on-primary: #ffffff;
  --color-on-dark: #faf9f5;
  --color-on-dark-soft: #a09d96;

  --color-success: #5db872;
  --color-warning: #d4a017;
  --color-error: #c64545;

  /* ===== Type =====
     All English text in Inter (per operator); Noto Sans Thai for Thai.
     Display + body share family with different weights/tracking.
     Mono: JetBrains Mono.
  */
  --font-display: "Inter", "Noto Sans Thai", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-sans: "Inter", "Noto Sans Thai", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

  --type-display-xl: 600 64px/1.04 var(--font-display);
  --type-display-lg: 600 48px/1.08 var(--font-display);
  --type-display-md: 600 36px/1.14 var(--font-display);
  --type-display-sm: 600 28px/1.20 var(--font-display);

  --type-title-lg: 500 22px/1.30 var(--font-sans);
  --type-title-md: 500 18px/1.40 var(--font-sans);
  --type-title-sm: 500 16px/1.40 var(--font-sans);

  --type-body-md: 400 16px/1.55 var(--font-sans);
  --type-body-sm: 400 14px/1.55 var(--font-sans);

  --type-caption: 500 13px/1.4 var(--font-sans);
  --type-caption-uppercase: 500 12px/1.4 var(--font-sans);
  --type-button: 500 14px/1.0 var(--font-sans);
  --type-nav: 500 14px/1.4 var(--font-sans);

  /* ===== Spacing ===== */
  --space-xxs: 4px;
  --space-xs: 8px;
  --space-sm: 12px;
  --space-md: 16px;
  --space-lg: 24px;
  --space-xl: 32px;
  --space-xxl: 48px;
  --space-section: 96px;

  /* ===== Radii ===== */
  --radius-xs: 4px;
  --radius-sm: 6px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --radius-xl: 16px;
  --radius-pill: 9999px;

  /* ===== Elevation ===== */
  --shadow-soft: 0 1px 3px rgba(20, 20, 19, 0.08);
  --shadow-lift: 0 4px 16px rgba(20, 20, 19, 0.06);

  /* ===== Layout ===== */
  --container-max: 1200px;
  --gutter: clamp(20px, 4vw, 32px);

  /* ===== Motion ===== */
  --ease: cubic-bezier(0.2, 0, 0, 1);
}

/* ===== Resets ===== */
*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  background: var(--color-canvas);
  color: var(--color-ink);
  font: var(--type-body-md);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
button { font: inherit; cursor: pointer; border: 0; background: transparent; color: inherit; }
a { color: inherit; text-decoration: none; }

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  color: var(--color-ink);
  margin: 0;
  text-wrap: balance;
  letter-spacing: -0.025em;
}
h1 { font-size: clamp(40px, 5.6vw, 72px); line-height: 1.02; letter-spacing: -0.035em; font-weight: 700; }
h2 { font-size: clamp(32px, 4vw, 48px); line-height: 1.08; letter-spacing: -0.03em; }
h3 { font-size: clamp(24px, 2.4vw, 32px); line-height: 1.15; letter-spacing: -0.025em; }
h4 { font-size: clamp(20px, 1.8vw, 24px); line-height: 1.25; letter-spacing: -0.02em; }

/* Thai-heavy headlines: fall back to the sans face for crispness */
.h-sans, .h-sans h1, .h-sans h2, .h-sans h3, .h-sans h4 {
  font-family: var(--font-sans);
  font-weight: 600;
  letter-spacing: -0.02em;
}

p { font: var(--type-body-md); color: var(--color-body); margin: 0; text-wrap: pretty; }

small, .caption {
  font: var(--type-caption);
  color: var(--color-muted);
}

.kicker {
  font: var(--type-caption-uppercase);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--color-muted);
  display: inline-flex;
  align-items: center;
  gap: 10px;
}
.kicker::before {
  content: "";
  width: 6px; height: 6px;
  background: var(--color-primary);
  border-radius: 50%;
}
.kicker--ondark { color: var(--color-on-dark-soft); }
.kicker--ondark::before { background: var(--color-on-primary); }

/* Italic accent — Inter italic for emphasis phrases (was serif italic before). */
.serif-it {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 500;
  letter-spacing: -0.015em;
  color: inherit;
}
