:root {
  color-scheme: light;
  --bg: #f8fbff;
  --surface: #ffffff;
  --surface-2: #edf6ff;
  --text: #182131;
  --muted: #627083;
  --line: #dbe7f2;
  --green: #128263;
  --green-2: #0d6752;
  --blue: #2563eb;
  --amber: #b46a0b;
  --ink: #10233f;
  --shadow: 0 16px 44px rgba(22, 45, 72, .09);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
}

a {
  color: inherit;
  text-decoration: none;
}

.siteHeader {
  background:
    radial-gradient(circle at top left, rgba(37,99,235,.13), transparent 36%),
    linear-gradient(120deg, rgba(18,130,99,.12), transparent 42%),
    linear-gradient(180deg, #ffffff, var(--bg));
  border-bottom: 1px solid var(--line);
}

.nav {
  width: min(1160px, calc(100% - 32px));
  margin: 0 auto;
  min-height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-weight: 850;
}

.brandMark {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: linear-gradient(135deg, var(--blue), var(--green));
  color: white;
  font-size: 24px;
  font-weight: 950;
  line-height: 1;
  box-shadow: 0 10px 24px rgba(37,99,235,.2);
}

.domainPill {
  padding: 4px 8px;
  border: 1px solid rgba(37,99,235,.18);
  border-radius: 999px;
  background: #eef5ff;
  color: var(--blue);
  font-size: 12px;
  font-weight: 900;
}

.navLinks {
  display: flex;
  gap: 18px;
  color: var(--muted);
  font-size: 14px;
}

.hero {
  width: min(1160px, calc(100% - 32px));
  margin: 0 auto;
  min-height: 420px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  align-items: center;
  gap: 36px;
  padding: 48px 0 58px;
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--green);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: .08em;
  text-transform: uppercase;
}

h1, h2, h3, p {
  margin-top: 0;
}

h1 {
  max-width: 820px;
  margin-bottom: 18px;
  font-size: clamp(36px, 6vw, 68px);
  line-height: .98;
  letter-spacing: 0;
}

h2 {
  margin-bottom: 10px;
  font-size: clamp(28px, 4vw, 42px);
  line-height: 1.08;
  letter-spacing: 0;
}

h3 {
  margin-bottom: 12px;
  font-size: 20px;
}

.lead {
  max-width: 720px;
  color: var(--muted);
  font-size: 18px;
  line-height: 1.65;
}

.heroStats {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 22px 0;
}

.heroStats span {
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255,255,255,.72);
  color: var(--muted);
}

.heroStats strong {
  color: var(--green-2);
  font-size: 20px;
}

.searchBox {
  width: min(680px, 100%);
  min-height: 62px;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  padding: 8px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: white;
  box-shadow: var(--shadow);
}

input, select {
  width: 100%;
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 12px;
  background: #fbfdfc;
  color: var(--text);
  font: inherit;
}

.searchBox input {
  border: 0;
  background: transparent;
  font-size: 16px;
}

button {
  min-height: 44px;
  border: 0;
  border-radius: 8px;
  padding: 0 16px;
  background: var(--green);
  color: white;
  font: inherit;
  font-weight: 800;
  cursor: pointer;
}

button.secondary {
  background: var(--surface-2);
  color: var(--green-2);
}

.ctaLink {
  min-height: 46px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-top: 8px;
  padding: 0 16px;
  border-radius: 8px;
  background: var(--green);
  color: #fff;
  font-weight: 850;
}

.heroPanel {
  display: grid;
  gap: 10px;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255,255,255,.8);
  box-shadow: var(--shadow);
}

.heroPanel strong {
  margin-bottom: 6px;
}

.heroPanel a {
  padding: 12px;
  border-radius: 8px;
  background: var(--surface-2);
  color: var(--green-2);
  font-weight: 750;
}

.section,
.contentBand {
  width: min(1160px, calc(100% - 32px));
  margin: 0 auto;
  padding: 48px 0;
}

.sectionHead {
  max-width: 760px;
  margin-bottom: 24px;
}

.sectionHead p {
  color: var(--muted);
  line-height: 1.65;
}

.categoryCards {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.categoryCards a {
  display: grid;
  gap: 8px;
  min-height: 128px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: 0 8px 24px rgba(28,58,43,.05);
}

.categoryCards strong {
  color: var(--green-2);
  font-size: 20px;
}

.categoryCards span,
.toolBar p {
  color: var(--muted);
}

.toolBar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 18px;
}

.filterChips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.chip {
  min-height: 38px;
  padding: 0 12px;
  border: 1px solid var(--line);
  background: white;
  color: var(--muted);
  box-shadow: none;
}

.chip.active {
  background: var(--green);
  color: white;
  border-color: var(--green);
}

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

.calcCard {
  min-height: 372px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: 0 10px 30px rgba(28,58,43,.06);
}

.calcCard.hidden {
  display: none;
}

.calcTop {
  display: flex;
  justify-content: space-between;
  gap: 12px;
}

.cardMeta,
.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 10px;
}

.cardMeta span,
.cardMeta b,
.tags span {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 3px 8px;
  border-radius: 999px;
  background: var(--surface-2);
  color: var(--green-2);
  font-size: 12px;
  font-weight: 800;
}

.cardMeta b {
  background: #fff2dc;
  color: var(--amber);
}

.tags {
  margin-top: -4px;
}

.tags span {
  background: transparent;
  border: 1px solid var(--line);
  color: var(--muted);
  font-weight: 650;
}

.calcIcon {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  border-radius: 8px;
  background: var(--surface-2);
  color: var(--green-2);
  font-weight: 900;
}

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

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

.fieldRow {
  display: grid;
  gap: 6px;
}

.fieldRow label {
  color: var(--muted);
  font-size: 13px;
  font-weight: 750;
}

.resultBox {
  margin-top: auto;
  padding: 14px;
  border-radius: 8px;
  background: #f1f7f4;
  border: 1px solid #d8e9df;
}

.resultBox strong {
  display: block;
  color: var(--green-2);
  font-size: 20px;
  line-height: 1.25;
}

.resultBox span {
  display: block;
  margin-top: 6px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
}

.adSlot {
  width: min(1160px, calc(100% - 32px));
  min-height: 84px;
  margin: 22px auto;
  display: grid;
  place-items: center;
  border: 1px dashed #b8cbbf;
  border-radius: 8px;
  background: #edf4f0;
  color: var(--muted);
  font-size: 14px;
}

.contentBand {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 420px;
  gap: 32px;
  align-items: start;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.contentBand p {
  color: var(--muted);
  line-height: 1.75;
}

.tips {
  display: grid;
  gap: 12px;
}

.tips article {
  display: grid;
  gap: 4px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: white;
}

.tips span {
  color: var(--muted);
}

.faq {
  display: grid;
  gap: 12px;
}

.editorial {
  border-top: 1px solid var(--line);
}

.articleGrid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.articleGrid article {
  min-height: 160px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: white;
}

.articleGrid span {
  display: block;
  color: var(--green);
  font-weight: 900;
  margin-bottom: 14px;
}

.articleGrid strong {
  display: block;
  margin-bottom: 8px;
  font-size: 18px;
}

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

details {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: white;
  padding: 16px 18px;
}

summary {
  cursor: pointer;
  font-weight: 850;
}

details p {
  margin: 12px 0 0;
  color: var(--muted);
  line-height: 1.6;
}

.footer {
  width: min(1160px, calc(100% - 32px));
  margin: 0 auto;
  padding: 28px 0 40px;
  display: flex;
  justify-content: space-between;
  gap: 18px;
  color: var(--muted);
  border-top: 1px solid var(--line);
}

.footer a {
  color: var(--green-2);
  font-weight: 800;
}

.footerLinks {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

@media (max-width: 980px) {
  .hero,
  .contentBand {
    grid-template-columns: 1fr;
  }

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

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

@media (max-width: 640px) {
  .nav {
    align-items: flex-start;
    flex-direction: column;
    padding: 18px 0;
  }

  .navLinks {
    width: 100%;
    justify-content: space-between;
  }

  .hero {
    min-height: unset;
    padding-top: 30px;
  }

  .searchBox {
    grid-template-columns: 1fr;
  }

  .calculatorGrid {
    grid-template-columns: 1fr;
  }

  .categoryCards,
  .articleGrid {
    grid-template-columns: 1fr;
  }

  .toolBar {
    align-items: flex-start;
    flex-direction: column;
  }

  .calcCard {
    min-height: unset;
  }

  .footer {
    flex-direction: column;
  }
}
