/* ==========================================================================
   Quote builder — in the homepage template's visual language
   Tokens mirror the template: paper #f5f5f5, cards #fafafa, ink #171717,
   muted #737373, hairlines #e5e5e5, radii 24/16/10, Switzer + Inter.
   ========================================================================== */

.qb {
  --qb-bg: #f5f5f5;
  --qb-card: #fafafa;
  --qb-ink: #171717;
  --qb-muted: #737373;
  --qb-line: #e5e5e5;
  --qb-dark: #171717;
  --qb-brand: #ff4d3d;
  --qb-ease: cubic-bezier(.22, 1, .36, 1);
  background: var(--qb-bg);
  color: var(--qb-ink);
  font-family: "Inter", "Inter Placeholder", sans-serif;
  padding: 40px 64px 120px;
}
.page-build { background: var(--qb-bg, #f5f5f5); }

.qb [hidden] { display: none !important; }
.qb-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------------------------------------------------------------- Heading */
.qb-head {
  display: grid;
  grid-template-columns: 328px minmax(0, 1fr) 260px;
  align-items: start;
  gap: 0 24px;
  max-width: 1312px;
  margin: 0 auto 56px;
}
.qb-eyebrow {
  margin: 0;
  font: 400 12px/16px "Inter", "Inter Placeholder", sans-serif;
  color: var(--qb-ink);
  display: flex;
  gap: 8px;
  padding-top: 10px;
}
.qb-eyebrow span { color: var(--qb-muted); letter-spacing: -0.06em; }
.qb-eyebrow--dark { color: #fafafa; padding: 0; }
.qb-title {
  margin: 0;
  font: 600 64px/72px "Switzer", "Switzer Placeholder", sans-serif;
  letter-spacing: -0.02em;
  color: #000;
  max-width: 640px;
}
.qb-indent { display: inline-block; width: 50px; }
.qb-lede {
  margin: 0;
  align-self: end;
  font-size: 14px;
  line-height: 20px;
  color: var(--qb-muted);
}

/* ------------------------------------------------------------------ Grid */
.qb-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 16px;
  max-width: 1312px;
  margin: 0 auto;
  align-items: start;
}

.qb-card {
  min-width: 0;
  background: var(--qb-card);
  border-radius: 24px;
  padding: 24px;
  min-height: 560px;
  display: flex;
  flex-direction: column;
}

/* ----------------------------------------------------------------- Steps */
.qb-steps {
  list-style: none;
  margin: 0 0 24px;
  padding: 4px;
  display: inline-flex;
  gap: 4px;
  background: var(--qb-bg);
  border-radius: 12px;
  align-self: flex-start;
}
.qb-step {
  border: 0;
  background: transparent;
  font: 500 14px/20px "Inter", sans-serif;
  color: var(--qb-muted);
  padding: 8px 14px;
  border-radius: 9px;
  cursor: pointer;
  display: flex;
  gap: 8px;
  align-items: center;
  transition: background-color .25s var(--qb-ease), color .25s var(--qb-ease);
}
.qb-step span { font-size: 11px; letter-spacing: 0.04em; opacity: 0.7; }
.qb-step:hover { color: var(--qb-ink); }
.qb-step.is-active { background: var(--qb-dark); color: #fafafa; }
.qb-step.is-done:not(.is-active) { color: var(--qb-ink); }

/* ---------------------------------------------------------------- Panels */
.qb-panel { border: 0; margin: 0; padding: 0; min-width: 0; display: none; }
.qb-panel.is-active { display: block; animation: qb-in .4s var(--qb-ease) both; }
@keyframes qb-in { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }

/* Packages */
.qb-packages { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.qb-package { position: relative; cursor: pointer; }
.qb-package input, .qb-addon input { position: absolute; opacity: 0; pointer-events: none; }
.qb-package__body {
  display: flex;
  flex-direction: column;
  gap: 12px;
  height: 100%;
  padding: 20px;
  border-radius: 16px;
  background: #fff;
  box-shadow: inset 0 0 0 1px var(--qb-line);
  transition: background-color .3s var(--qb-ease), box-shadow .3s var(--qb-ease), transform .3s var(--qb-ease);
}
.qb-package:hover .qb-package__body { transform: translateY(-3px); }
.qb-package__top { display: flex; justify-content: space-between; align-items: center; }
.qb-tag {
  font-size: 14px;
  line-height: 20px;
  padding: 6px 12px;
  border-radius: 8px;
  background: var(--qb-bg);
  color: var(--qb-muted);
}
.qb-package__price {
  font: 600 40px/44px "Switzer", sans-serif;
  letter-spacing: -0.03em;
  color: var(--qb-ink);
}
.qb-package__price small { font: 400 14px/20px "Inter", sans-serif; letter-spacing: 0; color: var(--qb-muted); margin-left: 6px; }
.qb-package__tagline { font-size: 14px; line-height: 20px; color: var(--qb-muted); }
.qb-package__specs { display: flex; flex-wrap: wrap; gap: 6px; }
.qb-package__specs span { font-size: 12px; line-height: 16px; padding: 4px 8px; border-radius: 6px; background: var(--qb-bg); color: var(--qb-ink); }
.qb-package__more { margin-top: auto; font-size: 13px; color: var(--qb-ink); }
.qb-package__features { display: none; flex-direction: column; gap: 6px; font-size: 13px; line-height: 18px; color: var(--qb-muted); }
.qb-package__features span::before { content: "✓"; margin-right: 8px; color: var(--qb-brand); }
.qb-package:hover .qb-package__features,
.qb-package input:focus-visible + .qb-package__body .qb-package__features { display: flex; }
.qb-package:hover .qb-package__more { display: none; }

.qb-package input:checked + .qb-package__body { background: var(--qb-dark); box-shadow: none; }
.qb-package input:checked + .qb-package__body .qb-package__price,
.qb-package input:checked + .qb-package__body .qb-package__more { color: #fafafa; }
.qb-package input:checked + .qb-package__body .qb-tag { background: rgba(255,255,255,.1); color: #fafafa; }
.qb-package input:checked + .qb-package__body .qb-package__specs span { background: rgba(255,255,255,.08); color: #e5e5e5; }
.qb-package input:checked + .qb-package__body .qb-package__tagline,
.qb-package input:checked + .qb-package__body .qb-package__features { color: #a3a3a3; }
.qb-package input:focus-visible + .qb-package__body { box-shadow: 0 0 0 2px var(--qb-brand); }

/* Tick */
.qb-check {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  box-shadow: inset 0 0 0 1.5px var(--qb-line);
  display: grid;
  place-items: center;
  flex: none;
  transition: background-color .25s var(--qb-ease), box-shadow .25s var(--qb-ease), transform .3s var(--qb-ease);
}
.qb-check::after {
  content: "";
  width: 9px;
  height: 5px;
  border: solid #fff;
  border-width: 0 0 2px 2px;
  transform: translateY(-1px) rotate(-45deg) scale(0);
  transition: transform .25s var(--qb-ease);
}
input:checked + .qb-package__body .qb-check,
input:checked ~ .qb-addon__side .qb-check { background: var(--qb-brand); box-shadow: none; }
input:checked + .qb-package__body .qb-check::after,
input:checked ~ .qb-addon__side .qb-check::after { transform: translateY(-1px) rotate(-45deg) scale(1); }

/* Add-ons */
.qb-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 16px; }
.qb-chip {
  border: 0;
  background: #fff;
  box-shadow: inset 0 0 0 1px var(--qb-line);
  border-radius: 999px;
  padding: 8px 14px;
  font: 500 13px/16px "Inter", sans-serif;
  color: var(--qb-ink);
  cursor: pointer;
  transition: background-color .25s var(--qb-ease), color .25s var(--qb-ease), box-shadow .25s var(--qb-ease);
}
.qb-chip span:not(:empty) {
  display: inline-grid;
  place-items: center;
  min-width: 18px;
  height: 18px;
  margin-left: 4px;
  border-radius: 9px;
  background: var(--qb-brand);
  color: #fff;
  font-size: 11px;
}
.qb-chip:hover { box-shadow: inset 0 0 0 1px #a3a3a3; }
.qb-chip.is-active { background: var(--qb-dark); color: #fafafa; box-shadow: none; }

.qb-addons { display: none; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.qb-addons.is-active { display: grid; animation: qb-in .35s var(--qb-ease) both; }
.qb-addon {
  position: relative;
  display: flex;
  gap: 12px;
  align-items: flex-start;
  justify-content: space-between;
  padding: 16px;
  border-radius: 16px;
  background: #fff;
  box-shadow: inset 0 0 0 1px var(--qb-line);
  cursor: pointer;
  transition: box-shadow .25s var(--qb-ease), background-color .25s var(--qb-ease);
}
.qb-addon:hover { box-shadow: inset 0 0 0 1px #a3a3a3; }
.qb-addon:has(input:checked) { box-shadow: inset 0 0 0 1.5px var(--qb-dark); }
.qb-addon__body { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.qb-addon__name { font: 500 15px/20px "Inter", sans-serif; color: var(--qb-ink); }
.qb-addon__name em {
  font-style: normal;
  font-size: 11px;
  margin-left: 8px;
  padding: 2px 7px;
  border-radius: 6px;
  background: rgba(255, 77, 61, .1);
  color: var(--qb-brand);
  vertical-align: 1px;
}
.qb-addon__desc {
  font-size: 13px;
  line-height: 18px;
  color: var(--qb-muted);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.qb-addon__side { display: flex; flex-direction: column; align-items: flex-end; gap: 8px; flex: none; }
.qb-addon__price { font: 600 15px/20px "Switzer", sans-serif; white-space: nowrap; }
.qb-addon__price small { display: block; text-align: right; font: 400 11px/14px "Inter", sans-serif; color: var(--qb-muted); }
.qb-qty { display: none; align-items: center; gap: 2px; background: var(--qb-bg); border-radius: 8px; padding: 2px; }
.qb-addon:has(input:checked) .qb-qty { display: inline-flex; }
.qb-qty button { width: 24px; height: 24px; border: 0; border-radius: 6px; background: #fff; cursor: pointer; font: 500 14px/1 "Inter", sans-serif; color: var(--qb-ink); }
.qb-qty output { min-width: 22px; text-align: center; font-size: 13px; }
.qb-note { margin: 16px 0 0; font-size: 12px; line-height: 16px; color: var(--qb-muted); }

/* Details */
.qb-fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px 24px; }
.qb-field { display: flex; flex-direction: column; gap: 6px; padding: 12px 0 8px; border-bottom: 1px solid var(--qb-line); transition: border-color .25s var(--qb-ease); }
.qb-field:focus-within { border-color: var(--qb-ink); }
.qb-field--wide { grid-column: 1 / -1; }
.qb-field span { font-size: 12px; line-height: 16px; color: var(--qb-muted); }
.qb-field input, .qb-field textarea {
  border: 0;
  background: transparent;
  outline: 0;
  font: 400 16px/24px "Inter", sans-serif;
  color: var(--qb-ink);
  padding: 0;
  resize: vertical;
}
.qb-field.is-invalid { border-color: var(--qb-brand); }
.qb-hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.qb-error { margin: 16px 0 0; font-size: 13px; color: var(--qb-brand); }

/* Done */
.qb-done { text-align: left; padding: 24px 4px; }
.qb-done h2 { margin: 20px 0 8px; font: 600 40px/44px "Switzer", sans-serif; letter-spacing: -0.02em; }
.qb-done p { margin: 0 0 20px; font-size: 16px; line-height: 24px; color: var(--qb-muted); max-width: 460px; }
.qb-done__mark { display: block; width: 56px; height: 56px; border-radius: 50%; background: var(--qb-brand); position: relative; }
.qb-done__mark::after { content: ""; position: absolute; left: 19px; top: 21px; width: 18px; height: 9px; border: solid #fff; border-width: 0 0 3px 3px; transform: rotate(-45deg); }
.qb-link { color: var(--qb-ink); font-size: 15px; text-decoration: none; border-bottom: 1px solid currentColor; }

/* ------------------------------------------------------------ Navigation */
.qb-nav { margin-top: auto; padding-top: 24px; display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.qb-back { border: 0; background: none; font: 500 14px/20px "Inter", sans-serif; color: var(--qb-muted); cursor: pointer; padding: 12px 0; }
.qb-back:hover { color: var(--qb-ink); }
.qb-btn.qb-nojs-submit { display: none; }

/* The template's button: a dot at the right that fills the button on hover */
.qb-btn {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  gap: 48px;
  min-width: 214px;
  height: 48px;
  padding: 0 17px;
  border: 0;
  border-radius: 10px;
  background: var(--qb-dark);
  color: #f5f5f5;
  font: 500 16px/24px "Inter", sans-serif;
  cursor: pointer;
  transition: gap .3s cubic-bezier(.58,0,.18,1);
}
.qb-btn i {
  position: relative;
  width: 10px;
  height: 10px;
  flex: none;
  transition: transform .3s cubic-bezier(.58,0,.18,1);
}
.qb-btn i::before {
  content: "";
  position: absolute;
  inset: 0;
  border: solid currentColor;
  border-width: 1.5px 1.5px 0 0;
  transform: rotate(45deg);
  transform-origin: 60% 40%;
}
.qb-btn::before {
  content: "";
  position: absolute;
  z-index: -1;
  right: 12px;
  top: 12px;
  width: 24px;
  height: 24px;
  border-radius: 99px;
  background: #262626;
  opacity: 0;
  transition: all .3s cubic-bezier(.58,0,.18,1);
}
.qb-btn:hover { gap: 56px; }
.qb-btn:hover::before { right: 0; top: 0; width: 100%; height: 100%; border-radius: 10px; opacity: 1; }
.qb-btn:hover i { transform: scale(1.5); }
.qb-btn:disabled { opacity: .5; cursor: progress; }
.qb-btn--light { background: #fafafa; color: var(--qb-ink); width: 100%; }
.qb-btn--light::before { background: #e5e5e5; }

/* --------------------------------------------------------------- Summary */
.qb-summary {
  position: sticky;
  top: 120px;
  background: var(--qb-dark);
  color: #fafafa;
  border-radius: 24px;
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}
.qb-lines { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; min-height: 44px; }
.qb-lines li {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-size: 14px;
  line-height: 20px;
  animation: qb-in .3s var(--qb-ease) both;
}
.qb-lines li span:first-child { color: #d4d4d4; }
.qb-lines li.is-package span:first-child { color: #fafafa; font-weight: 500; }
.qb-lines li button { border: 0; background: none; color: #737373; cursor: pointer; margin-left: 6px; padding: 0 2px; font-size: 14px; }
.qb-lines li button:hover { color: var(--qb-brand); }
.qb-lines .qb-empty { color: #737373; }
.qb-total { border-top: 1px solid #262626; padding-top: 18px; display: flex; flex-direction: column; gap: 4px; }
.qb-total__label { font-size: 12px; color: #a3a3a3; }
.qb-total__value { font: 600 48px/52px "Switzer", sans-serif; letter-spacing: -0.03em; font-variant-numeric: tabular-nums; }
.qb-total__monthly { font-size: 14px; color: #ff8a7a; }
.qb-summary__note { margin: 0; font-size: 12px; line-height: 16px; color: #737373; }

.qb-noscript { max-width: 1312px; margin: 24px auto 0; font-size: 13px; color: var(--qb-muted); }

/* Entry motion */
[data-qb-rise] { animation: qb-rise .6s var(--qb-ease) both; }
.qb-lede[data-qb-rise] { animation-delay: .08s; }
.qb-card[data-qb-rise] { animation-delay: .14s; }
@keyframes qb-rise { from { opacity: 0; transform: translateY(24px); } to { opacity: 1; transform: none; } }

/* ------------------------------------------------------------ Tablet */
@media (max-width: 1439.98px) {
  .qb { padding: 32px 40px 96px; }
  .qb-head { grid-template-columns: 200px minmax(0, 1fr); }
  .qb-lede { grid-column: 2; margin-top: 20px; max-width: 420px; }
  .qb-title { font-size: 48px; line-height: 56px; }
  .qb-grid { grid-template-columns: minmax(0, 1fr) 320px; }
}
@media (max-width: 1100px) {
  /* Packages become a swipeable row rather than a tall stack */
  .qb-packages {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    gap: 10px;
    margin: 0 -24px;
    padding: 4px 24px 8px;
    scrollbar-width: none;
  }
  .qb-packages::-webkit-scrollbar { display: none; }
  .qb-package { flex: 0 0 min(300px, 78%); scroll-snap-align: start; }
  .qb-package__more, .qb-package__features { display: none !important; }
}

/* ------------------------------------------------------------ Phone */
@media (max-width: 809.98px) {
  .qb { padding: 24px 20px 140px; }
  .qb-head { grid-template-columns: 1fr; gap: 16px; margin-bottom: 32px; }
  .qb-lede { grid-column: auto; margin: 0; }
  .qb-title { font-size: 36px; line-height: 40px; }
  .qb-indent { width: 24px; }
  .qb-grid { grid-template-columns: minmax(0, 1fr); }
  .qb-card { padding: 16px; min-height: 0; border-radius: 20px; }
  .qb-packages { margin: 0 -16px; padding: 4px 16px 8px; }
  .qb-steps { display: flex; width: 100%; }
  .qb-step { flex: 1; justify-content: center; padding: 8px 6px; font-size: 13px; }
  .qb-step span { display: none; }
  .qb-addons { grid-template-columns: 1fr; }
  .qb-fields { grid-template-columns: 1fr; }
  .qb-nav { display: none; }
  .qb-nojs-submit { width: 100%; }

  /* The summary becomes a bar pinned to the bottom of the screen */
  .qb-summary {
    position: fixed;
    left: 12px;
    right: 12px;
    bottom: 12px;
    top: auto;
    z-index: 800;
    padding: 12px 12px 12px 18px;
    border-radius: 18px;
    flex-direction: row;
    align-items: center;
    gap: 12px;
    box-shadow: 0 12px 32px rgba(0, 0, 0, .25);
  }
  .qb-summary .qb-eyebrow, .qb-summary .qb-lines, .qb-summary__note { display: none; }
  .qb-total { border: 0; padding: 0; flex: 1; gap: 0; }
  .qb-total__value { font-size: 26px; line-height: 30px; }
  .qb-total__monthly { font-size: 12px; }
  .qb-summary .qb-btn { width: auto; min-width: 0; gap: 16px; }
}

@media (prefers-reduced-motion: reduce) {
  .qb *, .qb *::before, .qb *::after { animation: none !important; transition: none !important; }
}
