:root {
  --bg: #07090d;
  --panel: #0e131b;
  --panel-2: #121923;
  --line: #263141;
  --text: #f4f7fb;
  --muted: #9ba8b9;
  --silver: #dce3eb;
  --blue: #5b8cff;
  --blue-2: #9bb9ff;
  --max: 1040px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  background:
    radial-gradient(circle at 80% 0%, rgba(59, 130, 246, .14), transparent 28rem),
    var(--bg);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.6;
}

a { color: inherit; }

.site-header {
  max-width: var(--max);
  margin: 0 auto;
  min-height: 72px;
  padding: 0 22px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  border-bottom: 1px solid rgba(255,255,255,.07);
}

.brand {
  display: flex;
  align-items: center;
  gap: 11px;
  text-decoration: none;
  font-weight: 750;
  letter-spacing: .02em;
}

.mark {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 9px;
  color: var(--blue-2);
  font-size: 11px;
}

.header-link {
  color: var(--muted);
  text-decoration: none;
  font-size: 14px;
}

.header-link:hover { color: var(--text); }

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

.hero {
  padding: 82px 0 48px;
  max-width: 850px;
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--blue-2);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .14em;
}

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

h1 {
  margin-bottom: 20px;
  font-size: clamp(44px, 8vw, 82px);
  line-height: .98;
  letter-spacing: -.055em;
  color: var(--silver);
}

h2 {
  margin-bottom: 14px;
  font-size: clamp(28px, 4.2vw, 48px);
  line-height: 1.05;
  letter-spacing: -.035em;
  color: var(--silver);
}

h3 {
  margin-bottom: 8px;
  font-size: 21px;
}

.lead {
  max-width: 760px;
  margin: 0;
  color: var(--muted);
  font-size: 19px;
}

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

.facts span {
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 7px 11px;
  color: var(--muted);
  font-size: 12px;
}

.calculator-card,
.results {
  border: 1px solid var(--line);
  background: linear-gradient(145deg, rgba(255,255,255,.025), rgba(255,255,255,.01));
  border-radius: 22px;
  padding: clamp(22px, 5vw, 44px);
  box-shadow: 0 24px 80px rgba(0,0,0,.25);
}

.section-head {
  margin-bottom: 28px;
}

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

label {
  display: grid;
  gap: 8px;
  color: var(--silver);
  font-weight: 700;
}

label small {
  color: var(--muted);
  font-weight: 400;
  font-size: 12px;
}

input, select {
  width: 100%;
  min-height: 52px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #0a0f16;
  color: var(--text);
  padding: 0 14px;
  font: inherit;
  outline: none;
}

input:focus, select:focus {
  border-color: var(--blue);
  box-shadow: 0 0 0 3px rgba(91,140,255,.12);
}

.money-field {
  display: grid;
  grid-template-columns: 105px 1fr;
  gap: 8px;
}

.percent-field {
  display: grid;
  grid-template-columns: 1fr 48px;
  align-items: center;
  gap: 8px;
}

.percent-field > span {
  height: 52px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #0a0f16;
  color: var(--muted);
}

.primary, .secondary {
  min-height: 52px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  padding: 0 19px;
  font-weight: 800;
  text-decoration: none;
  cursor: pointer;
}

button.primary {
  width: 100%;
  margin-top: 24px;
  border: 0;
}

.primary {
  background: linear-gradient(135deg, #7ea5ff, #4d7dff);
  color: #06101f;
}

.primary:hover { filter: brightness(1.06); }

.secondary {
  border: 1px solid var(--line);
  background: transparent;
  color: var(--silver);
}

.results {
  margin: 26px 0 70px;
}

.hidden { display: none; }

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

.result-grid article {
  min-height: 150px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 18px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--panel);
}

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

.result-grid strong {
  color: var(--silver);
  font-size: clamp(26px, 4vw, 40px);
  line-height: 1;
  letter-spacing: -.04em;
}

.interpretation {
  margin-top: 16px;
  padding: 22px;
  border-left: 3px solid var(--blue);
  background: var(--panel-2);
  border-radius: 0 12px 12px 0;
}

.interpretation p,
.cta-card p,
.disclaimer {
  color: var(--muted);
}

.cta-card {
  margin-top: 28px;
  padding: clamp(22px, 4vw, 34px);
  border: 1px solid rgba(91,140,255,.45);
  border-radius: 16px;
  background:
    radial-gradient(circle at 100% 0%, rgba(91,140,255,.14), transparent 20rem),
    var(--panel);
}

.button-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 22px;
}

.link-button {
  flex: 1 1 260px;
}

.disclaimer {
  margin: 26px 0 0;
  font-size: 12px;
}

footer {
  width: min(calc(100% - 36px), var(--max));
  margin: 0 auto;
  padding: 26px 0 36px;
  display: flex;
  justify-content: space-between;
  gap: 20px;
  border-top: 1px solid rgba(255,255,255,.07);
  color: var(--muted);
  font-size: 12px;
}

footer a { text-decoration: none; }

@media (max-width: 800px) {
  .field-grid, .result-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 560px) {
  .site-header { padding-inline: 16px; }
  .brand span:last-child { display: none; }
  main, footer { width: min(calc(100% - 24px), var(--max)); }
  .hero { padding-top: 58px; }
  .field-grid, .result-grid { grid-template-columns: 1fr; }
  .money-field { grid-template-columns: 92px 1fr; }
  footer { flex-direction: column; }
}
