/* Greenlit Eats site styles. Palette: cream, sage, terracotta, cocoa. */
:root {
  --cream: #F6F0E6;
  --sage: #7D9A78;
  --sage-dark: #5A7356;
  --sage-text: #4E684B;
  --sage-soft: #E9EFE7;
  --terracotta: #C5755A;
  --terra-dark: #9A4F3C;
  --terra-soft: #F7E7E0;
  --cocoa: #3C332C;
  --muted: #6B5E52;
  --white: #FFFFFF;
  --line: #E4D9C8;
  --shadow: 0 10px 30px rgba(60, 51, 44, 0.08);
  --radius: 18px;
  --header-h: 76px;
  --max: 1120px;
  --font-serif: "Fraunces", "Iowan Old Style", "Palatino Linotype", Palatino, serif;
  --font-sans: "Source Sans 3", "Source Sans Pro", "Segoe UI", sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--cream);
  color: var(--cocoa);
  font-family: var(--font-sans);
  font-size: 18px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--sage-text); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--terra-dark); }
h1, h2, h3, h4 {
  font-family: var(--font-serif);
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: -0.02em;
  color: var(--cocoa);
  margin: 0 0 0.6em;
}
h1 { font-size: clamp(2.1rem, 5vw, 3.4rem); }
h2 { font-size: clamp(1.6rem, 3.2vw, 2.2rem); }
h3 { font-size: 1.25rem; }
p { margin: 0 0 1em; }
ul, ol { margin: 0 0 1em; padding-left: 1.25em; }
.skip-link {
  position: absolute; left: 1rem; top: -4rem; z-index: 100;
  background: var(--cocoa); color: var(--cream); padding: 0.5rem 0.8rem; border-radius: 8px;
}
.skip-link:focus { top: 0.6rem; }

.wrap { width: min(var(--max), calc(100% - 2rem)); margin-inline: auto; }
.wrap-narrow { width: min(760px, calc(100% - 2rem)); margin-inline: auto; }

/* Header */
.site-header {
  position: sticky; top: 0; z-index: 50;
  height: var(--header-h);
  background: rgba(246, 240, 230, 0.92);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}
.header-inner {
  height: 100%;
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
}
.brand {
  display: flex; align-items: center; gap: 0.7rem;
  text-decoration: none; color: var(--cocoa);
  min-width: 0;
}
.brand img {
  width: 48px; height: 48px; border-radius: 14px;
  box-shadow: 0 0 0 1px rgba(60, 51, 44, 0.06);
}
.brand-text { display: flex; flex-direction: column; line-height: 1.1; }
.brand-name {
  font-family: var(--font-serif); font-weight: 600; font-size: 1.15rem; letter-spacing: -0.02em;
}
.brand-tag { font-size: 0.72rem; color: var(--muted); letter-spacing: 0.02em; margin-top: 0.15rem; }

.nav-toggle {
  display: none;
  background: transparent; border: 1px solid var(--line); color: var(--cocoa);
  border-radius: 10px; padding: 0.4rem 0.7rem; font: inherit; font-size: 0.95rem; cursor: pointer;
}
.site-nav { display: flex; align-items: center; gap: 0.2rem 1.1rem; }
.site-nav a {
  text-decoration: none; color: var(--cocoa); font-weight: 600; font-size: 1rem;
  padding: 0.35rem 0.15rem;
}
.site-nav a[aria-current="page"] { color: var(--sage-text); }
.site-nav a:hover { color: var(--terra-dark); }
.nav-pin {
  display: inline-flex; align-items: center; gap: 0.35rem;
  background: var(--sage); color: var(--cream) !important;
  padding: 0.4rem 0.8rem !important; border-radius: 999px; font-size: 0.92rem !important;
}
.nav-pin:hover { background: var(--sage-dark); color: var(--white) !important; }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.4rem;
  border-radius: 999px; padding: 0.7rem 1.25rem;
  font-weight: 600; font-size: 1rem; text-decoration: none; border: 0; cursor: pointer;
  font-family: inherit; line-height: 1;
}
.btn-primary { background: var(--terracotta); color: var(--white); }
.btn-primary:hover { background: var(--terra-dark); color: var(--white); }
.btn-secondary { background: var(--cocoa); color: var(--cream); }
.btn-secondary:hover { background: #2a241f; color: var(--white); }
.btn-ghost {
  background: transparent; color: var(--cocoa);
  border: 1.5px solid var(--cocoa);
}
.btn-ghost:hover { background: var(--cocoa); color: var(--cream); }
.btn-row { display: flex; flex-wrap: wrap; gap: 0.7rem; }

/* Hero */
.hero {
  padding: 3.2rem 0 2.6rem;
}
.hero-grid {
  display: grid; grid-template-columns: 1.15fr 0.85fr; gap: 2.4rem; align-items: center;
}
.eyebrow {
  display: inline-flex; align-items: center; gap: 0.5rem;
  font-size: 0.82rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--sage-text); margin-bottom: 0.9rem;
}
.hero h1 { margin-bottom: 0.7rem; }
.hero .lede { font-size: 1.15rem; color: var(--muted); max-width: 38em; margin-bottom: 1.3rem; }
.badges { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-bottom: 1.5rem; }
.badge {
  display: inline-flex; align-items: center; gap: 0.35rem;
  background: var(--sage-soft); color: var(--sage-text);
  border-radius: 999px; padding: 0.35rem 0.75rem; font-size: 0.88rem; font-weight: 600;
}
.badge-terra { background: var(--terra-soft); color: var(--terra-dark); }
.hero-photo {
  border-radius: 28px; overflow: hidden; box-shadow: var(--shadow);
  aspect-ratio: 1 / 1.05; background: var(--sage-soft);
}
.hero-photo img { width: 100%; height: 100%; object-fit: cover; }

/* Cards */
.section { padding: 2.6rem 0; }
.section-head {
  display: flex; justify-content: space-between; align-items: end; gap: 1rem;
  margin-bottom: 1.5rem; flex-wrap: wrap;
}
.section-kicker {
  font-size: 0.78rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--terra-dark); margin-bottom: 0.35rem;
}
.card-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
}
.card {
  background: var(--white);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  border: 1px solid rgba(60, 51, 44, 0.05);
  display: flex; flex-direction: column;
  text-decoration: none; color: inherit;
  height: 100%;
}
a.card:hover { transform: translateY(-3px); box-shadow: 0 16px 36px rgba(60, 51, 44, 0.12); }
a.card { transition: transform 0.2s ease, box-shadow 0.2s ease; }
.card-img { aspect-ratio: 4 / 3; overflow: hidden; background: var(--sage-soft); }
.card-img img { width: 100%; height: 100%; object-fit: cover; }
.card-body { padding: 1.05rem 1.15rem 1.2rem; display: flex; flex-direction: column; gap: 0.35rem; flex: 1; }
.card-cat {
  font-size: 0.75rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--sage-text);
}
.card h3 { font-size: 1.2rem; margin: 0; }
.card-meta { color: var(--muted); font-size: 0.92rem; margin-top: auto; padding-top: 0.4rem; }

/* How it works */
.how-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.15rem; }
.how-card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 1.4rem 1.3rem 1.5rem;
  border: 1px solid rgba(60, 51, 44, 0.05);
  box-shadow: var(--shadow);
}
.how-icon {
  width: 48px; height: 48px; border-radius: 14px;
  display: grid; place-items: center;
  background: var(--sage-soft); color: var(--sage-text);
  margin-bottom: 0.9rem; font-size: 1.3rem;
}
.how-card.terra .how-icon { background: var(--terra-soft); color: var(--terra-dark); }
.how-card h3 { margin-bottom: 0.4rem; }
.how-card p { color: var(--muted); margin: 0; font-size: 1rem; }

/* Recipe page */
.crumb {
  font-size: 0.95rem; color: var(--muted); margin: 1.3rem 0 1rem;
}
.crumb a { color: var(--sage-text); text-decoration: none; font-weight: 600; }
.crumb a:hover { text-decoration: underline; }
.recipe-hero { padding-bottom: 1rem; }
.recipe-hero-grid {
  display: grid; grid-template-columns: 1.05fr 0.95fr; gap: 2rem; align-items: start;
}
.recipe-hero-photo {
  border-radius: 24px; overflow: hidden; box-shadow: var(--shadow);
  aspect-ratio: 4 / 3; background: var(--sage-soft);
}
.recipe-hero-photo img { width: 100%; height: 100%; object-fit: cover; }
.recipe-actions { display: flex; flex-wrap: wrap; gap: 0.6rem; margin: 1.1rem 0 0.4rem; }
.times {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 0.6rem;
  margin: 1.1rem 0 0;
}
.time-cell {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 0.7rem 0.75rem;
}
.time-label {
  display: block; font-size: 0.72rem; font-weight: 700; letter-spacing: 0.08em;
  text-transform: uppercase; color: var(--muted);
}
.time-value { font-weight: 600; font-size: 0.98rem; }

.safety {
  background: var(--sage-soft);
  border-left: 6px solid var(--sage);
  border-radius: 16px;
  padding: 1.15rem 1.25rem;
  margin: 1.6rem 0;
}
.safety h2 { font-size: 1.15rem; margin-bottom: 0.7rem; }
.safety-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.safety h3 {
  font-family: var(--font-sans); font-size: 0.78rem; letter-spacing: 0.08em;
  text-transform: uppercase; color: var(--sage-text); margin-bottom: 0.3rem;
}
.safety p { margin: 0; font-size: 1rem; }

.recipe-card {
  background: var(--white);
  border-radius: 24px;
  box-shadow: var(--shadow);
  border: 1px solid rgba(60, 51, 44, 0.05);
  padding: 1.6rem 1.5rem 1.8rem;
  margin: 1.5rem 0 2rem;
}
.recipe-card h2 { margin-top: 1.1rem; }
.recipe-card h2:first-child { margin-top: 0; }
.ing-group { margin-bottom: 0.85rem; }
.ing-group h3 {
  font-family: var(--font-sans); font-size: 0.95rem; color: var(--sage-text);
  letter-spacing: 0.02em; margin: 0 0 0.3rem;
}
.steps { padding-left: 1.2em; }
.steps li { margin-bottom: 0.7rem; padding-left: 0.3rem; }
.notes { background: var(--cream); border-radius: 14px; padding: 1rem 1.1rem; }
.notes li { margin-bottom: 0.4rem; }
.callout-warn {
  background: var(--terra-soft);
  border-left: 6px solid var(--terracotta);
  border-radius: 16px;
  padding: 1rem 1.15rem;
  margin: 1rem 0;
}
.callout-warn h3 { font-family: var(--font-sans); font-size: 0.95rem; color: var(--terra-dark); margin-bottom: 0.3rem; }
.callout-warn p { margin: 0; }

.guide-section { margin: 1.2rem 0 1.5rem; }
.simple-table {
  width: 100%; border-collapse: collapse; font-size: 1rem;
  background: var(--white); border-radius: 12px; overflow: hidden;
}
.simple-table th, .simple-table td {
  text-align: left; padding: 0.65rem 0.8rem; border-bottom: 1px solid var(--line); vertical-align: top;
}
.simple-table th { background: var(--sage); color: var(--cream); font-weight: 600; }
.simple-table tr:last-child td { border-bottom: 0; }
.simple-table tr:nth-child(even) td { background: var(--cream); }

/* Filters */
.filters { display: flex; flex-wrap: wrap; gap: 0.5rem; margin: 0 0 1.5rem; }
.filter-btn {
  border: 1.5px solid var(--line); background: var(--white); color: var(--cocoa);
  border-radius: 999px; padding: 0.45rem 0.9rem; font: inherit; font-weight: 600;
  font-size: 0.95rem; cursor: pointer;
}
.filter-btn[aria-pressed="true"], .filter-btn:hover {
  background: var(--cocoa); color: var(--cream); border-color: var(--cocoa);
}

/* Products */
.product-feature {
  background: var(--white);
  border-radius: 24px;
  padding: 1.5rem 1.5rem 1.6rem;
  box-shadow: var(--shadow);
  border: 1px solid rgba(60, 51, 44, 0.05);
  margin-bottom: 1.6rem;
}
.product-list { display: grid; gap: 1rem; }
.product {
  background: var(--white);
  border-radius: 18px;
  padding: 1.15rem 1.2rem 1.2rem;
  border: 1px solid rgba(60, 51, 44, 0.06);
  box-shadow: var(--shadow);
}
.product h3 { margin-bottom: 0.15rem; font-size: 1.2rem; }
.product-brand { color: var(--muted); font-size: 0.95rem; margin-bottom: 0.6rem; }
.status {
  display: inline-block; border-radius: 999px; padding: 0.2rem 0.6rem;
  font-size: 0.75rem; font-weight: 700; letter-spacing: 0.03em;
  margin: 0 0.3rem 0.5rem 0;
}
.status-certified { background: var(--sage-soft); color: var(--sage-text); }
.status-fodmap-friendly { background: var(--sage-soft); color: var(--sage-text); }
.status-brand-listed { background: #F3EDE0; color: #6A5430; }
.status-ingredient-fit { background: var(--terra-soft); color: var(--terra-dark); }
.flag {
  display: inline-block; background: var(--cream); border: 1px solid var(--line);
  border-radius: 999px; padding: 0.15rem 0.55rem; font-size: 0.8rem; color: var(--muted);
  margin: 0 0.25rem 0.4rem 0;
}
.coming-soon {
  background: linear-gradient(180deg, var(--white), var(--sage-soft));
  border: 1px dashed var(--sage);
  border-radius: 24px;
  padding: 1.6rem 1.5rem;
  margin-top: 2rem;
}

/* Footer */
.site-footer {
  margin-top: 3rem;
  background: var(--cocoa);
  color: #E8DFD3;
  padding: 2.4rem 0 1.6rem;
}
.site-footer a { color: #F6F0E6; }
.footer-grid {
  display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 2rem;
  padding-bottom: 1.6rem; border-bottom: 1px solid rgba(246, 240, 230, 0.12);
}
.footer-brand { display: flex; align-items: center; gap: 0.7rem; margin-bottom: 0.8rem; }
.footer-brand img { width: 42px; height: 42px; border-radius: 12px; }
.footer-brand span { font-family: var(--font-serif); font-size: 1.2rem; color: var(--cream); }
.footer-col h2 {
  font-family: var(--font-sans); font-size: 0.78rem; letter-spacing: 0.1em;
  text-transform: uppercase; color: #C9B9A6; margin-bottom: 0.7rem;
}
.footer-col ul { list-style: none; padding: 0; margin: 0; }
.footer-col li { margin: 0.35rem 0; }
.footer-note { font-size: 0.88rem; color: #C9B9A6; margin: 1.1rem 0 0; }

/* 404 */
.page-404 { text-align: center; padding: 4rem 0 5rem; }
.page-404 h1 { margin-bottom: 0.6rem; }

.prose h2 { margin-top: 1.6rem; }
.prose .lede { font-size: 1.15rem; color: var(--muted); }

@media (max-width: 900px) {
  .hero-grid, .recipe-hero-grid, .how-grid, .card-grid { grid-template-columns: 1fr 1fr; }
  .times { grid-template-columns: 1fr 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .safety-grid { grid-template-columns: 1fr; }
}
@media (max-width: 700px) {
  :root { --header-h: 68px; }
  .nav-toggle { display: inline-flex; }
  .site-nav {
    display: none;
    position: absolute; top: var(--header-h); left: 0; right: 0;
    background: var(--cream);
    border-bottom: 1px solid var(--line);
    flex-direction: column; align-items: stretch;
    padding: 0.7rem 1rem 1rem; gap: 0.2rem;
  }
  body.nav-open .site-nav { display: flex; }
  .site-nav a { padding: 0.65rem 0.3rem; }
  .nav-pin { justify-content: center; margin-top: 0.3rem; }
  .hero { padding: 1.8rem 0 1.6rem; }
  .hero-grid, .recipe-hero-grid, .how-grid, .card-grid, .footer-grid { grid-template-columns: 1fr; }
  .hero-photo { aspect-ratio: 4 / 3; max-height: 320px; }
  .brand-tag { display: none; }
}

@media print {
  .skip-link, .site-header, .site-footer, .recipe-actions, .crumb,
  .recipe-hero-photo, .related, .no-print, .nav-toggle { display: none !important; }
  body { background: #fff; color: #000; font-size: 12pt; }
  .recipe-card, .safety, .notes, .callout-warn {
    box-shadow: none; border: 1px solid #ccc; break-inside: avoid;
  }
  a { color: inherit; text-decoration: none; }
  .wrap, .wrap-narrow { width: auto; margin: 0; }
  .recipe-hero { padding: 0; }
  h1 { font-size: 22pt; }
}
