/* ============================================================
   INTAKE — Typeform-style stepped lead form
   Reuses tokens from styles.css (palette, fonts, buttons)
   ============================================================ */
.intake-body { background: var(--bone); min-height: 100vh; }

.intake-main { max-width: 620px; margin: 0 auto; padding: 28px 22px 90px; min-height: 60vh; }

/* Progress bar — sits below the header (not sticky, so it can't fight it) */
.intake-progress { height: 6px; background: var(--bone-2); border-radius: 100px; overflow: hidden; margin-bottom: 26px; }
#progress-bar { display: block; height: 100%; width: 16%; background: var(--terra); transition: width .35s ease; }

/* Steps: only the active one shows */
.step { border: 0; margin: 0; padding: 0; }
.step:not(.is-active) { display: none; }
.step.is-active { animation: stepin .35s ease; }
@keyframes stepin { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }

.step-kicker { font-family: var(--head); font-size: 13px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--terra); margin: 0 0 10px; }
.step-q { font-family: var(--display); font-weight: 700; font-size: clamp(25px, 4.4vw, 34px); color: var(--espresso); line-height: 1.18; padding: 0; margin: 0 0 10px; outline: none; }
.step-help { font-size: 18px; color: var(--espresso-2); margin: 0 0 24px; }

/* Option cards */
.opt-grid { display: grid; gap: 12px; }
.opt-grid-inline { grid-template-columns: repeat(2, 1fr); }
.opt { position: relative; display: flex; align-items: center; gap: 12px; padding: 18px 20px; background: var(--surface); border: 2px solid var(--sand); border-radius: 12px; font-size: 19px; font-weight: 600; color: var(--espresso); cursor: pointer; transition: border-color .12s ease, background-color .12s ease, transform .06s ease; }
.opt:hover { border-color: var(--olive); }
.opt:active { transform: scale(.99); }
.opt input { position: absolute; opacity: 0; width: 0; height: 0; }
.opt span { line-height: 1.3; }
.opt input:checked ~ span { color: var(--espresso); }
.opt:has(input:checked) { border-color: var(--terra); background: #fff4ee; box-shadow: inset 0 0 0 1px var(--terra); }
.opt:has(input:focus-visible) { outline: 3px solid rgba(37,136,196,.4); outline-offset: 2px; }
.opt-sm { padding: 14px 16px; font-size: 17px; justify-content: center; text-align: center; }

/* Text inputs */
.step-input { width: 100%; min-height: 60px; padding: 16px 18px; font-family: var(--sans); font-size: 20px; color: var(--espresso); background: var(--surface); border: 2px solid var(--espresso-2); border-radius: 12px; margin-bottom: 6px; }
.step-input:focus { outline: 3px solid rgba(37,136,196,.4); border-color: var(--olive); }
.field-label { display: block; font-weight: 700; font-size: 16px; color: var(--espresso); margin: 18px 0 8px; }
.field-label:first-of-type { margin-top: 0; }
.req { color: var(--terra-dark); font-weight: 700; }
.opt-tag { color: var(--muted); font-weight: 400; }

/* File drop */
.filedrop { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 36px 20px; background: var(--surface); border: 2px dashed var(--olive); border-radius: 14px; cursor: pointer; text-align: center; }
.filedrop:hover { background: var(--surface-warm); }
.filedrop-icon { font-size: 34px; }
.filedrop-text { font-weight: 700; font-size: 19px; color: var(--espresso); }
.filedrop-sub { font-size: 15px; color: var(--muted); }
.step-or { text-align: center; font-size: 17px; color: var(--espresso-2); margin: 16px 0 0; }
.step-or a { color: var(--terra-dark); font-weight: 700; white-space: nowrap; }

/* Nav */
.step-nav { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 28px; }
.btn-back { background: transparent; border-color: transparent; box-shadow: none; color: var(--espresso-2); padding-left: 4px; padding-right: 4px; }
.btn-back:hover { background: transparent; color: var(--espresso); transform: none; box-shadow: none; }
.btn-next, .btn-submit { min-width: 170px; }
.form-status { font-size: 16px; font-weight: 700; margin: 14px 0 0; min-height: 1.2em; }
.form-status.error { color: var(--terra-dark); }
.form-status.ok { color: #2e7d46; }

/* Success */
.intake-success { text-align: center; padding: 60px 0 30px; max-width: 520px; margin: 0 auto; animation: stepin .4s ease; }
.success-check { width: 76px; height: 76px; margin: 0 auto 22px; border-radius: 50%; background: var(--olive); color: #fff; font-size: 42px; display: grid; place-items: center; }
.intake-success h1 { font-family: var(--display); font-weight: 700; font-size: clamp(28px, 5vw, 40px); margin: 0 0 12px; }
.intake-success p { font-size: 19px; color: var(--espresso-2); }
.success-call { margin: 18px 0 26px; }
.success-call a { color: var(--terra-dark); font-weight: 700; }

/* Caller note */
.intake-caller-note { max-width: 620px; margin: 40px auto 0; padding: 18px 20px; background: var(--bone-2); border-radius: 12px; font-size: 16px; color: var(--espresso-2); text-align: center; line-height: 1.5; }
.intake-caller-note strong { color: var(--espresso); }

@media (max-width: 480px) {
  .opt-grid-inline { grid-template-columns: repeat(2, 1fr); }
  .btn-next, .btn-submit { min-width: 0; flex: 1; }
}

/* Desktop: present the form as a defined, centered panel (not a bare column) */
@media (min-width: 760px) {
  .intake-main { max-width: 680px; padding-top: 48px; }
  #intake-form, .intake-success {
    background: var(--bone-2);
    border: 1px solid var(--sand);
    border-radius: 22px;
    box-shadow: var(--shadow-md);
    padding: 36px 44px 40px;
  }
  .intake-success { padding-top: 48px; }
  .step-q { font-size: 32px; }
}
