/* ============================================================
   EcoLibera LLC — shared stylesheet
   Palette: "digestate pale" backgrounds, deep tank green,
   biogas-flame teal accent, warm soil brown.
   Type: Space Grotesk (display/technical) + Source Serif 4 (body, trust)
         + JetBrains Mono (specs / data)
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@500;600;700&family=Source+Serif+4:ital,opsz,wght@0,8..60,400;0,8..60,500;0,8..60,600;1,8..60,400&family=JetBrains+Mono:wght@400;500;600&display=swap');

:root {
  --bg: #EEF1EA;
  --bg-alt: #E2E8DB;
  --paper: #FFFFFF;
  --ink: #16241C;
  --ink-soft: #47584C;
  --tank: #1B4332;
  --tank-dark: #12301F;
  --flame: #237E77;
  --flame-bright: #2FA8A0;
  --soil: #8C6A4E;
  --soil-pale: #E7DDCF;
  --line: #CBD3C2;
  --radius: 4px;
  --max: 1120px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: 'Source Serif 4', Georgia, serif;
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, .eyebrow, nav, .btn, .stat-label, .field label {
  font-family: 'Space Grotesk', 'Segoe UI', sans-serif;
}

h1, h2, h3, h4 {
  color: var(--tank-dark);
  line-height: 1.15;
  margin: 0 0 0.5em 0;
  font-weight: 600;
  letter-spacing: -0.01em;
}

h1 { font-size: clamp(2.1rem, 4.5vw, 3.4rem); font-weight: 700; }
h2 { font-size: clamp(1.5rem, 3vw, 2.1rem); }
h3 { font-size: 1.2rem; }

p { margin: 0 0 1.1em 0; max-width: 62ch; }

a { color: var(--flame); }

img { max-width: 100%; display: block; }

.mono, code, .spec-table, .stat-value {
  font-family: 'JetBrains Mono', 'Courier New', monospace;
}

.wrap {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 28px;
}

/* -------------------- header / nav -------------------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(238, 241, 234, 0.92);
  backdrop-filter: blur(6px);
  border-bottom: 1px solid var(--line);
}

.nav-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 0;
  gap: 20px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--ink);
}

.brand img { height: 40px; width: auto; }

.brand-name {
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 700;
  font-size: 1.15rem;
  color: var(--tank-dark);
  letter-spacing: -0.01em;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 6px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav-links a {
  text-decoration: none;
  color: var(--ink-soft);
  font-size: 0.95rem;
  font-weight: 500;
  padding: 8px 14px;
  border-radius: var(--radius);
  transition: background 0.15s, color 0.15s;
}

.nav-links a:hover,
.nav-links a[aria-current="page"] {
  background: var(--soil-pale);
  color: var(--tank-dark);
}

.nav-toggle { display: none; }

/* -------------------- buttons -------------------- */

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  padding: 12px 22px;
  border-radius: var(--radius);
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.12s ease, background 0.15s, border-color 0.15s;
}

.btn:hover { transform: translateY(-1px); }

.btn-primary {
  background: var(--flame);
  color: #F5FBF9;
}
.btn-primary:hover { background: var(--flame-bright); }

.btn-outline {
  background: transparent;
  border-color: var(--tank-dark);
  color: var(--tank-dark);
}
.btn-outline:hover { background: var(--tank-dark); color: #EAF2EC; }

.btn-ghost-light {
  background: transparent;
  border-color: rgba(255,255,255,0.5);
  color: #EAF2EC;
}
.btn-ghost-light:hover { background: rgba(255,255,255,0.12); }

/* -------------------- hero -------------------- */

.hero {
  background: linear-gradient(160deg, var(--tank) 0%, var(--tank-dark) 70%);
  color: #E9F1EB;
  padding: 84px 0 96px;
  position: relative;
  overflow: hidden;
}

.hero::after {
  content: "";
  position: absolute;
  right: -120px;
  top: -80px;
  width: 420px;
  height: 420px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(47,168,160,0.35) 0%, rgba(47,168,160,0) 70%);
}

.hero .eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--flame-bright);
  margin-bottom: 14px;
  display: block;
}

.hero h1 { color: #fff; max-width: 15ch; }

.hero p.lede {
  color: rgba(233, 241, 235, 0.86);
  font-size: 1.1rem;
  max-width: 56ch;
  margin-top: 18px;
}

.hero-actions {
  display: flex;
  gap: 14px;
  margin-top: 30px;
  flex-wrap: wrap;
}

/* -------------------- sections -------------------- */

section { padding: 72px 0; }
.section-alt { background: var(--bg-alt); }
.section-paper { background: var(--paper); }

.section-head { max-width: 68ch; margin-bottom: 40px; }
.section-head .eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--flame);
  display: block;
  margin-bottom: 10px;
}

/* -------------------- cards / grids -------------------- */

.grid {
  display: grid;
  gap: 22px;
}
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }

.card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 26px 24px;
}

.card h3 { margin-bottom: 10px; }
.card p { margin-bottom: 0; }

/* -------------------- process rail (signature element) -------------------- */

.process-rail {
  display: flex;
  gap: 0;
  counter-reset: step;
  overflow-x: auto;
  padding-bottom: 6px;
}

.process-step {
  counter-increment: step;
  flex: 1 1 0;
  min-width: 190px;
  position: relative;
  padding: 0 20px 0 0;
}

.process-step:not(:last-child)::after {
  content: "";
  position: absolute;
  top: 17px;
  right: 0;
  width: 100%;
  height: 2px;
  background: repeating-linear-gradient(90deg, var(--flame) 0 6px, transparent 6px 12px);
}

.process-step .num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--tank);
  color: #EAF2EC;
  font-family: 'JetBrains Mono', monospace;
  font-weight: 600;
  font-size: 0.9rem;
  margin-bottom: 14px;
  position: relative;
  z-index: 2;
}

.process-step h4 { font-size: 1rem; margin-bottom: 6px; }
.process-step p { font-size: 0.92rem; color: var(--ink-soft); }

/* -------------------- spec table -------------------- */

.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); }

table.spec-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--paper);
  font-size: 0.88rem;
}

.spec-table th, .spec-table td {
  padding: 12px 16px;
  text-align: left;
  border-bottom: 1px solid var(--line);
  white-space: nowrap;
}

.spec-table thead th {
  background: var(--tank);
  color: #EAF2EC;
  font-weight: 500;
  letter-spacing: 0.02em;
}

.spec-table tbody tr:hover { background: var(--soil-pale); }
.spec-table tbody tr:last-child td { border-bottom: none; }

/* -------------------- stat strip -------------------- */

.stat-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 28px;
  justify-content: space-between;
}

.stat {
  flex: 1 1 160px;
}

.stat-value {
  font-size: 2rem;
  font-weight: 600;
  color: var(--flame);
  display: block;
}

.stat-label {
  font-size: 0.82rem;
  color: var(--ink-soft);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

/* -------------------- audience segments -------------------- */

.segment {
  border-left: 3px solid var(--flame);
  padding: 4px 0 4px 20px;
}
.segment h3 { margin-bottom: 6px; }
.segment p { color: var(--ink-soft); font-size: 0.96rem; margin-bottom: 0; }

/* -------------------- callout / CTA band -------------------- */

.callout {
  background: var(--tank-dark);
  color: #E9F1EB;
  border-radius: var(--radius);
  padding: 48px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 26px;
}
.callout h2 { color: #fff; margin: 0; max-width: 22ch; }
.callout p { color: rgba(233,241,235,0.82); margin: 8px 0 0 0; }

/* -------------------- forms -------------------- */

form.contact-form {
  display: grid;
  gap: 18px;
  max-width: 560px;
}

.field { display: flex; flex-direction: column; gap: 6px; }

.field label {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--ink-soft);
  font-weight: 500;
}

.field input, .field textarea, .field select {
  font-family: 'Source Serif 4', serif;
  font-size: 1rem;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
  color: var(--ink);
}

.field textarea { resize: vertical; min-height: 120px; }

.field input:focus, .field textarea:focus, .field select:focus,
a:focus-visible, .btn:focus-visible {
  outline: 3px solid var(--flame-bright);
  outline-offset: 2px;
}

/* -------------------- footer -------------------- */

footer {
  background: var(--tank-dark);
  color: rgba(233,241,235,0.78);
  padding: 52px 0 30px;
}

footer .foot-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 30px;
  margin-bottom: 34px;
}

footer h4 { color: #EAF2EC; font-size: 0.95rem; margin-bottom: 14px; }
footer a { color: rgba(233,241,235,0.78); text-decoration: none; }
footer a:hover { color: var(--flame-bright); }
footer p { color: rgba(233,241,235,0.65); font-size: 0.92rem; }

.foot-brand { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
.foot-brand img { height: 32px; filter: brightness(0) invert(1); opacity: 0.92; }
.foot-brand span { font-family: 'Space Grotesk', sans-serif; font-weight: 700; color: #fff; }

.foot-bottom {
  border-top: 1px solid rgba(233,241,235,0.15);
  padding-top: 20px;
  font-size: 0.82rem;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
  color: rgba(233,241,235,0.55);
}

/* -------------------- responsive -------------------- */

@media (max-width: 860px) {
  .grid-3, .grid-2 { grid-template-columns: 1fr; }
  footer .foot-grid { grid-template-columns: 1fr; }
  .process-rail { flex-direction: column; }
  .process-step:not(:last-child)::after { display: none; }
}

@media (max-width: 720px) {
  .nav-links {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--bg);
    flex-direction: column;
    align-items: stretch;
    border-bottom: 1px solid var(--line);
    padding: 10px 20px 16px;
    display: none;
  }
  .nav-links.open { display: flex; }
  .nav-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: transparent;
    cursor: pointer;
  }
  .nav-cta { display: none; }
  .callout { flex-direction: column; align-items: flex-start; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .btn:hover { transform: none; }
}
