.leadbox,
.leadbox *,
.leadbox *::before,
.leadbox *::after {
  box-sizing: border-box;
}

.leadbox {
  position: fixed;
  z-index: 1200;
  right: clamp(18px, 2.5vw, 38px);
  bottom: clamp(18px, 2.5vw, 34px);
  color: var(--pw-ink, #202124);
  font-family: "Manrope", sans-serif;
  line-height: 1.5;
}

.nav-sidebar.open ~ .leadbox {
  visibility: hidden;
  opacity: 0;
  pointer-events: none;
}

.leadbox button,
.leadbox input,
.leadbox select,
.leadbox textarea {
  font: inherit;
}

.leadbox-launcher {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  width: 235px;
  min-height: 62px;
  padding: 9px 18px 9px 10px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, .12);
  border-radius: 999px;
  background: var(--pw-dark, #222326);
  box-shadow: 0 14px 34px rgba(24, 24, 27, .22);
  color: #fff;
  text-align: left;
  cursor: pointer;
  transition: width 420ms cubic-bezier(.22, 1, .36, 1), gap 320ms ease, padding 320ms ease, transform 180ms ease, box-shadow 180ms ease, background-color 180ms ease;
}

.leadbox-launcher:hover {
  background: #303136;
  box-shadow: 0 17px 40px rgba(24, 24, 27, .26);
  transform: translateY(-2px);
}

.leadbox-launcher:focus,
.leadbox-close:focus,
.leadbox-type-switch button:focus,
.leadbox-submit:focus {
  outline: 0;
}

.leadbox-launcher:focus-visible,
.leadbox-close:focus-visible,
.leadbox-type-switch button:focus-visible,
.leadbox-submit:focus-visible {
  box-shadow: 0 0 0 3px #fff, 0 0 0 5px var(--pw-pink-strong, #a34884);
}

.leadbox-launcher-icon {
  display: grid;
  flex: 0 0 44px;
  width: 44px;
  height: 44px;
  place-items: center;
  border-radius: 50%;
  background: var(--pw-pink-strong, #a34884);
}

.leadbox-launcher-icon svg {
  width: 25px;
  height: 25px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.55;
}

.leadbox-launcher-copy {
  display: grid;
  flex: 0 0 145px;
  gap: 1px;
  width: 145px;
  overflow: hidden;
  opacity: 1;
  transform: translateX(0);
  transition: width 320ms ease, flex-basis 320ms ease, opacity 180ms ease, transform 320ms ease;
}

.leadbox-launcher-copy span {
  color: rgba(255, 255, 255, .68);
  font-size: .75rem;
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: .04em;
  white-space: nowrap;
}

.leadbox-launcher-copy strong {
  font-size: .92rem;
  font-weight: 700;
  line-height: 1.3;
  letter-spacing: .01em;
  white-space: nowrap;
}

.leadbox.is-compact .leadbox-launcher {
  gap: 0;
  width: 62px;
  height: 62px;
  min-height: 62px;
  padding: 9px;
  border-color: rgba(163, 72, 132, .36);
  border-radius: 50%;
  background: var(--pw-pink-strong, #a34884);
  box-shadow: 0 12px 30px rgba(163, 72, 132, .34);
}

.leadbox.is-compact .leadbox-launcher-copy {
  flex-basis: 0;
  width: 0;
  opacity: 0;
  transform: translateX(10px);
}

.leadbox.is-compact .leadbox-launcher:hover,
.leadbox.is-compact .leadbox-launcher:focus-visible {
  gap: 12px;
  width: 235px;
  height: 62px;
  padding-right: 18px;
  padding-left: 10px;
  border-color: rgba(255, 255, 255, .12);
  border-radius: 999px;
  background: #303136;
  box-shadow: 0 17px 40px rgba(24, 24, 27, .26);
}

.leadbox.is-compact .leadbox-launcher:hover .leadbox-launcher-copy,
.leadbox.is-compact .leadbox-launcher:focus-visible .leadbox-launcher-copy {
  flex-basis: 145px;
  width: 145px;
  opacity: 1;
  transform: translateX(0);
}

.leadbox-panel {
  position: absolute;
  right: 0;
  bottom: 0;
  width: min(430px, calc(100vw - 32px));
  max-height: min(760px, calc(100vh - 32px));
  max-height: min(760px, calc(100dvh - 32px));
  overflow-x: hidden;
  overflow-y: auto;
  border: 1px solid rgba(32, 33, 36, .09);
  border-radius: 22px;
  background: var(--pw-paper, #fbf9f5);
  box-shadow: 0 24px 70px rgba(24, 24, 27, .25);
  opacity: 0;
  transform: translateY(14px) scale(.985);
  transform-origin: right bottom;
  transition: opacity 200ms ease, transform 260ms cubic-bezier(.22, 1, .36, 1);
}

.leadbox-panel:focus,
.home-page .leadbox-panel:focus-visible,
.subpage-page .leadbox-panel:focus-visible {
  outline: 0;
}

.leadbox-panel::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 4px;
  background: linear-gradient(90deg, var(--pw-pink-strong, #a34884), var(--pw-pink-soft, #e5a2d5));
}

.leadbox.is-open .leadbox-launcher {
  visibility: hidden;
  opacity: 0;
  pointer-events: none;
}

.leadbox.is-open .leadbox-panel {
  opacity: 1;
  transform: translateY(0) scale(1);
}

.leadbox-header {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 6px 18px;
  padding: 22px 28px 13px;
}

.leadbox-eyebrow {
  display: block;
  margin-bottom: 4px;
  color: var(--pw-pink-strong, #a34884);
  font-size: .75rem;
  font-weight: 700;
  line-height: 1.2;
  text-transform: uppercase;
  letter-spacing: .13em;
}

.leadbox-header h2 {
  margin: 0;
  color: var(--pw-ink, #202124);
  font-size: clamp(1.55rem, 4vw, 1.9rem);
  font-weight: 400;
  line-height: 1.15;
  letter-spacing: -.035em;
}

.leadbox-header p {
  grid-column: 1 / -1;
  max-width: 350px;
  margin: 0;
  color: var(--pw-muted, #626368);
  font-size: .87rem;
  line-height: 1.48;
}

.leadbox.is-sent .leadbox-header {
  display: flex;
  justify-content: flex-end;
  padding-bottom: 0;
}

.leadbox.is-sent .leadbox-header > div,
.leadbox.is-sent .leadbox-header > p,
.leadbox.is-sent .leadbox-type-switch {
  display: none;
}

.leadbox-close {
  position: relative;
  display: grid;
  width: 38px;
  height: 38px;
  margin: -5px -7px 0 0;
  padding: 0;
  place-items: center;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: var(--pw-ink, #202124);
  cursor: pointer;
  transition: background-color 180ms ease;
}

.leadbox-close:hover {
  background: #f0eae3;
}

.leadbox-close span,
.leadbox-close span::after {
  display: block;
  width: 20px;
  height: 1.5px;
  border-radius: 2px;
  background: currentColor;
}

.leadbox-close span {
  transform: rotate(45deg);
}

.leadbox-close span::after {
  content: "";
  transform: rotate(90deg);
}

.leadbox-type-switch {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  margin: 0 28px 15px;
  padding: 4px;
  border-radius: 11px;
  background: #eee9e2;
}

.leadbox-type-switch button {
  min-height: 36px;
  padding: 8px 10px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: #66646a;
  font-size: .81rem;
  font-weight: 700;
  line-height: 1.3;
  cursor: pointer;
  transition: background-color 180ms ease, box-shadow 180ms ease, color 180ms ease;
}

.leadbox-type-switch button.is-active {
  background: #fff;
  box-shadow: 0 2px 8px rgba(32, 33, 36, .08);
  color: var(--pw-ink, #202124);
}

.leadbox-form {
  padding: 0 28px 24px;
}

.leadbox-form.is-sent > :not(.leadbox-status) {
  display: none;
}

.leadbox-fields-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.leadbox-field {
  margin-bottom: 9px;
}

.leadbox-field label {
  display: block;
  margin-bottom: 5px;
  color: #38393d;
  font-size: .75rem;
  font-weight: 700;
  line-height: 1.35;
  text-transform: uppercase;
  letter-spacing: .035em;
}

.leadbox-field select {
  padding-right: 34px;
  cursor: pointer;
}

.leadbox-field textarea {
  min-height: 76px;
  resize: vertical;
}

.leadbox-field textarea::placeholder {
  color: #929093;
  opacity: 1;
}

.leadbox-form.was-validated input:invalid,
.leadbox-form.was-validated textarea:invalid,
.leadbox-form.was-validated .leadbox-privacy:has(input:invalid) {
  border-color: #a43a48;
}

.leadbox-privacy {
  display: grid;
  grid-template-columns: 20px 1fr;
  gap: 9px;
  align-items: start;
  margin: 1px 0 11px;
  padding: 4px 0;
  border: 1px solid transparent;
  border-radius: 7px;
}

.leadbox-privacy input {
  width: 17px;
  height: 17px;
  margin: 2px 0 0;
  accent-color: var(--pw-pink-strong, #a34884);
}

    .leadbox-privacy input:focus-visible {
        border-color: #77787c;
        background: #fff;
        box-shadow: 0 0 0 2px rgba(32, 33, 36, .08);
    }

.leadbox-privacy label {
  color: #5f6065;
  font-size: .77rem;
  line-height: 1.45;
}

.leadbox-privacy a,
.leadbox-footer a {
  color: var(--pw-ink, #202124);
  text-decoration-color: var(--pw-pink, #c66fb2);
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

.leadbox-privacy a:hover,
.leadbox-footer a:hover {
  color: var(--pw-pink-strong, #a34884);
}

.leadbox-actions {
  display: flex;
  gap: 14px;
  align-items: center;
  justify-content: space-between;
}

.leadbox-required {
  color: #77767a;
  font-size: .75rem;
}

.leadbox-submit {
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  min-height: 45px;
  min-width: 194px;
  padding: 12px 15px 11px 17px;
  border: 1px solid var(--pw-dark, #222326);
  border-radius: 9px;
  background: var(--pw-dark, #222326);
  color: #fff;
  font-size: .77rem;
  font-weight: 700;
  line-height: 1.3;
  text-transform: uppercase;
  letter-spacing: .015em;
  cursor: pointer;
  transition: background-color 180ms ease, transform 180ms ease;
}

.leadbox-submit:hover {
  background: #34353a;
  transform: translateY(-1px);
}

.leadbox-submit:disabled {
  cursor: wait;
  opacity: .7;
  transform: none;
}

.leadbox-submit-icon {
  margin-left: 14px;
  color: var(--pw-pink-soft, #e5a2d5);
  font-size: 1rem;
  transition: transform 180ms ease;
}

.leadbox-submit:hover .leadbox-submit-icon {
  transform: translateX(3px);
}

.leadbox-status {
  min-height: 0;
  color: #92313d;
  font-size: .82rem;
  line-height: 1.45;
}

.leadbox-status:not(:empty) {
  margin-top: 13px;
}

.leadbox-success {
  padding: 7px 0 18px;
  text-align: left;
}

.leadbox-success-icon {
  display: grid;
  width: 46px;
  height: 46px;
  margin-bottom: 18px;
  place-items: center;
  border-radius: 50%;
  background: rgba(163, 72, 132, .12);
  color: var(--pw-pink-strong, #a34884);
  font-size: 1.35rem;
}

.leadbox-success h3 {
  margin: 0 0 10px;
  color: var(--pw-ink, #202124);
  font-size: 1.55rem;
  font-weight: 400;
  line-height: 1.2;
  letter-spacing: -.025em;
}

.leadbox-success p {
  margin: 0 0 20px;
  color: var(--pw-muted, #626368);
  font-size: .92rem;
  line-height: 1.55;
}

.leadbox-success button {
  padding: 0 0 4px;
  border: 0;
  border-bottom: 1px solid var(--pw-pink, #c66fb2);
  background: transparent;
  color: var(--pw-ink, #202124);
  font-size: .77rem;
  font-weight: 700;
  text-transform: uppercase;
  cursor: pointer;
}

.leadbox-footer {
  display: flex;
  flex-wrap: wrap;
  gap: 3px 13px;
  padding: 11px 28px 13px;
  border-top: 1px solid var(--pw-line, #e6e0d8);
  background: #f4f0ea;
  color: #77767a;
  font-size: .76rem;
  line-height: 1.45;
}

.leadbox-footer span {
  flex-basis: 100%;
}

.leadbox-footer a {
  font-weight: 600;
}

.leadbox-honeypot {
  position: absolute !important;
  left: -10000px !important;
  width: 1px !important;
  height: 1px !important;
  overflow: hidden !important;
}

@media (max-width: 700px) {
  .leadbox {
    right: 14px;
    bottom: max(14px, env(safe-area-inset-bottom));
  }

  .leadbox-panel {
    position: fixed;
    inset: 10px;
    width: auto;
    max-height: calc(100vh - 20px);
    max-height: calc(100dvh - 20px);
    border-radius: 18px;
    transform-origin: center bottom;
  }

  .leadbox-header {
    padding: 22px 20px 13px;
  }

  .leadbox-type-switch {
    margin-right: 20px;
    margin-bottom: 15px;
    margin-left: 20px;
  }

  .leadbox-form {
    padding-right: 20px;
    padding-bottom: 22px;
    padding-left: 20px;
  }

  .leadbox-footer {
    padding-right: 20px;
    padding-left: 20px;
  }
}

@media (max-width: 470px) {
  .leadbox-fields-row {
    grid-template-columns: 1fr;
    gap: 0;
  }

  .leadbox-actions {
    align-items: stretch;
    flex-direction: column;
    gap: 9px;
  }

  .leadbox-submit {
    width: 100%;
  }
}

@media (max-width: 380px) {
  .leadbox .leadbox-launcher-copy {
    display: none;
  }

  .leadbox .leadbox-launcher,
  .leadbox.is-compact .leadbox-launcher:hover,
  .leadbox.is-compact .leadbox-launcher:focus-visible {
    gap: 0;
    width: 58px;
    height: 58px;
    min-height: 58px;
    padding: 7px;
    border-color: transparent;
    border-radius: 50%;
    background: var(--pw-pink-strong, #a34884);
    box-shadow: 0 10px 26px rgba(163, 72, 132, .28);
  }
}

@media (max-height: 560px) and (orientation: landscape) {
  .leadbox-panel {
    inset: 8px;
    max-height: calc(100dvh - 16px);
  }

  .leadbox-header {
    padding-top: 20px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .leadbox *,
  .leadbox *::before,
  .leadbox *::after {
    scroll-behavior: auto !important;
    transition-duration: .01ms !important;
  }
}

@media print {
  .leadbox {
    display: none !important;
  }
}
