/* =============================================================
   ROI calculator (roi.html)
   ============================================================= */

/* Author display rules (e.g. .roi-helper-grid { display:grid }) silently beat
   the UA's [hidden] { display:none } — this guard makes hidden mean hidden. */
[hidden] { display: none !important; }

.roi-intro { max-width: 780px; }
.roi-privacy { margin-top: 0.75rem; letter-spacing: 0.08em; }

/* ---- AI worksheet strip (copy prompt / import results) ---- */
.roi-ai-strip { display: flex; flex-wrap: wrap; gap: 0.6rem 1.5rem; margin-top: 1rem; }
.roi-ai-btn {
  background: none; border: 0; cursor: pointer; padding: 0.3rem 0;
  color: var(--amber-ink); font-family: var(--font-body); font-size: 0.85rem;
  text-align: left;
}
.roi-ai-btn:hover { text-decoration: underline; }
.roi-ai-panel {
  border: 1px dashed var(--rule);
  border-radius: 4px;
  padding: 1rem;
  margin-top: 0.75rem;
}
.roi-ai-text {
  width: 100%;
  background: rgba(255, 255, 255, 0.055);
  border: 1px solid var(--rule);
  border-radius: 4px;
  color: var(--bone-text);
  font-family: var(--font-mono);
  font-size: 0.78rem;
  line-height: 1.5;
  padding: 0.75rem;
  margin: 0.5rem 0 0.75rem;
  resize: vertical;
}
.roi-ai-text:focus { outline: none; border-color: var(--amber-ink); }
.roi-ai-actions { display: flex; gap: 0.75rem; align-items: center; }
.roi-ai-file { cursor: pointer; }
.roi-import-review { margin-top: 1rem; border-top: 1px solid var(--rule-soft); padding-top: 0.9rem; }
.roi-import-review-head { font-size: 0.85rem; color: var(--bone-text); margin: 0 0 0.6rem; }
.roi-import-review ul { list-style: none; padding: 0; margin: 0 0 1rem; }
.roi-import-review li {
  display: flex;
  justify-content: space-between;
  gap: 1.5rem;
  padding: 0.3rem 0;
  border-bottom: 1px solid var(--rule-soft);
  font-size: 0.82rem;
}
.roi-import-review li span:first-child { color: var(--text-mute); white-space: nowrap; }
.roi-import-review li span:last-child { text-align: right; }
.roi-import-review li.is-ok span:last-child { color: var(--bone-text); }
.roi-import-review li.is-missing span:last-child { color: var(--steel); }

/* ---- wizard chrome ---- */
.roi-wizard-bar { margin: 0 0 1.5rem; }
.roi-skip {
  display: block;
  margin-left: auto;
  background: none; border: 0; cursor: pointer;
  color: var(--steel); font-family: var(--font-body); font-size: 0.85rem;
  padding: 0.25rem 0 0.6rem;
}
.roi-skip:hover { color: var(--bone-text); }

/* labeled stepper: node + label per step, connector lines between */
.roi-wizard-progress { display: flex; width: 100%; }
.roi-step {
  flex: 1;
  position: relative;
  background: none; border: 0; padding: 0;
  font-family: var(--font-body);
  text-align: center;
  cursor: default;
}
.roi-step.is-done { cursor: pointer; }
.roi-step:not(:first-child)::before {
  content: '';
  position: absolute;
  top: 12px;
  right: 50%;
  width: 100%;
  height: 2px;
  background: var(--rule);
  z-index: 0;
}
.roi-step.is-done:not(:first-child)::before,
.roi-step.is-active:not(:first-child)::before { background: var(--amber); }
.roi-step-node {
  position: relative;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px; height: 24px;
  border-radius: 50%;
  border: 2px solid var(--rule);
  background: var(--bg);
  color: var(--text-mute);
  font-size: 0.72rem;
  font-weight: 600;
}
.roi-step.is-done .roi-step-node {
  border-color: var(--amber-ink);
  background: var(--amber);
  color: var(--bg);
}
.roi-step.is-active .roi-step-node {
  border-color: var(--amber-ink);
  color: var(--amber-ink);
}
.roi-step-label {
  display: block;
  margin-top: 0.35rem;
  font-size: 0.72rem;
  letter-spacing: 0.04em;
  color: var(--text-mute);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.roi-step.is-active .roi-step-label { color: var(--amber-ink); }
.roi-step.is-done .roi-step-label { color: var(--bone-text); }
.roi-step.is-done:hover .roi-step-label { color: var(--amber-ink); }
.roi-step-caption { display: none; }
@media (max-width: 767px) {
  /* Phones: nodes + connectors stay, one caption line replaces per-step labels */
  .roi-step-label { display: none; }
  .roi-step-caption {
    display: block;
    margin: 0.5rem 0 0;
    font-size: 0.72rem;
    color: var(--text-mute);
    text-align: center;
  }
}

.roi-wizard-nav {
  display: flex;
  justify-content: space-between;
  margin: 1.5rem 0 3rem;
}

/* ---- layout: editor = form + sticky results ---- */
.roi-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 2.5rem;
  align-items: start;
  padding-bottom: 4rem;
}
#roi-app[data-mode="wizard"] .roi-layout {
  grid-template-columns: minmax(0, 720px);
  justify-content: center;
}
#roi-app[data-mode="wizard"] .roi-results { display: none; }
#roi-app[data-mode="wizard"] .roi-card-remove { display: none; }
#roi-app[data-mode="editor"] .roi-wizard-bar { display: none; }
#roi-app[data-mode="editor"] .roi-wizard-nav { display: none; }

/* ---- panels ---- */
.roi-panel {
  background: var(--bg-lift);
  border: 1px solid var(--rule);
  border-radius: 4px;
  padding: 1.75rem 1.75rem 1.5rem;
  margin-bottom: 1.5rem;
}
.roi-panel-title {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 1.25rem;
  margin: 0 0 0.35rem;
  display: flex;
  align-items: baseline;
  gap: 0.75rem;
}
.roi-panel-num { font-size: 0.75rem; color: var(--amber-ink); }
.roi-panel-sub {
  color: var(--text-mute);
  font-size: 0.9rem;
  margin: 0 0 1.4rem;
  max-width: 62ch;
}
/* Field hierarchy on the calculator: the LABEL is the question — it wears the
   bright ink. Notes/hints stay muted so the two levels read apart. (Scoped to
   #roi-app so the contact form keeps its quieter look.) */
#roi-app .field-label { color: var(--bone-text); }
#roi-app .field-label .field-optional { color: var(--steel); }
#roi-app .field-input { background: rgba(255, 255, 255, 0.055); }

/* Vention-style rhythm: label hugs its input (0.3rem); fields separate from
   each other (1.25rem) so ownership is never ambiguous. */
#roi-app .field { gap: 0.3rem; }
.roi-panel > .field,
.roi-panel > .field-row,
.roi-panel > .roi-valuation { margin-bottom: 1.25rem; }
.roi-panel > .field:last-child,
.roi-panel > .field-row:last-child,
.roi-panel > .roi-valuation:last-child { margin-bottom: 0; }
.field-row .field { margin-bottom: 0; }

/* info icon: hover shows the note, click pins it (glyph injected as SVG) */
.roi-info {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 16px; height: 16px;
  margin-left: 0.45rem;
  vertical-align: -2px;
  border: 0;
  padding: 0;
  background: none;
  color: var(--steel);
  cursor: pointer;
  font-size: 0; /* hide the no-JS "i" fallback text */
}
.roi-info svg { width: 100%; height: 100%; display: block; }
.roi-info:hover { color: var(--amber-ink); }
.roi-infotip {
  position: absolute;
  z-index: 60;
  max-width: 300px;
  background: var(--bg);
  border: 1px solid var(--rule);
  border-left: 2px solid var(--amber);
  border-radius: 4px;
  padding: 0.6rem 0.8rem;
  font-size: 0.8rem;
  line-height: 1.5;
  color: var(--bone-text);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.45);
}

/* units basis toggle sits between label and input */
.roi-units-basis { font-size: 0.8rem; gap: 0.4rem; }
.roi-units-basis label {
  padding: 0.25rem 0.6rem;
  border: 1px solid var(--rule);
  border-radius: 3px;
  cursor: pointer;
}
.roi-units-basis label:has(input:checked) {
  border-color: var(--amber-ink);
  color: var(--amber-ink);
  background: rgba(232, 169, 60, 0.08);
}
.roi-units-basis input { position: absolute; opacity: 0; pointer-events: none; }

/* the custom value slot at the end of a chip row — same size as the chips */
.roi-chip-input.field-input {
  flex: 1 1 0;
  min-width: 0;
  padding: 0.3rem 0.2rem;
  font-size: 0.8rem;
  text-align: center;
}
.roi-chip-input.is-active {
  border-color: var(--amber-ink);
  color: var(--amber-ink);
  background: rgba(232, 169, 60, 0.08);
}

/* input adornments: $ prefix / unit suffix rendered inside the box */
.roi-input-wrap { position: relative; display: block; }
.roi-helper-grid label .roi-input-wrap { margin-top: 0.3rem; }
.roi-helper-grid label .roi-input-wrap .field-input { margin-top: 0; }
.roi-input-wrap::before,
.roi-input-wrap::after {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-mute);
  font-size: 0.9rem;
  pointer-events: none;
}
.roi-input-wrap[data-prefix]::before { content: attr(data-prefix); left: 0.9rem; }
.roi-input-wrap[data-suffix]::after { content: attr(data-suffix); right: 0.9rem; }
.roi-input-wrap[data-prefix] .field-input { padding-left: 1.7rem; }
.roi-input-wrap[data-suffix] .field-input { padding-right: 3.4rem; }
.roi-fieldnote {
  color: var(--text-mute);
  font-size: 0.8rem;
  margin: 0.4rem 0 0;
  line-height: 1.45;
}
.roi-row-3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 1rem; }

/* ---- card head / remove ---- */
.roi-card-head { display: flex; align-items: center; justify-content: space-between; }
.roi-card-remove {
  background: none; border: 0; cursor: pointer;
  color: var(--steel); font-size: 1.4rem; line-height: 1;
  padding: 0.25rem 0.5rem;
}
.roi-card-remove:hover { color: var(--fault); }

/* ---- mechanism picker ---- */
.roi-picker {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.9rem;
  margin-bottom: 1rem;
}
.roi-pick {
  display: block;
  border: 1px solid var(--rule);
  border-radius: 4px;
  padding: 0.9rem 1rem;
  cursor: pointer;
  transition: border-color 0.15s linear, background 0.15s linear;
}
.roi-pick:hover { border-color: var(--steel); }
.roi-pick:has(input:checked) {
  border-color: var(--amber-ink);
  background: rgba(232, 169, 60, 0.06);
}
.roi-pick input { margin-right: 0.5rem; accent-color: var(--amber-ink); }
.roi-pick-title { font-family: var(--font-display); font-size: 0.95rem; }
.roi-pick-desc {
  display: block;
  color: var(--text-mute);
  font-size: 0.8rem;
  margin-top: 0.3rem;
  line-height: 1.4;
}

/* ---- quick-pick chips ---- */
/* one row, equal-width boxes per category, custom slot included */
.roi-chips { display: flex; flex-wrap: nowrap; align-items: stretch; gap: 0.35rem; }
.roi-chip {
  flex: 1 1 0;
  min-width: 0;
  background: none;
  border: 1px solid var(--rule);
  border-radius: 3px;
  color: var(--text-mute);
  font-family: var(--font-body);
  font-size: 0.8rem;
  padding: 0.3rem 0.2rem;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  cursor: pointer;
}
.roi-chip:hover { border-color: var(--steel); color: var(--bone-text); }
.roi-chip.is-active {
  border-color: var(--amber-ink);
  color: var(--amber-ink);
  background: rgba(232, 169, 60, 0.08);
}

/* ---- gates + valuation toggles ---- */
.roi-gate {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem 1rem;
  padding: 0.65rem 0;
  border-bottom: 1px solid var(--rule-soft);
  margin-bottom: 0.5rem;
}
.roi-gate-q { font-size: 0.9rem; }
.roi-toggle { display: flex; gap: 1rem; font-size: 0.9rem; color: var(--text-mute); }
.roi-toggle label { cursor: pointer; }
.roi-toggle input { accent-color: var(--amber-ink); margin-right: 0.3rem; }
.roi-gate-blocked {
  background: rgba(232, 169, 60, 0.08);
  border-left: 2px solid var(--amber);
  padding: 0.7rem 0.9rem;
  font-size: 0.85rem;
  color: var(--bone-text);
  margin: 0.75rem 0;
}
.roi-valuation { margin-top: 1rem; }
.roi-val-output { margin-top: 0.75rem; padding-left: 0.9rem; border-left: 1px solid var(--rule); }

/* ---- helpers (expanders) ---- */
.roi-helper-toggle {
  background: none; border: 0; cursor: pointer; padding: 0.3rem 0 0;
  color: var(--amber-ink); font-size: 0.8rem; font-family: var(--font-body);
  text-align: left;
}
.roi-helper-toggle:hover { text-decoration: underline; }
.roi-helper {
  border: 1px dashed var(--rule);
  border-radius: 4px;
  padding: 0.9rem;
  margin-top: 0.6rem;
}
.roi-helper-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0.75rem; margin-bottom: 0.75rem; }
.roi-helper-grid label {
  display: block;
  font-size: 0.8rem;
  color: var(--text-mute);
}
.roi-helper-grid label .field-input { margin-top: 0.3rem; }
.roi-helper-apply { font-size: 0.85rem; }
.roi-target-out {
  font-size: 0.95rem;
  color: var(--amber-ink);
  padding: 0.6rem 0;
}
.roi-mat-mode { display: flex; gap: 1.25rem; font-size: 0.85rem; color: var(--text-mute); margin-bottom: 0.75rem; }
.roi-mat-mode input { accent-color: var(--amber-ink); margin-right: 0.3rem; }

/* ---- dynamic lines (labor / upside) ---- */
.roi-line {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr) auto;
  gap: 0.75rem 1rem;
  align-items: end;
  padding: 0.75rem 0;
  border-bottom: 1px solid var(--rule-soft);
}
.roi-line .field { margin: 0; }
.roi-line-realloc {
  grid-column: 1 / -1;
  font-size: 0.8rem;
  color: var(--text-mute);
  cursor: pointer;
}
.roi-line-realloc input { accent-color: var(--amber-ink); margin-right: 0.4rem; }
.roi-line-remove {
  background: none; border: 0; cursor: pointer;
  color: var(--steel); font-size: 1.2rem; align-self: center;
}
.roi-line-remove:hover { color: var(--fault); }
.roi-line-upside { grid-template-columns: minmax(0, 1.4fr) minmax(0, 0.8fr) auto; align-items: center; }
.roi-add-line { margin-top: 0.9rem; font-size: 0.85rem; }

/* ---- soft rack ---- */
.roi-soft-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.6rem 1.25rem;
  margin-bottom: 1rem;
  font-size: 0.9rem;
}
.roi-soft-grid label { cursor: pointer; color: var(--text); }
.roi-soft-grid input { accent-color: var(--amber-ink); margin-right: 0.45rem; }

/* ---- results ---- */
.roi-results { position: sticky; top: calc(var(--nav-height) + 16px); }
.roi-results-inner {
  background: var(--bg-lift);
  border: 1px solid var(--rule);
  border-radius: 4px;
  padding: 1.5rem;
}
.roi-results-head { margin-bottom: 1rem; }
.roi-tiles { display: grid; gap: 0.75rem; margin-bottom: 1.25rem; }
.roi-tile {
  border: 1px solid var(--rule);
  border-radius: 4px;
  padding: 0.9rem 1rem;
}
.roi-tile-lead { border-color: var(--amber-ink); }
.roi-tile-value {
  font-family: var(--font-display);
  font-size: 1.6rem;
  font-weight: 600;
  line-height: 1.1;
}
.roi-tile-lead .roi-tile-value { color: var(--amber-ink); }
.roi-tile-value.is-muted { color: var(--text-mute); font-size: 1.15rem; }
.roi-tile-label {
  color: var(--text-mute);
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-top: 0.3rem;
}
/* ---- break-even chart ---- */
.roi-chart { margin: 0 0 1.1rem; }
.roi-chart-title {
  font-size: 0.7rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-mute);
  margin-bottom: 0.4rem;
}
.roi-chart-body { position: relative; }
.roi-ch { width: 100%; height: auto; display: block; }
.roi-ch-grid { stroke: var(--rule-soft); stroke-width: 1; }
.roi-ch-zero { stroke: var(--rule); stroke-width: 1.5; }
.roi-ch-line { stroke: var(--amber); stroke-width: 2; fill: none; stroke-linejoin: round; }
.roi-ch-dot { fill: var(--amber); stroke: var(--bg-lift); stroke-width: 2; }
.roi-ch-tick { fill: var(--text-mute); font-size: 8.5px; font-family: var(--font-body); }
.roi-ch-belabel { fill: var(--bone-text); font-size: 9.5px; font-family: var(--font-body); }
.roi-ch-cross { stroke: var(--steel); stroke-width: 1; stroke-dasharray: 3 3; pointer-events: none; }
.roi-ch-tip {
  position: absolute;
  top: 0;
  transform: translateX(-50%);
  background: var(--bg);
  border: 1px solid var(--rule);
  border-radius: 3px;
  padding: 0.15rem 0.45rem;
  font-size: 0.68rem;
  color: var(--bone-text);
  pointer-events: none;
  white-space: nowrap;
}

.roi-breakdown { width: 100%; border-collapse: collapse; font-size: 0.85rem; margin-bottom: 1rem; }
.roi-breakdown td { padding: 0.45rem 0; border-bottom: 1px solid var(--rule-soft); }
.roi-bd-val { text-align: right; white-space: nowrap; }
.roi-bd-pct { color: var(--text-mute); font-size: 0.75rem; margin-left: 0.35rem; }
.roi-bd-blocked { color: var(--text-mute); }
.roi-bd-opcost td { color: var(--text-mute); }
.roi-bd-math {
  font-size: 0.7rem;
  color: var(--text-mute);
  line-height: 1.4;
  margin-top: 0.15rem;
  word-break: break-word;
}
.roi-notes { margin-bottom: 0.5rem; }
.roi-note-share { border-left-color: var(--amber-ink); }
.roi-note {
  font-size: 0.8rem;
  color: var(--text-mute);
  border-left: 2px solid var(--rule);
  padding-left: 0.75rem;
  margin: 0 0 0.6rem;
  line-height: 1.45;
}
.roi-note-freed { border-left-color: var(--signal); }
.roi-upside-note {
  font-size: 0.85rem;
  color: var(--signal);
  margin: 0.5rem 0 0.75rem;
}
.roi-actions { display: grid; gap: 0.6rem; margin: 1.25rem 0 1rem; }
.roi-action-btn { width: 100%; text-align: center; justify-content: center; }
.roi-email-form {
  border: 1px dashed var(--rule);
  border-radius: 4px;
  padding: 1rem;
}
.roi-email-form .roi-turnstile { margin: 0.75rem 0; min-height: 65px; }
.roi-share {
  background: none; border: 0; cursor: pointer;
  color: var(--steel); font-size: 0.8rem; font-family: var(--font-body);
  padding: 0.1rem 0;
}
.roi-share:hover { color: var(--bone-text); }
.roi-disclaimer {
  color: var(--text-mute);
  font-size: 0.75rem;
  line-height: 1.5;
  margin: 0.75rem 0 0;
}

/* ---- mobile results bar ---- */
.roi-mobile-bar {
  display: none;
  position: fixed;
  left: 0; right: 0; bottom: 0;
  z-index: 40;
  background: rgba(26, 29, 33, 0.97);
  border-top: 1px solid var(--amber);
  padding: 0.7rem var(--container-pad);
  cursor: pointer;
  border-left: 0; border-right: 0; border-bottom: 0;
  color: var(--bone-text);
  font-family: var(--font-body);
  text-align: left;
  align-items: baseline;
  gap: 0.75rem;
}
.roi-mobile-bar-label {
  font-size: 0.7rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-mute);
}
.roi-mobile-bar-value { font-family: var(--font-display); font-size: 1.15rem; color: var(--amber-ink); }
.roi-mobile-bar-hint { margin-left: auto; font-size: 0.75rem; color: var(--text-mute); }
/* In wizard mode the bar still shows the live payback (so phones aren't typing
   blind), but the results panel is hidden — so no jump hint, no pointer. */
.roi-mobile-bar.is-wizard { cursor: default; }
.roi-mobile-bar.is-wizard .roi-mobile-bar-hint { display: none; }

/* ---- upside builders + CTA note + methodology section ---- */
.roi-upside-helpers { margin-top: 0.75rem; display: grid; gap: 0.15rem; }
.roi-cta-note { margin: -0.2rem 0 0.2rem; text-align: center; }
.roi-method { border-top: 1px solid var(--rule-soft); }
.section-title-sm {
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 600;
  margin-bottom: 1.25rem;
}
.roi-method-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem 2.5rem;
  max-width: 900px;
}
.roi-method-grid h3 {
  font-family: var(--font-display);
  font-size: 0.95rem;
  margin-bottom: 0.4rem;
  color: var(--amber-ink);
}
.roi-method-grid p { font-size: 0.9rem; color: var(--text-mute); line-height: 1.6; }
@media (max-width: 767px) {
  .roi-method-grid { grid-template-columns: 1fr; }
}

/* ---- resume-or-fresh choice (saved session never renders unchosen) ---- */
#roi-app[data-resume] .roi-layout,
#roi-app[data-resume] .roi-wizard-bar { display: none; }
.roi-resume {
  border: 1px solid var(--rule);
  border-left: 2px solid var(--amber);
  border-radius: 4px;
  background: var(--bg-lift);
  padding: 1.5rem;
  margin: 1rem 0 2rem;
}
.roi-resume-title { margin: 0 0 0.35rem; font-size: 1rem; }
.roi-resume-sub { margin: 0 0 1rem; font-size: 0.8rem; color: var(--text-mute); }
.roi-resume-actions { display: flex; flex-wrap: wrap; gap: 0.75rem; }

/* ---- print report ---- */
.roi-report { display: none; }

@media print {
  body { background: #fff; color: #111; }
  body > header, body > footer, .roi-mobile-bar { display: none !important; }
  main > * { display: none !important; }
  main > #roi-report {
    display: block !important;
    color: #111;
    font-family: 'Source Sans 3', Arial, sans-serif;
    font-size: 11pt;
    line-height: 1.5;
    max-width: 7.2in;
    margin: 0 auto;
  }
  .roi-rep-head {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    border-bottom: 2px solid #111;
    padding-bottom: 0.35in;
    margin-bottom: 0.3in;
  }
  .roi-rep-wordmark {
    font-family: 'Barlow Condensed', Arial, sans-serif;
    font-weight: 600;
    font-size: 18pt;
    letter-spacing: 0.04em;
  }
  .roi-rep-wordmark span {
    display: block;
    font-size: 7pt;
    font-weight: 400;
    letter-spacing: 0.3em;
    text-transform: uppercase;
    color: #666;
  }
  .roi-rep-meta { text-align: right; font-size: 10pt; color: #333; }
  .roi-rep-tiles { display: flex; gap: 0.25in; margin-bottom: 0.3in; }
  .roi-rep-tile {
    flex: 1;
    border: 1px solid #bbb;
    padding: 0.15in;
  }
  .roi-rep-tile:first-child { border: 2px solid #111; }
  .roi-rep-tile-v { font-family: 'Barlow Condensed', Arial, sans-serif; font-size: 16pt; font-weight: 600; }
  .roi-rep-tile-l { font-size: 7.5pt; letter-spacing: 0.08em; text-transform: uppercase; color: #555; margin-top: 4pt; }
  #roi-report h3 {
    font-family: 'Barlow Condensed', Arial, sans-serif;
    font-size: 11pt;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    margin: 0.25in 0 0.1in;
  }
  .roi-rep-table { width: 100%; border-collapse: collapse; font-size: 10pt; }
  .roi-rep-table td { padding: 4pt 0; border-bottom: 1px solid #ddd; }
  .roi-rep-num { text-align: right; white-space: nowrap; }
  .roi-rep-total td { border-top: 2px solid #111; border-bottom: none; font-weight: 600; }
  .roi-rep-chart { margin: 0.1in 0 0.2in; max-width: 5.5in; }
  .roi-rep-chart .roi-ch-grid { stroke: #e0e0e0; }
  .roi-rep-chart .roi-ch-zero { stroke: #999; }
  .roi-rep-chart .roi-ch-line { stroke: #1A1D21; stroke-width: 2; fill: none; }
  .roi-rep-chart .roi-ch-dot { fill: #1A1D21; stroke: #fff; stroke-width: 2; }
  .roi-rep-chart .roi-ch-tick { fill: #777; font-size: 8.5px; }
  .roi-rep-chart .roi-ch-belabel { fill: #111; font-size: 9.5px; font-weight: 600; }
  .roi-rep-math { font-size: 8pt; color: #666; font-family: 'IBM Plex Mono', Consolas, monospace; margin-top: 2pt; }
  .roi-rep-y1 td { color: #444; border-bottom: none; }
  .roi-rep-notes { font-size: 9pt; color: #444; margin: 0.12in 0; padding-left: 0.2in; }
  #roi-report ul { padding-left: 0.2in; margin: 0.08in 0; }
  .roi-rep-upside { font-size: 9.5pt; color: #333; }
  .roi-rep-foot {
    margin-top: 0.35in;
    padding-top: 0.15in;
    border-top: 1px solid #bbb;
    font-size: 8.5pt;
    color: #555;
  }
}

/* ---- responsive ---- */
@media (max-width: 1023px) {
  .roi-layout { grid-template-columns: 1fr; }
  .roi-results { position: static; }
  .roi-mobile-bar { display: flex; }
  .roi-picker { grid-template-columns: 1fr; }
  .roi-soft-grid { grid-template-columns: 1fr; }
  .roi-row-3 { grid-template-columns: 1fr; }
  .roi-helper-grid { grid-template-columns: 1fr; }
  .roi-line { grid-template-columns: 1fr; align-items: stretch; }
  .roi-line-remove { justify-self: end; }
  /* Touch targets: the helper toggles carry the whole no-data path. */
  .roi-helper-toggle { padding: 0.6rem 0 0.5rem; }
  .roi-toggle { gap: 0.5rem; }
  .roi-toggle label { padding: 0.45rem 0.6rem; border: 1px solid var(--rule-soft); border-radius: 4px; }
  .roi-share { padding: 0.55rem 0; }
  .roi-skip { padding: 0.5rem 0; }
}

@media (max-width: 480px) {
  /* Give the Turnstile widget room inside the dashed email box. */
  .roi-results-inner { padding: 1rem; }
  .roi-email-form { padding: 0.75rem 0.6rem; }
}

/* =============================================================
   v4 compatibility + light-theme corrections
   The calculator markup is carried over from the live site unchanged so
   roi.js keeps working. These rules map its v1-era classes onto the v4
   system and fix the few places the ported CSS assumed a dark ground.
   ============================================================= */

.mono {
  font-family: var(--font-mono);
  font-weight: 400;
  font-size: 0.78rem;
  letter-spacing: 0.10em;
  text-transform: uppercase;
  color: var(--ink-2);
}
.section-kicker {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  font-weight: 500;
  letter-spacing: 0.10em;
  text-transform: uppercase;
  color: var(--amber-ink);
  margin-bottom: 0.85rem;
}
.section-title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(2rem, 4vw, 2.9rem);
  line-height: 1.08;
  margin: 0 0 1rem;
  text-wrap: balance;
}
.section-title-sm {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.6rem;
  margin-bottom: 1.25rem;
}
.section-body { color: var(--ink-2); max-width: 68ch; }
.section-tight { padding: 2.75rem 0; }

/* The calculator sits on the mist ground so its white panels read as cards */
body:has(#roi-app) { background: var(--bone); }
.roi-panel, .roi-results-inner { box-shadow: 0 1px 2px rgba(26, 29, 33, 0.05); }

/* Ported from a dark theme: these assumed light text on a dark bar */
.roi-mobile-bar {
  background: rgba(251, 250, 248, 0.97);
  border-top: 3px solid var(--amber);
  box-shadow: 0 -4px 16px rgba(26, 29, 33, 0.12);
}
.roi-step-node { background: var(--panel); }
.roi-step.is-done .roi-step-node { color: var(--dark); }
.roi-infotip { box-shadow: 0 6px 20px rgba(26, 29, 33, 0.18); }
.roi-tile-value { font-family: var(--font-display); font-weight: 700; }
.roi-panel-title { font-family: var(--font-display); font-weight: 700; }
.roi-pick-title { font-family: var(--font-display); font-weight: 600; font-size: 1.05rem; }
