/* Funnel flow: steps, options, transitions, intake, thank-you */

h1.funnel-headline {
  margin-top: 1.5rem;
  font-family: Georgia, "Times New Roman", serif;
  line-height: 1.05;
  font-weight: 500;
  text-align: center;
  color: #18376e;
  font-size: 3.0rem;
}

p.funnel-headline   {
  margin: 0.6rem auto 0;
  text-align: center;
  max-width: 720px;
  font-family: Georgia, "Times New Roman", serif;
  line-height: 1e.35;
  color: #222;
  font-size: 1.4rem;
  margin-bottom: 25px;;
}
#optionsContainer{
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 12px;
  text-align: center;
}
#optionsContainer.step-age_check{
  flex-direction: column;
  align-items: center;
}
#optionsContainer.step-age_check button{
white-space: nowrap;
}
.progress-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.back-row {
  display: flex;
  justify-content: flex-start;
}

.back-row .btn-back-ghost {
  padding-left: 0;
}

.step-meta {
  font-size: 0.8125rem;
  color: #6c757d;
  font-variant-numeric: tabular-nums;
  min-width: 4ch;
  text-align: left;
  flex-shrink: 0;
}

.question-text {
  font-size: 1.4rem;
  font-weight: 600;
  text-align: center;
  margin-bottom: 1.5rem;
  line-height: 1.35;
  color: #18376e;
}

.option-btn {
  border-radius: 6px;
  max-width: 320px;
 
  padding: 14px 24px;
  font-size: 1.2rem;
  font-weight: 600;
  transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
  min-height: 48px;
  /* background: #fff; */
 
  color: #fff;
  
  background: #0E2247;
 
}
.intake-form{
  max-width: 600px;
  margin: 0 auto;
}
.form-floating>.form-control-plaintext~label::after, .form-floating>.form-control:focus~label::after, .form-floating>.form-control:not(:placeholder-shown)~label::after, .form-floating>.form-select~label::after {
  position: absolute;
  inset: 1rem 0.375rem;
  z-index: -1;
  height: 1.5em;
  content: "";
  background:transparent;
  border-radius: var(--bs-border-radius);
}
button[type="submit"]{
 margin: 0 auto;
  border-radius: 6px;
  max-width: 320px;
 
  padding: 14px 24px;
  font-size: 1.2rem;
  font-weight: 600;
  transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
  min-height: 48px;
  /* background: #fff; */
 
  color: #fff;
  
  background: #0E2247;
}
.option-btn:hover,
.option-btn:focus,
.option-btn.active,
.option-btn.selected {
  background-color: #0d6efd !important;
  border-color: #0d6efd !important;
  color: #fff !important;
}

.options-yes-no {
  display: flex;
  flex-direction: row;
  flex-wrap: nowrap;
  gap: 12px;
}

.options-yes-no .option-btn {
  flex: 1 1 0;
  min-width: 0;
  margin-bottom: 0;
}

.step-pane {
  position: relative;
}

.step-transition-enter {
  opacity: 0;
  transform: translateY(12px);
}

.step-transition-active {
  opacity: 1;
  transform: translateY(0);
  transition: opacity 0.3s ease, transform 0.3s ease;
}

.btn-back-ghost {
  color: #6c757d;
  font-size: 0.875rem;
  padding: 0.35rem 0.75rem;
}

.btn-back-ghost:hover {
  color: #0d6efd;
  background: rgba(13, 110, 253, 0.08);
}

.intake-heading {
  font-size: 1.5rem;
  font-weight: 700;
  text-align: center;
  margin-bottom: 0.5rem;
}

.intake-sub {
  text-align: center;
  color: #6c757d;
  margin-bottom: 1.5rem;
  font-size: 0.95rem;
}

.intake-form .form-floating > .form-control,
.intake-form .form-floating > .form-select {
  height: calc(3.5rem + 2px);
  border-radius: 12px;
  border: 1px solid #6c7179;
  background-color: #fbfcfe;
  font-size: 1rem;
  transition: border-color 0.15s ease, box-shadow 0.15s ease, background-color 0.15s ease;
}

.intake-form .form-floating > .form-control:hover,
.intake-form .form-floating > .form-select:hover {
  border-color: #c6cddb;
}

.intake-form .form-floating > .form-control:focus,
.intake-form .form-floating > .form-select:focus {
  background-color: #fff;
  border-color: #0d6efd;
  box-shadow: 0 0 0 4px rgba(13, 110, 253, 0.15);
  outline: none;
}

.intake-form .form-floating > label {
  color: #6c757d;
  padding: 1rem 0.9rem;
}

.intake-form .form-floating > .form-control::placeholder {
  color: transparent;
}

.intake-form .form-control.is-valid,
.intake-form .was-validated .form-control:valid {
  border-color: #198754;
  background-image: none;
  padding-right: 0.9rem;
}

.intake-form .form-control.is-valid:focus,
.intake-form .was-validated .form-control:valid:focus {
  box-shadow: 0 0 0 4px rgba(25, 135, 84, 0.15);
}

/* Green check icon for #email and #phone when they pass live validation.
   We paint it on the .form-floating WRAPPER instead of the input because
   WebKit's autofill override uses an inset box-shadow to kill the yellow
   autofill background, and that shadow paints over any background-image
   on the input itself — hiding the icon on autofilled fields. Rendering
   via the wrapper's ::after keeps the check visible above the input
   regardless of autofill state. */
.intake-form .form-floating:has(> #email.is-valid),
.intake-form .form-floating:has(> #phone.is-valid) {
  position: relative;
}

.intake-form .form-floating:has(> #email.is-valid) > .form-control,
.intake-form .form-floating:has(> #phone.is-valid) > .form-control {
  padding-right: 2.75rem;
}

.intake-form .form-floating:has(> #email.is-valid)::after,
.intake-form .form-floating:has(> #phone.is-valid)::after {
  content: "";
  position: absolute;
  top: 50%;
  right: 1rem;
  width: 1.25rem;
  height: 1.25rem;
  transform: translateY(-50%);
  background-image: url("data:image/svg+xml;charset=UTF-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23198754'%3E%3Cpath d='M16 8A8 8 0 1 1 0 8a8 8 0 0 1 16 0zm-3.97-3.03a.75.75 0 0 0-1.08.022L7.477 9.417 5.384 7.323a.75.75 0 0 0-1.06 1.06L6.97 11.03a.75.75 0 0 0 1.079-.02l3.992-4.99a.75.75 0 0 0-.011-1.05z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-size: 1.25rem 1.25rem;
  pointer-events: none;
  z-index: 3;
}

/* We only show the check icon — never the "looks good" text. */
.intake-form .valid-feedback {
  display: none !important;
}

/* Autofill detection hook for WebKit (Chrome / Safari / Edge). When the
   browser autofills an input it applies the :-webkit-autofill pseudo-class,
   which triggers this named animation. JS listens for animationstart with
   animationName === "funnelAutofill" and re-runs the validators so the
   green check shows up without requiring user interaction. Keyframes must
   declare at least one property or Chromium won't fire animationstart. */
@keyframes funnelAutofill {
  from { opacity: 1; }
  to   { opacity: 1; }
}

.intake-form input:-webkit-autofill,
.intake-form input:-webkit-autofill:hover,
.intake-form input:-webkit-autofill:focus,
.intake-form input:-webkit-autofill:active {
  animation-name: funnelAutofill;
  animation-duration: 1ms;
  -webkit-animation-name: funnelAutofill;
  -webkit-animation-duration: 1ms;
  transition: background-color 9999s ease-in-out 0s;
  -webkit-text-fill-color: #212529 !important;
  -webkit-box-shadow: 0 0 0 1000px #fbfcfe inset !important;
  box-shadow: 0 0 0 1000px #fbfcfe inset !important;
}

.intake-form .form-control.is-invalid,
.intake-form .was-validated .form-control:invalid {
  border-color: #dc3545;
  background-image: none;
  padding-right: 0.9rem;
}

.intake-form .form-control.is-invalid:focus,
.intake-form .was-validated .form-control:invalid:focus {
  box-shadow: 0 0 0 4px rgba(220, 53, 69, 0.15);
}

.intake-form .btn-primary {
  border-radius: 12px;
  padding: 0.9rem 1.25rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  box-shadow: 0 6px 18px rgba(13, 110, 253, 0.25);
  transition: transform 0.1s ease, box-shadow 0.15s ease, background-color 0.15s ease;
}

.intake-form .btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 8px 22px rgba(13, 110, 253, 0.32);
}

.intake-form .btn-primary:active {
  transform: translateY(0);
  box-shadow: 0 4px 12px rgba(13, 110, 253, 0.25);
}

.intake-form .btn-primary:disabled,
.intake-form .btn-primary.disabled {
  background-color: #8fb4ef;
  border-color: #8fb4ef;
  color: #fff;
  box-shadow: none;
  transform: none;
  cursor: not-allowed;
  opacity: 1;
}

.intake-form .btn-primary:disabled:hover,
.intake-form .btn-primary.disabled:hover {
  transform: none;
  box-shadow: none;
}

.thank-you-wrap {
  text-align: center;
  padding: 1rem 0;
}

.thank-you-wrap .bi-check-circle-fill {
  font-size: 3rem;
  color: #198754;
  margin-bottom: 1rem;
}

@media (max-width: 575.98px) {
  .option-btn {
    font-size: 1rem;
  }
  #optionsContainer.step-age_check{
   
     text-align: center;
  }
}
