/* ══════════════════════════════════════════════════════════
   Quote estimate — step-by-step wizard enhancements
   Live distance + estimate strip, then a clean inline result.
   Submits to quote.php which emails the admin and stores the lead.
   ══════════════════════════════════════════════════════════ */

/* ---- live estimate strip inside the footer (above the buttons) ---- */
.mq-wizard-v2 .mq-foot {
  flex-wrap: wrap;
}
.mq-pv {
  flex: 0 0 100%;
  max-width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 2px;
  padding: 9px 12px;
  border: 1px solid var(--mq-line, #e6e3da);
  border-radius: 11px;
  background: var(--mq-canvas, #f7f6f2);
}
.mq-wizard-v2 .mq-pv { display: none; }
.mq-wizard-v2.mq-show-preview .mq-pv { display: flex; }
.mq-wizard-v2 .mq-pv-hint { color: var(--mq-muted, #66758a); }
.mq-pv-route {
  font-size: 12.5px;
  font-weight: 700;
  color: var(--mq-ink, #141b2e);
}
.mq-pv-route i {
  font-style: normal;
  color: var(--mq-brand, #3457d5);
  font-weight: 900;
}
.mq-pv-info {
  font-size: 12.5px;
  color: var(--mq-muted, #69708a);
  white-space: nowrap;
}
.mq-pv-info b {
  color: var(--mq-brand-deep, #2543ad);
  font-size: 13px;
}
.mq-pv-hint {
  flex: 1 1 100%;
  text-align: center;
  font-size: 12px;
  color: var(--mq-muted, #69708a);
}

/* ---- input error state ---- */
.mq-error {
  border-color: #d64545 !important;
  box-shadow: 0 0 0 3px rgba(214, 69, 69, .18) !important;
  animation: mq-shake .25s ease;
}
@keyframes mq-shake {
  25% { transform: translateX(-3px); }
  75% { transform: translateX(3px); }
}

/* ---- inline submit result ---- */
.mq-result {
  margin: 0 26px 18px;
  border-radius: 14px;
  padding: 16px 18px;
  display: grid;
  gap: 8px;
  font-size: 13.5px;
  line-height: 1.55;
}
.mq-wizard-v2 .mq-result {
  margin: 0 24px 20px;
  padding: 18px 20px;
  border-radius: 12px;
  box-shadow: 0 8px 20px rgba(17, 47, 79, .08);
}
.mq-result b {
  font-size: 14.5px;
}
.mq-result.is-ok {
  border: 1px solid #bfe6cd;
  background: #f0fbf4;
  color: #14532d;
}
.mq-result.is-ok b {
  color: #166534;
}
.mq-result.is-error {
  border: 1px solid #f0c3c3;
  background: #fdf3f3;
  color: #7f1d1d;
}
.mq-result.is-error b {
  color: #991b1b;
}
.mq-result small {
  color: inherit;
  opacity: .85;
}
.mq-result-wa {
  justify-self: start;
  display: inline-flex;
  align-items: center;
  margin-top: 2px;
  padding: 11px 16px;
  border-radius: 11px;
  background: #25d366;
  color: #fff;
  font: 800 13.5px/1.2 Arial, Helvetica, sans-serif;
  text-decoration: none;
  box-shadow: 0 8px 18px rgba(37, 211, 102, .28);
}
.mq-result-wa:hover {
  filter: brightness(1.05);
}

/* ---- reduced spacing on small screens ---- */
@media (max-width: 480px) {
  .mq-pv { justify-content: center; }
  .mq-result { margin-right: 18px; margin-left: 18px; padding: 14px; }
}

/* Keep contact autofill helpful without making it look like a warning box. */
.mq-wizard-v2 .mq-autofill {
  display: inline-flex;
  width: auto;
  flex-direction: row;
  align-items: center;
  gap: 7px;
  margin: 0 0 14px;
  padding: 7px 10px;
  border: 0;
  border-radius: 7px;
  background: #f1f5f9;
  color: var(--mq-brand-deep);
  font-size: 11px;
}
.mq-wizard-v2 .mq-autofill span { font-size: 11px; }

/* Simple quote card: one screen, four essential details, one action. */
.mq-simple {
  overflow: hidden;
  border: 1px solid #d9e4ee !important;
  border-radius: 20px !important;
  background: #fff !important;
  box-shadow: 0 20px 50px rgba(17, 47, 79, .14) !important;
}
.mq-simple-head { padding: 26px 28px 20px; background: linear-gradient(135deg, #f4f8fd, #fff); border-bottom: 1px solid #e3ebf2; }
.mq-simple-head .mq-eyebrow { display: inline-block; margin-bottom: 10px; padding: 5px 10px; border-radius: 99px; background: #e8f1fb; color: #1d4f91; font: 800 10px Arial, sans-serif; letter-spacing: .06em; text-transform: uppercase; }
.mq-simple-head h2 { margin: 0 0 6px; color: #17243b; font: 800 25px/1.15 Arial, sans-serif; letter-spacing: -.5px; }
.mq-simple-head p { margin: 0; color: #66758a; font-size: 13px; line-height: 1.5; }
.mq-simple-body { display: grid; gap: 16px; padding: 24px 28px 20px; }
.mq-simple-primary { display: grid; gap: 16px; }
.mq-simple-body > .mq-simple-row, .mq-simple-body > .mq-simple-message { display: none; }
.mq-simple [hidden] { display: none !important; }
.mq-simple-step-two { display: grid; gap: 16px; }
.mq-simple-step-title span { color: #1d4f91; font-size: 10px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; }
.mq-simple-step-title h3 { margin: 5px 0 4px; color: #17243b; font-size: 18px; }
.mq-simple-step-title p { margin: 0; color: #718294; font-size: 12px; }
.mq-distance-field > span { display: flex; justify-content: space-between; }
.mq-distance-field > span em { color: #1d4f91; }
.mq-distance-field > div { position: relative; }
.mq-distance-field input { padding-right: 42px; }
.mq-distance-field b { position: absolute; top: 15px; right: 13px; color: #66758a; font-size: 12px; }
.mq-simple label { display: grid; gap: 7px; color: #40546a; font-size: 11px; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; }
.mq-simple label em { color: #8795a5; font-size: 10px; font-style: normal; font-weight: 500; letter-spacing: 0; text-transform: none; }
.mq-simple input, .mq-simple select, .mq-simple textarea { width: 100%; min-height: 46px; box-sizing: border-box; padding: 12px 13px; border: 1px solid #d4e0ea; border-radius: 10px; background: #f8fafc; color: #17243b; font: 14px Arial, sans-serif; outline: 0; }
.mq-simple select { appearance: auto; }
.mq-simple textarea { min-height: 72px; resize: vertical; }
.mq-simple input:focus, .mq-simple select:focus, .mq-simple textarea:focus { border-color: #1d4f91; background: #fff; box-shadow: 0 0 0 4px #e8f1fb; }
.mq-simple-route, .mq-simple-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.mq-simple-route { position: relative; }
.mq-simple-swap { position: absolute; z-index: 1; top: 29px; left: calc(50% - 17px); width: 34px; height: 34px; border: 1px solid #d4e0ea; border-radius: 50%; background: #fff; color: #1d4f91; cursor: pointer; }
.mq-simple-foot { display: flex; align-items: center; gap: 15px; padding: 17px 28px 22px; border-top: 1px solid #e3ebf2; }
.mq-simple-back { border: 0; background: transparent; color: #66758a; font-weight: 700; cursor: pointer; }
.mq-simple-submit { margin-left: auto; min-height: 48px; padding: 0 22px; border: 0; border-radius: 10px; background: linear-gradient(135deg, #1d5a9f, #123b70); color: #fff; font: 800 14px Arial, sans-serif; box-shadow: 0 8px 18px rgba(29, 79, 145, .25); cursor: pointer; }
.mq-simple-submit span { margin-left: 8px; font-size: 18px; vertical-align: -1px; }
.mq-simple-submit:hover { filter: brightness(1.08); }
.mq-simple-foot small { color: #7d8b9a; font-size: 10px; line-height: 1.45; }
.mq-simple .mq-pv { display: none !important; }
.mq-simple .mq-result { margin: 0 28px 22px; }
.mq-quote-modal { position: fixed; inset: 0; z-index: 1000; display: grid; place-items: center; padding: 20px; }
.mq-modal-backdrop { position: absolute; inset: 0; background: rgba(13, 29, 48, .62); backdrop-filter: blur(4px); }
.mq-modal-card { position: relative; width: min(100%, 430px); box-sizing: border-box; padding: 30px 26px 26px; border: 1px solid #dce7f0; border-radius: 18px; background: #fff; box-shadow: 0 24px 70px rgba(4, 25, 48, .28); text-align: center; animation: mq-modal-in .2s ease-out; }
@keyframes mq-modal-in { from { opacity: 0; transform: translateY(10px) scale(.98); } to { opacity: 1; transform: none; } }
.mq-modal-close { position: absolute; top: 10px; right: 12px; width: 32px; height: 32px; border: 0; border-radius: 50%; background: #f1f5f8; color: #607286; font-size: 22px; line-height: 1; cursor: pointer; }
.mq-modal-icon { display: grid; width: 44px; height: 44px; margin: 0 auto 12px; place-items: center; border-radius: 50%; background: #e9f7ef; color: #16834a; font-size: 24px; font-weight: 800; }
.mq-modal-card h2 { margin: 0 0 18px; color: #17243b; font: 800 21px/1.2 Arial, sans-serif; }
.mq-modal-estimate { display: grid; gap: 5px; margin-bottom: 16px; padding: 16px; border: 1px solid #cfe0f0; border-radius: 12px; background: #f2f7fc; }
.mq-modal-estimate small { color: #58718a; font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; }
.mq-modal-estimate strong { color: #123b70; font: 800 25px Arial, sans-serif; }
.mq-modal-estimate span { color: #6b7d8f; font-size: 11px; line-height: 1.45; }
.mq-modal-message { display: grid; gap: 8px; color: #536679; font-size: 13px; line-height: 1.5; }
.mq-modal-message b { color: #176b42; font-size: 14px; }
.mq-modal-message small { color: #718294; }
.mq-modal-message .mq-result-wa { justify-self: center; margin-top: 6px; }
.mq-modal-loading { padding-top: 34px; padding-bottom: 34px; }
.mq-modal-loading p { margin: 0 0 4px; color: #536679; font-size: 13px; }
.mq-modal-loading small { color: #8795a5; font-size: 11px; }
.mq-spinner { width: 38px; height: 38px; margin: 0 auto 18px; border: 4px solid #dbe8f3; border-top-color: #1d4f91; border-radius: 50%; animation: mq-spin .8s linear infinite; }
@keyframes mq-spin { to { transform: rotate(360deg); } }
@media(max-width:480px) { .mq-modal-card { padding: 27px 18px 20px; } }
@media(max-width:560px) { .mq-simple-head, .mq-simple-body { padding-right: 18px; padding-left: 18px; } .mq-simple-foot { align-items: stretch; flex-direction: column; padding-right: 18px; padding-left: 18px; } .mq-simple-submit { width: 100%; } .mq-simple-route, .mq-simple-row { grid-template-columns: 1fr; } .mq-simple-swap { top: 50%; left: calc(50% - 17px); transform: translateY(-50%); } .mq-simple-route { gap: 14px; } .mq-simple-route label:first-child input { padding-right: 44px; } }

/* ══════════════════════════════════════════════════════════
   Professional wizard: step indicator + live estimate summary
   ══════════════════════════════════════════════════════════ */

/* ---- step progress indicator (persistent across steps) ---- */
.mq-steps {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px dashed #dbe5ee;
}
.mq-step {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
}
.mq-step-dot {
  display: grid;
  place-items: center;
  width: 27px;
  height: 27px;
  border-radius: 50%;
  background: #e5edf5;
  color: #8b9bad;
  font: 800 12px/1 Arial, sans-serif;
}
.mq-step.is-active .mq-step-dot {
  background: linear-gradient(135deg, #1d5a9f, #123b70);
  color: #fff;
  box-shadow: 0 4px 12px rgba(29, 79, 145, .32);
}
.mq-step-line {
  flex: 1 1 auto;
  min-width: 46px;
  height: 3px;
  border-radius: 99px;
  background: #e5edf5;
  transition: background .25s ease;
}
.mq-step-label {
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .07em;
  text-transform: uppercase;
  color: #8b9bad;
  white-space: nowrap;
}
.mq-step.is-active .mq-step-label { color: #1d4f91; }
.mq-simple-details-active .mq-step-line { background: linear-gradient(90deg, #1d5a9f, #3b6fc0); }
.mq-simple-details-active .mq-step[data-step="2"] .mq-step-dot {
  background: linear-gradient(135deg, #1d5a9f, #123b70);
  color: #fff;
  box-shadow: 0 4px 12px rgba(29, 79, 145, .32);
}
.mq-simple-details-active .mq-step[data-step="2"] .mq-step-label { color: #1d4f91; }
