:root {
  --ink: #172026;
  --muted: #5e6a72;
  --line: #d9e0e4;
  --panel: #ffffff;
  --bg: #f5f7f2;
  --mint: #0f766e;
  --blue: #2563eb;
  --amber: #d97706;
  --coral: #dc5a47;
  --soft-mint: #e7f4ef;
  --soft-blue: #eaf1ff;
  --shadow: 0 16px 36px rgba(23, 32, 38, 0.1);
}

* {
  box-sizing: border-box;
}

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

a {
  color: inherit;
}

.site-header,
.site-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 18px clamp(18px, 4vw, 56px);
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 5;
  background: rgba(245, 247, 242, 0.94);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(14px);
}

.brand,
.nav,
.site-footer nav {
  display: flex;
  align-items: center;
  gap: 16px;
}

.brand {
  text-decoration: none;
  font-weight: 800;
}

.brand-mark {
  display: inline-grid;
  width: 38px;
  height: 38px;
  place-items: center;
  border-radius: 8px;
  background: var(--mint);
  color: white;
  font-size: 0.78rem;
  letter-spacing: 0;
}

.nav a,
.site-footer a {
  color: var(--muted);
  text-decoration: none;
  font-weight: 650;
  font-size: 0.95rem;
}

.nav a:hover,
.site-footer a:hover {
  color: var(--ink);
}

main {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
}

.tool-band {
  display: grid;
  grid-template-columns: minmax(0, 0.92fr) minmax(360px, 1.08fr);
  gap: 24px;
  align-items: start;
  padding: 42px 0 28px;
}

.tool-intro,
.calculator,
.breakdown,
.content-grid article,
.faq-band,
.page-shell,
.metric-panel {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.tool-intro {
  padding: clamp(24px, 4vw, 42px);
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--mint);
  font-size: 0.82rem;
  font-weight: 800;
  text-transform: uppercase;
}

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

h1 {
  max-width: 780px;
  margin-bottom: 18px;
  font-size: clamp(2.1rem, 5vw, 4.3rem);
  line-height: 1.02;
  letter-spacing: 0;
}

h2 {
  margin-bottom: 14px;
  font-size: clamp(1.35rem, 2.6vw, 2rem);
  line-height: 1.14;
  letter-spacing: 0;
}

.lead {
  color: var(--muted);
  font-size: 1.1rem;
}

.trust-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 26px;
}

.trust-row span {
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 8px 12px;
  background: var(--soft-mint);
  color: #10524d;
  font-weight: 700;
  font-size: 0.9rem;
}

.calculator {
  padding: 22px;
}

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

label {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-weight: 750;
  font-size: 0.9rem;
}

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

input:focus,
button:focus {
  outline: 3px solid rgba(37, 99, 235, 0.22);
  outline-offset: 2px;
}

.actions,
.copy-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  margin-top: 18px;
}

button {
  min-height: 44px;
  border: 0;
  border-radius: 6px;
  padding: 11px 16px;
  font: inherit;
  font-weight: 800;
  cursor: pointer;
}

.primary {
  background: var(--ink);
  color: white;
}

.secondary {
  background: var(--soft-blue);
  color: #1742a0;
}

.primary:hover {
  background: #0b1115;
}

.secondary:hover {
  background: #dce8ff;
}

.results-band {
  display: grid;
  grid-template-columns: minmax(0, 0.92fr) minmax(360px, 1.08fr);
  gap: 24px;
  margin-bottom: 28px;
}

.metric-panel {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1px;
  overflow: hidden;
  background: var(--line);
}

.metric {
  min-height: 126px;
  padding: 20px;
  background: white;
}

.metric span {
  display: block;
  color: var(--muted);
  font-weight: 750;
}

.metric strong {
  display: block;
  margin-top: 10px;
  font-size: clamp(1.55rem, 3vw, 2.5rem);
  line-height: 1;
}

.breakdown {
  padding: 24px;
}

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

.line-item {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  border-bottom: 1px solid var(--line);
  padding-bottom: 10px;
}

.line-item span:first-child {
  color: var(--muted);
}

.line-item strong {
  white-space: nowrap;
}

.copy-note {
  min-height: 24px;
  margin: 0;
  color: var(--mint);
  font-weight: 800;
}

.ad-slot {
  min-height: 90px;
  display: grid;
  place-items: center;
  margin: 8px 0 28px;
  border: 1px dashed #a6b3ba;
  border-radius: 8px;
  background: #eef2f4;
  color: #67747c;
  font-weight: 750;
}

.content-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 22px;
  margin-bottom: 28px;
}

.content-grid article,
.faq-band,
.page-shell {
  padding: 24px;
}

.content-grid p,
.content-grid li,
.faq-band p,
.page-shell p,
.page-shell li {
  color: var(--muted);
}

ol,
ul {
  padding-left: 1.25rem;
}

.faq-band {
  margin-bottom: 38px;
}

details {
  border-top: 1px solid var(--line);
  padding: 16px 0;
}

details:first-of-type {
  margin-top: 10px;
}

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

.site-footer {
  margin-top: 20px;
  border-top: 1px solid var(--line);
  background: #eef2ea;
}

.site-footer p {
  margin: 4px 0 0;
  color: var(--muted);
}

.page-shell {
  max-width: 860px;
  margin: 42px auto;
}

.page-shell h1 {
  font-size: clamp(2rem, 4vw, 3.2rem);
}

.notice {
  border-left: 5px solid var(--amber);
  padding: 14px 16px;
  background: #fff6e7;
  color: #653c04;
  border-radius: 6px;
}

.tool-link-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-top: 22px;
}

.tool-link {
  display: block;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 16px;
  text-decoration: none;
  background: white;
}

.tool-link strong {
  display: block;
  margin-bottom: 6px;
}

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

@media (max-width: 880px) {
  .site-header,
  .site-footer {
    align-items: flex-start;
    flex-direction: column;
  }

  .nav {
    width: 100%;
    overflow-x: auto;
    padding-bottom: 2px;
  }

  .tool-band,
  .results-band,
  .content-grid {
    grid-template-columns: 1fr;
  }

  .tool-band {
    padding-top: 26px;
  }

  .results-band {
    gap: 18px;
  }
}

@media (max-width: 560px) {
  main {
    width: min(100% - 24px, 1180px);
  }

  .form-grid,
  .metric-panel,
  .tool-link-grid {
    grid-template-columns: 1fr;
  }

  .metric {
    min-height: 104px;
  }

  .site-footer nav {
    flex-wrap: wrap;
  }
}
