/* Nudge — site styles. Mirrors Nudge/DesignSystem/Theme.swift:
   green #1A3A1E, greenLight #EEF4EE, muted #6B8A6E, border #D4E4D4,
   amber #C87533, going #2D7A3A, grey #9AA0A6, white canvas.
   Radii: card 20, pill 20, input 12, button 24.
   Type: DM Sans (body) / Playfair Display (headings). */

:root {
  --green: #1A3A1E;
  --green-light: #EEF4EE;
  --muted: #6B8A6E;
  --border: #D4E4D4;
  --amber: #C87533;
  --going: #2D7A3A;
  --grey: #9AA0A6;
  --canvas: #FFFFFF;
  --r-card: 20px;
  --r-pill: 20px;
  --r-input: 12px;
  --r-button: 24px;
  --sans: "DM Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --serif: "Playfair Display", Georgia, serif;
}

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

html { scroll-behavior: smooth; }

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

.wrap { max-width: 960px; margin: 0 auto; padding: 0 24px; }
.wrap--narrow { max-width: 720px; }

/* ---------- Header ---------- */

.site-header {
  border-bottom: 1.5px solid var(--border);
  background: var(--canvas);
}
.site-header .wrap {
  display: flex; align-items: center; justify-content: space-between;
  padding-top: 18px; padding-bottom: 18px;
}
.wordmark {
  font-family: var(--serif);
  font-weight: 600;
  font-size: 1.5rem;
  color: var(--green);
  text-decoration: none;
  letter-spacing: 0.01em;
}
.site-nav { display: flex; gap: 8px; }
.site-nav a {
  font-size: 0.85rem; font-weight: 500;
  color: var(--muted); text-decoration: none;
  padding: 8px 16px; border-radius: var(--r-pill);
  transition: background .18s ease, color .18s ease;
}
.site-nav a:hover, .site-nav a.active {
  background: var(--green-light); color: var(--green);
}

/* ---------- Type ---------- */

h1, h2, h3 { font-family: var(--serif); font-weight: 600; line-height: 1.2; }
h1 { font-size: clamp(2.4rem, 6vw, 3.6rem); }
h2 { font-size: 1.5rem; }
h3 { font-size: 1.15rem; }
.accent { font-style: italic; font-weight: 500; }
.lede { color: var(--muted); font-size: 1.125rem; max-width: 34em; }

/* SectionLabel: 10px / 600 / .09em tracked uppercase, muted */
.section-label {
  font-size: 0.7rem; font-weight: 600;
  letter-spacing: 0.09em; text-transform: uppercase;
  color: var(--muted);
}

/* ---------- Hero ---------- */

.hero { padding: 88px 0 72px; }
.hero .wrap {
  display: grid; grid-template-columns: 1.15fr 0.85fr;
  gap: 56px; align-items: center;
}
.hero-copy > * + * { margin-top: 20px; }
.hero-actions { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; margin-top: 28px; }

@media (max-width: 760px) {
  .hero { padding: 56px 0 48px; }
  .hero .wrap { grid-template-columns: 1fr; gap: 40px; }
}

/* ---------- Buttons (PrimaryButton: green pill, radius 24) ---------- */

.btn {
  display: inline-block;
  font-family: var(--sans); font-size: 0.9rem; font-weight: 500;
  padding: 14px 28px; border-radius: var(--r-button);
  text-decoration: none; cursor: pointer;
  transition: opacity .18s ease, background .18s ease;
}
.btn--primary { background: var(--green); color: #fff; }
.btn--primary:hover { opacity: 0.9; }
.btn--outline {
  background: transparent; color: var(--green);
  border: 1.5px solid var(--border);
}
.btn--outline:hover { background: var(--green-light); }

/* ---------- Cards (Card: white, radius 20, 1.5px border) ---------- */

.card {
  background: var(--canvas);
  border: 1.5px solid var(--border);
  border-radius: var(--r-card);
  padding: 24px;
}

/* ---------- Hero mock nudge card ---------- */

.mock-card { max-width: 360px; margin: 0 auto; box-shadow: 0 20px 48px rgba(26, 58, 30, 0.08); }
.mock-card .mock-head { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 6px; }
.mock-title { font-family: var(--serif); font-weight: 600; font-size: 1.2rem; }
.mock-meta { color: var(--muted); font-size: 0.85rem; margin-bottom: 16px; }
.mock-foot { display: flex; justify-content: space-between; align-items: center; margin-top: 16px; }

.dot-label { display: inline-flex; align-items: center; gap: 5px; font-size: 0.75rem; font-weight: 500; }
.dot-label::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.dot-label--going { color: var(--going); }
.dot-label--pending { color: var(--amber); }

.avatar-stack { display: flex; }
.avatar {
  width: 30px; height: 30px; border-radius: 50%;
  background: var(--green-light);
  border: 1.5px solid var(--border);
  display: flex; align-items: center; justify-content: center;
  font-size: 0.65rem; font-weight: 500; color: var(--green);
}
.avatar + .avatar { margin-left: -8px; }
.avatar--pending { background: #fff; color: var(--muted); border-style: dashed; }

.count-pill {
  background: var(--green); color: #fff;
  font-size: 0.7rem; font-weight: 500;
  padding: 4px 10px; border-radius: 999px;
}

.chip {
  display: inline-block; background: var(--green-light); color: var(--green);
  border: 1px solid var(--border); border-radius: var(--r-pill);
  font-size: 0.8rem; font-weight: 500; padding: 6px 14px;
}

/* ---------- Feature grid ---------- */

.features { padding: 24px 0 88px; }
.features .section-label { display: block; text-align: center; margin-bottom: 28px; }
.feature-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
@media (max-width: 760px) { .feature-grid { grid-template-columns: 1fr; } }
.feature-card h3 { margin: 14px 0 8px; }
.feature-card p { color: var(--muted); font-size: 0.95rem; }
.feature-icon {
  width: 44px; height: 44px; border-radius: var(--r-input);
  background: var(--green-light); border: 1px solid var(--border);
  display: flex; align-items: center; justify-content: center;
}
.feature-icon svg { width: 22px; height: 22px; stroke: var(--green); }

/* ---------- Mission band ---------- */

.mission { padding: 0 0 88px; }
.mission .card {
  background: var(--green-light); border-color: var(--border);
  padding: 48px 40px; text-align: center;
}
.mission blockquote {
  font-family: var(--serif); font-style: italic; font-weight: 500;
  font-size: clamp(1.3rem, 3vw, 1.7rem); line-height: 1.4;
  max-width: 24em; margin: 0 auto;
}
.mission .section-label { display: block; margin-bottom: 16px; }

/* ---------- Legal pages ---------- */

.page { padding: 64px 0 96px; }
.page-header { margin-bottom: 40px; }
.page-header .section-label { display: block; margin-bottom: 10px; }
.page-header h1 { font-size: clamp(2rem, 5vw, 2.6rem); }
.page-header .meta { color: var(--grey); font-size: 0.9rem; margin-top: 10px; }

.legal h2 {
  font-size: 1.25rem; margin: 40px 0 12px;
  padding-top: 28px; border-top: 1.5px solid var(--border);
}
.legal h2:first-of-type { border-top: none; padding-top: 0; margin-top: 0; }
.legal p, .legal li { color: #2f4a33; }
.legal p + p { margin-top: 12px; }
.legal ul { padding-left: 22px; margin: 12px 0; }
.legal li + li { margin-top: 8px; }
.legal a { color: var(--going); }
.legal strong { color: var(--green); }

.callout {
  background: var(--green-light);
  border: 1.5px solid var(--border);
  border-radius: var(--r-card);
  padding: 20px 24px; margin: 16px 0;
}

/* ---------- Footer ---------- */

.site-footer { border-top: 1.5px solid var(--border); padding: 32px 0 48px; }
.site-footer .wrap {
  display: flex; justify-content: space-between; align-items: center;
  flex-wrap: wrap; gap: 16px;
}
.site-footer .fine { color: var(--grey); font-size: 0.85rem; }
.footer-links { display: flex; gap: 20px; }
.footer-links a {
  color: var(--muted); font-size: 0.85rem; font-weight: 500; text-decoration: none;
}
.footer-links a:hover { color: var(--green); }
