body:has(.quick-quote[open]) {
  overflow: hidden;
}

.quick-quote {
  width: min(520px, calc(100% - 32px));
  max-width: none;
  max-height: min(690px, calc(100dvh - 32px));
  padding: 0;
  overflow: auto;
  border: 0;
  border-radius: 27px;
  background: #fff;
  box-shadow: 0 28px 80px rgba(20, 20, 22, .3);
  color: #424447;
  font-family: var(--font-body, "DM Sans", "Segoe UI", sans-serif);
}

.quick-quote[open] {
  display: block;
  animation: quick-quote-enter .22s ease-out;
}

.quick-quote::backdrop {
  background: rgba(18, 19, 21, .52);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
}

.quick-quote__heading {
  position: sticky;
  z-index: 1;
  top: 0;
  display: flex;
  min-height: 58px;
  align-items: center;
  gap: 12px;
  padding: 12px 18px;
  background: linear-gradient(115deg, #b52d3b, #922331);
  color: #fff;
}

.quick-quote__icon {
  display: grid;
  width: 36px;
  height: 36px;
  flex: 0 0 36px;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, .34);
  border-radius: 50%;
  color: #fff;
  font-size: 23px;
}

.quick-quote__icon svg {
  width: 22px;
  height: 22px;
}

.quick-quote__heading h2 {
  margin: 0;
  color: #fff;
  font-family: var(--font-display, "Manrope", "Segoe UI", sans-serif);
  font-size: 16px;
  font-weight: 800;
  letter-spacing: -.035em;
  line-height: 1.3;
}

.quick-quote__heading p {
  margin: 1px 0 0;
  color: #e1e1e2;
  font-size: 11px;
  line-height: 1.4;
}

.quick-quote__close {
  display: grid;
  width: 34px;
  height: 34px;
  flex: 0 0 34px;
  place-items: center;
  margin-left: auto;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, .14);
  color: #fff;
  cursor: pointer;
  font-size: 25px;
  line-height: 1;
}

.quick-quote__close:hover {
  background: var(--red, #b52d3b);
}

.quick-quote__form {
  padding: 13px 18px 11px;
}

.quick-quote__fields {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px 11px;
}

.quick-quote__field {
  min-width: 0;
  color: #5a5d61;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .035em;
  line-height: 1.35;
  text-transform: uppercase;
}

.quick-quote__field > span,
.quick-quote__field label > span {
  color: var(--red, #b52d3b);
}

.quick-quote__field--full {
  grid-column: 1 / -1;
}

.quick-quote__field input,
.quick-quote__field textarea {
  width: 100%;
  min-width: 0;
  border: 1px solid #dedfe1;
  border-radius: 15px;
  outline: none;
  background: #fff;
  color: #292a2d;
  font: 400 12px/1.45 var(--font-body, "DM Sans", "Segoe UI", sans-serif);
  letter-spacing: 0;
  text-transform: none;
  transition: border-color .18s, box-shadow .18s;
}

.quick-quote__field > input,
.quick-quote__field > textarea {
  display: block;
  margin-top: 6px;
}

.quick-quote__field input {
  height: 36px;
  padding: 0 11px;
}

.quick-quote__field textarea {
  min-height: 62px;
  resize: vertical;
  padding: 9px 11px;
}

.quick-quote__field input::placeholder,
.quick-quote__field textarea::placeholder {
  color: #919397;
  opacity: 1;
}

.quick-quote__field input:focus,
.quick-quote__field textarea:focus {
  border-color: var(--red, #b52d3b);
  box-shadow: 0 0 0 3px rgba(181, 45, 59, .12);
}

.quick-quote__captcha {
  display: grid;
  margin-top: 6px;
  grid-template-columns: auto 34px minmax(0, 1fr);
  align-items: center;
  gap: 7px;
}

.quick-quote__challenge {
  padding: 9px 10px;
  border-radius: 18px;
  background: #f7eeee;
  color: #812631;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .04em;
  white-space: nowrap;
}

.quick-quote__refresh {
  height: 34px;
  border: 1px solid #dedfe1;
  border-radius: 50%;
  background: #fff;
  color: #65676b;
  cursor: pointer;
  font-size: 18px;
}

.quick-quote__refresh:hover {
  border-color: var(--red, #b52d3b);
  color: var(--red, #b52d3b);
}

.quick-quote__captcha input {
  height: 34px;
}

.quick-quote__error {
  min-height: 0;
  color: #a31e2c;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0;
  text-transform: none;
}

.quick-quote__error:not(:empty) {
  margin-top: 5px;
}

.quick-quote__submit {
  display: flex;
  width: 100%;
  min-height: 37px;
  align-items: center;
  justify-content: center;
  gap: 9px;
  margin-top: 8px;
  border: 0;
  border-radius: 24px;
  background: var(--red, #b52d3b);
  color: #fff;
  cursor: pointer;
  font: 700 12px/1 var(--font-body, "DM Sans", "Segoe UI", sans-serif);
  transition: background .18s, transform .18s;
}

.quick-quote__submit:hover {
  transform: translateY(-1px);
  background: var(--red-dark, #922331);
}

.quick-quote__submit:focus-visible,
.quick-quote__close:focus-visible,
.quick-quote__refresh:focus-visible {
  outline: 3px solid rgba(181, 45, 59, .35);
  outline-offset: 2px;
}

@keyframes quick-quote-enter {
  from { opacity: 0; transform: translateY(8px) scale(.99); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

@media (max-width: 480px) {
  .quick-quote {
    max-height: calc(100dvh - 20px);
    border-radius: 21px;
  }

  .quick-quote__heading {
    min-height: 58px;
    padding: 10px 13px;
  }

  .quick-quote__form {
    padding: 12px 13px 10px;
  }

  .quick-quote__fields {
    gap: 10px 8px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .quick-quote[open] { animation: none; }
  .quick-quote__field input,
  .quick-quote__field textarea,
  .quick-quote__submit { transition: none; }
}