* {
  box-sizing: border-box;
}

:root {
  --navy: #081629;
  --navy-2: #0e223b;
  --blue: #1f6fff;
  --blue-dark: #1555c5;
  --gold: #ffbf3f;
  --green: #0c9a6b;
  --white: #ffffff;
  --bg: #f4f7fb;
  --surface: #ffffff;
  --text: #122033;
  --muted: #657184;
  --line: #dce4ee;
  --danger: #b42318;
  --max: 1140px;
}

html {
  scroll-behavior: smooth;
}

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

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

button,
input,
select,
textarea {
  font: inherit;
}

.container {
  width: min(calc(100% - 36px), var(--max));
  margin: 0 auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 30;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(220, 228, 238, 0.9);
}

.nav {
  min-height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  letter-spacing: -0.03em;
}

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

.header-cta {
  padding: 10px 16px;
  border-radius: 10px;
  background: var(--navy);
  color: white;
  font-weight: 700;
}

.hero {
  position: relative;
  overflow: hidden;
  color: white;
  background:
    radial-gradient(circle at 80% 10%, rgba(31, 111, 255, 0.35), transparent 34%),
    linear-gradient(140deg, var(--navy), var(--navy-2));
  padding: 94px 0 88px;
}

.hero::after {
  content: "";
  position: absolute;
  width: 360px;
  height: 360px;
  border-radius: 50%;
  background: rgba(255, 191, 63, 0.10);
  right: -120px;
  bottom: -160px;
}

.hero-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1.25fr 0.75fr;
  gap: 60px;
  align-items: center;
}

.eyebrow {
  margin: 0 0 14px;
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  color: #9dbbff;
}

.eyebrow.dark {
  color: var(--blue);
}

h1 {
  margin: 0;
  max-width: 790px;
  font-size: clamp(3rem, 7vw, 5.75rem);
  line-height: 0.98;
  letter-spacing: -0.06em;
}

h2 {
  margin: 0;
  font-size: clamp(2.2rem, 5vw, 4rem);
  line-height: 1.06;
  letter-spacing: -0.045em;
}

h3 {
  line-height: 1.25;
}

.lede {
  margin: 26px 0 0;
  max-width: 690px;
  font-size: 1.1rem;
  color: #cbd7e8;
}

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

.btn {
  border: 0;
  border-radius: 12px;
  padding: 14px 20px;
  font-weight: 800;
  cursor: pointer;
  transition: transform 0.15s ease, background 0.15s ease;
}

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

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

.btn-primary:hover {
  background: var(--blue-dark);
}

.btn-secondary {
  color: white;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.18);
}

.btn-light {
  color: var(--text);
  background: #eef3f8;
}

.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
}

.trust-row {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  margin-top: 34px;
  color: #aab9ce;
  font-size: 0.92rem;
}

.hero-card {
  padding: 30px;
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.14);
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.22);
}

.hero-card-label {
  margin: 0 0 18px;
  color: #9dbbff;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.12em;
}

.hero-stat {
  padding: 16px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
}

.hero-stat strong,
.hero-stat span {
  display: block;
}

.hero-stat span {
  margin-top: 3px;
  color: #b9c7d9;
  font-size: 0.92rem;
}

.section {
  padding: 92px 0;
}

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

.steps article {
  padding: 28px;
  background: white;
  border: 1px solid var(--line);
  border-radius: 18px;
}

.steps article > span {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background: #eaf1ff;
  color: var(--blue);
  font-weight: 800;
}

.steps h3 {
  margin: 20px 0 8px;
}

.steps p {
  margin: 0;
  color: var(--muted);
}

.estimate-section {
  background: #eef3f8;
}

.section-heading,
.results-heading {
  display: flex;
  justify-content: space-between;
  gap: 40px;
  align-items: end;
  margin-bottom: 34px;
}

.section-note {
  max-width: 470px;
  margin: 0;
  color: var(--muted);
}

.calculator-shell {
  background: white;
  border: 1px solid var(--line);
  border-radius: 24px;
  box-shadow: 0 24px 60px rgba(8, 22, 41, 0.08);
  overflow: hidden;
}

.progress-wrap {
  padding: 22px 28px;
  background: #f8fafc;
  border-bottom: 1px solid var(--line);
}

.progress-meta {
  display: flex;
  justify-content: space-between;
  margin-bottom: 10px;
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--muted);
}

.progress-track {
  height: 8px;
  border-radius: 999px;
  background: #e4eaf1;
  overflow: hidden;
}

.progress-bar {
  width: 20%;
  height: 100%;
  background: linear-gradient(90deg, var(--blue), #57a0ff);
  transition: width 0.25s ease;
}

#solarForm {
  padding: 34px;
}

.form-step {
  display: none;
}

.form-step.active {
  display: block;
}

.step-header {
  margin-bottom: 28px;
}

.step-kicker {
  margin: 0 0 8px;
  color: var(--blue);
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0.12em;
}

.step-header h3 {
  margin: 0;
  font-size: clamp(1.75rem, 4vw, 2.6rem);
  letter-spacing: -0.035em;
}

.step-header p:last-child {
  margin: 10px 0 0;
  color: var(--muted);
}

.field {
  margin-bottom: 22px;
}

.field label {
  display: block;
  margin-bottom: 8px;
  font-weight: 700;
}

input,
select,
textarea {
  width: 100%;
  border: 1px solid #cfd8e4;
  border-radius: 12px;
  padding: 13px 14px;
  color: var(--text);
  background: white;
  outline: none;
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--blue);
  box-shadow: 0 0 0 3px rgba(31, 111, 255, 0.12);
}

small {
  display: block;
  margin-top: 7px;
  color: var(--muted);
}

.two-col {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}

.input-prefix,
.input-suffix {
  display: flex;
  align-items: center;
  border: 1px solid #cfd8e4;
  border-radius: 12px;
  background: white;
  overflow: hidden;
}

.input-prefix:focus-within,
.input-suffix:focus-within {
  border-color: var(--blue);
  box-shadow: 0 0 0 3px rgba(31, 111, 255, 0.12);
}

.input-prefix span,
.input-suffix span {
  padding: 0 14px;
  color: var(--muted);
  white-space: nowrap;
}

.input-prefix input,
.input-suffix input {
  border: 0;
  border-radius: 0;
  box-shadow: none;
}

.check-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
  margin-bottom: 24px;
}

.check-card {
  display: flex;
  gap: 12px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 14px;
  cursor: pointer;
}

.check-card:has(input:checked) {
  border-color: var(--blue);
  background: #f2f6ff;
}

.check-card input {
  width: auto;
  margin-top: 4px;
}

.check-card strong,
.check-card small {
  display: block;
}

.check-card small {
  margin-top: 3px;
}

.consent {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 16px;
  border-radius: 12px;
  background: #f7f9fc;
  color: var(--muted);
}

.consent input {
  width: auto;
  margin-top: 5px;
}

.form-actions {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  margin-top: 30px;
  padding-top: 24px;
  border-top: 1px solid var(--line);
}

.form-error {
  min-height: 24px;
  margin: 14px 0 0;
  color: var(--danger);
  font-weight: 700;
}

.results {
  margin-top: 38px;
}

.result-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
}

.result-card {
  padding: 24px;
  background: white;
  border: 1px solid var(--line);
  border-radius: 18px;
}

.primary-result {
  background: var(--navy);
  color: white;
  border-color: var(--navy);
}

.result-card p {
  min-height: 48px;
  margin: 0 0 18px;
  color: var(--muted);
}

.primary-result p {
  color: #b8c5d8;
}

.result-card strong {
  display: block;
  font-size: 2.2rem;
  line-height: 1;
}

.result-card span {
  display: block;
  margin-top: 7px;
  color: var(--muted);
}

.primary-result span {
  color: #b8c5d8;
}

.result-details {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  margin-top: 18px;
}

.result-details article,
.lead-summary {
  padding: 24px;
  background: white;
  border: 1px solid var(--line);
  border-radius: 18px;
}

.result-details h3,
.lead-summary h3 {
  margin-top: 0;
}

.result-details p {
  margin-bottom: 0;
  color: var(--muted);
}

.lead-summary {
  margin-top: 18px;
}

.lead-summary pre {
  max-height: 300px;
  overflow: auto;
  padding: 16px;
  border-radius: 12px;
  background: #0b1728;
  color: #dbe8f7;
  white-space: pre-wrap;
}

.hidden {
  display: none !important;
}

footer {
  padding: 52px 0;
  background: var(--navy);
  color: white;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 42px;
}

.footer-brand {
  margin-bottom: 14px;
}

footer p {
  color: #b7c5d8;
}

.fine-print {
  margin: 0;
  font-size: 0.9rem;
}

@media (max-width: 900px) {
  .hero-grid,
  .section-heading,
  .results-heading,
  .footer-grid {
    grid-template-columns: 1fr;
    display: grid;
  }

  .steps,
  .result-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .result-details {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 650px) {
  .header-cta {
    display: none;
  }

  .hero {
    padding-top: 70px;
  }

  .steps,
  .two-col,
  .check-grid,
  .result-grid {
    grid-template-columns: 1fr;
  }

  #solarForm {
    padding: 24px 20px;
  }

  .progress-wrap {
    padding: 20px;
  }

  .section {
    padding: 72px 0;
  }
}
