/* NutriFlux brand identity (brand book 016 — colour palette, 011 — print font).
 * The four palette colours are exact and must not be substituted:
 *   Nutri Vital Leaf Green #38903a (PMS 7739 C) — main
 *   Fresh Flux Green       #77ae2c (PMS 369 C)  — main
 *   Active Lime Green      #abcd07 (PMS 390 C)
 *   Nutri Deep Root        #051d05 (PMS 3435 C)
 * Nunito is the only brand typeface: Black (900) for H1/H2, SemiBold (600)
 * for H3/H4, ExtraLight/Regular for body.
 * Tints and surfaces below are derived from those four, not new brand colours.
 */
:root {
  color-scheme: light;
  --brand: #38903a;
  --brand-dark: #051d05;
  --brand-soft: #DCEBD4;
  --green: #77ae2c;
  --lime: #abcd07;
  --red: #E1452B;
  --cream: #F6FAF4;
  --sand: #E8F1E4;
  --white: #FFFFFF;
  --ink: #051d05;
  --ink-700: #2C4A2C;
  --ink-500: #5A6F58;
  --line: rgba(5, 29, 5, 0.14);
  --heading: Nunito, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --body: Nunito, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --page: min(1240px, calc(100vw - 40px));
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--cream);
  color: var(--ink);
  font-family: var(--body);
  font-size: 16px;
  line-height: 1.55;
  text-rendering: optimizeLegibility;
}
img { display: block; max-width: 100%; }
a { color: inherit; }
button, input { font: inherit; }

.skip-link {
  position: fixed;
  z-index: 100;
  top: 12px;
  left: 12px;
  transform: translateY(-160%);
  background: var(--ink);
  color: white;
  padding: 10px 14px;
  border-radius: 8px;
}
.skip-link:focus { transform: translateY(0); }

.site-header {
  width: var(--page);
  margin: 0 auto;
  min-height: 88px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  border-bottom: 1px solid var(--line);
}
.brand { width: 158px; display: inline-flex; align-items: center; }
.site-header nav { display: flex; align-items: center; gap: 28px; font-size: 14px; font-weight: 800; }
.site-header nav a { text-decoration: none; }
.site-header nav a:not(.nav-cta):hover { color: var(--brand-dark); }
.nav-cta {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  padding: 0 18px;
  background: var(--ink);
  color: white;
  border-radius: 999px;
}

.hero {
  width: var(--page);
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(420px, .92fr);
  gap: clamp(48px, 7vw, 112px);
  align-items: center;
  min-height: 710px;
  padding: 84px 0 96px;
}
.eyebrow,
.section-index,
.system-label,
.visual-label {
  margin: 0 0 20px;
  color: var(--brand-dark);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: .12em;
  text-transform: uppercase;
}
.hero h1,
h2 {
  font-family: var(--heading);
  /* Fredoka's heaviest real static weight is 700 — 800 doesn't exist and
     forces the browser to synthesize (fake-embolden) it, which reads as
     blurry/pixelated at display sizes. */
  font-weight: 700;
  letter-spacing: -.045em;
  line-height: .98;
  margin: 0;
}
.hero h1 { font-size: clamp(54px, 7.1vw, 104px); max-width: 760px; }
.hero h1 span { color: var(--brand); }
.hero-body {
  max-width: 630px;
  margin: 34px 0 0;
  font-size: clamp(18px, 1.45vw, 22px);
  color: var(--ink-700);
}
.hero-actions { margin-top: 38px; display: flex; align-items: center; gap: 24px; flex-wrap: wrap; }
.button {
  border: 0;
  min-height: 50px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 22px;
  border-radius: 12px;
  font-weight: 900;
  text-decoration: none;
  cursor: pointer;
  transition: transform 160ms ease, background-color 160ms ease;
}
.button:hover { transform: translateY(-2px); }
.button:focus-visible,
.text-link:focus-visible,
.site-header a:focus-visible,
input:focus-visible {
  outline: 3px solid rgba(63, 142, 92, .4);
  outline-offset: 3px;
}
.button-primary { background: var(--brand); color: white; }
.button-primary:hover { background: var(--brand-dark); }
.button-dark { background: var(--ink); color: white; }
.text-link { font-weight: 900; text-decoration-thickness: 2px; text-underline-offset: 6px; }
.microcopy { margin: 24px 0 0; color: var(--ink-500); font-size: 13px; }

.hero-system {
  position: relative;
  overflow: hidden;
  min-height: 570px;
  background: var(--green);
  color: white;
  padding: 38px 34px 32px;
  border-radius: 34px 34px 104px 34px;
  isolation: isolate;
}
.hero-system::after {
  content: "";
  position: absolute;
  width: 270px;
  height: 270px;
  right: -105px;
  top: -110px;
  border: 54px solid rgba(255,255,255,.08);
  border-radius: 50%;
  z-index: -1;
}
.system-label { color: rgba(255,255,255,.76); }
.hero-system ol { list-style: none; padding: 0; margin: 28px 0 0; position: relative; z-index: 2; }
.hero-system li {
  display: grid;
  grid-template-columns: 42px 1fr;
  gap: 14px;
  align-items: start;
  padding: 17px 0;
  border-top: 1px solid rgba(255,255,255,.25);
}
.hero-system li:last-child { border-bottom: 1px solid rgba(255,255,255,.25); }
.step-number { font-size: 11px; font-weight: 900; opacity: .72; padding-top: 4px; }
.hero-system strong { display: block; font-family: var(--heading); font-size: 23px; line-height: 1.05; }
.hero-system small { display: block; margin-top: 5px; max-width: 280px; color: rgba(255,255,255,.76); font-size: 13px; line-height: 1.4; }
.system-accent strong { color: #FFF1E8; }
.hero-mascot {
  position: absolute;
  right: -10px;
  bottom: -12px;
  width: 185px;
  filter: drop-shadow(0 14px 20px rgba(26,20,16,.16));
  transform-origin: 50% 85%;
  animation: mascot-breathe 4s ease-in-out infinite;
}

.statement {
  background: var(--brand);
  color: white;
  padding: clamp(72px, 9vw, 128px) max(20px, calc((100vw - min(1240px, calc(100vw - 40px))) / 2));
  display: grid;
  grid-template-columns: minmax(180px, .35fr) minmax(0, 1fr);
  gap: 48px;
}
.statement .section-index { color: rgba(255,255,255,.74); }
.statement h2 { max-width: 980px; font-size: clamp(44px, 6vw, 84px); }
.statement p:not(.section-index) { max-width: 690px; margin: 30px 0 0; font-size: 20px; color: rgba(255,255,255,.86); }

.food-language {
  width: var(--page);
  margin: 0 auto;
  padding: 118px 0 110px;
  border-bottom: 1px solid var(--line);
}
.food-intro { display: grid; grid-template-columns: .34fr 1fr; column-gap: 48px; align-items: start; }
.food-intro .section-index { grid-row: span 2; }
.food-intro h2 { max-width: 760px; font-size: clamp(42px, 5vw, 72px); }
.food-intro > p:last-child { max-width: 620px; margin: 24px 0 0; color: var(--ink-500); font-size: 18px; }
.food-rail {
  display: flex;
  gap: 12px;
  overflow-x: auto;
  padding: 54px 0 16px;
  scrollbar-width: thin;
  scrollbar-color: var(--brand-soft) transparent;
}
/* Matches the app's own Chip component (components/ui/Chip.tsx): a soft
 * filled pill with no stroke, not an outlined badge — the app never puts a
 * hard border on a tag/chip. */
.food-rail span {
  flex: 0 0 auto;
  font-family: var(--heading);
  font-weight: 700;
  font-size: clamp(20px, 2.4vw, 32px);
  line-height: 1;
  padding: 17px 24px 19px;
  border-radius: 999px;
  background: var(--brand-soft);
  color: var(--ink);
}
.food-rail span:nth-child(3n + 2) { background: var(--sand); }
.food-rail span:nth-child(3n + 3) { background: var(--white); }
.rail-note { margin: 10px 0 0; color: var(--ink-500); font-size: 13px; }

.recovery-story {
  width: var(--page);
  margin: 0 auto;
  padding: 116px 0;
  display: grid;
  grid-template-columns: minmax(360px, .84fr) minmax(0, 1.16fr);
  gap: clamp(52px, 8vw, 120px);
  align-items: center;
}
.recovery-visual {
  position: relative;
  min-height: 560px;
  overflow: hidden;
  background: var(--sand);
  border-radius: 26px 92px 26px 26px;
}
.recovery-visual::before {
  content: "";
  position: absolute;
  width: 300px;
  height: 300px;
  left: -130px;
  bottom: -90px;
  border-radius: 50%;
  background: var(--brand-soft);
}
.recovery-visual img { position: absolute; width: 285px; right: 22px; bottom: 90px; }
.visual-label { position: absolute; left: 28px; top: 28px; color: var(--brand-dark); }
.recovery-copyline {
  position: absolute;
  left: 28px;
  right: 28px;
  bottom: 28px;
  font-family: var(--heading);
  font-size: clamp(32px, 3vw, 48px);
  font-weight: 700;
  line-height: 1;
  letter-spacing: -.04em;
}
.recovery-copy h2 { font-size: clamp(42px, 5vw, 70px); }
.recovery-copy > p:not(.section-index) { margin: 28px 0 0; max-width: 650px; font-size: 18px; color: var(--ink-500); }
.recovery-copy ul { margin: 34px 0 0; padding: 0; list-style: none; border-top: 1px solid var(--line); }
.recovery-copy li { padding: 15px 0; border-bottom: 1px solid var(--line); font-weight: 800; }

.kiro {
  background: var(--ink);
  color: white;
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(360px, .9fr);
  gap: 70px;
  align-items: center;
  padding: 108px max(20px, calc((100vw - min(1240px, calc(100vw - 40px))) / 2));
}
.kiro .section-index { color: #EFA37A; }
.kiro h2 { font-size: clamp(48px, 5.6vw, 78px); max-width: 720px; }
.kiro-copy > p:not(.section-index) { margin: 28px 0 0; max-width: 680px; color: rgba(255,255,255,.72); font-size: 18px; }
.guardrail-strip {
  margin-top: 38px;
  border-top: 1px solid rgba(255,255,255,.2);
  border-bottom: 1px solid rgba(255,255,255,.2);
  padding: 18px 0;
  display: grid;
  grid-template-columns: minmax(150px,.32fr) 1fr;
  gap: 20px;
}
.guardrail-strip span { color: rgba(255,255,255,.66); }
.kiro-visual { min-height: 470px; position: relative; background: var(--green); border-radius: 90px 26px 26px 26px; overflow: hidden; }
.kiro-visual::after { content: ""; position: absolute; width: 210px; height: 210px; border: 40px solid rgba(255,255,255,.08); border-radius: 50%; top: -80px; right: -70px; }
.kiro-visual img { width: 295px; position: absolute; left: 50%; top: 47%; transform: translate(-50%, -50%); }
.kiro-caption { position: absolute; left: 28px; bottom: 26px; font-family: var(--heading); font-size: 27px; font-weight: 700; line-height: 1.04; }

.early-access {
  width: var(--page);
  margin: 0 auto;
  padding: 110px 0;
  display: grid;
  grid-template-columns: minmax(0, .9fr) minmax(420px, 1.1fr);
  gap: 80px;
  align-items: end;
}
.early-access h2 { font-size: clamp(44px, 5vw, 72px); max-width: 650px; }
.early-access > div > p:last-child { color: var(--ink-500); max-width: 580px; font-size: 18px; }
#waitlist-form label { display: block; font-weight: 900; margin-bottom: 10px; }
.input-row { display: grid; grid-template-columns: 1fr auto; gap: 10px; }
.input-row input {
  min-height: 54px;
  width: 100%;
  border: 2px solid var(--ink);
  border-radius: 12px;
  background: white;
  padding: 0 16px;
  color: var(--ink);
}
.turnstile-slot:empty { display: none; }
.turnstile-slot { margin-top: 14px; }
/* Sits between the button and the status line: the consent this form collects
   has to be readable next to the action that gives it, not buried in a footer. */
.consent-note { margin: 14px 0 0; max-width: 46ch; color: var(--ink-500); font-size: 13px; line-height: 1.55; }
.consent-note a { color: inherit; text-underline-offset: 3px; }
.form-status { min-height: 24px; margin: 10px 0 0; color: var(--ink-500); font-size: 14px; }
.form-status[data-state="success"] { color: var(--green); font-weight: 800; }
.form-status[data-state="error"] { color: var(--red); font-weight: 800; }

footer {
  width: var(--page);
  margin: 0 auto;
  border-top: 1px solid var(--line);
  padding: 34px 0 48px;
  display: flex;
  flex-direction: column;
  gap: 18px;
  color: var(--ink-500);
  font-size: 13px;
}
.footer-brand { display: flex; align-items: center; gap: 18px; }
footer img { width: 48px; height: 48px; object-fit: contain; flex-shrink: 0; }
footer p { margin: 0; }
footer strong { color: var(--ink); }
.footer-legal { display: flex; flex-wrap: wrap; gap: 8px 22px; }
.footer-legal a { color: var(--ink-500); text-decoration: none; }
.footer-legal a:hover, .footer-legal a:focus-visible { color: var(--ink); text-decoration: underline; }
.legal-note { max-width: 640px; }

@keyframes mascot-breathe {
  0%, 100% { transform: translateY(0) rotate(-1deg); }
  50% { transform: translateY(-7px) rotate(1deg); }
}

@media (max-width: 980px) {
  :root { --page: min(100% - 32px, 760px); }
  .site-header nav a:not(.nav-cta) { display: none; }
  .hero,
  .recovery-story,
  .kiro,
  .early-access { grid-template-columns: 1fr; }
  .hero { gap: 46px; min-height: auto; padding: 64px 0 72px; }
  .hero h1 { font-size: clamp(54px, 12vw, 88px); }
  .hero-system { min-height: 530px; }
  .statement { grid-template-columns: 1fr; gap: 18px; }
  .food-intro { grid-template-columns: 1fr; }
  .food-intro .section-index { grid-row: auto; }
  .recovery-visual { min-height: 510px; }
  .kiro { padding-left: max(16px, calc((100vw - var(--page))/2)); padding-right: max(16px, calc((100vw - var(--page))/2)); }
  .kiro-visual { order: -1; }
  .early-access { gap: 44px; }
}

@media (max-width: 620px) {
  :root { --page: calc(100vw - 28px); }
  .site-header { min-height: 76px; }
  .brand { width: 132px; }
  .nav-cta { min-height: 44px; padding: 0 14px; }
  .hero { padding-top: 54px; }
  .hero h1 { font-size: clamp(50px, 15vw, 72px); }
  .hero-body { font-size: 18px; }
  .hero-actions { align-items: flex-start; flex-direction: column; gap: 18px; }
  .hero-system { min-height: 560px; padding: 30px 24px; border-radius: 26px 26px 72px 26px; }
  .hero-mascot { width: 155px; }
  .statement { padding-left: 18px; padding-right: 18px; }
  .statement h2,
  .food-intro h2,
  .recovery-copy h2,
  .kiro h2,
  .early-access h2 { font-size: clamp(40px, 12vw, 56px); }
  .food-language, .recovery-story, .early-access { padding-top: 82px; padding-bottom: 82px; }
  .recovery-story { gap: 48px; }
  .recovery-visual { min-height: 440px; }
  .recovery-visual img { width: 235px; right: 5px; }
  .kiro { padding-top: 82px; padding-bottom: 82px; gap: 46px; }
  .kiro-visual { min-height: 420px; }
  .kiro-visual img { width: 250px; }
  .guardrail-strip { grid-template-columns: 1fr; gap: 4px; }
  .input-row { grid-template-columns: 1fr; }
  .input-row .button { width: 100%; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    scroll-behavior: auto !important;
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
}
