/* ===========================
   CALCULADORA DE PRESUPUESTO
=========================== */
.calc {
  background: var(--black);
  border-top: 1px solid var(--border);
  padding: 120px 0;
}

.calc__inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 40px;
  position: relative;
}

.calc__header {
  margin-bottom: 64px;
}
.calc__index {
  font-size: .75rem;
  font-weight: 600;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--steel);
  margin-bottom: 20px;
}
.calc__header h2 {
  font-family: var(--font-title);
  font-size: clamp(40px, 5.5vw, 66px);
  color: var(--white);
  line-height: 1.0;
  margin-bottom: 0;
}
.calc__header p {
  font-family: var(--font-body);
  color: rgba(255,255,255,.65);
  font-size: .95rem;
  line-height: 1.75;
  max-width: 520px;
  margin-top: 20px;
}

/* Progress bar */
.calc__progress {
  display: flex;
  align-items: center;
  gap: 0;
  margin-bottom: 56px;
}
.calc__step-dot {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  position: relative;
}
.calc__step-dot span {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 1.5px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: .75rem;
  font-weight: 700;
  color: rgba(255,255,255,.5);
  transition: border-color .3s ease, background .3s ease, color .3s ease;
  background: var(--black);
  z-index: 1;
}
.calc__step-dot label {
  font-size: .7rem;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: rgba(255,255,255,.5);
  white-space: nowrap;
  transition: color .3s ease;
}
.calc__step-dot.active span {
  border-color: var(--white);
  color: var(--white);
  background: var(--black);
}
.calc__step-dot.active label { color: rgba(255,255,255,.6); }
.calc__step-dot.done span {
  border-color: var(--steel);
  background: var(--steel);
  color: var(--black);
}
.calc__step-dot.done label { color: var(--steel); }

.calc__progress-line {
  flex: 1;
  height: 1px;
  background: var(--border);
  margin: 0 12px;
  margin-bottom: 24px;
  position: relative;
  overflow: hidden;
}
.calc__progress-line::after {
  content: '';
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 0%;
  background: var(--steel);
  transition: width .4s ease;
}
.calc__progress-line.filled::after { width: 100%; }

/* Panels */
.calc__panel { display: none; }
.calc__panel.active { display: block; }

.calc__prev-summary {
  font-size: .75rem;
  font-weight: 600;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--steel);
  margin-bottom: 12px;
  min-height: 1em;
}

.calc__question {
  font-family: var(--font-title);
  font-size: clamp(28px, 4vw, 42px);
  font-weight: 400;
  color: var(--white);
  margin-bottom: 32px;
  line-height: 1.05;
  letter-spacing: .01em;
}

/* Slider m² */
.calc__slider-wrap {
  display: flex;
  flex-direction: column;
  gap: 20px;
}
.calc__slider-value {
  font-family: var(--font-title);
  font-size: 5rem;
  color: var(--white);
  line-height: 1;
}
.calc__slider-value span {
  font-size: 1.8rem;
  color: var(--steel);
  margin-left: 4px;
}
.calc__range {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 2px;
  background: var(--border);
  outline: none;
  border-radius: 2px;
  position: relative;
}
.calc__range::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--white);
  cursor: pointer;
  border: 3px solid var(--black);
  box-shadow: 0 0 0 1.5px var(--white);
  transition: transform .2s ease;
}
.calc__range::-webkit-slider-thumb:hover { transform: scale(1.2); }
.calc__range-labels {
  display: flex;
  justify-content: space-between;
  font-size: .75rem;
  color: rgba(255,255,255,.55);
  font-weight: 500;
}

/* Opciones tipo/nivel */
.calc__options {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}
.calc__options--3 { grid-template-columns: repeat(3, 1fr); }

.calc__option {
  border: 1.5px solid var(--border);
  border-radius: var(--r);
  padding: 20px;
  cursor: pointer;
  transition: border-color .2s ease, background .2s ease;
  background: transparent;
  text-align: left;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.calc__option:hover {
  border-color: rgba(255,255,255,.3);
  background: var(--surface);
}
.calc__option.selected {
  border-color: var(--white);
  background: rgba(255,255,255,.05);
}
.calc__option-icon { font-size: 1.6rem; margin-bottom: 4px; }
.calc__option-name {
  font-family: var(--font-title);
  font-size: 1.3rem;
  font-weight: 400;
  color: var(--white);
  letter-spacing: .02em;
}
.calc__option-desc {
  font-family: var(--font-title);
  font-size: 1rem;
  color: rgba(255,255,255,.6);
  line-height: 1.2;
  letter-spacing: .02em;
}

/* Navegación pasos */
.calc__nav {
  display: flex;
  gap: 12px;
  margin-top: 40px;
}
.calc__btn-next {
  padding: 14px 36px;
  background: var(--white);
  color: var(--black);
  font-family: var(--font-body);
  font-size: .9rem;
  font-weight: 700;
  border: none;
  border-radius: var(--r);
  cursor: pointer;
  transition: background .2s ease, transform .15s ease-out;
  letter-spacing: .04em;
}
.calc__btn-next:hover {
  background: var(--pure);
  transform: translateY(-1px);
}
.calc__btn-next:disabled {
  opacity: .3;
  cursor: not-allowed;
  transform: none;
}
.calc__btn-back {
  padding: 14px 24px;
  background: transparent;
  color: rgba(255,255,255,.65);
  font-family: var(--font-body);
  font-size: .9rem;
  font-weight: 600;
  border: 1.5px solid var(--border);
  border-radius: var(--r);
  cursor: pointer;
  transition: color .2s ease, border-color .2s ease;
}
.calc__btn-back:hover { color: var(--white); border-color: rgba(255,255,255,.3); }

/* Resultado */
.calc__result {
  display: none;
  flex-direction: column;
  gap: 32px;
}
.calc__result.active { display: flex; }

.calc__result-range {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r);
  padding: 40px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.calc__result-label {
  font-family: var(--font-body);
  font-size: .75rem;
  font-weight: 700;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--steel);
}
.calc__result-price {
  font-family: var(--font-title);
  font-size: clamp(40px, 7vw, 72px);
  color: var(--white);
  line-height: 1;
}
.calc__result-note {
  font-size: .82rem;
  color: rgba(255,255,255,.55);
  line-height: 1.6;
  margin-top: 8px;
}

.calc__result-summary {
  display: flex;
  gap: 0;
  border: 1px solid var(--border);
  border-radius: var(--r);
  overflow: hidden;
}
.calc__summary-item {
  flex: 1;
  padding: 20px 24px;
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.calc__summary-item:last-child { border-right: none; }
.calc__summary-label {
  font-size: .7rem;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--steel);
}
.calc__summary-val {
  font-size: .95rem;
  font-weight: 600;
  color: var(--white);
}

.calc__result-disclaimer {
  font-size: .8rem;
  color: rgba(255,255,255,.55);
  line-height: 1.65;
  padding: 20px;
  border: 1px solid var(--border);
  border-radius: var(--r);
  border-left: 3px solid var(--steel);
}

.calc__result-cta {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}
.calc__btn-reset {
  padding: 14px 24px;
  background: transparent;
  color: rgba(255,255,255,.65);
  font-family: var(--font-body);
  font-size: .88rem;
  font-weight: 600;
  border: 1.5px solid var(--border);
  border-radius: var(--r);
  cursor: pointer;
  transition: color .2s ease, border-color .2s ease;
}
.calc__btn-reset:hover { color: var(--white); border-color: rgba(255,255,255,.3); }

/* Responsive */
@media (max-width: 768px) {
  .calc { padding: 80px 0; }
  .calc__inner { padding: 0 24px; }
  .calc__options { grid-template-columns: 1fr 1fr; }
  .calc__options--3 { grid-template-columns: 1fr; }
  .calc__result-summary { flex-direction: column; }
  .calc__summary-item { border-right: none; border-bottom: 1px solid var(--border); }
  .calc__summary-item:last-child { border-bottom: none; }
  .calc__header { margin-bottom: 40px; }
  .calc__progress { margin-bottom: 36px; }
  .calc__nav { flex-direction: row; flex-wrap: wrap; }
  .calc__btn-next { flex: 1; }
}
@media (max-width: 480px) {
  .calc__options { grid-template-columns: 1fr; }
  .calc__slider-value { font-size: 3.5rem; }
  /* Ocultar labels del progress bar en pantallas muy pequeñas */
  .calc__step-dot label { display: none; }
  .calc__progress { gap: 0; }
}
