/* === Reset & tokens === */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; }
img { max-width: 100%; height: auto; display: block; }
button { font: inherit; cursor: pointer; }
a { color: inherit; }

:root {
  --color-primary: #15803D;
  --color-secondary: #22C55E;
  --color-accent: #0369A1;
  --color-neutral-dark: #14532D;
  --color-neutral-light: #F0FDF4;
  --color-ink: #0f2a19;
  --color-muted: #4b6b57;
  --color-line: rgba(20, 83, 45, 0.14);
  --font-heading: 'Lora', Georgia, serif;
  --font-body: 'Inter', system-ui, sans-serif;
  --radius: 12px;
  --sidebar-w: 240px;
}

body {
  font-family: var(--font-body);
  color: var(--color-ink);
  background: var(--color-neutral-light);
  line-height: 1.6;
  font-size: 16px;
}

h1, h2, h3 { font-family: var(--font-heading); color: var(--color-neutral-dark); line-height: 1.2; margin: 0 0 .75rem; font-weight: 600; letter-spacing: -0.01em; }
h1 { font-size: clamp(2rem, 5vw, 3.25rem); font-weight: 700; }
h2 { font-size: clamp(1.5rem, 3vw, 2.15rem); }
h3 { font-size: 1.2rem; }
p  { margin: 0 0 1rem; }

.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.skip-link { position: absolute; left: -1000px; top: 0; background: var(--color-neutral-dark); color: var(--color-neutral-light); padding: .5rem 1rem; z-index: 9999; }
.skip-link:focus { left: 0; }

/* === Sidebar (mobile: top header) === */
.sidebar {
  background: var(--color-neutral-dark);
  color: var(--color-neutral-light);
  padding: 1rem 1.25rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  position: sticky;
  top: 0;
  z-index: 50;
}
.sidebar .logo { display: inline-flex; }
.sidebar .logo img { height: 72px; width: auto; display: block; }
.sidebar-nav { display: none; }
.sidebar-nav.is-open { display: block; position: absolute; top: 100%; left: 0; right: 0; background: var(--color-neutral-dark); padding: 1rem 1.25rem 1.5rem; }
.sidebar-nav ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: .25rem; }
.sidebar-nav a { display: block; padding: .6rem .25rem; color: var(--color-neutral-light); text-decoration: none; font-weight: 500; border-bottom: 1px solid rgba(240,253,244,0.08); }
.sidebar-nav a[aria-current="page"] { color: var(--color-secondary); }
.sidebar-foot { display: none; }

.nav-toggle {
  background: transparent; border: 1px solid rgba(240,253,244,0.3); border-radius: 6px;
  padding: .5rem; display: inline-flex; flex-direction: column; gap: 4px;
}
.nav-toggle span { display: block; width: 22px; height: 2px; background: var(--color-neutral-light); }
.nav-toggle .sr-only { position: absolute; }

/* === Main === */
main { padding: 0; }
.hero, .section, .cta-band, .site-footer { padding-left: 1.25rem; padding-right: 1.25rem; }

/* === Hero === */
.hero { padding-top: 2.5rem; padding-bottom: 2.5rem; max-width: 960px; margin: 0 auto; }
.eyebrow { font-family: var(--font-body); font-size: .8rem; letter-spacing: .12em; text-transform: uppercase; color: var(--color-primary); font-weight: 600; margin: 0 0 .75rem; }
.hero h1 { margin-bottom: 1rem; max-width: 22ch; }
.lede { font-size: 1.15rem; color: var(--color-muted); max-width: 55ch; margin-bottom: 1.5rem; }
.hero-cta { margin: 0 0 2rem; }
.hero-figure { margin: 2rem 0 0; }
.hero-figure img { width: 100%; aspect-ratio: 16/9; object-fit: cover; border-radius: var(--radius); }

/* === Buttons === */
.btn { display: inline-block; padding: .85rem 1.5rem; border-radius: 8px; text-decoration: none; font-weight: 600; font-size: 1rem; transition: transform .15s ease, box-shadow .15s ease, background .15s ease; }
.btn-primary { background: var(--color-primary); color: #fff; }
.btn-primary:hover { background: var(--color-neutral-dark); }
.btn-accent { background: var(--color-accent); color: #fff; }
.btn-accent:hover { transform: translateY(-1px); }

/* === Sections === */
.section { padding-top: 3rem; padding-bottom: 3rem; max-width: 1080px; margin: 0 auto; }
.section.narrow { max-width: 720px; }
.section-head { text-align: left; margin-bottom: 2rem; max-width: 60ch; }
.section-head p { color: var(--color-muted); font-size: 1.05rem; }

/* === Cards === */
.cards { display: grid; grid-template-columns: 1fr; gap: 1.25rem; }
.card {
  background: #fff; border: 1px solid var(--color-line); border-radius: var(--radius);
  padding: 1.75rem; display: block; text-decoration: none; color: inherit;
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}
.card-link:hover { transform: translateY(-2px); box-shadow: 0 12px 30px -18px rgba(20,83,45,0.35); border-color: var(--color-secondary); }
.card h3 { color: var(--color-neutral-dark); margin-bottom: .5rem; }
.card p { color: var(--color-muted); margin: 0; }
.card-icon { display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; border-radius: 50%; background: var(--color-neutral-light); color: var(--color-primary); margin-bottom: 1rem; }

/* === Testimonial === */
.testimonial blockquote { margin: 0; text-align: center; max-width: 44rem; margin: 0 auto; }
.testimonial p { font-family: var(--font-heading); font-style: italic; font-size: 1.3rem; line-height: 1.5; color: var(--color-neutral-dark); }
.testimonial cite { display: block; margin-top: 1rem; font-style: normal; color: var(--color-muted); font-size: .95rem; letter-spacing: .04em; }

/* === CTA band === */
.cta-band {
  background: var(--color-primary); color: #fff; text-align: center;
  padding-top: 3.5rem; padding-bottom: 3.5rem; margin: 3rem 0 0;
}
.cta-band h2 { color: #fff; }
.cta-band p { color: rgba(255,255,255,0.9); max-width: 46ch; margin-left: auto; margin-right: auto; }
.cta-band .btn { margin-top: 1rem; }

/* === Showcase image === */
.showcase { margin: 0; }
.showcase img { width: 100%; aspect-ratio: 16/9; object-fit: cover; border-radius: var(--radius); }

/* === FAQ === */
.faq details { border-bottom: 1px solid var(--color-line); padding: 1rem 0; }
.faq summary { font-family: var(--font-heading); font-size: 1.1rem; color: var(--color-neutral-dark); cursor: pointer; list-style: none; padding-right: 1.5rem; position: relative; font-weight: 600; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: 0; top: 0; font-size: 1.4rem; color: var(--color-primary); }
.faq details[open] summary::after { content: "−"; }
.faq details p { margin: .75rem 0 0; color: var(--color-muted); }

/* === Form === */
.contact-form { display: flex; flex-direction: column; gap: 1.1rem; }
.field { display: flex; flex-direction: column; gap: .35rem; }
.field label { font-weight: 600; font-size: .95rem; color: var(--color-neutral-dark); }
.field input, .field textarea {
  font: inherit; padding: .75rem .9rem; border: 1px solid var(--color-line); border-radius: 8px; background: #fff; color: var(--color-ink);
}
.field input:focus, .field textarea:focus { outline: 2px solid var(--color-secondary); outline-offset: 1px; border-color: var(--color-secondary); }
.form-consent { display: flex; gap: .6rem; align-items: flex-start; font-size: .9rem; color: var(--color-muted); }
.form-consent input { margin-top: .25rem; }
.form-consent a { color: var(--color-primary); }

/* === Footer === */
.site-footer { background: var(--color-neutral-dark); color: var(--color-neutral-light); padding-top: 3rem; padding-bottom: 2rem; margin-top: 3rem; }
.footer-grid { display: grid; grid-template-columns: 1fr; gap: 2rem; max-width: 1080px; margin: 0 auto; }
.footer-brand { font-family: var(--font-heading); font-size: 1.4rem; font-weight: 600; margin-bottom: .25rem; color: #fff; }
.site-footer nav ul, .legal-links { list-style: none; margin: 0; padding: 0; }
.site-footer nav li, .legal-links li { margin: .35rem 0; }
.site-footer a { color: var(--color-neutral-light); text-decoration: none; }
.site-footer a:hover { color: var(--color-secondary); }
.site-footer address { font-style: normal; }
.legal-links { margin-top: 1rem; display: flex; gap: 1rem; flex-wrap: wrap; }
.copyright { max-width: 1080px; margin: 2rem auto 0; padding-top: 1.5rem; border-top: 1px solid rgba(240,253,244,0.12); font-size: .85rem; color: rgba(240,253,244,0.65); }

/* === Cookie banner === */
.cookie-banner {
  position: fixed; left: 1rem; right: 1rem; bottom: 1rem;
  display: none; z-index: 9999;
  background: var(--color-neutral-dark); color: var(--color-neutral-light);
  padding: 1.25rem; border-radius: var(--radius);
  box-shadow: 0 20px 60px -20px rgba(0,0,0,0.5);
  max-width: 640px;
}
.cookie-banner.is-visible { display: block; }
.cookie-banner p { margin: 0 0 .9rem; font-size: .95rem; }
.cookie-banner__actions { display: flex; gap: .5rem; flex-wrap: wrap; }
.cookie-banner button { background: transparent; color: var(--color-neutral-light); border: 1px solid rgba(240,253,244,0.3); border-radius: 6px; padding: .55rem .95rem; font-size: .9rem; }
.cookie-banner [data-cookie-accept] { background: var(--color-accent); border-color: var(--color-accent); color: #fff; }
.cookie-banner__prefs { margin-top: 1rem; display: flex; flex-direction: column; gap: .5rem; }
.cookie-banner__prefs label { display: flex; align-items: center; gap: .5rem; font-size: .9rem; }
.cookie-banner__prefs [data-cookie-save] { align-self: flex-start; margin-top: .5rem; }

/* === Desktop layout: sidebar-nav archetype === */
@media (min-width: 900px) {
  body.has-sidebar { display: grid; grid-template-columns: var(--sidebar-w) 1fr; min-height: 100vh; }
  .sidebar {
    position: sticky; top: 0; height: 100vh;
    display: flex; flex-direction: column; align-items: stretch; justify-content: flex-start;
    padding: 2rem 1.5rem; gap: 2rem;
  }
  .sidebar .logo img { height: 96px; }
  .sidebar-nav { display: block; position: static; padding: 0; background: transparent; }
  .sidebar-nav ul { flex-direction: column; gap: .1rem; }
  .sidebar-nav a { border-bottom: 0; padding: .5rem .5rem; border-left: 2px solid transparent; }
  .sidebar-nav a:hover { color: var(--color-secondary); }
  .sidebar-nav a[aria-current="page"] { border-left-color: var(--color-secondary); }
  .nav-toggle { display: none; }
  .sidebar-foot { display: block; margin-top: auto; font-size: .8rem; color: rgba(240,253,244,0.5); }

  main { min-width: 0; }
  .hero { padding-top: 4rem; padding-bottom: 3rem; padding-left: 3rem; padding-right: 3rem; }
  .section { padding: 4rem 3rem; }
  .cta-band { padding-left: 3rem; padding-right: 3rem; padding-top: 4.5rem; padding-bottom: 4.5rem; }
  .site-footer { padding-left: 3rem; padding-right: 3rem; }

  .cards-3 { grid-template-columns: repeat(3, 1fr); }
  .cards-4 { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1.2fr 1fr 1.4fr; }
}

@media (min-width: 1200px) {
  .cards-4 { grid-template-columns: repeat(4, 1fr); }
}
