/* ============================================================
   CONTACT / LEAD QUALIFIER
   ============================================================ */

/* --- Hero --- */
.contact-hero {
  padding: calc(var(--nav-h) + 80px) 0 120px;
  min-height: 100vh;
}

.contact-header {
  max-width: 640px;
  margin-bottom: 48px;
}

.contact-header h1 {
  font-size: clamp(32px, 4vw, 48px);
  font-weight: 600;
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin-bottom: 16px;
}

/* --- Qualifier form wrapper --- */
.qualifier-form {
  max-width: 640px;
  position: relative;
}

/* --- Progress bar --- */
.form-progress {
  height: 3px;
  background: var(--border);
  border-radius: 2px;
  overflow: hidden;
  margin-bottom: 12px;
}

.form-progress__bar {
  height: 100%;
  width: 20%;
  background: var(--accent);
  border-radius: 2px;
  transition: width 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.form-progress__label {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  text-transform: uppercase;
  margin-bottom: 40px;
}

/* --- Steps container --- */
.form-steps {
  position: relative;
  min-height: 320px;
}

.form-step {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  opacity: 0;
  transform: translateY(16px);
  pointer-events: none;
  transition: opacity 0.3s ease, transform 0.3s ease;
}

.form-step.is-active {
  position: relative;
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

.form-step.is-exiting {
  opacity: 0;
  transform: translateY(-12px);
}

/* --- Question --- */
.form-step__question {
  font-size: clamp(20px, 2.5vw, 26px);
  font-weight: 600;
  line-height: 1.3;
  letter-spacing: -0.01em;
  margin-bottom: 28px;
}

/* --- Option cards --- */
.form-options {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.form-option {
  display: flex;
  align-items: center;
  width: 100%;
  padding: 18px 22px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  cursor: pointer;
  transition: border-color 0.2s ease, background 0.2s ease, transform 0.15s ease;
  text-align: left;
  color: var(--text);
  font-family: var(--sans);
  font-size: 15px;
  font-weight: 400;
  line-height: 1.4;
}

.form-option:hover {
  border-color: var(--text-muted);
  background: var(--bg-card-hover);
}

.form-option.is-selected {
  border-color: var(--accent);
  background: var(--accent-dim);
}

.form-option:active {
  transform: scale(0.99);
}

.form-option__label {
  flex: 1;
}

/* --- Navigation --- */
.form-nav {
  margin-top: 24px;
}

.form-back {
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
}

.form-back.is-visible {
  opacity: 1;
  pointer-events: auto;
}

/* --- Modals (shared by qualified + disqualified) ---
   display: none keeps the iframe out of the layout entirely when closed,
   so it can't intercept touch events on the form behind it. */
.qual-modal {
  position: fixed;
  inset: 0;
  z-index: 1400;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgba(0, 0, 0, 0.55);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.qual-modal.is-visible {
  display: flex;
  opacity: 1;
  pointer-events: auto;
}

.qual-modal__panel {
  width: 100%;
  max-width: 620px;
  max-height: calc(100vh - 48px);
  overflow-y: auto;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 32px;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.45);
  transform: translateY(16px) scale(0.98);
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.qual-modal.is-visible .qual-modal__panel {
  transform: translateY(0) scale(1);
}

.qual-modal__header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 8px;
}

.qual-modal__label {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 10px;
}

.qual-modal__title {
  font-size: 28px;
  font-weight: 600;
  letter-spacing: -0.01em;
  line-height: 1.1;
  margin: 0;
  color: var(--text);
}

.qual-modal__close {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text);
  cursor: pointer;
  flex-shrink: 0;
  font-size: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: border-color 0.2s ease, background 0.2s ease, transform 0.25s ease;
}

.qual-modal__close:hover {
  border-color: var(--accent);
  background: var(--accent-dim);
  transform: rotate(90deg);
}

.qual-modal__sub {
  font-size: 14px;
  line-height: 1.65;
  color: var(--text-muted);
  margin: 0 0 24px;
}

.qual-modal__embed {
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
}

.qual-modal__embed iframe {
  display: block;
  min-height: 600px;
}

/* --- Disqualify email capture --- */
.disqual-capture__row {
  display: flex;
  align-items: stretch;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  transition: border-color 0.2s ease;
}

.disqual-capture__row:focus-within {
  border-color: var(--text);
}

.disqual-capture__input {
  flex: 1;
  background: transparent;
  border: none;
  outline: none;
  padding: 14px 18px;
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.12em;
  color: var(--text);
}

.disqual-capture__input::placeholder {
  color: var(--text-dim);
}

.disqual-capture__btn {
  white-space: nowrap;
  border-radius: 0;
  padding: 14px 20px;
  font-size: 12px;
}

.disqual-success__msg {
  font-size: 15px;
  font-weight: 500;
  color: var(--accent);
  margin: 0;
}

.qual-modal__footer {
  margin-top: 24px;
  font-size: 13px;
  line-height: 1.6;
  color: var(--text-dim);
}

.qual-modal__footer a {
  color: var(--text-muted);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

.qual-modal__footer a:hover {
  color: var(--accent);
}

/* --- Responsive --- */
@media (max-width: 768px) {
  .contact-hero {
    padding: calc(var(--nav-h) + 60px) 0 80px;
  }

  .contact-header {
    margin-bottom: 36px;
  }

  .qualifier-form {
    max-width: 100%;
  }

  .form-progress__label {
    margin-bottom: 28px;
  }

  .form-steps {
    min-height: auto;
  }

  .form-step {
    position: relative;
    display: none;
  }

  .form-step.is-active {
    display: block;
    position: relative;
  }

  .form-step__question {
    margin-bottom: 20px;
    font-size: 20px;
  }

  .form-options {
    gap: 8px;
  }

  .form-option {
    padding: 16px 18px;
    font-size: 14px;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
  }

  .qual-modal {
    padding: 12px;
    align-items: flex-end;
  }

  .qual-modal__panel {
    padding: 24px;
    border-radius: 16px;
    max-height: calc(100vh - 24px);
  }

  .qual-modal__title {
    font-size: 22px;
  }

  .qual-modal__embed iframe {
    min-height: 500px;
  }

  .disqual-capture__row {
    flex-direction: column;
  }

  .disqual-capture__btn {
    border-radius: 0;
    padding: 14px;
  }

  /* Mobile-only page blur when the disqualifier modal is open.
     Mirrors the cookie-consent treatment (consent.css) — light 6px blur on
     everything except the modal itself, with a smooth fade. */
  html.disqual-open body > *:not(.qual-modal):not(.cc-banner):not(.cc-modal):not(.site-drawer) {
    filter: blur(6px);
    will-change: filter;
  }
}
html body > *:not(.qual-modal):not(.cc-banner):not(.cc-modal):not(.site-drawer) {
  transition: filter 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

/* --- Reduced motion --- */
@media (prefers-reduced-motion: reduce) {
  .form-step,
  .form-progress__bar,
  .form-option,
  .form-back {
    transition: none;
  }
  .form-result {
    animation: none;
  }
}
