/* === Formuli Theme === */
/* Palette: Deep forest + warm amber + parchment cream */

:root {
  --bg: #f5f0e6;
  --bg-alt: #ebe5d8;
  --bg-dark: #1a2e23;
  --bg-card: #ffffff;
  --fg: #2a2a25;
  --fg-muted: #6b6960;
  --fg-light: #f5f0e6;
  --accent: #c08b5c;
  --accent-light: #dbb68a;
  --accent-dark: #8b6340;
  --green: #3d6b52;
  --green-light: #5a9474;
  --green-muted: rgba(61,107,82,0.08);
  --serif: 'Cormorant Garamond', 'Georgia', serif;
  --sans: 'DM Sans', 'Helvetica Neue', sans-serif;
  --radius: 12px;
  --max-w: 1140px;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--fg);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

/* === NAV === */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  background: rgba(245,240,230,0.85);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(42,42,37,0.06);
}
.nav-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 16px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.nav-logo {
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 8px;
}
.logo-mark {
  font-size: 24px;
  color: var(--green);
}
.logo-text {
  font-family: var(--serif);
  font-size: 22px;
  font-weight: 700;
  color: var(--fg);
  letter-spacing: -0.02em;
}
.nav-tagline {
  font-size: 13px;
  color: var(--fg-muted);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

/* === HERO === */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  overflow: hidden;
  padding: 100px 24px 80px;
}
.hero-bg-pattern {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 80% 60% at 70% 40%, rgba(61,107,82,0.06) 0%, transparent 70%),
    radial-gradient(ellipse 50% 80% at 20% 80%, rgba(192,139,92,0.05) 0%, transparent 60%);
  pointer-events: none;
}
.hero-content {
  max-width: var(--max-w);
  margin: 0 auto;
  width: 100%;
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 60px;
  align-items: center;
}
.hero-eyebrow {
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--green);
  margin-bottom: 20px;
  font-weight: 500;
}
.hero-title {
  font-family: var(--serif);
  font-size: clamp(42px, 6vw, 72px);
  font-weight: 600;
  line-height: 1.1;
  letter-spacing: -0.02em;
  color: var(--fg);
  margin-bottom: 28px;
}
.hero-title em {
  color: var(--green);
  font-style: italic;
}
.hero-lede {
  font-size: 18px;
  line-height: 1.7;
  color: var(--fg-muted);
  max-width: 500px;
}

/* Hero visual - botanical rings */
.hero-visual {
  display: flex;
  align-items: center;
  justify-content: center;
}
.herb-circle {
  position: relative;
  width: 360px;
  height: 360px;
}
.herb-ring {
  position: absolute;
  border-radius: 50%;
  border: 1px solid;
}
.herb-ring-outer {
  inset: 0;
  border-color: rgba(61,107,82,0.12);
  animation: spin-slow 60s linear infinite;
}
.herb-ring-outer::before {
  content: '';
  position: absolute;
  top: 10%; left: -4px;
  width: 8px; height: 8px;
  background: var(--green-light);
  border-radius: 50%;
}
.herb-ring-middle {
  inset: 40px;
  border-color: rgba(192,139,92,0.15);
  animation: spin-slow 45s linear infinite reverse;
}
.herb-ring-middle::before {
  content: '';
  position: absolute;
  bottom: 5%; right: -3px;
  width: 6px; height: 6px;
  background: var(--accent-light);
  border-radius: 50%;
}
.herb-ring-inner {
  inset: 80px;
  border-color: rgba(61,107,82,0.1);
  animation: spin-slow 30s linear infinite;
}
.herb-center {
  position: absolute;
  inset: 120px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: radial-gradient(circle, rgba(61,107,82,0.04) 0%, transparent 70%);
  border-radius: 50%;
}
.herb-character {
  font-size: 56px;
  color: var(--green);
  font-family: var(--serif);
  line-height: 1;
}
.herb-label {
  font-size: 12px;
  color: var(--fg-muted);
  letter-spacing: 0.08em;
  margin-top: 8px;
}
@keyframes spin-slow {
  to { transform: rotate(360deg); }
}

/* === PHILOSOPHY === */
.philosophy {
  padding: 120px 24px;
  background: var(--bg-dark);
  color: var(--fg-light);
}
.philosophy-inner {
  max-width: var(--max-w);
  margin: 0 auto;
}
.philosophy-label {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--accent-light);
  margin-bottom: 16px;
}
.philosophy-title {
  font-family: var(--serif);
  font-size: clamp(28px, 4vw, 44px);
  font-weight: 600;
  line-height: 1.2;
  margin-bottom: 60px;
  max-width: 680px;
}
.philosophy-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 40px;
}
.philosophy-card {
  padding: 32px 0;
  border-top: 1px solid rgba(245,240,230,0.1);
}
.card-number {
  font-size: 13px;
  color: var(--accent);
  font-weight: 700;
  margin-bottom: 16px;
}
.philosophy-card h3 {
  font-family: var(--serif);
  font-size: 26px;
  font-weight: 600;
  margin-bottom: 12px;
}
.philosophy-card p {
  font-size: 15px;
  line-height: 1.7;
  color: rgba(245,240,230,0.65);
}

/* === CONSTITUTIONS === */
.constitutions {
  padding: 120px 24px;
}
.constitutions-inner {
  max-width: var(--max-w);
  margin: 0 auto;
}
.section-label {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--green);
  margin-bottom: 12px;
  font-weight: 500;
}
.constitutions-header h2 {
  font-family: var(--serif);
  font-size: clamp(28px, 4vw, 42px);
  font-weight: 600;
  margin-bottom: 16px;
}
.section-desc {
  font-size: 17px;
  color: var(--fg-muted);
  max-width: 560px;
  line-height: 1.7;
  margin-bottom: 48px;
}
.constitution-scroll {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}
.constitution-chip {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 22px;
  background: var(--bg-card);
  border-radius: 100px;
  font-size: 15px;
  font-weight: 500;
  border: 1px solid rgba(42,42,37,0.06);
  transition: all 0.2s;
}
.constitution-chip:hover, .constitution-chip.active {
  border-color: var(--green);
  background: var(--green-muted);
}
.chip-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  flex-shrink: 0;
}
.chip-zh {
  font-size: 13px;
  color: var(--fg-muted);
  margin-left: 4px;
}

/* === SEASONS === */
.seasons {
  padding: 120px 24px;
  background: var(--bg-alt);
}
.seasons-inner {
  max-width: var(--max-w);
  margin: 0 auto;
}
.seasons-inner h2 {
  font-family: var(--serif);
  font-size: clamp(28px, 4vw, 42px);
  font-weight: 600;
  margin-bottom: 16px;
}
.seasons-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  margin-top: 48px;
}
.season-card {
  padding: 36px 28px;
  border-radius: var(--radius);
  background: var(--bg-card);
  border: 1px solid rgba(42,42,37,0.06);
  transition: transform 0.2s;
}
.season-card:hover {
  transform: translateY(-4px);
}
.season-icon {
  font-size: 40px;
  margin-bottom: 16px;
  line-height: 1;
}
.season-spring .season-icon { color: #5a9474; }
.season-summer .season-icon { color: #c08b5c; }
.season-autumn .season-icon { color: #b87333; }
.season-winter .season-icon { color: #6b8fad; }
.season-card h3 {
  font-family: var(--serif);
  font-size: 22px;
  font-weight: 600;
  margin-bottom: 10px;
}
.season-card p {
  font-size: 14px;
  color: var(--fg-muted);
  line-height: 1.65;
}

/* === FORMULAS === */
.formulas {
  padding: 120px 24px;
}
.formulas-inner {
  max-width: var(--max-w);
  margin: 0 auto;
}
.formulas-inner h2 {
  font-family: var(--serif);
  font-size: clamp(28px, 4vw, 42px);
  font-weight: 600;
  margin-bottom: 48px;
}
.formulas-feature {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 48px;
  align-items: start;
}
.formula-block {
  background: var(--bg-dark);
  color: var(--fg-light);
  border-radius: var(--radius);
  overflow: hidden;
}
.formula-header {
  padding: 20px 28px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid rgba(245,240,230,0.08);
}
.formula-tag {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--accent-light);
  background: rgba(192,139,92,0.12);
  padding: 4px 12px;
  border-radius: 100px;
}
.formula-constitution {
  font-size: 13px;
  color: rgba(245,240,230,0.5);
}
.formula-body {
  padding: 8px 0;
}
.formula-row {
  padding: 16px 28px;
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  border-bottom: 1px solid rgba(245,240,230,0.04);
}
.formula-row:last-child { border-bottom: none; }
.formula-category {
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--accent-light);
  flex-shrink: 0;
  width: 120px;
}
.formula-detail {
  font-size: 15px;
  color: rgba(245,240,230,0.75);
  text-align: right;
}
.formula-aside {
  padding-top: 12px;
}
.formula-aside p {
  font-size: 16px;
  color: var(--fg-muted);
  line-height: 1.75;
  margin-bottom: 20px;
}

/* === CLOSING === */
.closing {
  padding: 140px 24px;
  text-align: center;
  background:
    radial-gradient(ellipse 60% 50% at 50% 50%, rgba(61,107,82,0.05) 0%, transparent 70%);
}
.closing-inner {
  max-width: 640px;
  margin: 0 auto;
}
.closing-character {
  font-size: 64px;
  color: var(--green);
  margin-bottom: 28px;
  line-height: 1;
}
.closing h2 {
  font-family: var(--serif);
  font-size: clamp(32px, 5vw, 52px);
  font-weight: 600;
  line-height: 1.15;
  margin-bottom: 24px;
}
.closing p {
  font-size: 17px;
  color: var(--fg-muted);
  line-height: 1.75;
}

/* === FOOTER === */
.footer {
  padding: 32px 24px;
  border-top: 1px solid rgba(42,42,37,0.08);
}
.footer-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.footer-logo {
  font-family: var(--serif);
  font-size: 18px;
  font-weight: 700;
  color: var(--fg);
}
.footer-copy {
  font-size: 13px;
  color: var(--fg-muted);
}

/* === RESPONSIVE === */
@media (max-width: 768px) {
  .hero-content {
    grid-template-columns: 1fr;
    gap: 48px;
  }
  .hero-visual { order: -1; }
  .herb-circle { width: 240px; height: 240px; }
  .herb-ring-middle { inset: 28px; }
  .herb-ring-inner { inset: 56px; }
  .herb-center { inset: 80px; }
  .herb-character { font-size: 40px; }
  .philosophy-grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }
  .seasons-grid {
    grid-template-columns: 1fr 1fr;
    gap: 16px;
  }
  .formulas-feature {
    grid-template-columns: 1fr;
  }
  .formula-row {
    flex-direction: column;
    gap: 4px;
  }
  .formula-detail { text-align: left; }
  .nav-tagline { display: none; }
  .footer-inner { flex-direction: column; gap: 8px; text-align: center; }
}
@media (max-width: 480px) {
  .seasons-grid { grid-template-columns: 1fr; }
  .constitution-scroll { gap: 8px; }
  .constitution-chip { padding: 10px 16px; font-size: 14px; }
}