:root {
  --ink: #17201b;
  --muted: #5f6d66;
  --paper: #f7f2ea;
  --surface: #fffaf2;
  --line: #ded3c4;
  --green: #2f6b4f;
  --green-dark: #17412f;
  --coral: #c9634a;
  --gold: #d7a842;
  --blue: #527994;
  --shadow: 0 18px 50px rgba(37, 30, 19, 0.12);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background: var(--paper);
}

a {
  color: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 18px clamp(20px, 4vw, 56px);
  background: rgba(247, 242, 234, 0.94);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(16px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  text-decoration: none;
}

.brand-mark {
  display: grid;
  width: 32px;
  height: 32px;
  place-items: center;
  color: white;
  background: var(--green);
  border-radius: 50%;
}

.top-nav {
  display: flex;
  gap: 18px;
  color: var(--muted);
  font-size: 0.95rem;
}

.top-nav a {
  text-decoration: none;
}

.hero {
  min-height: 78vh;
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(280px, 0.8fr);
  gap: clamp(28px, 5vw, 72px);
  align-items: center;
  padding: clamp(56px, 9vw, 118px) clamp(20px, 6vw, 84px);
  background:
    linear-gradient(120deg, rgba(47, 107, 79, 0.12), rgba(201, 99, 74, 0.09)),
    var(--paper);
}

.hero h1 {
  max-width: 850px;
  margin: 0;
  font-size: clamp(3rem, 7vw, 6.8rem);
  line-height: 0.96;
  letter-spacing: 0;
}

.lede {
  max-width: 660px;
  color: var(--muted);
  font-size: clamp(1.1rem, 2vw, 1.35rem);
  line-height: 1.6;
}

.eyebrow,
.panel-label {
  margin: 0 0 12px;
  color: var(--coral);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

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

.button,
button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 18px;
  border: 1px solid var(--green);
  border-radius: 6px;
  font: inherit;
  font-weight: 750;
  text-decoration: none;
  cursor: pointer;
}

.button.primary,
button {
  color: white;
  background: var(--green);
}

.button.ghost {
  color: var(--green-dark);
  background: transparent;
}

.hero-panel,
.calculator-card,
.results-card,
.content-card,
.budget-list article,
.article-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.hero-panel {
  padding: clamp(24px, 4vw, 38px);
}

.hero-panel strong {
  display: block;
  font-size: clamp(2rem, 4vw, 4rem);
  line-height: 1;
}

.hero-panel p {
  color: var(--muted);
  line-height: 1.6;
}

.section {
  padding: clamp(54px, 7vw, 92px) clamp(20px, 6vw, 84px);
}

.section-heading {
  max-width: 760px;
  margin-bottom: 30px;
}

.section-heading h2,
.split h2,
.email-section h2,
.article-hero h1 {
  margin: 0 0 12px;
  font-size: clamp(2rem, 4vw, 3.8rem);
  line-height: 1.04;
  letter-spacing: 0;
}

.section-heading p,
.split p,
.email-section p,
.article-hero p,
.article-card p {
  color: var(--muted);
  line-height: 1.65;
}

.calculator-grid {
  display: grid;
  grid-template-columns: minmax(280px, 0.9fr) minmax(280px, 1.1fr);
  gap: 22px;
  align-items: start;
}

.calculator-card,
.results-card {
  padding: clamp(20px, 3vw, 32px);
}

.form-row,
.slider-row {
  margin-bottom: 18px;
}

label,
legend {
  display: block;
  margin-bottom: 8px;
  font-weight: 750;
}

input,
select {
  width: 100%;
  min-height: 44px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  color: var(--ink);
  background: white;
  font: inherit;
}

.two-up {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.checks {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.checks label {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  color: var(--muted);
  font-weight: 650;
}

.checks input {
  width: auto;
  min-height: auto;
}

.result-main {
  margin-top: 12px;
  font-size: clamp(3rem, 7vw, 6rem);
  font-weight: 850;
  line-height: 1;
}

.result-sub {
  margin: 10px 0 24px;
  color: var(--muted);
  font-size: 1.15rem;
}

.result-strip {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-bottom: 24px;
}

.result-strip div {
  padding: 14px;
  background: #f0e7d9;
  border-radius: 6px;
}

.result-strip span {
  display: block;
  color: var(--muted);
  font-size: 0.82rem;
}

.result-strip strong {
  display: block;
  margin-top: 4px;
}

.breakdown {
  display: grid;
  gap: 10px;
}

.bar-row {
  display: grid;
  grid-template-columns: 126px 1fr 82px;
  gap: 12px;
  align-items: center;
  color: var(--muted);
  font-size: 0.92rem;
}

.bar {
  height: 10px;
  overflow: hidden;
  background: #eadfce;
  border-radius: 999px;
}

.bar span {
  display: block;
  height: 100%;
  background: var(--blue);
  border-radius: inherit;
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

.content-card {
  display: block;
  min-height: 230px;
  padding: 22px;
  text-decoration: none;
  transition: transform 180ms ease, box-shadow 180ms ease;
}

.content-card:hover {
  transform: translateY(-3px);
}

.content-card span {
  color: var(--gold);
  font-weight: 850;
}

.content-card h3 {
  margin: 28px 0 10px;
  font-size: 1.25rem;
}

.content-card p {
  color: var(--muted);
  line-height: 1.55;
}

.band {
  background: #e7eee8;
}

.link-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.link-grid a {
  padding: 18px;
  color: var(--green-dark);
  background: rgba(255, 255, 255, 0.64);
  border: 1px solid rgba(47, 107, 79, 0.18);
  border-radius: 6px;
  font-weight: 750;
  text-decoration: none;
}

.split {
  display: grid;
  grid-template-columns: minmax(280px, 0.9fr) minmax(280px, 1.1fr);
  gap: 32px;
  align-items: start;
}

.budget-list {
  display: grid;
  gap: 14px;
}

.budget-list article {
  padding: 20px;
}

.budget-list p {
  margin-bottom: 0;
}

.email-section {
  display: grid;
  grid-template-columns: minmax(280px, 1fr) minmax(280px, 0.8fr);
  gap: 28px;
  align-items: center;
  background: var(--green-dark);
  color: white;
}

.email-section p,
.email-section .eyebrow {
  color: rgba(255, 255, 255, 0.78);
}

.email-form {
  display: flex;
  gap: 10px;
}

.email-form input {
  border-color: transparent;
}

.email-form button {
  border-color: white;
  background: var(--coral);
  white-space: nowrap;
}

.site-footer {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  padding: 24px clamp(20px, 6vw, 84px);
  color: var(--muted);
  border-top: 1px solid var(--line);
}

.article-hero {
  padding: clamp(52px, 8vw, 96px) clamp(20px, 6vw, 84px) 34px;
}

.article-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: 28px;
  padding: 0 clamp(20px, 6vw, 84px) clamp(54px, 7vw, 92px);
}

.article-card {
  padding: clamp(22px, 3vw, 34px);
  margin-bottom: 16px;
}

.article-card h2 {
  margin: 0 0 12px;
  font-size: clamp(1.5rem, 2.6vw, 2.2rem);
}

.article-card li {
  margin-bottom: 10px;
  color: var(--muted);
  line-height: 1.55;
}

.aside-box {
  position: sticky;
  top: 88px;
  padding: 20px;
  background: #e7eee8;
  border: 1px solid rgba(47, 107, 79, 0.18);
  border-radius: 8px;
}

.aside-box a {
  display: block;
  margin-top: 10px;
  color: var(--green-dark);
  font-weight: 800;
}

.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;
}

@media (max-width: 940px) {
  .hero,
  .calculator-grid,
  .split,
  .email-section,
  .article-layout {
    grid-template-columns: 1fr;
  }

  .card-grid,
  .link-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .article-layout {
    padding-top: 0;
  }

  .aside-box {
    position: static;
  }
}

@media (max-width: 640px) {
  .site-header,
  .site-footer,
  .email-form {
    align-items: stretch;
    flex-direction: column;
  }

  .top-nav {
    flex-wrap: wrap;
  }

  .hero {
    min-height: auto;
  }

  .card-grid,
  .link-grid,
  .result-strip,
  .two-up {
    grid-template-columns: 1fr;
  }

  .bar-row {
    grid-template-columns: 1fr;
    gap: 6px;
  }
}
