/* Lead capture — floating button + guided quote wizard (native <dialog>) */

.quote-fab {
  position: fixed;
  right: 22px;
  bottom: 22px;
  z-index: 800;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: var(--accent);
  color: #fff;
  border: 0;
  border-radius: 980px;
  padding: 15px 24px;
  font-family: inherit;
  font-size: 15px;
  font-weight: 600;
  letter-spacing: -0.01em;
  cursor: pointer;
  box-shadow: 0 8px 28px rgba(213,68,68,.42);
  opacity: 0;
  visibility: hidden;
  transform: translateY(14px) scale(.96);
  transition: transform .38s var(--ease-out), box-shadow .3s var(--ease-out),
              background .2s var(--ease), opacity .3s var(--ease), visibility .3s;
}
/* only appears once the hero is scrolled past */
body.past-hero .quote-fab { opacity: 1; visibility: visible; transform: none; }
body.past-hero .quote-fab:hover { background: var(--accent-2); transform: translateY(-3px); box-shadow: 0 14px 36px rgba(213,68,68,.5); }
.quote-fab svg { width: 19px; height: 19px; flex-shrink: 0; }
@media (max-width: 520px) {
  .quote-fab { right: 14px; bottom: 14px; padding: 13px 20px; font-size: 14px; }
}

/* ---------- dialog ---------- */
.qw {
  width: min(540px, calc(100vw - 32px));
  max-height: min(88vh, 820px);
  padding: 0;
  border: 0;
  border-radius: var(--r-lg);
  background: var(--bg);
  color: var(--ink);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
}
.qw::backdrop {
  background: rgba(8, 12, 22, .58);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
.qw[open] { animation: qwIn .38s var(--ease-out); }
.qw[open]::backdrop { animation: qwFade .38s var(--ease-out); }
@keyframes qwIn { from { opacity: 0; transform: translateY(18px) scale(.97); } to { opacity: 1; transform: none; } }
@keyframes qwFade { from { opacity: 0; } to { opacity: 1; } }

.qw__head {
  position: relative;
  background: var(--dark);
  color: #fff;
  padding: 28px 30px 24px;
}
.qw__head h2 { font-size: 1.4rem; letter-spacing: -0.028em; margin: 0; }
.qw__head p { margin: 7px 0 0; font-size: 14.5px; color: rgba(255,255,255,.6); }
.qw__close {
  position: absolute; top: 18px; right: 18px;
  width: 34px; height: 34px;
  display: grid; place-items: center;
  border: 0; border-radius: 50%;
  background: rgba(255,255,255,.1); color: #fff;
  cursor: pointer;
  transition: background .2s var(--ease);
}
.qw__close:hover { background: rgba(255,255,255,.2); }
.qw__close svg { width: 15px; height: 15px; }

.qw__bar { display: flex; gap: 5px; padding: 18px 30px 0; }
.qw__bar span { height: 3px; flex: 1; border-radius: 3px; background: var(--bg-tint); transition: background .35s var(--ease); }
.qw__bar span.on { background: var(--accent); }

.qw {
  --qw-pad-x: 30px;
  --qw-pad-b: 30px;
}
.qw__body {
  padding: 22px var(--qw-pad-x) var(--qw-pad-b);
  overflow-y: auto;
  max-height: calc(88vh - 172px);
}
@media (max-width: 520px) {
  .qw { --qw-pad-x: 22px; --qw-pad-b: 24px; }
  .qw__head { padding: 24px 22px 20px; }
  .qw__bar { padding-inline: 22px; }
}

.qw__step { animation: qwStep .32s var(--ease-out); }
@keyframes qwStep { from { opacity: 0; transform: translateX(10px); } to { opacity: 1; transform: none; } }

.qw__q { font-size: 1.2rem; font-weight: 700; letter-spacing: -0.025em; margin: 0 0 20px; line-height: 1.3; }

.qw__opts { display: grid; gap: 10px; }
.qw__opt {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  width: 100%;
  text-align: left;
  font-family: inherit;
  font-size: 16px;
  font-weight: 500;
  color: var(--ink);
  background: var(--bg-alt);
  border: 1.5px solid var(--hairline);
  border-radius: var(--r-sm);
  padding: 16px 18px;
  cursor: pointer;
  transition: border-color .18s var(--ease), background .18s var(--ease), transform .18s var(--ease-out);
}
.qw__opt:hover { border-color: var(--accent); background: #fff; transform: translateX(3px); }
.qw__opt svg { width: 16px; height: 16px; color: var(--ink-faint); flex-shrink: 0; transition: color .18s var(--ease), transform .2s var(--ease-out); }
.qw__opt:hover svg { color: var(--accent); transform: translateX(3px); }

.qw__note {
  margin: 20px 0 0;
  padding: 14px 16px;
  background: var(--bg-tint);
  border-radius: var(--r-sm);
  font-size: 12.5px;
  line-height: 1.55;
  color: var(--ink-soft);
}

.qw__consent {
  display: flex; gap: 11px; align-items: flex-start;
  margin-top: 18px;
  font-size: 12.5px; line-height: 1.5; color: var(--ink-soft);
  cursor: pointer;
}
.qw__consent input { margin: 2px 0 0; flex-shrink: 0; width: 16px; height: 16px; accent-color: var(--accent); }

.qw__privacy { margin: 10px 0 0; font-size: 12px; color: var(--ink-faint); }
.qw__privacy a { color: var(--ink-soft); text-decoration: underline; text-underline-offset: 2px; }
.qw__privacy a:hover { color: var(--accent); }

.qw__err { margin: 14px 0 0; font-size: 14px; color: var(--accent-2); display: none; }
.qw__err.show { display: block; }

.qw__actions {
  display: flex; justify-content: space-between; align-items: center; gap: 12px;
  position: sticky;
  bottom: calc(-1 * var(--qw-pad-b, 30px));
  margin: 22px calc(-1 * var(--qw-pad-x, 30px)) calc(-1 * var(--qw-pad-b, 30px));
  padding: 16px var(--qw-pad-x, 30px);
  background: var(--bg);
  border-top: 1px solid var(--hairline);
}
.qw__actions .btn { flex-shrink: 0; }
/* steps with no form don't need the bar to span full width */
.qw__step > .qw__actions:last-child { border-top: 0; }

.qw__done { text-align: center; padding: 18px 0 8px; }
.qw__done-ico {
  width: 62px; height: 62px; margin: 0 auto 20px;
  display: grid; place-items: center;
  border-radius: 50%;
  background: rgba(26,127,75,.1); color: #1a7f4b;
}
.qw__done-ico svg { width: 30px; height: 30px; }
.qw__done h3 { font-size: 1.4rem; margin: 0 0 10px; letter-spacing: -0.028em; }
.qw__done p { margin: 0 0 24px; color: var(--ink-soft); font-size: 15.5px; line-height: 1.6; }

.qw__hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
