/* Grassroots Intelligence — shared stylesheet. Plain CSS, no framework. */
:root {
  --bg: #fbfbf9;
  --surface: #ffffff;
  --ink: #1f2937;
  --muted: #5b6472;
  --line: #e7e5de;
  --accent: #0f766e;        /* deep teal — the one accent color */
  --accent-dark: #0b5f55;
  --accent-soft: #e6f4f2;
  --radius: 12px;
  --maxw: 1120px;
  --shadow: 0 2px 12px rgba(15, 118, 110, 0.08);
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.65;
  font-size: 17px;
}

img, svg { max-width: 100%; height: auto; }

h1, h2, h3 { line-height: 1.25; letter-spacing: -0.01em; margin-top: 0; }
h1 { font-size: clamp(2rem, 4.5vw, 3rem); }
h2 { font-size: clamp(1.5rem, 3vw, 2.1rem); margin-bottom: 0.6em; }
h3 { font-size: 1.2rem; margin-bottom: 0.4em; }
p { margin: 0 0 1em; }
a { color: var(--accent); }
a:hover { color: var(--accent-dark); }

.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 1.25rem; }
.section { padding: 4rem 0; }
.section.alt { background: var(--surface); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }

.lead { font-size: 1.2rem; color: var(--muted); max-width: 44rem; }
.center { text-align: center; }
.muted { color: var(--muted); }
.small { font-size: 0.9rem; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-block;
  background: var(--accent);
  color: #fff;
  padding: 0.8rem 1.6rem;
  border-radius: 999px;
  text-decoration: none;
  font-weight: 600;
  border: 2px solid var(--accent);
  cursor: pointer;
  font-size: 1rem;
}
.btn:hover { background: var(--accent-dark); border-color: var(--accent-dark); color: #fff; }
.btn.ghost { background: transparent; color: var(--accent); }
.btn.ghost:hover { background: var(--accent-soft); color: var(--accent-dark); }
.btn-row { display: flex; gap: 0.75rem; flex-wrap: wrap; margin-top: 1.5rem; }

/* ---------- Header / nav ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255,255,255,0.97);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(6px);
}
.nav-bar { display: flex; align-items: center; justify-content: space-between; height: 68px; }
.brand { display: flex; align-items: center; gap: 0.6rem; text-decoration: none; color: var(--ink); font-weight: 700; font-size: 1.15rem; }
.brand svg { flex: none; }
.nav-links { display: flex; align-items: center; gap: 1.1rem; list-style: none; margin: 0; padding: 0; }
.nav-links a { text-decoration: none; color: var(--ink); font-weight: 500; font-size: 0.95rem; white-space: nowrap; }
.nav-links a:hover, .nav-links a[aria-current="page"] { color: var(--accent); }
.nav-cta { padding: 0.55rem 1.2rem; font-size: 0.95rem; white-space: nowrap; }
.menu-toggle {
  display: none;
  background: none; border: 1px solid var(--line); border-radius: 8px;
  padding: 0.5rem 0.65rem; cursor: pointer; color: var(--ink);
}
.menu-toggle:focus-visible, a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible {
  outline: 3px solid var(--accent); outline-offset: 2px;
}

/* ---------- Hero ---------- */
.hero { padding: 5rem 0 4rem; }
.hero .wrap { text-align: center; }
.hero-logo { display: block; margin: 0 auto 1.5rem; max-width: 420px; width: 80%; height: auto; }
.hero h1 { margin-bottom: 0.5em; }
.hero .lead { margin: 0 auto; }
.hero .btn-row { justify-content: center; }

/* ---------- Cards & grids ---------- */
.grid { display: grid; gap: 1.25rem; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.6rem;
  box-shadow: var(--shadow);
}
.card h3 { margin-top: 0.75rem; }
.icon {
  width: 44px; height: 44px; border-radius: 10px;
  background: var(--accent-soft); color: var(--accent);
  display: inline-flex; align-items: center; justify-content: center;
}
.icon svg { width: 24px; height: 24px; }

/* ---------- Steps ---------- */
.steps { list-style: none; margin: 2rem 0 0; padding: 0; counter-reset: step; display: grid; gap: 1rem; }
.steps li {
  counter-increment: step;
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 1.25rem 1.5rem 1.25rem 4.25rem;
  position: relative; box-shadow: var(--shadow);
}
.steps li::before {
  content: counter(step);
  position: absolute; left: 1.25rem; top: 1.15rem;
  width: 2.1rem; height: 2.1rem; border-radius: 50%;
  background: var(--accent); color: #fff; font-weight: 700;
  display: flex; align-items: center; justify-content: center;
}
.steps strong { display: block; margin-bottom: 0.25rem; }

/* ---------- Pricing table ---------- */
.price-table { width: 100%; border-collapse: collapse; background: var(--surface); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.price-table th, .price-table td { text-align: left; padding: 1rem 1.25rem; border-bottom: 1px solid var(--line); vertical-align: top; }
.price-table thead th { background: var(--accent); color: #fff; }
.price-table tbody tr:last-child th, .price-table tbody tr:last-child td { border-bottom: none; }
.price { font-weight: 700; color: var(--accent); white-space: nowrap; }

/* ---------- Placeholder badge ---------- */
.tbd {
  display: inline-block; background: #fef3c7; color: #92400e;
  border: 1px dashed #d97706; border-radius: 6px;
  padding: 0.1rem 0.55rem; font-size: 0.8rem; font-weight: 700; vertical-align: middle;
}
.placeholder-box {
  border: 2px dashed var(--line); border-radius: var(--radius);
  padding: 1.5rem; background: #fffdf5; text-align: center; color: var(--muted);
}

/* ---------- FAQ ---------- */
.faq-item { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); margin-bottom: 0.9rem; box-shadow: var(--shadow); }
.faq-item summary { cursor: pointer; padding: 1.1rem 1.4rem; font-weight: 600; list-style: none; }
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: "+"; float: right; color: var(--accent); font-weight: 700; }
.faq-item[open] summary::after { content: "–"; }
.faq-item .answer { padding: 0 1.4rem 1.2rem; color: var(--muted); }

/* ---------- Forms ---------- */
.form { max-width: 640px; }
.field { margin-bottom: 1.1rem; }
.field label { display: block; font-weight: 600; margin-bottom: 0.35rem; }
.field input, .field select, .field textarea {
  width: 100%; padding: 0.7rem 0.9rem; font-size: 1rem; font-family: inherit;
  border: 1px solid #cbd5e1; border-radius: 8px; background: #fff; color: var(--ink);
}
.field textarea { min-height: 120px; resize: vertical; }
.field .error { color: #b91c1c; font-size: 0.88rem; margin-top: 0.3rem; display: none; }
.field.invalid input, .field.invalid select, .field.invalid textarea { border-color: #b91c1c; }
.field.invalid .error { display: block; }
.form-note { background: var(--accent-soft); border-radius: 8px; padding: 1rem 1.2rem; margin-bottom: 1.5rem; }
.hp { position: absolute; left: -9999px; } /* honeypot */

/* ---------- Footer ---------- */
.site-footer { background: #14332f; color: #d7e3e1; margin-top: 0; }
.site-footer a { color: #d7e3e1; }
.site-footer a:hover { color: #fff; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 2rem; padding: 3rem 0 2rem; }
.footer-grid h4 { color: #fff; margin: 0 0 0.8rem; font-size: 1rem; }
.footer-grid ul { list-style: none; margin: 0; padding: 0; }
.footer-grid li { margin-bottom: 0.5rem; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,0.15); padding: 1.25rem 0; display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap; font-size: 0.88rem; }

/* ---------- Cookie banner ---------- */
.cookie-banner {
  position: fixed; bottom: 1rem; left: 1rem; right: 1rem; max-width: 560px;
  background: var(--ink); color: #fff; border-radius: var(--radius);
  padding: 1.1rem 1.3rem; z-index: 100; display: none;
  box-shadow: 0 8px 30px rgba(0,0,0,0.25);
}
.cookie-banner.show { display: block; }
.cookie-banner p { margin: 0 0 0.8rem; font-size: 0.92rem; }
.cookie-banner .btn { padding: 0.5rem 1.1rem; font-size: 0.9rem; }

/* ---------- Article ---------- */
.article { max-width: 46rem; }
.article h2 { margin-top: 2rem; }
.article ul, .article ol { padding-left: 1.4rem; }
.article li { margin-bottom: 0.5rem; }
.byline { color: var(--muted); font-size: 0.92rem; margin-bottom: 2rem; }

/* ---------- 404 ---------- */
.notfound { text-align: center; padding: 6rem 0; }
.notfound h1 { font-size: 4rem; color: var(--accent); }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .grid-3 { grid-template-columns: 1fr 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 960px) {
  .menu-toggle { display: inline-block; margin-left: auto; }
  .nav-links {
    display: none; position: absolute; top: 68px; left: 0; right: 0;
    background: #fff; border-bottom: 1px solid var(--line);
    flex-direction: column; align-items: stretch; gap: 0; padding: 0.5rem 1.25rem 1rem;
  }
  .nav-links.open { display: flex; }
  .nav-links li { border-top: 1px solid var(--line); }
  .nav-links li:first-child { border-top: none; }
  .nav-links a { display: block; padding: 0.75rem 0; }
  .nav-links .btn { margin-top: 0.75rem; text-align: center; }
}
@media (max-width: 640px) {
  .section { padding: 2.75rem 0; }
  .grid-3, .grid-2 { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
}

/* ================= Motion system (2026-10-07) =================
   Progressive enhancement: animations only apply when JS adds .js to <html>.
   All motion uses transform/opacity (GPU-friendly). Respects prefers-reduced-motion. */

::selection { background: var(--accent); color: #fff; }

/* Scroll progress bar */
#scroll-progress {
  position: fixed; top: 0; left: 0; right: 0; height: 3px; z-index: 60;
  background: linear-gradient(90deg, var(--accent), #14b8a6);
  transform-origin: 0 50%; transform: scaleX(0);
}

/* Header condenses on scroll */
.site-header { transition: box-shadow 0.3s ease, background 0.3s ease; }
.site-header.scrolled { box-shadow: 0 4px 24px rgba(15, 118, 110, 0.12); }
.site-header.scrolled .nav-bar { height: 58px; }
.nav-bar { transition: height 0.3s ease; }

/* Eyebrow labels */
.eyebrow {
  display: inline-flex; align-items: center; gap: 0.6rem;
  font-size: 0.8rem; font-weight: 700; letter-spacing: 0.14em;
  text-transform: uppercase; color: var(--accent); margin-bottom: 0.9rem;
}
.eyebrow::before { content: ""; width: 2rem; height: 2px; background: var(--accent); border-radius: 2px; }

/* Hero entrance (staggered) */
html.js .hero-anim { opacity: 0; translate: 0 28px; }
html.js .hero-anim.in {
  opacity: 1; translate: 0 0;
  transition: opacity 0.7s ease, translate 0.7s cubic-bezier(0.22, 0.61, 0.36, 1);
  transition-delay: var(--hd, 0ms);
}

/* Hero aurora blobs */
.hero { position: relative; overflow: hidden; }
.hero-blobs { position: absolute; inset: 0; pointer-events: none; z-index: 0; }
.hero-blobs span {
  position: absolute; border-radius: 50%; filter: blur(90px); opacity: 0.5;
  animation: drift 14s ease-in-out infinite alternate;
}
.hero-blobs span:nth-child(1) { width: 480px; height: 480px; left: -140px; top: -120px; background: #99f6e4; }
.hero-blobs span:nth-child(2) { width: 380px; height: 380px; right: -100px; top: 10%; background: #ccfbf1; animation-delay: -5s; }
.hero-blobs span:nth-child(3) { width: 300px; height: 300px; left: 40%; bottom: -160px; background: #e6f4f2; animation-delay: -9s; }
@keyframes drift {
  from { transform: translate(0, 0) scale(1); }
  to { transform: translate(60px, 40px) scale(1.12); }
}
.hero .wrap { position: relative; z-index: 1; }
.hero h1 { font-size: clamp(2.4rem, 5.5vw, 3.8rem); }

/* Scroll reveals */
html.js .reveal { opacity: 0; translate: 0 26px; }
html.js .reveal.in {
  opacity: 1; translate: 0 0;
  transition: opacity 0.65s ease, translate 0.65s cubic-bezier(0.22, 0.61, 0.36, 1);
  transition-delay: var(--rd, 0ms);
}

/* Cards: hover lift + teal glow */
.card { transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease; }
.card:hover {
  transform: translateY(-6px);
  box-shadow: 0 14px 34px rgba(15, 118, 110, 0.16);
  border-color: rgba(15, 118, 110, 0.4);
}
.steps li, .faq-item { transition: transform 0.3s ease, box-shadow 0.3s ease; }
.steps li:hover, .faq-item:hover { transform: translateY(-3px); box-shadow: 0 10px 26px rgba(15, 118, 110, 0.12); }

/* Buttons: shine sweep */
.btn { position: relative; overflow: hidden; transition: transform 0.25s ease, background 0.25s ease, box-shadow 0.25s ease; }
.btn:hover { transform: translateY(-2px); box-shadow: 0 8px 22px rgba(15, 118, 110, 0.28); }
.btn::after {
  content: ""; position: absolute; top: 0; left: -80%; width: 50%; height: 100%;
  background: linear-gradient(100deg, transparent, rgba(255,255,255,0.35), transparent);
  transform: skewX(-20deg); transition: left 0.5s ease;
}
.btn:hover::after { left: 130%; }

/* Marquee ticker */
.marquee {
  overflow: hidden; background: #14332f; color: #d7e3e1;
  padding: 0.9rem 0; white-space: nowrap;
}
.marquee-track { display: inline-flex; gap: 3rem; padding-right: 3rem; animation: marquee 28s linear infinite; }
.marquee:hover .marquee-track { animation-play-state: paused; }
.marquee-track span { font-weight: 600; font-size: 0.95rem; letter-spacing: 0.04em; }
.marquee-track span b { color: #5eead4; font-weight: 700; }
@keyframes marquee { to { transform: translateX(-50%); } }

/* Stats band */
.stats-band { background: var(--surface); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.5rem; padding: 3rem 0; text-align: center; }
.stat-num { font-size: clamp(2.2rem, 4vw, 3.2rem); font-weight: 800; color: var(--accent); line-height: 1.1; font-variant-numeric: tabular-nums; }
.stat-label { color: var(--muted); font-size: 0.95rem; margin-top: 0.35rem; }

/* Footer reveal + back-to-top */
#to-top {
  position: fixed; right: 1.25rem; bottom: 1.25rem; z-index: 60;
  width: 46px; height: 46px; border-radius: 50%;
  background: var(--accent); color: #fff; border: none; cursor: pointer;
  font-size: 1.2rem; line-height: 1; box-shadow: 0 6px 20px rgba(15,118,110,0.35);
  opacity: 0; translate: 0 12px; pointer-events: none;
  transition: opacity 0.3s ease, translate 0.3s ease, background 0.2s ease;
}
#to-top.show { opacity: 1; translate: 0 0; pointer-events: auto; }
#to-top:hover { background: var(--accent-dark); }

/* Pricing table row hover */
.price-table tbody tr { transition: background 0.2s ease; }
.price-table tbody tr:hover { background: var(--accent-soft); }

/* FAQ smooth open (JS toggles .open on click) */
.faq-item .answer { display: grid; grid-template-rows: 0fr; transition: grid-template-rows 0.35s ease; padding: 0 1.4rem; }
.faq-item .answer > * { overflow: hidden; margin: 0; }
.faq-item.open .answer { grid-template-rows: 1fr; padding-bottom: 1.2rem; }
.faq-item summary::after { content: "+"; float: right; color: var(--accent); font-weight: 700; transition: transform 0.3s ease; }
.faq-item.open summary::after { content: "–"; transform: rotate(180deg); }

/* Reduced motion: everything calm */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
  html.js .reveal, html.js .hero-anim { opacity: 1; translate: 0 0; }
  .marquee-track { animation: none; }
  #to-top { display: none; }
}

@media (max-width: 640px) {
  .stats { grid-template-columns: 1fr 1fr; }
  .hero-blobs span { opacity: 0.35; }
}
