@import url("fonts.aa37bf38f1cf.css");

/* Project-specific styles. */

/* Tokens mirror the Framework One design system
   (.docs/Framework One Design System/colors_and_type.css). One brand color
   (#0082BE) on near-white; hovers swap to the deep navy, never a custom blue. */
:root {
  /* --- Brand / primary (from Matt's comps) --- */
  --bf-primary: #0082BE;
  --bf-primary-rgb: 0, 130, 190;
  --bf-primary-hover: #243746;     /* button hover swaps to ink navy */
  --bf-primary-dark: #0F5E7E;      /* deep teal — accent text / emphasis */
  --bf-primary-tint: #E6F4F9;      /* tinted fill (active nav, soft chips) */
  --bf-primary-border: #A9D4E9;    /* tinted hover/focus border on tiles */

  /* --- Ink / surfaces --- */
  --bf-ink: #243746;
  --bf-bg: #F7F8FA;
  --bf-surface: #FFFFFF;
  --bf-blue-soft: #E6F4F9;         /* legacy alias of --bf-primary-tint */
  --bf-section-blue: #EBF5FA;
  --bf-secondary: #9ECCE5;
  --bf-chart-muted: #CBD9E2;       /* muted bar (stalled-draft series + its legend swatch) */

  /* --- Text --- */
  --bf-text-muted: #6B7280;
  --bf-text-light: #9CA3AF;

  /* --- Borders (faint → default → strong) --- */
  --bf-border-faint: #EEF1F4;      /* internal hairlines (card headers, sidebar) */
  --bf-border: #E2E8F0;            /* default surface border */
  --bf-border-strong: #CBD5E1;     /* dividers that need to read */
  --bf-input-bg: #F1F2F2;

  /* --- Status: success / error --- */
  --bf-success: #16A34A;
  --bf-success-soft: #DCFCE7;
  --bf-success-ink: #166534;
  --bf-error: #DC2626;
  --bf-error-light: #FEE2E2;
  --bf-error-dark: #B91C1C;
  --bf-error-border: #FECACA;

  /* --- Status: warning (generic) --- */
  --bf-warning: #CA8A04;
  --bf-warning-soft: #FEFCE8;
  --bf-warning-border: #FEF08A;

  /* --- Capacity semantics: booked (amber) + unpublished (orange) --- */
  --bf-booked-soft: #FEF6E7;
  --bf-booked-border: #F0C36D;
  --bf-booked-ink: #92400E;
  --bf-unpublished-soft: #FFF7ED;
  --bf-unpublished-border: #FED7AA;
  --bf-unpublished-ink: #C2410C;
  --bf-toggle-off: #D4DBE2;

  /* --- Accent: purple — canonical for Pathways/diagnosis badges, the Waiting
     stage, the waitlist Pathways chip, and the needs_followup status badge.
     Repoint here; do not re-inline these hexes per screen. --- */
  --bf-accent-purple: #7E22CE;     /* solid: stage dot / status text */
  --bf-accent-purple-soft: #FAF5FF;
  --bf-accent-purple-border: #E9D5FF;
  --bf-accent-purple-ink: #6D3FA8;

  /* --- Radii --- */
  --bf-radius-sm: 6px;
  --bf-radius: 8px;       /* buttons / inputs */
  --bf-radius-md: 9px;    /* topbar controls (search, bell) */
  --bf-radius-lg: 12px;   /* legacy card radius */
  --bf-radius-card: 14px; /* cards in Matt's comps */
  --bf-radius-xl: 16px;   /* auth inputs + buttons only */
  --bf-radius-2xl: 24px;  /* auth card only */

  /* --- Shell geometry --- */
  --bf-sidebar-width: 248px;
  --bf-topbar-height: 64px;

  /* --- Elevation / motion --- */
  --bf-shadow-sm: 0 1px 2px rgba(16, 24, 40, 0.04);
  --bf-shadow-md: 0 4px 12px rgba(0, 0, 0, 0.08);
  --bf-shadow-tile-hover: 0 2px 8px rgba(16, 24, 40, 0.07);
  --bf-ring: 0 0 0 2px rgba(var(--bf-primary-rgb), 0.44);
  --bf-transition: 160ms cubic-bezier(0.4, 0, 0.2, 1);
}

.alert-debug {
  color: black;
  background-color: white;
  border-color: #d6e9c6;
}

.alert-error {
  color: #b94a48;
  background-color: #f2dede;
  border-color: #eed3d7;
}

body.intake-flow {
  /* Marketing-site parity (aba.behavioralframework.com): the caregiver flow
     uses the public site's exact blue, tint, and ink. Scoped here rather than
     on :root so the staff console keeps the product palette. */
  --bf-primary: #0171B2;
  --bf-primary-rgb: 1, 113, 178;
  --bf-primary-hover: #015AA0;     /* darken on hover, like the public site */
  --bf-primary-dark: #0B4C64;
  --bf-primary-tint: #E3F6FF;
  --bf-blue-soft: #E3F6FF;
  --bf-section-blue: #E3F6FF;
  --bf-ink: #1C2C34;
  --bs-primary: var(--bf-primary);
  --bs-primary-rgb: 1, 113, 178;
  --bs-success: var(--bf-success);
  --bs-success-rgb: 22, 163, 74;
  --bs-danger: var(--bf-error);
  --bs-danger-rgb: 220, 38, 38;
  --bs-body-color: var(--bf-ink);
  --bs-body-bg: var(--bf-bg);
  color: var(--bf-ink);
  background: var(--bf-bg);
  font-family: "DM Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

.intake-wrapper {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  background: var(--bf-bg);
}

/* ---------- Header ---------- */

/* Mirrors the aba.behavioralframework.com header: white bar, horizontal logo,
   the marketing nav, and one blue pill on the right. Ours is "Call Us" rather
   than "Get Started" so the phone stays on every screen (A3). */
.intake-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--bf-surface);
  border-bottom: 1px solid var(--bf-border);
}

.intake-brand {
  display: inline-flex;
  align-items: center;
  flex: 0 0 auto;
}

.intake-brand-logo {
  display: block;
  width: auto;
  height: 44px;
}

.intake-nav {
  display: flex;
  align-items: center;
  gap: 2rem;
  margin: 0 auto;
}

.intake-nav a,
.intake-footer-links a,
.intake-footer-call a {
  color: var(--bf-ink);
  font-size: 0.95rem;
  font-weight: 400;
  text-decoration: none;
  white-space: nowrap;
}

.intake-nav a:hover,
.intake-nav a:focus-visible,
.intake-footer-links a:hover,
.intake-footer-links a:focus-visible,
.intake-footer-call a:hover,
.intake-footer-call a:focus-visible {
  color: var(--bf-primary);
}

/* ---------- Progress / stepper ---------- */

.intake-progress {
  background: var(--bf-surface);
  border-bottom: 1px solid var(--bf-border);
}

.intake-progress-bar {
  position: relative;
  height: 6px;
  overflow: hidden;
  background: var(--bf-border);
  border-radius: 999px;
}

/* DS: no gradients in the main UI — the fill is the one brand color. */
.intake-progress-fill {
  height: 100%;
  width: 0;
  background: var(--bf-primary);
  border-radius: inherit;
  transition: width 200ms cubic-bezier(0.4, 0, 0.2, 1);
}

.intake-progress-meta {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  margin-top: 0.5rem;
  color: var(--bf-text-muted);
  font-size: 0.75rem;
  font-weight: 500;
}

.intake-step-row {
  display: none;
}

.step-item {
  min-width: 28px;
}

.step-dot {
  width: 28px;
  height: 28px;
  flex-shrink: 0;
  border: 1.5px solid var(--bf-border);
  border-radius: 50%;
  background: var(--bf-surface);
  color: var(--bf-text-light);
  font-size: 0.75rem;
  transition: background-color var(--bf-transition), border-color var(--bf-transition), color var(--bf-transition), box-shadow var(--bf-transition);
}

.step-dot.step-done {
  border-color: var(--bf-success);
  background: var(--bf-success);
  color: var(--bf-surface);
}

.step-dot.step-active {
  border-color: var(--bf-primary);
  background: var(--bf-primary);
  color: var(--bf-surface);
  box-shadow: 0 0 0 4px rgba(var(--bf-primary-rgb), 0.16);
}

.step-dot.step-pending {
  background: var(--bf-surface);
  color: var(--bf-text-light);
}

.step-label {
  color: var(--bf-text-light);
  font-size: 0.65rem;
  font-weight: 500;
  white-space: nowrap;
}

.step-label.step-label-done {
  color: var(--bf-success);
}

.step-label.step-label-active {
  color: var(--bf-primary);
  font-weight: 700;
}

.step-connector {
  height: 2px;
  border-top: 2px solid var(--bf-border);
  transition: border-color var(--bf-transition);
}

.step-connector.step-connector-done {
  border-color: var(--bf-success);
}

.intake-current-step {
  margin: 0.45rem 0 0;
  color: var(--bf-ink);
  font-size: 0.875rem;
  font-weight: 600;
  text-align: center;
}

.intake-current-step strong,
.intake-current-step .intake-current-step-label {
  color: var(--bf-primary);
}

/* ---------- Content & typography ---------- */

.intake-content {
  width: 100%;
  max-width: 720px;
}

/* ============================================================
   Caregiver flow — desktop/tablet rehaul (comps, BF logo kept).
   Clean top bar + gray canvas + centered column + thin step bar;
   forms sit directly on the canvas (the step's card is neutralized).
   ============================================================ */

.intake-header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  max-width: 1180px;
  margin: 0 auto;
  height: 80px;
  padding: 0 32px;
}

/* The marketing site's pill CTA, carrying the phone. */
.intake-callus {
  display: inline-flex;
  align-items: center;
  flex: 0 0 auto;
  gap: 0.45rem;
  min-height: 44px;
  padding: 0 1.25rem;
  border-radius: 999px;
  background: var(--bf-primary);
  color: #fff;
  font-size: 0.95rem;
  font-weight: 600;
  white-space: nowrap;
  text-decoration: none;
  transition: background-color var(--bf-transition);
}

.intake-callus:hover,
.intake-callus:focus-visible {
  background: var(--bf-primary-hover);
  color: #fff;
}

.intake-main {
  flex: 1 0 auto;
  padding: 50px 24px 90px;
}

/* ---------- Footer (mirrors the marketing footer) ---------- */

.intake-footer {
  background: var(--bf-primary-tint);
  color: var(--bf-ink);
}

.intake-footer-inner {
  max-width: 1180px;
  margin: 0 auto;
  padding: 48px 32px 28px;
}

.intake-footer-top {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 2rem 3rem;
}

.intake-footer-brand {
  display: inline-flex;
  flex: 0 0 auto;
}

.intake-footer-logo {
  display: block;
  width: auto;
  height: 56px;
}

.intake-footer-nav {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  padding-top: 0.35rem;
}

.intake-footer-links,
.intake-footer-call {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 2.5rem;
}

.intake-footer-rule {
  margin: 2rem 0 1.25rem;
  border: 0;
  border-top: 1px solid rgba(28, 44, 52, 0.15);
  opacity: 1;
}

.intake-footer-copy {
  margin: 0;
  color: var(--bf-text-muted);
  font-size: 0.85rem;
}

.intake-col {
  width: 100%;
  max-width: 640px;
  margin: 0 auto;
}

/* The slot picker goes wide for the week-at-a-glance grid. */
.intake-col--wide {
  max-width: 880px;
}

/* Thin progress bar + "Step X of N", sitting atop the column (comp). */
.intake-stepbar {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  margin-bottom: 1.5rem;
}

.intake-stepbar-track {
  flex: 1;
  height: 5px;
  border-radius: 999px;
  background: var(--bf-border-faint);
  overflow: hidden;
}

.intake-stepbar-label {
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--bf-text-muted);
  white-space: nowrap;
}

/* The step content sits in a white, rounded card on the gray canvas (comp). */
.intake-col > .card.intake-card {
  background: var(--bf-surface);
  border: 1px solid var(--bf-border);
  border-radius: 16px;
  box-shadow: 0 8px 28px rgba(16, 24, 40, 0.08);
}

.intake-col > .card.intake-card > .card-body {
  padding: 1.9rem 2rem;
}

@media (max-width: 575.98px) {
  .intake-col > .card.intake-card > .card-body {
    padding: 1.4rem 1.25rem;
  }
}

/* Comp typography: larger step headings. */
.intake-col h2 {
  font-size: 1.6rem;
  font-weight: 700;
  letter-spacing: -0.01em;
}

/* Comp buttons: slightly rounder. */
.intake-wrapper .btn {
  border-radius: 11px;
}

/* Comp service/choice cards: larger icon tile, rounder, bigger title. */
.intake-col .service-card,
.intake-col .intake-choice {
  border-radius: 14px !important;
  padding: 1.1rem 1.15rem !important;
}

.intake-col .option-icon {
  width: 2.875rem;
  height: 2.875rem;
  border-radius: 12px;
}

.intake-col .service-card > span:last-child .fw-semibold,
.intake-col .service-card .d-block.fw-semibold {
  font-size: 1rem;
}

/* Single-select preference rows: native radios provide mutual exclusivity and
   the whole card reflects the selected option. */
#care-setting-group .intake-choice {
  cursor: pointer;
}

#care-setting-group .intake-choice::after {
  content: none;
}

#care-setting-group .intake-choice:has(input:checked) {
  border-color: var(--bf-primary) !important;
  background: var(--bf-blue-soft) !important;
  box-shadow: 0 0 0 1px rgba(var(--bf-primary-rgb), 0.35), var(--bf-shadow-sm);
}

/* Targeted by type, not by .form-check-input: RadioSelect renders bare inputs
   (the Bootstrap class is only attached to the checkbox widgets), and setting
   the class on the widget would also land on the group's wrapping <div>. */
#care-setting-group input[type="radio"] {
  width: 1.3rem;
  height: 1.3rem;
  flex: 0 0 auto;
  margin: 0;
  accent-color: var(--bf-primary);
}

/* "I'm not sure" qualifying question — styled answer cards, not raw radios. */
.ns-panel {
  border: 1px solid var(--bf-primary-border);
  background: #F7FCFE;
  border-radius: 14px;
  padding: 1rem 1.1rem 1.1rem;
}

.ns-eyebrow {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--bf-primary);
  margin-bottom: 0.5rem;
}

.ns-eyebrow svg {
  flex: 0 0 auto;
}

.ns-question {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--bf-ink);
  margin: 0 0 0.8rem;
}

.ns-options {
  display: grid;
  gap: 0.6rem;
}

.ns-option {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  background: var(--bf-surface);
  border: 1px solid var(--bf-border);
  border-radius: 11px;
  padding: 0.7rem 0.85rem;
  cursor: pointer;
  transition: border-color var(--bf-transition), background-color var(--bf-transition), box-shadow var(--bf-transition);
}

.ns-option:hover {
  border-color: var(--bf-primary);
  box-shadow: var(--bf-shadow-sm);
}

.ns-option:has(input:checked) {
  border-color: var(--bf-primary);
  background: var(--bf-blue-soft);
  box-shadow: 0 0 0 1px rgba(var(--bf-primary-rgb), 0.35), var(--bf-shadow-sm);
}

.ns-option-icon {
  flex: 0 0 auto;
  width: 1.9rem;
  height: 1.9rem;
  border-radius: 8px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--bf-primary-tint);
  color: var(--bf-primary);
}

.ns-option-label {
  flex: 1;
  min-width: 0;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--bf-ink);
}

.ns-option-hint {
  flex: 0 0 auto;
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--bf-text-light);
  white-space: nowrap;
}

/* Disabled CTA ("Answer to continue") reads clearly inactive. */
.intake-wrapper .btn-primary:disabled,
.intake-wrapper .btn-primary[disabled] {
  background: var(--bf-border-strong);
  border-color: var(--bf-border-strong);
  color: var(--bf-surface);
  cursor: not-allowed;
  opacity: 1;
}

/* Modality header above the slot grid (comp). */
.intake-modality-header {
  display: flex;
  align-items: flex-start;
  gap: 0.7rem;
  background: var(--bf-primary-tint);
  border: 1px solid var(--bf-primary-border);
  border-radius: 13px;
  padding: 0.85rem 1rem;
  margin-bottom: 1.25rem;
}

.intake-modality-header svg {
  flex: 0 0 auto;
  color: var(--bf-primary);
  margin-top: 1px;
}

.intake-modality-title {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--bf-primary-dark);
}

.intake-modality-sub {
  font-size: 0.8rem;
  color: var(--bf-primary-dark);
  opacity: 0.85;
  margin-top: 1px;
}

/* Desktop week-at-a-glance: the day strip becomes a multi-column grid that
   fills the wide column instead of a horizontal scroller. */
@media (min-width: 768px) {
  .intake-col--wide .slot-strip-track {
    display: grid !important;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 12px !important;
    overflow: visible !important;
  }
  .intake-col--wide .slot-day {
    min-width: 0;
  }
}

/* 15-minute hold reassurance above the slot-picker actions. */
.intake-hold-note {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.82rem;
  color: var(--bf-text-muted);
  margin: 1rem 0 0.85rem;
}

.intake-hold-note svg {
  flex: 0 0 auto;
  color: var(--bf-warning);
}

/* KEL-1687: a location with no availability stays on the list so the family
   can still find it, but must not read as clickable — the card is a plain
   panel, not a link, and its Join waitlist button carries the only action. */
.clinic-card--unavailable {
  cursor: default;
  background: var(--bf-surface-muted, #F8FAFC);
}

.clinic-card--unavailable .fw-semibold {
  color: var(--bf-text-muted);
}

/* Confirmation card: service + duration chip header (single-appt). */
.intake-visit-card-hdr--split {
  justify-content: space-between;
}

.intake-duration-chip {
  flex: 0 0 auto;
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--bf-primary-dark);
  background: var(--bf-primary-tint);
  border: 1px solid var(--bf-primary-border);
  border-radius: var(--bf-radius-sm);
  padding: 0.1rem 0.5rem;
}

/* Confirmation code line (two-appt confirmation). */
.intake-conf-code {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  margin-top: 0.9rem;
  font-size: 0.82rem;
  color: var(--bf-text-muted);
}

.intake-conf-code svg {
  flex: 0 0 auto;
  color: var(--bf-primary);
}

.intake-conf-code strong {
  color: var(--bf-ink);
}

/* No-availability: present the call-us + waitlist offer on the canvas cleanly. */
.intake-col .no-availability {
  background: var(--bf-surface);
  border: 1px solid var(--bf-border);
  border-radius: var(--bf-radius-card);
  padding: 1.4rem;
  margin: 0;
}

/* Below the wide desktop breakpoint the pill shortens to "Call Us" so the
   five nav links keep their spacing. */
@media (max-width: 1199.98px) {
  .intake-callus-num {
    display: none;
  }
}

/* Like the marketing site, the nav links drop out below desktop widths and
   only the logo and the pill remain. */
@media (max-width: 991.98px) {
  .intake-nav {
    display: none;
  }
}

@media (max-width: 575.98px) {
  .intake-header-inner {
    padding: 0 16px;
    height: 60px;
  }
  .intake-brand-logo {
    height: 34px;
  }
  .intake-callus {
    min-height: 40px;
    padding: 0 1rem;
    font-size: 0.9rem;
  }
  .intake-main {
    padding: 34px 16px 74px;
  }
  .intake-col h2 {
    font-size: 1.4rem;
  }
  .intake-callus-num {
    display: none;
  }
  .intake-footer-inner {
    padding: 36px 16px 24px;
  }
  .intake-footer-top {
    flex-direction: column;
    gap: 1.5rem;
  }
  .intake-footer-logo {
    height: 48px;
  }
  .intake-footer-links {
    flex-direction: column;
    gap: 0.75rem;
  }
}

.intake-wrapper h1,
.intake-wrapper h2,
.intake-wrapper h3,
.intake-wrapper h4,
.intake-wrapper h5,
.intake-wrapper h6 {
  color: var(--bf-ink);
  letter-spacing: -0.01em;
}

/* Page and step titles are set in Roboto Slab (the self-hosted stand-in for
   the marketing site's Museo Slab headings); everything else stays DM Sans.
   Bootstrap's fw-* utilities are !important, so titles carry
   .intake-step-title instead of fw-semibold / fw-bold. Weight comes from the
   heading rules: step h2 titles keep the 700 of the `.intake-col h2` comp rule
   above; page h1 titles sit lighter, like the marketing h1. */
.intake-wrapper h1,
.intake-step-title {
  font-family: "Roboto Slab", Georgia, serif;
  letter-spacing: 0;
}

.intake-wrapper h1 {
  font-weight: 400;
}

/* Lead sentence under a step heading: calm, readable measure. */
.intake-card .card-body > .text-muted:first-of-type,
.intake-card .card-body > h2 + .text-muted {
  max-width: 58ch;
  line-height: 1.55;
}

.intake-wrapper .text-muted {
  color: var(--bf-text-muted) !important;
}

/* ---------- Cards ---------- */

.intake-card,
.intake-wrapper > .container .card {
  min-width: 0;
  border: 1px solid var(--bf-border) !important;
  border-radius: var(--bf-radius-lg);
  background: var(--bf-surface);
  box-shadow: var(--bf-shadow-sm);
}

.intake-wrapper .card-body {
  min-width: 0;
  padding: 1.5rem;
}

/* ---------- Forms ---------- */

.intake-wrapper .form-label {
  color: var(--bf-ink);
  font-size: 0.875rem;
  font-weight: 600;
  margin-bottom: 0.4rem;
}

.intake-wrapper .form-control,
.intake-wrapper .form-select {
  min-height: 44px;
  border-color: var(--bf-border);
  border-radius: var(--bf-radius);
  background-color: var(--bf-input-bg);
  color: var(--bf-ink);
  transition: border-color var(--bf-transition), box-shadow var(--bf-transition), background-color var(--bf-transition);
}

.intake-wrapper .form-control::placeholder {
  color: var(--bf-text-light);
}

.intake-wrapper textarea.form-control {
  min-height: 96px;
}

.intake-wrapper .form-control:focus,
.intake-wrapper .form-select:focus {
  border-color: var(--bf-primary);
  background-color: var(--bf-surface);
  box-shadow: var(--bf-ring);
}

.intake-wrapper .form-check-input {
  border-color: var(--bf-border);
}

.intake-wrapper .form-check-input:checked {
  border-color: var(--bf-primary);
  background-color: var(--bf-primary);
}

.intake-wrapper .form-check-input:focus {
  border-color: var(--bf-primary);
  box-shadow: var(--bf-ring);
}

.intake-wrapper .form-text {
  color: var(--bf-text-muted);
}

.intake-wrapper .is-invalid,
.intake-wrapper .form-control.is-invalid,
.intake-wrapper .form-select.is-invalid {
  border-color: var(--bf-error);
}

.intake-wrapper .invalid-feedback,
.intake-wrapper .text-danger {
  color: var(--bf-error) !important;
}

.intake-date-input {
  max-width: 220px;
}

/* ---------- Actions / buttons ---------- */

.intake-actions {
  display: flex;
  flex-direction: column-reverse;
  gap: 0.5rem;
  margin-top: 1.75rem;
}

/* Buttons mirror the marketing site's CTAs: pill-shaped, brand fill, darken
   on hover; no movement, no colored shadows. */
.intake-wrapper .btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  min-height: 48px;
  padding: 0.5rem 1.4rem;
  line-height: 1.2;
  border-radius: 999px;
  font-weight: 600;
  letter-spacing: 0.01em;
  transition: background-color var(--bf-transition), border-color var(--bf-transition), box-shadow var(--bf-transition), color var(--bf-transition);
}

/* Compact controls (week paging in the slot picker) stay small pills. */
.intake-wrapper .btn-sm {
  min-height: 36px;
  padding: 0.25rem 0.9rem;
  font-size: 0.85rem;
}

.intake-wrapper .btn-link {
  min-height: 0;
  padding: 0;
  border-radius: 0;
}

.intake-wrapper .btn-primary {
  border-color: var(--bf-primary);
  background: var(--bf-primary);
  color: var(--bf-surface);
}

.intake-wrapper .btn-primary:hover,
.intake-wrapper .btn-primary:focus {
  border-color: var(--bf-primary-hover);
  background: var(--bf-primary-hover);
  color: var(--bf-surface);
}

.intake-wrapper .btn-outline-secondary {
  border-color: var(--bf-border);
  background: var(--bf-surface);
  color: var(--bf-ink);
}

.intake-wrapper .btn-outline-secondary:hover,
.intake-wrapper .btn-outline-secondary:focus {
  border-color: var(--bf-primary);
  background: var(--bf-blue-soft);
  color: var(--bf-primary);
}

.intake-wrapper .btn-success {
  border-color: var(--bf-success);
  background: var(--bf-success);
}

.intake-wrapper .btn:focus-visible {
  outline: none;
  box-shadow: var(--bf-ring);
}

/* ---------- Choice cards & slots ---------- */

/* KEL-1609: spelled-out "Eastern Standard Time (EST)" under the slot-strip
   day header — its own small wrapping line so the 118px day columns (and the
   375px viewport) stay clean; CT/MT badges stay inline and untouched. */
.slot-day-tz {
  display: block;
  font-size: 0.68rem;
  font-weight: 400;
  line-height: 1.25;
  white-space: normal;
  overflow-wrap: break-word;
}

.intake-choice,
.service-card,
.slot-card {
  position: relative;
  width: 100%;
  min-width: 0;
  border: 1px solid var(--bf-border) !important;
  border-radius: var(--bf-radius) !important;
  background: var(--bf-surface) !important;
  color: var(--bf-ink);
  cursor: pointer;
  transition: border-color var(--bf-transition), background-color var(--bf-transition), box-shadow var(--bf-transition);
}

/* DS hover: subtle — border/tint change only, nothing moves. */
.intake-choice:hover,
.service-card:hover,
.slot-card:hover {
  border-color: var(--bf-primary) !important;
  box-shadow: var(--bf-shadow-sm);
}

.intake-choice.is-selected,
.service-card.border-primary,
.slot-card.border-primary,
.slot-card.slot-selected {
  border-color: var(--bf-primary) !important;
  background: var(--bf-blue-soft) !important;
  box-shadow: 0 0 0 1px rgba(var(--bf-primary-rgb), 0.35), var(--bf-shadow-sm);
}

/* Trailing selection indicator on full-width choice rows. */
.service-card::after,
.intake-choice::after {
  content: "";
  flex: 0 0 auto;
  align-self: center;
  margin-left: auto;
  width: 1.4rem;
  height: 1.4rem;
  border: 2px solid var(--bf-border);
  border-radius: 50%;
  background-color: var(--bf-surface);
  background-position: center;
  background-repeat: no-repeat;
  background-size: 0.8rem;
  transition: border-color var(--bf-transition), background-color var(--bf-transition);
}

.service-card.border-primary::after,
.intake-choice.is-selected::after {
  border-color: var(--bf-primary);
  background-color: var(--bf-primary);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23fff'%3E%3Cpath d='M13.854 3.646a.5.5 0 0 1 0 .708l-7 7a.5.5 0 0 1-.708 0l-3.5-3.5a.5.5 0 1 1 .708-.708L6.5 10.293l6.646-6.647a.5.5 0 0 1 .708 0z'/%3E%3C/svg%3E");
}

/* Slot tiles: compact, centered; corner check when selected. */
.slot-card {
  min-height: 56px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.slot-card.slot-selected::after {
  content: "";
  position: absolute;
  top: 0.3rem;
  right: 0.3rem;
  width: 1rem;
  height: 1rem;
  border-radius: 50%;
  background-color: var(--bf-primary);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23fff'%3E%3Cpath d='M13.854 3.646a.5.5 0 0 1 0 .708l-7 7a.5.5 0 0 1-.708 0l-3.5-3.5a.5.5 0 1 1 .708-.708L6.5 10.293l6.646-6.647a.5.5 0 0 1 .708 0z'/%3E%3C/svg%3E");
  background-position: center;
  background-repeat: no-repeat;
  background-size: 0.7rem;
}

.intake-wrapper .bg-primary-subtle {
  background-color: var(--bf-blue-soft) !important;
}

.intake-wrapper .border-primary {
  border-color: var(--bf-primary) !important;
}

.option-icon {
  width: 2.75rem;
  height: 2.75rem;
  flex: 0 0 auto;
  border-radius: var(--bf-radius);
  background: var(--bf-blue-soft);
  color: var(--bf-primary);
  transition: background-color var(--bf-transition), color var(--bf-transition);
}

.service-card.border-primary .option-icon,
.intake-choice.is-selected .option-icon {
  background: var(--bf-primary);
  color: var(--bf-surface);
}

.intake-choice > span:last-child,
.service-card > span:last-child,
.slot-card > span:last-child {
  min-width: 0;
}

.intake-choice .text-muted,
.service-card .text-muted,
.slot-card .text-muted,
.intake-card p {
  overflow-wrap: anywhere;
}

/* Soft on-brand panel (e.g. the "Not Sure" follow-up question). */
.intake-soft-panel {
  border: 1px solid rgba(var(--bf-primary-rgb), 0.18);
  border-radius: var(--bf-radius);
  background: var(--bf-blue-soft);
}

/* ---------- Task surfaces (uploads, consents, signature) ---------- */

.intake-task-surface {
  border: 1px dashed var(--bf-border);
  border-radius: var(--bf-radius);
  background: var(--bf-surface);
  transition: border-color var(--bf-transition), background-color var(--bf-transition);
}

.intake-task-surface:hover {
  border-color: var(--bf-secondary);
}

.intake-doc-icon {
  color: var(--bf-text-muted);
}

.intake-signature-pad {
  position: relative;
  touch-action: none;
  background: var(--bf-surface);
}

.intake-signature-pad::before {
  content: "";
  position: absolute;
  left: 1.25rem;
  right: 1.25rem;
  bottom: 2.4rem;
  border-bottom: 1px dashed var(--bf-border);
  pointer-events: none;
}

.intake-signature-pad::after {
  content: "Sign here";
  position: absolute;
  left: 1.25rem;
  bottom: 1.5rem;
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--bf-text-light);
  pointer-events: none;
}

.intake-signature-pad canvas {
  position: relative;
  z-index: 1;
  display: block;
  width: 100%;
  height: 160px;
  cursor: crosshair;
}

/* ---------- Forced-read consent docs (S9, KEL-1044) ---------- */

.intake-consent-doc {
  max-height: 11rem;
  overflow-y: auto;
  padding: 0.75rem 0.9rem;
  border: 1px solid var(--bf-border);
  border-radius: var(--bf-radius);
  background: var(--bf-surface);
  /* hint that there is more to read */
  box-shadow: inset 0 -12px 12px -12px rgba(0, 0, 0, 0.18);
}

.intake-consent-doc:focus-visible {
  outline: 2px solid var(--bf-secondary);
  outline-offset: 2px;
}

/* Once read to the bottom, drop the "more below" shadow and mark it done. */
[data-consent-gate].consent-read .intake-consent-doc {
  box-shadow: none;
  border-color: var(--bf-success);
}

/* ---------- E-signature ceremony (signature envelopes) ---------- */

.esign-progress {
  list-style: none;
  padding: 0;
  margin: 0 0 0.5rem;
  display: grid;
  gap: 0.35rem;
}

.esign-progress-item {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 0.85rem;
}

.esign-progress-item a {
  color: var(--bf-ink);
  text-decoration: none;
}

.esign-progress-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.5rem;
  height: 1.5rem;
  border-radius: 50%;
  border: 1px solid var(--bf-border-strong);
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--bf-text-muted);
  background: var(--bf-surface);
}

.esign-progress-item.is-reviewed .esign-progress-num {
  border-color: var(--bf-success);
  background: var(--bf-success-soft);
  color: var(--bf-success-ink);
}

.esign-progress-state {
  margin-left: auto;
  font-size: 0.75rem;
  color: var(--bf-text-muted);
}

.esign-progress-item.is-reviewed .esign-progress-state {
  color: var(--bf-success-ink);
  font-weight: 600;
}

/* Contrast: the ceremony's own text stays at 4.5:1 on every surface it sits
   on — success ink on the acknowledged tint, deep teal for badges and links,
   ink for the end-of-document sentinel on the page tray. */
.esign-doc .badge.text-bg-primary {
  background-color: var(--bf-primary-dark) !important;
}

.esign-doc.is-acknowledged .text-muted,
.esign-doc.is-acknowledged .esign-doc-title .small {
  color: var(--bf-success-ink) !important;
}

.esign-doc [data-consent-end],
.esign-doc-note {
  color: var(--bf-ink);
}

.esign-doc-head {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.esign-doc-title {
  display: flex;
  flex-direction: column;
}

.esign-doc.is-acknowledged {
  border-style: solid;
  border-color: var(--bf-success);
  background: var(--bf-success-soft);
}

/* Page images stack inside the same scroll-gated region the placeholder
   consents use; intrinsic width/height keep the sentinel below the pages
   before the lazy images load. */
.esign-doc-pages {
  max-height: 60vh;
  min-height: 18rem;
  padding: 0.5rem;
  background: var(--bf-bg);
  overscroll-behavior: contain;
  touch-action: pan-y pinch-zoom;
  -webkit-overflow-scrolling: touch;
}

@media (max-width: 575.98px) {
  .esign-doc-pages {
    max-height: 55vh;
    min-height: 16rem;
  }
}

.esign-page {
  position: relative;
  margin: 0 0 0.5rem;
  background: #fff;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.08);
}

.esign-page img {
  display: block;
  width: 100%;
  height: auto;
}

.esign-signature-page {
  background: #fff;
  border: 1px solid var(--bf-border);
  border-radius: var(--bf-radius);
  padding: 1rem 1.25rem;
  margin: 0 0 0.75rem;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.08);
}

.esign-signature-page-title {
  font-weight: 700;
}

.esign-signature-page-box {
  min-height: 5.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px dashed var(--bf-primary);
  border-radius: 4px;
  background: rgba(var(--bf-primary-rgb), 0.06);
  padding: 0.5rem 1rem;
  margin-bottom: 0.75rem;
  transition: border-color var(--bf-transition), background-color var(--bf-transition);
}

.esign-signature-page-box.is-adopted {
  border-style: solid;
  border-color: var(--bf-success);
  background: var(--bf-success-soft);
}

.esign-signature-page-box img {
  max-width: 100%;
  max-height: 4.5rem;
  object-fit: contain;
}

.esign-signature-page-placeholder {
  font-size: 0.8rem;
  color: var(--bf-text-muted);
  text-align: center;
}

.esign-typed-preview-inline,
.esign-typed-preview {
  font-family: "Caveat", "Segoe Script", "Bradley Hand", cursive;
  color: var(--bf-ink);
  line-height: 1;
}

.esign-typed-preview-inline {
  font-size: 2.2rem;
}

.esign-typed-preview {
  font-size: 2.25rem;
  min-height: 4.5rem;
  padding: 0.75rem 1.25rem;
  display: flex;
  align-items: center;
}

.esign-signature-page-meta {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.15rem 0.75rem;
  font-size: 0.8rem;
  margin: 0;
}

.esign-signature-page-meta dt {
  color: var(--bf-text-muted);
  font-weight: 500;
}

.esign-signature-page-meta dd {
  margin: 0;
}

.esign-mono {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.72rem;
  color: var(--bf-text-muted);
  word-break: break-all;
}

.esign-adopted-badge {
  color: var(--bf-success-ink);
  font-weight: 600;
  font-size: 0.85rem;
}

.esign-signed-chip {
  font-size: 0.72rem;
  font-weight: 600;
  padding: 0.1rem 0.55rem;
  border-radius: 999px;
  background: var(--bf-primary-tint);
  color: var(--bf-primary-dark);
  white-space: nowrap;
}

.esign-signed-chip.is-signed {
  background: var(--bf-success-soft);
  color: var(--bf-success-ink);
}

/* The Sign button needs 4.5:1 for its 16px label; Bootstrap's success green
   (#16A34A) only reaches 3.3:1 on white text, so the ceremony uses a darker
   green with the success ink on hover. The app themes .btn-success and
   .btn-outline-primary directly, hence the explicit overrides. */
.intake-wrapper .esign-sign-btn,
.intake-wrapper .esign-sign-btn:disabled {
  background-color: #15803d !important;
  border-color: #15803d !important;
  color: #fff !important;
}

.intake-wrapper .esign-sign-btn:hover,
.intake-wrapper .esign-sign-btn:focus-visible {
  background-color: var(--bf-success-ink) !important;
  border-color: var(--bf-success-ink) !important;
}

.intake-wrapper .esign-pdf-link {
  color: var(--bf-primary-dark) !important;
  border-color: var(--bf-primary-dark) !important;
}

.intake-wrapper .esign-pdf-link:hover,
.intake-wrapper .esign-pdf-link:focus-visible {
  background-color: var(--bf-primary-dark) !important;
  color: #fff !important;
}

.esign-intent-note {
  color: var(--bf-primary-dark);
}

.esign-intent {
  border-left: 3px solid var(--bf-primary);
  padding: 0.5rem 0.9rem;
  margin-bottom: 1rem;
  background: var(--bf-primary-tint);
  border-radius: 0 var(--bf-radius) var(--bf-radius) 0;
}

/* ---------- Confirmation moment ---------- */

.intake-success-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 84px;
  height: 84px;
  border-radius: 50%;
  background: var(--bf-success-soft);
  color: var(--bf-success); /* icons inherit via currentColor (DS) */
}

.intake-summary {
  border-color: rgba(22, 163, 74, 0.22) !important;
  background: var(--bf-success-soft) !important;
}

.intake-complete-summary {
  max-width: 480px;
}

.intake-summary-list dt {
  color: var(--bf-text-muted);
  font-weight: 500;
}

.intake-summary-list dd {
  color: var(--bf-ink);
}

.intake-summary-list dt,
.intake-summary-list dd {
  padding-top: 0.4rem;
  padding-bottom: 0.4rem;
}

.intake-summary-list > dt:nth-of-type(n + 2),
.intake-summary-list > dd:nth-of-type(n + 2) {
  border-top: 1px solid var(--bf-border);
}

.intake-next-note {
  color: var(--bf-text-muted);
  font-size: 0.85rem;
}

.intake-complete-actions {
  flex-direction: column;
}

/* ---------- Alerts ---------- */

.intake-wrapper .alert-info {
  border-color: rgba(var(--bf-primary-rgb), 0.22);
  background: var(--bf-blue-soft);
  color: var(--bf-ink);
}

.intake-wrapper .alert-warning {
  border-color: var(--bf-warning-border);
  background: var(--bf-warning-soft);
  color: var(--bf-ink);
}

.intake-wrapper .alert-danger {
  border-color: rgba(220, 38, 38, 0.22);
  background: var(--bf-error-light);
  color: var(--bf-error-dark);
}

/* ---------- Two-appointment (Pathways DMV) flow ---------- */

/* "Visit 1 of 2" pill + subtitle on the schedule steps. */
.intake-visit-badge-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.intake-visit-badge {
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--bf-primary);
  background: var(--bf-primary-tint);
  border: 1px solid var(--bf-primary-border);
  border-radius: var(--bf-radius-sm);
  padding: 0.18rem 0.5rem;
}

.intake-visit-badge-sub {
  font-size: 0.78rem;
  color: var(--bf-text-light);
}

/* Inline explainer notes (route hint, testing-visit spacing rule). */
.intake-note {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  border-radius: var(--bf-radius);
  border: 1px solid var(--bf-border);
  background: var(--bf-bg);
  padding: 0.7rem 0.85rem;
  font-size: 0.82rem;
  line-height: 1.45;
}

.intake-note svg {
  flex: 0 0 auto;
  margin-top: 1px;
}

.intake-note--info {
  color: var(--bf-text-muted);
}

.intake-note--info svg {
  color: var(--bf-primary);
}

.intake-note--warn {
  background: var(--bf-warning-soft);
  border-color: var(--bf-warning-border);
  color: var(--bf-booked-ink);
}

.intake-note--warn svg {
  color: var(--bf-warning);
}

.intake-note-aside {
  color: var(--bf-text-light);
}

/* Visit 2 picker: day-grouped time tiles (2-up on mobile, fills width up). */
.appt2-daygroup + .appt2-daygroup {
  margin-top: 1.1rem;
}

.appt2-day-hdr {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--bf-ink);
  margin-bottom: 0.5rem;
}

/* KEL-1609: spelled-out "Eastern Standard Time (EST)" in the visit-2 day
   header — lighter weight and free to wrap so it stays clean at 375px. */
.appt2-day-tz {
  font-weight: 400;
  color: var(--bf-text-light);
  white-space: normal;
}

.appt2-times {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.55rem;
}

@media (min-width: 560px) {
  .appt2-times {
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  }
}

/* "Visit 1 held: …" reassurance above the book button. */
.intake-held-note {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.8rem;
  color: var(--bf-text-muted);
  margin: 0.85rem 0 0.25rem;
}

.intake-held-note svg {
  flex: 0 0 auto;
  color: var(--bf-primary);
}

/* Big tinted feature icon (no-inventory reassurance). */
.intake-feature-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  border-radius: var(--bf-radius-card);
  background: var(--bf-primary-tint);
  color: var(--bf-primary);
}

/* Two-row "what happens next" mini-steps (no-inventory state). */
.intake-mini-steps {
  border: 1px solid var(--bf-border);
  border-radius: var(--bf-radius-card);
  overflow: hidden;
}

.intake-mini-step {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  padding: 0.85rem 0.9rem;
}

.intake-mini-step + .intake-mini-step {
  border-top: 1px solid var(--bf-border-faint);
}

.intake-mini-step-icon {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2rem;
  height: 2rem;
  border-radius: var(--bf-radius);
  background: var(--bf-border-faint);
  color: var(--bf-text-light);
}

.intake-mini-step-icon.is-done {
  background: var(--bf-primary-tint);
  color: var(--bf-primary);
}

/* Confirmation: numbered visit cards (1 col mobile, 2 col on wider screens). */
.intake-complete-summary--wide {
  max-width: 680px;
}

.intake-visit-cards {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.9rem;
}

@media (min-width: 620px) {
  .intake-visit-cards {
    grid-template-columns: 1fr 1fr;
  }
}

.intake-visit-card {
  border: 1px solid var(--bf-border);
  border-radius: var(--bf-radius-card);
  overflow: hidden;
}

/* Single-appointment confirmation: one card, centred on its own. Deliberately
   NOT wrapped in .intake-visit-cards — that grid's 2-column rule keys off the
   viewport, so a lone card would be laid into the left track at half width. */
.intake-visit-card--solo {
  max-width: 460px;
}

.intake-visit-card-hdr {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.7rem 0.9rem;
  background: var(--bf-blue-soft);
  border-bottom: 1px solid var(--bf-primary-border);
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--bf-primary-dark);
}

.intake-visit-card-num {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.25rem;
  height: 1.25rem;
  padding: 0 0.3rem;
  border-radius: var(--bf-radius-sm);
  background: var(--bf-primary);
  color: var(--bf-surface);
  font-size: 0.72rem;
}

.intake-visit-card-body {
  padding: 0.9rem;
}

.intake-visit-row {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
}

.intake-visit-row + .intake-visit-row {
  margin-top: 0.7rem;
}

.intake-visit-row svg {
  flex: 0 0 auto;
  margin-top: 2px;
  color: var(--bf-primary);
}

/* ---------- Motion: near-silent (DS) ----------
   Mirrors wct-modal-in: 200ms, scale 0.96 + 8px rise. No bounces/springs. */

@keyframes intake-rise {
  from { opacity: 0; transform: scale(0.96) translateY(8px); }
  to { opacity: 1; transform: scale(1) translateY(0); }
}

.intake-content > .card,
.intake-content > .text-center {
  animation: intake-rise 200ms cubic-bezier(0.4, 0, 0.2, 1) both;
}

@media (prefers-reduced-motion: reduce) {
  .intake-progress-fill,
  .intake-content > .card,
  .intake-content > .text-center,
  .intake-success-badge,
  .intake-choice,
  .service-card,
  .slot-card,
  .esign-doc,
  .esign-signature-page-box,
  .intake-wrapper .btn {
    animation: none !important;
    transition: none !important;
  }
}

/* ---------- Responsive ---------- */

@media (min-width: 576px) {
  .intake-step-row {
    display: flex;
  }

  .step-dot {
    width: 32px;
    height: 32px;
    font-size: 0.8rem;
  }

  .step-item {
    min-width: 48px;
  }

  .intake-current-step {
    display: none;
  }

  .intake-actions {
    flex-direction: row;
    justify-content: space-between;
  }

  .intake-complete-actions {
    justify-content: center;
  }

  .intake-wrapper .card-body {
    padding: 2rem;
  }
}

@media (max-width: 575.98px) {
  .intake-wrapper .container {
    max-width: 100%;
    padding-right: 0.75rem;
    padding-left: 0.75rem;
  }

  .intake-wrapper .card-body,
  .intake-wrapper .card-body.p-4 {
    padding: 1.25rem !important;
  }

  .intake-choice,
  .service-card {
    align-items: flex-start !important;
    gap: 0.75rem !important;
    padding: 0.875rem !important;
  }

  .service-card::after,
  .intake-choice::after {
    align-self: flex-start;
    margin-top: 0.1rem;
  }

  .option-icon {
    width: 2.5rem;
    height: 2.5rem;
  }

  .intake-actions .btn {
    width: 100%;
  }
}

/* ===================================================================
   AUTH (sign in / sign up / password) — branded entrance card.
   =================================================================== */

body.bf-auth {
  --bs-primary: var(--bf-primary);
  --bs-primary-rgb: 0, 130, 190;
  --bs-body-color: var(--bf-ink);
  margin: 0;
  color: var(--bf-ink);
  font-family: "DM Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: var(--bf-bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

.auth-shell {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  padding: 1.5rem;
}

.auth-card {
  width: 100%;
  max-width: 416px;
  padding: 2rem 2rem 1.85rem;
  background: var(--bf-surface);
  border: 1px solid var(--bf-border);
  border-radius: var(--bf-radius-2xl);
  box-shadow: var(--bf-shadow-sm);
  animation: intake-rise 200ms cubic-bezier(0.4, 0, 0.2, 1) both;
}

.auth-brand {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  margin-bottom: 1.6rem;
}

.auth-brand-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 42px;
  width: 42px;
  height: 42px;
  border-radius: var(--bf-radius);
  background: var(--bf-ink);
  color: #fff;
  font-family: "Roboto Slab", serif;
  font-weight: 700;
  letter-spacing: -0.03em;
}

.auth-brand b { display: block; font-family: "Roboto Slab", serif; font-size: 1rem; line-height: 1.15; }
.auth-brand small { display: block; color: var(--bf-text-light); font-size: 0.7rem; font-weight: 600; letter-spacing: 0.07em; text-transform: uppercase; }
.brand-logo { flex: 0 0 auto; display: block; object-fit: contain; }
.auth-brand .brand-logo { width: 42px; height: 42px; }

.bf-auth h1 {
  font-family: "Roboto Slab", Georgia, serif;
  font-weight: 700;
}

.bf-auth h1, .bf-auth h2, .bf-auth h3,
.bf-auth h4, .bf-auth h5, .bf-auth h6 {
  color: var(--bf-ink);
  font-size: 1.4rem;
  letter-spacing: -0.01em;
  margin: 0 0 0.35rem;
}

.bf-auth h2, .bf-auth h3 { margin-top: 1.75rem; font-size: 1.1rem; font-weight: 600; }
.bf-auth p { color: var(--bf-text-muted); font-size: 0.9rem; }
.bf-auth .form-label { margin-bottom: 0.35rem; color: var(--bf-ink); font-size: 0.85rem; font-weight: 600; }

.bf-auth .form-control,
.bf-auth .form-select {
  min-height: 46px;
  border-color: var(--bf-border);
  border-radius: var(--bf-radius-xl);
  background-color: var(--bf-input-bg);
  color: var(--bf-ink);
  transition: border-color var(--bf-transition), box-shadow var(--bf-transition), background-color var(--bf-transition);
}

.bf-auth .form-control::placeholder { color: var(--bf-text-light); }
.bf-auth .form-control:focus,
.bf-auth .form-select:focus { border-color: var(--bf-primary); background-color: var(--bf-surface); box-shadow: var(--bf-ring); }
.bf-auth .form-check-input { border-color: var(--bf-border); }
.bf-auth .form-check-input:checked { background-color: var(--bf-primary); border-color: var(--bf-primary); }
.bf-auth .form-check-input:focus { border-color: var(--bf-primary); box-shadow: var(--bf-ring); }
.bf-auth .form-check-label { font-size: 0.88rem; color: var(--bf-text-muted); }

.bf-auth .btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  width: 100%;
  min-height: 46px;
  margin-top: 0.5rem;
  padding: 0.6rem 1.25rem;
  border-radius: var(--bf-radius-xl);
  font-size: 0.95rem;
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: 0.01em;
  transition: background-color var(--bf-transition), border-color var(--bf-transition), box-shadow var(--bf-transition);
}

.bf-auth .btn + .btn { margin-top: 0.6rem; }
.bf-auth .btn-primary { border-color: var(--bf-primary); background: var(--bf-primary); color: #fff; }
.bf-auth .btn-primary:hover,
.bf-auth .btn-primary:focus { border-color: var(--bf-primary-hover); background: var(--bf-primary-hover); color: #fff; }
.bf-auth .btn-secondary { border-color: var(--bf-border); background: var(--bf-input-bg); color: var(--bf-ink); }
.bf-auth .btn-secondary:hover,
.bf-auth .btn-secondary:focus { border-color: var(--bf-secondary); background: #E7ECF1; color: var(--bf-ink); }
.bf-auth .btn-danger { border-color: var(--bf-error); background: var(--bf-error); color: #fff; }
.bf-auth .btn-danger:hover,
.bf-auth .btn-danger:focus { border-color: var(--bf-error-dark); background: var(--bf-error-dark); color: #fff; }
.bf-auth a { color: var(--bf-primary); text-decoration: none; font-weight: 500; }
.bf-auth a:hover { text-decoration: underline; }
.bf-auth .alert { border-radius: var(--bf-radius); }
.bf-auth .alert-danger { border-color: rgba(220, 38, 38, 0.22); background: var(--bf-error-light); color: var(--bf-error-dark); }
.bf-auth .alert-success { border-color: rgba(22, 163, 74, 0.22); background: var(--bf-success-soft); color: var(--bf-success-ink); }
.auth-card--wide { max-width: 520px; }
.auth-foot { margin-top: 1.25rem; color: var(--bf-text-light); font-size: 0.78rem; }
.auth-foot a { color: var(--bf-text-muted); }
.auth-foot a:hover { color: var(--bf-primary); }
