/* ============================================================
   CALCULATOR.CSS — Price estimator page
   ============================================================ */

/* ─── Hero ─── */
.calc-hero {
  background: var(--parchment);
  padding: 150px 0 88px;
  text-align: center;
}
.calc-hero h1 {
  font-size: clamp(2.4rem, 4.5vw, 3.6rem);
  color: var(--green-deep);
  margin-bottom: 16px;
}
.calc-hero p {
  color: var(--text-mid);
  font-size: 1.05rem;
  max-width: 520px;
  margin: 0 auto;
  line-height: 1.7;
}

/* ─── Main section ─── */
.calc-section {
  padding: 64px 0 88px;
  background: var(--cream);
}

/* ─── Service notice banner ─── */
.service-notice {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  background: #fff8e1;
  border: 1.5px solid #f0c846;
  border-radius: 6px;
  padding: 16px 20px;
  margin-bottom: 36px;
  font-size: 0.9rem;
  color: var(--text-mid);
  line-height: 1.6;
}
.service-notice svg {
  width: 20px;
  height: 20px;
  fill: #b8860b;
  flex-shrink: 0;
  margin-top: 2px;
}
.service-notice a {
  color: var(--terracotta);
  font-weight: 700;
  text-decoration: underline;
}

/* ─── Calculator grid ─── */
.calc-grid {
  display: grid;
  grid-template-columns: 1fr 400px;
  gap: 36px;
  align-items: start;
}

/* ─── Inputs panel ─── */
.calc-inputs {
  background: #fff;
  border-radius: 8px;
  padding: 40px;
  box-shadow: var(--shadow);
}

/* ─── Fieldset ─── */
.calc-fieldset {
  border: none;
  padding: 0;
  margin-bottom: 36px;
  overflow: hidden;
  max-height: 600px;
  opacity: 1;
  transition: max-height 0.45s ease, opacity 0.3s ease, margin-bottom 0.4s ease;
}
.calc-fieldset.calc-fieldset--hidden {
  max-height: 0;
  opacity: 0;
  margin-bottom: 0;
  pointer-events: none;
}

/* ─── Step label ─── */
.calc-step-label {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--text-mid);
  margin-bottom: 18px;
  margin: 0 0 18px;
}
.step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--green-deep);
  color: #fff;
  font-size: 0.7rem;
  font-weight: 700;
  flex-shrink: 0;
}

/* ─── Service cards ─── */
.service-cards {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}
.service-card {
  cursor: pointer;
  display: block;
  position: relative;
}
.service-card input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
  width: 0;
}
.service-card__body {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 24px 16px 20px;
  border: 2px solid #e0ddd6;
  border-radius: 6px;
  gap: 8px;
  transition: border-color 0.25s ease, background 0.25s ease;
}
.service-card:hover .service-card__body {
  border-color: var(--sage);
}
.service-card input:checked + .service-card__body {
  border-color: var(--terracotta);
  background: #fff8f5;
}
.service-card__icon {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.service-card__icon svg {
  width: 32px;
  height: 32px;
  fill: var(--sage);
  transition: fill 0.25s ease;
}
.service-card input:checked + .service-card__body .service-card__icon svg {
  fill: var(--terracotta);
}
.service-card__name {
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-dark);
  line-height: 1.2;
}
.service-card__desc {
  font-size: 0.78rem;
  color: var(--text-light);
  line-height: 1.4;
}

/* ─── Option pills ─── */
.option-pills {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}
.option-pill {
  cursor: pointer;
  display: block;
  position: relative;
}
.option-pill input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
  width: 0;
}
.option-pill span {
  display: block;
  padding: 10px 20px;
  border: 2px solid #e0ddd6;
  border-radius: 100px;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text-mid);
  transition: border-color 0.22s ease, background 0.22s ease, color 0.22s ease;
  white-space: nowrap;
}
.option-pill:hover span {
  border-color: var(--sage);
}
.option-pill input:checked + span {
  background: var(--green-deep);
  border-color: var(--green-deep);
  color: #fff;
}

/* ─── Size input ─── */
.size-input-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 20px;
}
#sizeInput {
  flex: 1;
  padding: 14px 16px;
  border: 2px solid #e0ddd6;
  border-radius: 4px;
  font-size: 1.6rem;
  font-family: var(--font-display);
  color: var(--text-dark);
  background: #fff;
  text-align: center;
  transition: border-color 0.22s ease;
  -moz-appearance: textfield;
  appearance: textfield;
}
#sizeInput::-webkit-outer-spin-button,
#sizeInput::-webkit-inner-spin-button { -webkit-appearance: none; }
#sizeInput:focus {
  outline: none;
  border-color: var(--green-deep);
}
.size-unit {
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-light);
  white-space: nowrap;
}
.size-slider-wrap { margin-top: 4px; }
#sizeSlider {
  width: 100%;
  accent-color: var(--terracotta);
  cursor: pointer;
  height: 4px;
}
.size-range-labels {
  display: flex;
  justify-content: space-between;
  margin-top: 6px;
  font-size: 0.71rem;
  color: var(--text-light);
}

/* ─── Result column ─── */
.calc-result-col {
  position: sticky;
  top: 100px;
}
.calc-result {
  background: var(--green-deep);
  border-radius: 8px;
  padding: 40px 36px;
  color: #fff;
  min-height: 380px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

/* ─── Result states ─── */
.result-state {
  text-align: center;
}

/* placeholder */
.result-state-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: rgba(255,255,255,0.07);
  margin-bottom: 18px;
}
.result-state-icon svg {
  width: 28px;
  height: 28px;
  fill: var(--sage);
}
.result-state-icon--sm { width: 48px; height: 48px; }
.result-state-icon--sm svg { width: 22px; height: 22px; }

.result-placeholder-title {
  font-family: var(--font-display);
  font-size: 1.5rem;
  color: var(--cream);
  margin-bottom: 10px;
}
.result-placeholder-text {
  font-size: 0.88rem;
  color: rgba(245,240,232,0.55);
  line-height: 1.6;
}

/* incomplete */
.result-incomplete-text {
  font-size: 0.9rem;
  color: rgba(245,240,232,0.6);
  margin-top: 8px;
}

/* estimate */
.result-label {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--sage);
  margin-bottom: 10px;
}
.result-price {
  font-family: var(--font-display);
  font-size: clamp(1.9rem, 3vw, 2.8rem);
  color: #fff;
  line-height: 1.1;
  margin-bottom: 6px;
}
.result-qualifier {
  font-size: 0.78rem;
  color: rgba(245,240,232,0.5);
  margin-bottom: 24px;
}
.result-breakdown {
  background: rgba(255,255,255,0.07);
  border-radius: 6px;
  padding: 18px 20px;
  margin-bottom: 28px;
  text-align: left;
}
.breakdown-list {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 9px 16px;
  margin: 0;
}
.breakdown-list dt {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: rgba(245,240,232,0.45);
  align-self: center;
}
.breakdown-list dd {
  font-size: 0.86rem;
  color: var(--cream);
  font-weight: 600;
  margin: 0;
}
.result-cta { text-align: center; }
.result-cta .btn-primary { width: 100%; }
.result-cta-note {
  font-size: 0.73rem;
  color: rgba(245,240,232,0.38);
  margin-top: 10px;
}

/* contact state */
.result-contact-title {
  font-family: var(--font-display);
  font-size: 1.25rem;
  color: var(--cream);
  margin: 16px 0 10px;
}
.result-contact-text {
  font-size: 0.86rem;
  color: rgba(245,240,232,0.68);
  line-height: 1.65;
  margin-bottom: 24px;
}

/* ─── Disclaimer section ─── */
.calc-disclaimer-section {
  background: var(--parchment);
  padding: 80px 0;
}
.disclaimer-card {
  display: flex;
  gap: 32px;
  background: #fff;
  border-radius: 8px;
  padding: 44px 40px;
  box-shadow: 0 2px 12px rgba(26,46,26,0.07);
}
.disclaimer-card__icon {
  flex-shrink: 0;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: #e8f0e8;
  display: flex;
  align-items: center;
  justify-content: center;
}
.disclaimer-card__icon svg {
  width: 26px;
  height: 26px;
  fill: var(--green-mid);
}
.disclaimer-card__title {
  font-size: clamp(1.25rem, 2.2vw, 1.65rem);
  color: var(--green-deep);
  margin-bottom: 12px;
}
.disclaimer-card__lead {
  color: var(--text-mid);
  font-size: 0.95rem;
  margin-bottom: 18px;
  line-height: 1.7;
}
.disclaimer-card__list {
  padding-left: 18px;
  margin-bottom: 18px;
}
.disclaimer-card__list li {
  font-size: 0.875rem;
  color: var(--text-mid);
  margin-bottom: 9px;
  line-height: 1.65;
}
.disclaimer-card__body p:last-child {
  font-size: 0.875rem;
  color: var(--text-mid);
}
.disclaimer-card__body p:last-child a {
  color: var(--terracotta);
  font-weight: 700;
  text-decoration: underline;
}

/* ─── CTA section ─── */
.calc-cta-section {
  background: var(--green-deep);
  padding: 96px 0;
  text-align: center;
}
.calc-cta-inner { max-width: 600px; margin: 0 auto; }
.calc-cta-section .section-tag { color: var(--sage); }
.calc-cta-section h2 {
  font-size: clamp(1.9rem, 3.5vw, 2.9rem);
  color: var(--cream);
  margin-bottom: 16px;
}
.calc-cta-section p {
  color: rgba(245,240,232,0.72);
  font-size: 1rem;
  margin-bottom: 36px;
  line-height: 1.7;
}

/* ─── Responsive ─── */
@media (max-width: 1024px) {
  .calc-grid { grid-template-columns: 1fr; }
  .calc-result-col { position: static; }
}
@media (max-width: 768px) {
  .calc-hero { padding: 120px 0 64px; }
  .calc-inputs { padding: 28px 22px; }
  .service-cards { grid-template-columns: 1fr; }
  .calc-result { padding: 32px 24px; min-height: auto; }
  .disclaimer-card { flex-direction: column; gap: 20px; padding: 28px 24px; }
  .option-pills { flex-direction: column; }
  .option-pill span { white-space: normal; }
}
