.calculator-page { overflow-x: hidden; }
.calculator-page [hidden] { display: none !important; }
.location-search { position: relative; }
.location-suggestions { position: absolute; z-index: 20; top: 82px; left: 0; right: 0; max-height: 310px; overflow-y: auto; border: 1px solid #aeb6b3; background: #fff; box-shadow: 0 16px 40px rgba(10,21,27,.14); }
.location-suggestions button { width: 100%; display: block; padding: 13px 15px; border: 0; border-bottom: 1px solid #e1e3df; background: #fff; color: var(--ink); text-align: left; line-height: 1.4; cursor: pointer; }
.location-suggestions button:hover,.location-suggestions button[aria-selected="true"] { background: #fff2eb; }
.manual-map-link { width: fit-content; padding: 3px 0; border: 0; border-bottom: 1px solid #8f9996; background: transparent; color: #26373e; font-size: 12px; cursor: pointer; }
.calc-map-step { padding: 18px; border: 1px solid #c4c9c5; background: #ebeae4; }
.map-heading { display: flex; justify-content: space-between; gap: 18px; margin-bottom: 14px; }
.map-heading strong { font-family: Georgia,serif; font-size: 20px; font-weight: 400; }
.map-heading p { margin: 6px 0 0; color: #657176; font-size: 12px; line-height: 1.5; }
.map-heading > span { align-self: start; padding: 7px 9px; background: #fff; color: #8b3f2a; font-size: 11px; }
.calc-map { width: 100%; height: 310px; border: 1px solid #b9c0bd; background: repeating-linear-gradient(45deg,#e2e3de 0 12px,#ecece7 12px 24px); }
.map-manual { display: grid; grid-template-columns:auto 1fr auto 1fr; align-items:center; gap:8px; margin-top:12px; }
.map-manual input { min-width: 0; min-height: 44px; padding: 0 10px; border: 1px solid #bcc2bf; }
.map-actions { display: flex; flex-wrap: wrap; gap: 9px; margin-top: 12px; }
.map-actions button { min-height: 44px; padding: 0 13px; border: 1px solid #aeb6b3; background: transparent; cursor: pointer; }
.map-actions .button { width: auto; border-color: var(--copper); }
#map-message { margin: 10px 0 0; color: #59666c; font-size: 12px; line-height: 1.5; }
.calc-constraints { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; margin: 0; padding: 15px; border: 1px solid #c4c9c5; }
.calc-constraints legend { padding: 0 5px; color: #424f55; font-size: 13px; font-weight: 700; }
.calc-constraints label { display: flex; align-items: flex-start; gap: 8px; color: #58656a; font-size: 12px; line-height: 1.4; }
.calc-constraints input { flex: none; width: 17px; min-height: 17px; height: 17px; margin: 0; }
.confirmed-location { margin-bottom: 16px; padding: 12px; border-left: 3px solid var(--copper); background: rgba(255,255,255,.08); color: rgba(255,255,255,.8); font-size: 13px; }
.estimate-table { width: 100%; margin: 8px 0; border-collapse: collapse; color: rgba(255,255,255,.8); font-size: 12px; }
.estimate-table th,.estimate-table td { padding: 8px 5px; border-bottom: 1px solid var(--line-dark); background: transparent; text-align: left; }
.estimate-table th:last-child,.estimate-table td:last-child { text-align: right; }

@media (max-width: 767px) {
  .calculator-intro h1 {
    max-width: 100%;
    font-size: clamp(34px, 10vw, 40px);
    overflow-wrap: anywhere;
  }
  .calculator-page .calc-wide { max-width: calc(100vw - 28px); }
  .inner-header-shell { gap: 6px; }
  .inner-header .header-cta { max-width: 116px; padding-inline: 9px; overflow: hidden; font-size: 10px; }
  .calc-map { height: 260px; }
  .map-heading { flex-direction: column; }
  .map-heading > span { align-self: flex-start; }
  .map-manual { grid-template-columns: 1fr 1fr; }
  .map-manual label { grid-column: 1; }
  .map-manual input { grid-column: 2; }
  .map-actions button,.map-actions .button { width: 100%; }
  .calc-constraints { grid-template-columns: 1fr; }
}
