:root {
  --ink: #17211b;
  --muted: #607064;
  --line: #d8ded5;
  --paper: #fbfcf8;
  --surface: #ffffff;
  --sage: #537b5b;
  --sage-dark: #2f5c3a;
  --clay: #c66f42;
  --sky: #dbeef4;
  --gold: #f1c95b;
  --shadow: 0 18px 50px rgba(36, 52, 41, 0.14);
}

* {
  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:
    linear-gradient(135deg, rgba(219, 238, 244, 0.62), rgba(251, 252, 248, 0) 34%),
    linear-gradient(180deg, #fbfcf8 0%, #f3f6ef 100%);
}

a {
  color: inherit;
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  min-height: 72px;
  padding: 16px clamp(18px, 5vw, 72px);
  border-bottom: 1px solid var(--line);
  background: rgba(251, 252, 248, 0.92);
  position: sticky;
  top: 0;
  z-index: 2;
  backdrop-filter: blur(12px);
}

.brand,
.nav {
  display: flex;
  align-items: center;
}

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

.brand-mark {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 8px;
  color: white;
  background: var(--sage-dark);
}

.nav {
  gap: 20px;
  color: var(--muted);
  font-size: 0.94rem;
}

.nav a {
  text-decoration: none;
}

.workspace {
  display: grid;
  grid-template-columns: minmax(260px, 0.82fr) minmax(320px, 1.08fr);
  grid-template-areas:
    "intro form"
    "intro results";
  gap: 22px;
  padding: clamp(28px, 5vw, 72px);
  max-width: 1220px;
  margin: 0 auto;
}

.intro-panel {
  grid-area: intro;
  align-self: stretch;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 22px;
  min-height: 620px;
  padding: clamp(24px, 4vw, 48px);
  border: 1px solid var(--line);
  border-radius: 8px;
  background:
    linear-gradient(160deg, rgba(83, 123, 91, 0.93), rgba(47, 92, 58, 0.94)),
    url("assets/pricing-ledger.svg");
  background-size: cover;
  color: white;
  box-shadow: var(--shadow);
}

.intro-panel h1,
.intro-panel p {
  max-width: 540px;
}

.intro-panel h1 {
  margin: 0;
  font-size: clamp(2.1rem, 5vw, 4.8rem);
  line-height: 0.95;
}

.intro-panel p {
  margin: 0;
  color: rgba(255, 255, 255, 0.84);
  font-size: 1.05rem;
  line-height: 1.65;
}

.eyebrow {
  margin: 0 0 8px;
  color: var(--clay);
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

.intro-panel .eyebrow {
  color: var(--gold);
}

.visual-strip {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  width: min(100%, 480px);
}

.visual-strip div {
  min-width: 0;
  padding: 16px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.13);
}

.visual-strip span,
.result-main span,
.guide-grid span {
  display: block;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
}

.visual-strip span {
  color: rgba(255, 255, 255, 0.7);
}

.visual-strip strong {
  display: block;
  margin-top: 8px;
  font-size: clamp(1.1rem, 3vw, 1.55rem);
}

.site-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  width: min(100%, 680px);
  margin: 4px 0 0;
}

.site-stats div {
  min-width: 0;
  padding: 14px;
  border: 1px solid rgba(255, 255, 255, 0.24);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.12);
}

.site-stats dt,
.site-stats dd {
  margin: 0;
}

.site-stats dt {
  color: white;
  font-size: clamp(1.2rem, 3vw, 1.55rem);
  font-weight: 850;
}

.site-stats dd {
  margin-top: 6px;
  color: rgba(255, 255, 255, 0.74);
  font-size: 0.78rem;
  font-weight: 800;
  line-height: 1.25;
  text-transform: uppercase;
}

.site-stats-light {
  width: 100%;
  margin-top: 26px;
}

.site-stats-light div {
  border-color: var(--line);
  background: var(--surface);
}

.site-stats-light dt {
  color: var(--sage-dark);
}

.site-stats-light dd {
  color: var(--muted);
}

.calculator-card,
.results-panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: var(--shadow);
}

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

.form-header,
.section-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
}

.section-copy {
  max-width: 720px;
  margin: 12px 0 0;
  color: var(--muted);
  line-height: 1.6;
}

h2 {
  margin: 0;
  font-size: clamp(1.45rem, 3vw, 2rem);
  line-height: 1.1;
}

.field-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin: 24px 0;
}

label {
  display: grid;
  gap: 8px;
  min-width: 0;
  color: var(--muted);
  font-size: 0.92rem;
  font-weight: 700;
}

input,
select,
textarea {
  width: 100%;
  min-height: 48px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px 12px;
  color: var(--ink);
  background: var(--paper);
  font: inherit;
  font-weight: 750;
}

input:focus,
select:focus,
textarea:focus {
  outline: 3px solid rgba(198, 111, 66, 0.22);
  border-color: var(--clay);
}

textarea {
  min-height: 96px;
  resize: vertical;
}

.checkbox-row {
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: start;
  gap: 10px;
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.45;
}

.checkbox-row input {
  width: 18px;
  min-height: 18px;
  margin-top: 2px;
}

button,
.affiliate-button {
  min-height: 48px;
  border: 0;
  border-radius: 8px;
  padding: 0 18px;
  font: inherit;
  font-weight: 800;
  cursor: pointer;
  text-decoration: none;
}

.primary-button,
.affiliate-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  color: white;
  background: var(--sage-dark);
}

.ghost-button {
  color: var(--sage-dark);
  background: var(--sky);
}

.results-panel {
  grid-area: results;
  padding: clamp(20px, 3vw, 32px);
}

.result-main {
  padding: 18px;
  border-radius: 8px;
  background: var(--sky);
}

.result-main strong {
  display: block;
  margin-top: 4px;
  font-size: clamp(2.4rem, 7vw, 4rem);
  line-height: 1;
}

.result-main p {
  margin: 12px 0 0;
  color: var(--muted);
  line-height: 1.5;
}

.result-cta {
  display: grid;
  gap: 12px;
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid rgba(47, 92, 58, 0.18);
}

.result-cta .affiliate-button {
  width: fit-content;
}

.trust-note {
  margin: 14px 0 0;
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.55;
}

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

.metric-grid div {
  min-width: 0;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
}

dt {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 800;
}

dd {
  margin: 8px 0 0;
  font-size: 1.2rem;
  font-weight: 850;
}

.recommendation-band,
.content-band {
  max-width: 1220px;
  margin: 0 auto;
  padding: clamp(28px, 5vw, 72px);
}

.recommendation-band {
  display: grid;
  grid-template-columns: 1fr minmax(220px, 320px);
  align-items: center;
  gap: 24px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.recommendation-band p {
  max-width: 680px;
  color: var(--muted);
  line-height: 1.65;
}

.offer-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  max-width: 760px;
  margin-top: 18px;
}

.offer-card {
  display: block;
  min-width: 0;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  text-decoration: none;
}

.offer-card span {
  color: var(--clay);
  font-size: 0.72rem;
  font-weight: 850;
  text-transform: uppercase;
}

.offer-card strong {
  display: block;
  margin-top: 8px;
  line-height: 1.25;
}

.offer-card p {
  margin: 8px 0 0;
  font-size: 0.9rem;
}

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

.guide-grid a {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 154px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  text-decoration: none;
}

.guide-grid strong {
  margin-top: 22px;
  line-height: 1.25;
}

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

.experiment-grid article {
  min-width: 0;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
}

.experiment-grid span {
  color: var(--clay);
  font-size: 0.75rem;
  font-weight: 800;
  text-transform: uppercase;
}

.experiment-grid strong {
  display: block;
  margin-top: 10px;
  font-size: 1.12rem;
}

.experiment-grid p {
  margin: 12px 0 0;
  color: var(--muted);
  line-height: 1.55;
}

.experiment-log {
  display: grid;
  gap: 12px;
  margin-top: 18px;
}

.experiment-entry {
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
}

.experiment-entry div {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}

.experiment-entry span {
  color: var(--clay);
  font-size: 0.75rem;
  font-weight: 850;
  text-transform: uppercase;
}

.experiment-entry strong {
  color: var(--sage-dark);
}

.experiment-entry time {
  color: var(--muted);
  font-size: 0.88rem;
}

.experiment-entry p {
  margin: 10px 0 0;
  color: var(--muted);
  line-height: 1.55;
}

.footer {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  padding: 24px clamp(18px, 5vw, 72px);
  color: var(--muted);
  border-top: 1px solid var(--line);
  font-size: 0.88rem;
}

.guide-page {
  max-width: 880px;
  margin: 0 auto;
  padding: clamp(28px, 6vw, 84px) clamp(18px, 5vw, 40px);
}

.guide-page h1 {
  margin: 0;
  font-size: clamp(2rem, 5vw, 4.2rem);
  line-height: 1;
}

.guide-page article {
  margin-top: 28px;
  color: #25352a;
  font-size: 1.05rem;
  line-height: 1.75;
}

.guide-page .callout {
  padding: 18px;
  border-left: 5px solid var(--clay);
  background: white;
}

.formula-table {
  margin: 22px 0;
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
}

.formula-table table {
  width: 100%;
  border-collapse: collapse;
  min-width: 620px;
}

.formula-table th,
.formula-table td {
  padding: 14px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}

.formula-table th {
  color: var(--sage-dark);
  background: var(--sky);
  font-size: 0.82rem;
  text-transform: uppercase;
}

.formula-table tr:last-child td {
  border-bottom: 0;
}

.faq-list {
  display: grid;
  gap: 8px;
  margin-top: 18px;
}

.faq-list h3 {
  margin: 12px 0 0;
  font-size: 1.05rem;
}

.faq-list p {
  margin: 0;
}

.vertical-page {
  max-width: 1220px;
  margin: 0 auto;
  padding: clamp(28px, 5vw, 72px);
}

.vertical-intro {
  max-width: 820px;
  margin-bottom: 24px;
}

.vertical-intro h1 {
  margin: 0;
  font-size: clamp(2rem, 5vw, 4.2rem);
  line-height: 1;
}

.vertical-intro p {
  color: var(--muted);
  font-size: 1.06rem;
  line-height: 1.65;
}

.vertical-tool {
  display: grid;
  grid-template-columns: minmax(320px, 1.05fr) minmax(300px, 0.95fr);
  gap: 22px;
  align-items: start;
}

.partner-form {
  display: grid;
  gap: 16px;
  margin-top: 24px;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: white;
}

.dashboard-metrics {
  grid-template-columns: repeat(auto-fit, minmax(132px, 1fr));
}

.dashboard-notes {
  padding-inline: 0;
}

.dashboard-workbench {
  padding-inline: 0;
}

@media (max-width: 940px) {
  .workspace {
    grid-template-columns: 1fr;
    grid-template-areas:
      "intro"
      "form"
      "results";
  }

  .intro-panel {
    min-height: auto;
  }

  .metric-grid,
  .dashboard-metrics,
  .experiment-grid,
  .site-stats,
  .guide-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .recommendation-band {
    grid-template-columns: 1fr;
  }

  .offer-list {
    grid-template-columns: 1fr;
  }

  .vertical-tool {
    grid-template-columns: 1fr;
  }
}

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

  .nav {
    width: 100%;
    justify-content: space-between;
    gap: 10px;
  }

  .field-grid,
  .metric-grid,
  .dashboard-metrics,
  .experiment-grid,
  .guide-grid,
  .site-stats,
  .visual-strip {
    grid-template-columns: 1fr;
  }

  .form-header {
    flex-direction: column;
  }

  .ghost-button {
    width: 100%;
  }
}
