.cotizador-section {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(circle at 8% 16%, rgba(128, 168, 208, .18), transparent 28rem),
    linear-gradient(180deg, #f8fbfe 0%, var(--paper) 100%);
}

.cotizador-section::after {
  position: absolute;
  right: -180px;
  bottom: -220px;
  width: 480px;
  height: 480px;
  border: 1px solid rgba(20, 48, 82, .08);
  border-radius: 50%;
  content: "";
  pointer-events: none;
}

.cotizador-heading {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(260px, .65fr);
  align-items: end;
  gap: 48px;
  margin-bottom: 52px;
}

.cotizador-heading h2 { max-width: 760px; }
.cotizador-heading .lead { max-width: 660px; }

.cotizador-privacy {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 16px 18px;
  color: var(--navy);
  background: rgba(255, 255, 255, .72);
  border: 1px solid rgba(20, 48, 82, .12);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  font-size: .9rem;
  line-height: 1.55;
}

.cotizador-privacy svg {
  width: 22px;
  height: 22px;
  flex: 0 0 auto;
  color: var(--success);
}

.cotizador-layout {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(250px, .64fr) minmax(0, 1.36fr);
  align-items: start;
  gap: 40px;
}

.cotizador-guide {
  position: sticky;
  top: 112px;
  padding: 30px;
  color: #fff;
  background: var(--navy);
  border-radius: 12px;
  box-shadow: var(--shadow-lg);
}

.cotizador-guide::before {
  display: block;
  width: 44px;
  height: 3px;
  margin-bottom: 24px;
  background: var(--accent);
  content: "";
}

.cotizador-guide h3 { margin-bottom: 14px; color: #fff; font-size: 1.65rem; }
.cotizador-guide > p { color: rgba(255, 255, 255, .72); font-size: .94rem; }

.cotizador-guide-list {
  display: grid;
  gap: 18px;
  margin: 28px 0 0;
  padding: 0;
  list-style: none;
}

.cotizador-guide-list li {
  display: grid;
  grid-template-columns: 28px 1fr;
  gap: 12px;
  color: rgba(255, 255, 255, .82);
  font-size: .88rem;
  line-height: 1.45;
}

.cotizador-guide-list span {
  display: grid;
  width: 28px;
  height: 28px;
  place-items: center;
  color: var(--navy);
  background: var(--accent);
  border-radius: 50%;
  font-size: .74rem;
  font-weight: 900;
}

.cotizador-guide-note {
  margin-top: 28px;
  padding-top: 20px;
  color: rgba(255, 255, 255, .62);
  border-top: 1px solid rgba(255, 255, 255, .14);
  font-size: .78rem;
}

.cotizador-card {
  min-width: 0;
  padding: clamp(24px, 4vw, 44px);
  background: var(--surface);
  border: 1px solid rgba(20, 48, 82, .12);
  border-radius: 12px;
  box-shadow: var(--shadow-lg);
}

.cotizador-progress { margin-bottom: 34px; }

.cotizador-progress-copy {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 10px;
  color: var(--muted);
  font-size: .82rem;
  font-weight: 800;
  letter-spacing: .04em;
  text-transform: uppercase;
}

.cotizador-progress-track {
  height: 8px;
  overflow: hidden;
  background: var(--blue-soft);
  border-radius: 999px;
}

.cotizador-progress-bar {
  width: 16.666%;
  height: 100%;
  background: linear-gradient(90deg, var(--blue), var(--navy-2));
  border-radius: inherit;
  transition: width .25s var(--ease);
}

.cotizador-panel { border: 0; margin: 0; padding: 0; min-width: 0; }
.cotizador-panel[hidden], .cotizador-results[hidden], .cotizador-conditional[hidden] { display: none !important; }

.cotizador-step-kicker {
  display: block;
  margin-bottom: 8px;
  color: var(--blue);
  font-size: .76rem;
  font-weight: 900;
  letter-spacing: .1em;
  text-transform: uppercase;
}

.cotizador-panel legend {
  display: block;
  width: 100%;
  margin-bottom: 10px;
  padding: 0;
  color: var(--navy);
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(1.7rem, 3vw, 2.2rem);
  font-weight: 600;
  line-height: 1.15;
}

.cotizador-step-lead {
  margin-bottom: 28px;
  color: var(--muted);
  font-size: .98rem;
}

.cotizador-choice-grid { display: grid; gap: 12px; }
.cotizador-choice-grid.two-columns { grid-template-columns: repeat(2, minmax(0, 1fr)); }

.cotizador-choice {
  position: relative;
  display: flex;
  align-items: flex-start;
  gap: 12px;
  min-height: 68px;
  padding: 14px 16px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  cursor: pointer;
  transition: border-color .2s ease, background .2s ease, box-shadow .2s ease;
  touch-action: manipulation;
  box-sizing: border-box;
}

.cotizador-choice:hover { border-color: rgba(79, 120, 159, .62); }
.cotizador-choice:has(input:checked) {
  background: rgba(238, 245, 251, .9);
  border-color: var(--blue);
  box-shadow: 0 0 0 2px rgba(79, 120, 159, .14);
}

.cotizador-choice input[type="radio"],
.cotizador-choice input[type="checkbox"],
.cotizador-asset-row input[type="checkbox"] {
  appearance: auto;
  -webkit-appearance: auto;
  width: 18px !important;
  min-width: 18px !important;
  max-width: 18px !important;
  height: 18px !important;
  min-height: 18px !important;
  max-height: 18px !important;
  padding: 0 !important;
  margin: 3px 0 0 0 !important;
  border: none !important;
  border-radius: 50% !important;
  background: transparent !important;
  box-shadow: none !important;
  accent-color: var(--navy) !important;
  cursor: pointer;
  flex: 0 0 18px !important;
  display: inline-block !important;
}

.cotizador-choice input[type="checkbox"],
.cotizador-asset-row input[type="checkbox"] {
  border-radius: 3px !important;
}

.cotizador-choice span {
  display: block;
  flex: 1 1 auto;
  min-width: 0;
}

.cotizador-choice strong { display: block; color: var(--navy); font-size: .92rem; line-height: 1.35; }
.cotizador-choice small { display: block; margin-top: 3px; color: var(--muted); font-size: .78rem; line-height: 1.45; }

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

.cotizador-field { min-width: 0; }
.cotizador-field-full { grid-column: 1 / -1; }

.cotizador-field label {
  display: block;
  margin-bottom: 8px;
  color: var(--navy);
  font-size: .86rem;
  font-weight: 800;
}

.cotizador-field input,
.cotizador-field select {
  width: 100%;
  min-height: 52px;
  padding: 11px 13px;
  color: var(--ink);
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 6px;
  outline: none;
  transition: border-color .2s ease, box-shadow .2s ease;
}

.cotizador-field input:focus,
.cotizador-field select:focus {
  border-color: var(--blue);
  box-shadow: 0 0 0 4px rgba(79, 120, 159, .14);
}

.cotizador-field input[disabled] { color: #8290a3; background: #eef1f4; cursor: not-allowed; }

.cotizador-help {
  display: block;
  margin-top: 7px;
  color: var(--muted);
  font-size: .76rem;
  line-height: 1.45;
}

.cotizador-inline-note {
  margin-top: 20px;
  padding: 14px 16px;
  color: var(--navy);
  background: var(--accent-soft);
  border-left: 3px solid var(--accent);
  border-radius: 4px;
  font-size: .82rem;
}

.cotizador-assets { display: grid; gap: 14px; }

.cotizador-asset-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(180px, .72fr);
  align-items: center;
  gap: 16px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.cotizador-asset-row .cotizador-choice { min-height: auto; padding: 0; border: 0; }
.cotizador-asset-row .cotizador-choice:hover,
.cotizador-asset-row .cotizador-choice:has(input:checked) { background: transparent; border: 0; box-shadow: none; }

.cotizador-summary {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 24px;
  padding: 18px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.cotizador-summary div { display: flex; justify-content: space-between; gap: 14px; font-size: .8rem; }
.cotizador-summary span { color: var(--muted); }
.cotizador-summary strong { color: var(--navy); text-align: right; font-variant-numeric: tabular-nums; }

.cotizador-error {
  min-height: 24px;
  margin-top: 18px;
  color: #a51d2d;
  font-size: .84rem;
  font-weight: 700;
}

.cotizador-actions {
  display: flex;
  justify-content: flex-end;
  gap: 12px;
  margin-top: 26px;
}

.cotizador-actions .button { min-width: 140px; }

.cotizador-results-header {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: start;
  gap: 24px;
  padding-bottom: 28px;
  border-bottom: 1px solid var(--line);
}

.cotizador-result-badge {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  margin-bottom: 13px;
  padding: 6px 11px;
  color: var(--navy);
  background: var(--accent-soft);
  border-radius: 999px;
  font-size: .74rem;
  font-weight: 900;
  letter-spacing: .05em;
  text-transform: uppercase;
}

.cotizador-results h3 { margin-bottom: 10px; font-size: clamp(1.8rem, 3vw, 2.35rem); }
.cotizador-result-message { max-width: 660px; color: var(--muted); }

.cotizador-result-icon {
  display: grid;
  width: 58px;
  height: 58px;
  place-items: center;
  color: #fff;
  background: var(--success);
  border-radius: 50%;
  font-size: 1.45rem;
  font-weight: 900;
}

.cotizador-result-icon[data-status="parcial"] { background: var(--blue); }
.cotizador-result-icon[data-status="no-viable"] { background: #9a4e22; }

.cotizador-recommendation {
  display: grid;
  gap: 5px;
  margin: 24px 0;
  padding: 18px 20px;
  background: var(--blue-soft);
  border-left: 3px solid var(--blue);
}

.cotizador-recommendation span { color: var(--blue); font-size: .74rem; font-weight: 900; letter-spacing: .08em; text-transform: uppercase; }
.cotizador-recommendation strong { color: var(--navy); font-size: 1.02rem; }
.cotizador-recommendation small { color: var(--muted); }

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

.cotizador-metric {
  min-width: 0;
  padding: 20px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.cotizador-metric.is-primary { color: #fff; background: var(--navy); border-color: var(--navy); }
.cotizador-metric span { display: block; margin-bottom: 8px; color: var(--muted); font-size: .76rem; font-weight: 800; line-height: 1.4; }
.cotizador-metric strong { display: block; color: var(--navy); font-size: clamp(1.25rem, 3vw, 1.75rem); line-height: 1.2; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.cotizador-metric small { display: block; margin-top: 7px; color: var(--muted); font-size: .72rem; line-height: 1.4; }
.cotizador-metric.is-primary span,
.cotizador-metric.is-primary small { color: rgba(255, 255, 255, .68); }
.cotizador-metric.is-primary strong { color: #fff; }

.cotizador-investment {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 20px;
  margin-top: 14px;
  padding: 20px;
  background: var(--accent-soft);
  border: 1px solid rgba(128, 168, 208, .48);
  border-radius: 8px;
}

.cotizador-investment > div > span { display: block; color: var(--navy); font-size: .86rem; font-weight: 900; }
.cotizador-investment small { display: block; margin-top: 5px; color: var(--muted); font-size: .72rem; }
.cotizador-investment > strong { color: var(--navy); font-size: 1.3rem; text-align: right; font-variant-numeric: tabular-nums; }
.cotizador-investment > strong > span { display: block; color: inherit; font: inherit; }

.cotizador-payment {
  margin-top: 18px;
  padding: 24px;
  background: #f5f8fb;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.cotizador-payment-heading {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(220px, .72fr);
  gap: 24px;
  align-items: end;
  margin-bottom: 22px;
}

.cotizador-payment-heading h4,
.cotizador-comparison-heading h4 {
  margin: 0;
  color: var(--navy);
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.35rem;
  line-height: 1.25;
}

.cotizador-payment-heading p {
  margin: 0;
  color: var(--muted);
  font-size: .8rem;
  line-height: 1.55;
}

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

.cotizador-payment-stage {
  min-width: 0;
  padding: 18px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 6px;
}

.cotizador-payment-stage-head {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 80px;
  margin-bottom: 14px;
}

.cotizador-payment-stage-meta {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 10px;
  min-height: 42px;
}

.cotizador-payment-stage-meta span {
  display: block;
  color: var(--muted);
  font-size: .72rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: .02em;
  line-height: 1.35;
}

.cotizador-payment-stage output {
  padding: 3px 8px;
  color: var(--navy);
  background: var(--accent-soft);
  border-radius: 4px;
  font-size: .7rem;
  font-weight: 800;
  white-space: nowrap;
  line-height: 1.2;
  flex-shrink: 0;
}

.cotizador-payment-stage-head strong {
  display: block;
  color: var(--navy);
  font-size: 1.25rem;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
  line-height: 1.2;
}

.cotizador-payment-stage label {
  display: block;
  min-height: 18px;
  margin-bottom: 8px;
  color: var(--navy);
  font-size: .76rem;
  font-weight: 800;
  line-height: 1.3;
}

.cotizador-payment-stage input[type="range"] {
  width: 100%;
  min-height: 28px;
  margin: 0;
  padding: 0;
  accent-color: var(--blue);
  cursor: pointer;
}

.cotizador-range-labels {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  margin-top: 3px;
  color: var(--muted);
  font-size: .64rem;
}

.cotizador-payment-stage p {
  margin: 16px 0 3px;
  color: var(--muted);
  font-size: .78rem;
}

.cotizador-payment-stage p strong {
  color: var(--navy);
  font-size: 1.02rem;
  font-variant-numeric: tabular-nums;
}

.cotizador-payment-stage > small {
  color: var(--muted);
  font-size: .68rem;
  line-height: 1.45;
}

.cotizador-comparison {
  margin-top: 18px;
  padding-top: 24px;
  border-top: 1px solid var(--line);
}

.cotizador-comparison-heading { margin-bottom: 16px; }

.cotizador-comparison-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
}

.cotizador-comparison-grid article {
  min-width: 0;
  padding: 18px;
  background: #fff;
  border-right: 1px solid var(--line);
}

.cotizador-comparison-grid article:last-child { border-right: 0; }
.cotizador-comparison-grid article.is-saving { background: rgba(29, 122, 69, .08); }
.cotizador-comparison-grid span { display: block; color: var(--muted); font-size: .72rem; font-weight: 800; }
.cotizador-comparison-grid strong {
  display: block;
  margin: 7px 0 5px;
  color: var(--navy);
  font-size: clamp(1rem, 2.4vw, 1.35rem);
  font-variant-numeric: tabular-nums;
  overflow-wrap: anywhere;
}
.cotizador-comparison-grid .is-saving strong { color: var(--success); }
.cotizador-comparison-grid small { color: var(--muted); font-size: .66rem; line-height: 1.4; }

[data-theme="dark"] .cotizador-payment {
  background: #161a22;
  border-color: rgba(201, 169, 98, .12);
}

[data-theme="dark"] .cotizador-payment-heading h4,
[data-theme="dark"] .cotizador-comparison-heading h4,
[data-theme="dark"] .cotizador-payment-stage-head strong,
[data-theme="dark"] .cotizador-payment-stage label,
[data-theme="dark"] .cotizador-payment-stage p strong,
[data-theme="dark"] .cotizador-comparison-grid strong {
  color: #f0ede8;
}

[data-theme="dark"] .cotizador-payment-heading p,
[data-theme="dark"] .cotizador-payment-stage-head span,
[data-theme="dark"] .cotizador-payment-stage p,
[data-theme="dark"] .cotizador-payment-stage > small,
[data-theme="dark"] .cotizador-range-labels,
[data-theme="dark"] .cotizador-comparison-grid span,
[data-theme="dark"] .cotizador-comparison-grid small {
  color: #a8b0bd;
}

[data-theme="dark"] .cotizador-payment-stage,
[data-theme="dark"] .cotizador-comparison-grid article {
  background: #1e2330;
  border-color: rgba(255, 255, 255, .08);
}

[data-theme="dark"] .cotizador-payment-stage output {
  color: #0d0f13;
  background: #c9a962;
}

[data-theme="dark"] .cotizador-payment-stage input[type="range"] { accent-color: #c9a962; }

[data-theme="dark"] .cotizador-comparison {
  border-top-color: rgba(255, 255, 255, .08);
}

[data-theme="dark"] .cotizador-comparison-grid {
  border-color: rgba(255, 255, 255, .08);
}

[data-theme="dark"] .cotizador-comparison-grid article.is-saving {
  background: rgba(29, 122, 69, .18);
}

[data-theme="dark"] .cotizador-comparison-grid .is-saving strong { color: #75d69f; }

.cotizador-disclaimer {
  margin-top: 20px;
  color: var(--muted);
  font-size: .74rem;
  line-height: 1.55;
}

.cotizador-results .cotizador-actions { justify-content: space-between; align-items: center; }

@media (max-width: 980px) {
  .cotizador-heading { grid-template-columns: 1fr; gap: 24px; }
  .cotizador-layout { grid-template-columns: 1fr; }
  .cotizador-guide { position: static; display: grid; grid-template-columns: 1fr 1fr; gap: 22px 32px; }
  .cotizador-guide::before { grid-column: 1 / -1; margin-bottom: 0; }
  .cotizador-guide-list { margin: 0; }
  .cotizador-guide-note { margin: 0; padding: 0; border: 0; }
}

@media (max-width: 700px) {
  .cotizador-choice-grid.two-columns,
  .cotizador-form-grid,
  .cotizador-summary,
  .cotizador-metrics { grid-template-columns: 1fr; }
  .cotizador-field-full { grid-column: auto; }
  .cotizador-guide { grid-template-columns: 1fr; padding: 24px; }
  .cotizador-guide::before { grid-column: auto; }
  .cotizador-asset-row { grid-template-columns: 1fr; }
  .cotizador-results-header,
  .cotizador-investment,
  .cotizador-payment-heading,
  .cotizador-payment-grid { grid-template-columns: 1fr; }
  .cotizador-investment strong { text-align: left; }
  .cotizador-comparison-grid { grid-template-columns: 1fr; }
  .cotizador-comparison-grid article { border-right: 0; border-bottom: 1px solid var(--line); }
  .cotizador-comparison-grid article:last-child { border-bottom: 0; }
}

@media (max-width: 560px) {
  .cotizador-section .container { width: min(calc(100% - 24px), var(--container)); }
  .cotizador-card { padding: 22px 16px; }
  .cotizador-payment { padding: 18px 14px; }
  .cotizador-progress-copy { font-size: .72rem; }
  .cotizador-actions,
  .cotizador-results .cotizador-actions { display: grid; grid-template-columns: 1fr; }
  .cotizador-actions .button { width: 100%; }
}

@media (prefers-reduced-motion: reduce) {
  .cotizador-progress-bar { transition: none; }
}
