:root {
  --roi-ink: #15191e;
  --roi-muted: #5d6875;
  --roi-navy: #0b3c5c;
  --roi-blue: #116a9b;
  --roi-gold: #c8952b;
  --roi-green: #26735f;
  --roi-line: #d7e0e7;
  --roi-soft: #f4f8fb;
}

.roi-page main {
  color: var(--roi-ink);
  background: #ffffff;
}

.roi-heading {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 0.58fr);
  gap: clamp(38px, 5vw, 72px);
  align-items: end;
  padding: clamp(42px, 5vw, 68px) clamp(18px, 6vw, 88px) clamp(34px, 4vw, 52px);
  border-bottom: 1px solid var(--roi-line);
  background: var(--roi-soft);
}

.roi-heading h1 {
  max-width: 820px;
  font-size: 4.25rem;
  line-height: 1.02;
}

.roi-heading > div > p:last-child {
  max-width: 780px;
  margin: 18px 0 0;
  color: var(--roi-muted);
  font-size: 1.18rem;
}

.roi-benchmark {
  margin: 0;
  border-top: 3px solid var(--roi-gold);
}

.roi-benchmark div {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 24px;
  align-items: center;
  padding: 14px 0;
  border-bottom: 1px solid #c7d5de;
}

.roi-benchmark dt {
  color: #405364;
  font-size: 0.9rem;
  font-weight: 700;
}

.roi-benchmark dd {
  margin: 0;
  color: var(--roi-navy);
  font-size: 1.65rem;
  font-weight: 850;
}

.roi-calculator {
  display: grid;
  grid-template-columns: minmax(340px, 0.78fr) minmax(500px, 1.22fr);
  min-height: 760px;
  border-bottom: 1px solid var(--roi-line);
}

.roi-inputs,
.roi-results {
  padding: clamp(42px, 6vw, 76px) clamp(18px, 5vw, 68px);
}

.roi-inputs {
  background: #ffffff;
  border-right: 1px solid var(--roi-line);
}

.roi-results {
  background: var(--roi-navy);
  color: #ffffff;
}

.roi-section-label h2 {
  max-width: 700px;
  font-size: 2.5rem;
}

.roi-section-label > p:last-child {
  max-width: 680px;
  margin: 14px 0 0;
  color: var(--roi-muted);
}

.roi-results .eyebrow {
  color: #9fd4ee;
}

.roi-results .roi-section-label h2 {
  color: #ffffff;
}

.roi-fields {
  display: grid;
  gap: 22px;
  margin-top: 36px;
}

.roi-field {
  display: grid;
  gap: 8px;
}

.roi-field > span:first-child,
.roi-pricing legend {
  color: #293b4d;
  font-size: 0.92rem;
  font-weight: 780;
}

.roi-field small {
  color: #687686;
  font-size: 0.8rem;
}

.roi-input-wrap {
  position: relative;
  display: flex;
  align-items: center;
  min-height: 52px;
  border: 3px solid #111820;
  border-radius: 4px;
  background: #ffffff;
  box-shadow: 0 2px 0 rgba(17, 24, 32, 0.08);
}

.roi-input-wrap::before,
.roi-input-wrap::after {
  position: absolute;
  z-index: 1;
  color: #526170;
  font-weight: 800;
  pointer-events: none;
}

.roi-input-wrap[data-prefix]::before {
  left: 16px;
  content: attr(data-prefix);
}

.roi-input-wrap[data-suffix]::after {
  right: 16px;
  content: attr(data-suffix);
}

.roi-input-wrap input {
  width: 100%;
  min-width: 0;
  height: 48px;
  padding: 0 16px;
  border: 0;
  outline: 0;
  color: var(--roi-ink);
  background: transparent;
  font: inherit;
  font-size: 1.08rem;
  font-weight: 800;
}

.roi-input-wrap[data-prefix] input {
  padding-left: 34px;
}

.roi-input-wrap[data-suffix] input {
  padding-right: 40px;
}

.roi-input-wrap:focus-within {
  border-color: var(--roi-blue);
  box-shadow: 0 0 0 3px rgba(17, 106, 155, 0.18);
}

.roi-pricing {
  display: grid;
  gap: 18px;
  margin: 38px 0 0;
  padding: 28px 0 0;
  border: 0;
  border-top: 1px solid var(--roi-line);
}

.roi-price-field[hidden] {
  display: none;
}

.roi-mode {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 4px;
  padding: 4px;
  background: #e6edf2;
  border-radius: 6px;
}

.roi-mode label {
  min-width: 0;
}

.roi-mode input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.roi-mode span {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 8px 12px;
  border-radius: 4px;
  color: #4d5d6d;
  font-size: 0.88rem;
  font-weight: 800;
  text-align: center;
  cursor: pointer;
}

.roi-mode input:checked + span {
  color: #ffffff;
  background: var(--roi-navy);
}

.roi-mode input:focus-visible + span {
  outline: 3px solid rgba(17, 106, 155, 0.32);
}

.roi-assumption {
  display: grid;
  gap: 5px;
  margin-top: 30px;
  padding: 20px 22px;
  border-left: 4px solid var(--roi-gold);
  background: #fff8e8;
}

.roi-assumption strong {
  color: var(--roi-navy);
}

.roi-assumption span {
  color: #5d6875;
  font-size: 0.86rem;
}

.roi-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 28px;
}

.roi-actions .button.secondary,
.roi-clear {
  min-height: 42px;
  padding: 0 16px;
  border-radius: 5px;
  font: inherit;
  font-size: 0.86rem;
  font-weight: 800;
  cursor: pointer;
}

.roi-actions .button.secondary {
  color: var(--roi-navy);
  border: 1px solid var(--roi-navy);
  background: #ffffff;
}

.roi-clear {
  color: #5b6875;
  border: 0;
  background: transparent;
}

.roi-primary-result {
  margin-top: 42px;
  padding: 26px 0 30px;
  border-top: 1px solid rgba(255, 255, 255, 0.22);
  border-bottom: 1px solid rgba(255, 255, 255, 0.22);
}

.roi-primary-result span {
  display: block;
  color: #b8d8e8;
  font-size: 0.86rem;
  font-weight: 800;
  text-transform: uppercase;
}

.roi-primary-result strong {
  display: block;
  margin-top: 8px;
  color: #ffffff;
  font-size: 5.7rem;
  line-height: 1;
}

.roi-primary-result small {
  display: block;
  max-width: 650px;
  margin-top: 10px;
  color: rgba(255, 255, 255, 0.68);
}

.roi-value-mix {
  margin: 28px 0;
}

.roi-value-bar {
  display: flex;
  width: 100%;
  height: 14px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.12);
}

.roi-value-bar span:first-child {
  background: var(--roi-gold);
}

.roi-value-bar span:last-child {
  background: #56a88e;
}

.roi-value-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 26px;
  margin-top: 12px;
  color: rgba(255, 255, 255, 0.72);
  font-size: 0.8rem;
}

.roi-value-legend span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.roi-value-legend i {
  width: 10px;
  height: 10px;
}

.roi-value-legend .payment {
  background: var(--roi-gold);
}

.roi-value-legend .capacity {
  background: #56a88e;
}

.roi-breakdown {
  margin: 0;
}

.roi-breakdown div {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 24px;
  align-items: center;
  padding: 15px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.15);
}

.roi-breakdown dt {
  color: rgba(255, 255, 255, 0.78);
}

.roi-breakdown dt small {
  display: block;
  margin-top: 2px;
  color: #9fd4ee;
  font-size: 0.72rem;
}

.roi-breakdown dd {
  margin: 0;
  color: #ffffff;
  font-weight: 800;
}

.roi-net-results {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1px;
  margin-top: 34px;
  background: #35637b;
  border: 1px solid #35637b;
}

.roi-net-results div {
  min-height: 116px;
  padding: 20px;
  background: #123f59;
}

.roi-net-results span {
  display: block;
  color: #b8d8e8;
  font-size: 0.78rem;
  font-weight: 780;
  text-transform: uppercase;
}

.roi-net-results strong {
  display: block;
  margin-top: 10px;
  color: #ffffff;
  font-size: 1.9rem;
  line-height: 1.08;
}

.roi-status {
  margin: 20px 0 0;
  color: #f4cd79;
  font-size: 0.86rem;
}

.roi-method {
  display: grid;
  grid-template-columns: minmax(260px, 0.48fr) minmax(0, 1fr);
  gap: clamp(36px, 6vw, 88px);
  padding: clamp(58px, 8vw, 96px) clamp(18px, 6vw, 88px);
  background: var(--roi-soft);
}

.roi-method h2,
.roi-next h2 {
  font-size: 3.2rem;
}

.roi-method-steps {
  border-top: 1px solid #bfd0dc;
}

.roi-method-steps article {
  display: grid;
  grid-template-columns: 54px minmax(180px, 0.52fr) minmax(260px, 1fr);
  gap: 22px;
  align-items: start;
  padding: 24px 0;
  border-bottom: 1px solid #bfd0dc;
}

.roi-method-steps span {
  color: var(--roi-gold);
  font-weight: 850;
}

.roi-method-steps h3 {
  color: var(--roi-navy);
  font-size: 1.12rem;
}

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

.roi-next {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 36px;
  align-items: center;
  margin: clamp(54px, 7vw, 88px) clamp(18px, 6vw, 88px);
  padding: clamp(38px, 6vw, 68px);
  color: #ffffff;
  background: var(--roi-blue);
}

.roi-next h2 {
  color: #ffffff;
}

.roi-next p:not(.eyebrow) {
  max-width: 780px;
  color: rgba(255, 255, 255, 0.78);
}

.roi-next .eyebrow {
  color: #d9edf7;
}

.roi-next .button {
  color: var(--roi-navy);
  border-color: #ffffff;
  background: #ffffff;
}

.roi-citations {
  margin: 0 clamp(18px, 6vw, 88px) clamp(48px, 7vw, 82px);
  padding-top: 22px;
  border-top: 1px solid var(--roi-line);
  color: #697685;
  font-size: 0.76rem;
}

.roi-citations p {
  max-width: 1100px;
}

.roi-citations a {
  color: var(--roi-blue);
  text-decoration: underline;
}

@media (max-width: 1050px) {
  .roi-heading,
  .roi-calculator,
  .roi-method,
  .roi-next {
    grid-template-columns: 1fr;
  }

  .roi-calculator,
  .roi-inputs,
  .roi-results {
    min-height: 0;
  }

  .roi-inputs {
    border-right: 0;
    border-bottom: 1px solid var(--roi-line);
  }

  .roi-heading h1 {
    font-size: 3.5rem;
  }

  .roi-section-label h2 {
    font-size: 2.25rem;
  }

  .roi-primary-result strong {
    font-size: 4.6rem;
  }
}

@media (max-width: 680px) {
  .roi-heading h1 {
    font-size: 2.55rem;
    line-height: 1.05;
    overflow-wrap: normal;
    word-break: normal;
  }

  .roi-section-label h2,
  .roi-method h2,
  .roi-next h2 {
    font-size: 2rem;
  }

  .roi-primary-result strong {
    font-size: 3.2rem;
  }

  .roi-net-results strong {
    font-size: 1.65rem;
  }

  .roi-net-results,
  .roi-method-steps article {
    grid-template-columns: 1fr;
  }

  .roi-method-steps article {
    gap: 8px;
  }

  .roi-benchmark div,
  .roi-breakdown div {
    gap: 14px;
  }

  .roi-next .button {
    width: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  .roi-page * {
    scroll-behavior: auto !important;
  }
}
