/* =========================================================================
   BetterPro design system
   Navy + coral brand. Mobile-first. Real type scale, elevation, motion
   tokens, and component states — built to feel like one coherent product,
   not a stack of one-off page styles.
   ========================================================================= */

:root {
  /* --- brand color --- */
  --navy-950: #0d1526;
  --navy-900: #142242;
  --navy-850: #1a2c52;
  --navy-800: #223260;
  --navy-100: #eef1f8;
  --coral-500: #ff8a63;
  --coral-600: #ff7a52;
  --coral-700: #e8623c;
  --coral-800: #c94f2e;
  --gray-25: #fbfbfd;
  --gray-50: #f6f7fb;
  --gray-100: #eceef2;
  --gray-200: #dde1e9;
  --gray-300: #c7cddb;
  --gray-500: #69728a;
  --gray-600: #545e75;
  --gray-700: #333c54;
  --green-600: #1f9d55;
  --green-700: #197f45;
  --gold-500: #f0a93b;

  /* --- elevation --- */
  --shadow-xs: 0 1px 2px rgba(13, 21, 38, 0.06);
  --shadow-sm: 0 2px 8px rgba(13, 21, 38, 0.08);
  --shadow-md: 0 10px 28px rgba(13, 21, 38, 0.14);
  --shadow-lg: 0 20px 48px rgba(13, 21, 38, 0.20);
  --shadow-coral: 0 10px 24px rgba(232, 98, 60, 0.28);

  /* --- radius scale --- */
  --r-sm: 8px;
  --r-md: 12px;
  --r-lg: 18px;
  --r-xl: 24px;
  --r-pill: 999px;

  /* --- spacing scale --- */
  --sp-1: 4px;
  --sp-2: 8px;
  --sp-3: 12px;
  --sp-4: 16px;
  --sp-5: 20px;
  --sp-6: 28px;
  --sp-7: 40px;

  /* --- motion --- */
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-standard: cubic-bezier(0.4, 0, 0.2, 1);
  --dur-fast: 140ms;
  --dur-normal: 240ms;
  --dur-slow: 420ms;

  --max-width: 1080px;
  color-scheme: light;
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }

html { -webkit-text-size-adjust: 100%; }

body {
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  color: var(--gray-700);
  background: var(--gray-50);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  -webkit-tap-highlight-color: transparent;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; touch-action: manipulation; -webkit-tap-highlight-color: transparent; }
:focus-visible { outline: 2.5px solid var(--coral-600); outline-offset: 2px; border-radius: 4px; }

h1, h2, h3 { font-family: 'Lexend', 'Plus Jakarta Sans', sans-serif; letter-spacing: -0.02em; color: var(--navy-900); margin: 0; }

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 18px;
}

/* ---------------------------------------------------------------------
   Header
   --------------------------------------------------------------------- */
.site-header {
  background: var(--navy-900);
  color: #fff;
  padding: 15px 0;
  position: sticky;
  top: 0;
  z-index: 50;
  box-shadow: 0 1px 0 rgba(255,255,255,0.06), var(--shadow-sm);
}
.site-header .container { padding: 0 14px; }
.site-header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  min-height: 56px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 9px;
  font-family: 'Lexend', sans-serif;
  font-weight: 700;
  font-size: 1.2rem;
  letter-spacing: -0.02em;
  color: #fff;
}
.brand-mark {
  width: 30px;
  height: 30px;
  border-radius: 9px;
  background: linear-gradient(150deg, var(--coral-500), var(--coral-700));
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: 'Lexend', sans-serif;
  font-size: 0.92rem;
  font-weight: 800;
  box-shadow: 0 3px 8px rgba(232, 98, 60, 0.35);
}
.site-nav {
  display: none;
  align-items: center;
  gap: 26px;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--gray-300);
}
.site-nav a { transition: color var(--dur-fast) var(--ease-standard); }
.site-nav a:hover { color: #fff; }
@media (min-width: 860px) {
  .site-nav { display: flex; }
}

.site-header-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.btn-sm {
  padding: 8px 12px;
  min-height: 38px;
  font-size: 0.8rem;
  white-space: nowrap;
}
.header-cta .cta-short { display: none; }
@media (max-width: 400px) {
  .btn-sm { padding: 7px 9px; font-size: 0.72rem; }
  .brand { font-size: 1.02rem; gap: 7px; }
  .brand-mark { width: 26px; height: 26px; font-size: 0.82rem; }
  .header-cta .cta-full { display: none; }
  .header-cta .cta-short { display: inline; }
}

.menu-toggle {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 4px;
  width: 44px;
  height: 44px;
  border: none;
  background: transparent;
  border-radius: var(--r-sm);
  cursor: pointer;
  flex-shrink: 0;
}
.menu-toggle:hover { background: rgba(255,255,255,0.08); }
.menu-toggle-bar {
  display: block;
  width: 19px;
  height: 2px;
  border-radius: 2px;
  background: #fff;
  transition: transform var(--dur-fast) var(--ease-standard), opacity var(--dur-fast) var(--ease-standard);
}
.menu-toggle[aria-expanded="true"] .menu-toggle-bar:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.menu-toggle[aria-expanded="true"] .menu-toggle-bar:nth-child(2) { opacity: 0; }
.menu-toggle[aria-expanded="true"] .menu-toggle-bar:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }
@media (min-width: 860px) {
  .menu-toggle { display: none; }
}

.mobile-nav {
  display: flex;
  flex-direction: column;
  max-height: 0;
  overflow: hidden;
  background: var(--navy-950);
  border-top: 1px solid rgba(255,255,255,0.08);
  transition: max-height var(--dur-normal) var(--ease-out);
}
.mobile-nav.is-open { max-height: 320px; }
.mobile-nav a {
  padding: 14px 18px;
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--gray-300);
  border-bottom: 1px solid rgba(255,255,255,0.06);
  min-height: 48px;
  display: flex;
  align-items: center;
}
.mobile-nav a:hover { color: #fff; }
.mobile-nav a:last-child { border-bottom: none; }
@media (min-width: 860px) {
  .mobile-nav { display: none; }
}

/* ---------------------------------------------------------------------
   Buttons — one component, every page
   --------------------------------------------------------------------- */
.btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: none;
  border-radius: var(--r-md);
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-weight: 700;
  font-size: 1rem;
  padding: 14px 22px;
  min-height: 48px;
  cursor: pointer;
  transition: transform var(--dur-fast) var(--ease-out),
              box-shadow var(--dur-normal) var(--ease-out),
              background var(--dur-fast) var(--ease-standard),
              color var(--dur-fast) var(--ease-standard);
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
}
.btn:active { transform: translateY(1px) scale(0.98); }

.btn-primary {
  background: linear-gradient(155deg, var(--coral-500), var(--coral-700));
  color: #fff;
  box-shadow: var(--shadow-coral);
}
.btn-primary:hover { transform: translateY(-1.5px); box-shadow: 0 14px 30px rgba(232, 98, 60, 0.34); }
.btn-primary:active { transform: translateY(0px) scale(0.98); box-shadow: 0 6px 14px rgba(232, 98, 60, 0.30); }

.btn-secondary {
  background: #fff;
  color: var(--navy-900);
  border: 1.5px solid var(--gray-200);
  box-shadow: var(--shadow-xs);
}
.btn-secondary:hover { border-color: var(--navy-800); transform: translateY(-1px); box-shadow: var(--shadow-sm); }

.btn-block { width: 100%; }
.btn-lg { padding: 16px 24px; font-size: 1.05rem; min-height: 52px; }
.btn[disabled] { opacity: 0.6; cursor: not-allowed; transform: none !important; }

/* success / loading morphs, shared by every "contact" action */
.btn-success {
  background: linear-gradient(155deg, #26b464, var(--green-700)) !important;
  box-shadow: 0 10px 24px rgba(31, 157, 85, 0.30) !important;
}
.btn-spinner {
  width: 16px; height: 16px;
  border-radius: 50%;
  border: 2.5px solid rgba(255,255,255,0.45);
  border-top-color: #fff;
  animation: spin 0.7s linear infinite;
  flex-shrink: 0;
}
@keyframes spin { to { transform: rotate(360deg); } }

.btn-check {
  display: inline-flex;
  animation: pop var(--dur-slow) var(--ease-out);
}
@keyframes pop {
  0% { transform: scale(0.4); opacity: 0; }
  60% { transform: scale(1.15); opacity: 1; }
  100% { transform: scale(1); }
}

/* ---------------------------------------------------------------------
   Hero / funnel
   --------------------------------------------------------------------- */
.hero {
  background: var(--navy-950);
  color: #fff;
  padding: 44px 0 60px;
  position: relative;
  overflow: hidden;
}
.hero .container { position: relative; z-index: 2; }

/* Slowly-rotating, lightly-blurred photo backdrop behind the hero copy -
   pure mood/atmosphere (no claim these are "our" investigators), same as
   any professional-services site using editorial stock photography. The
   dark overlay on top keeps the white headline readable regardless of
   which photo is showing. */
.hero-bg-photos {
  position: absolute;
  inset: 0;
  z-index: 0;
}
.hero-bg-photo {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  opacity: 0;
  transition: opacity 1.6s ease-in-out;
}
.hero-bg-photo.is-active { opacity: 1; }
.hero-bg-overlay {
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
    radial-gradient(ellipse 900px 500px at 15% -10%, rgba(255,122,82,0.16), transparent 60%),
    linear-gradient(175deg, rgba(13,21,38,0.62) 0%, rgba(26,44,82,0.60) 100%);
}
@media (prefers-reduced-motion: reduce) {
  .hero-bg-photo { transition: none; }
}
.hero h1 {
  font-size: clamp(1.6rem, 5.4vw, 2.6rem);
  line-height: 1.18;
  color: #fff;
  margin: 0 0 12px;
  animation: fadeUp var(--dur-slow) var(--ease-out) both;
}
.hero p.sub {
  color: var(--gray-300);
  margin: 0 0 26px;
  font-size: 1.02rem;
  max-width: 46ch;
  animation: fadeUp var(--dur-slow) var(--ease-out) 60ms both;
}
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

.funnel-card {
  background: #fff;
  border-radius: var(--r-xl);
  box-shadow: var(--shadow-lg);
  padding: 22px 20px;
  color: var(--gray-700);
  position: relative;
  animation: fadeUp var(--dur-slow) var(--ease-out) 120ms both;
}
@media (min-width: 768px) {
  .funnel-card { padding: 32px 36px; }
}

.field-label {
  display: block;
  font-weight: 700;
  font-size: 0.85rem;
  color: var(--navy-900);
  margin-bottom: 7px;
  letter-spacing: -0.01em;
}
.field-hint {
  font-size: 0.8rem;
  color: var(--gray-500);
  margin: 6px 0 0;
}
.text-input, .zip-input {
  width: 100%;
  border: 1.5px solid var(--gray-200);
  border-radius: var(--r-md);
  padding: 15px 16px;
  font-size: 1.06rem;
  font-family: inherit;
  color: var(--gray-700);
  background: var(--gray-25);
  transition: border-color var(--dur-fast) var(--ease-standard), box-shadow var(--dur-fast) var(--ease-standard), background var(--dur-fast);
}
.text-input:focus, .zip-input:focus {
  outline: none;
  border-color: var(--coral-600);
  background: #fff;
  box-shadow: 0 0 0 4px rgba(255, 122, 82, 0.14);
}
.locked-field {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  border: 1.5px dashed var(--gray-200);
  background: var(--navy-100);
  border-radius: var(--r-md);
  padding: 13px 15px;
  font-weight: 700;
  color: var(--navy-900);
  font-size: 0.98rem;
}
.locked-field .locked-note {
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--gray-500);
  background: #fff;
  border-radius: var(--r-sm);
  padding: 4px 9px;
  white-space: nowrap;
}

/* funnel step transitions: slide + fade, not a hard cut */
.funnel-steps { position: relative; }
.funnel-step {
  display: none;
}
.funnel-step.is-active {
  display: block;
  animation: stepIn var(--dur-normal) var(--ease-out) both;
}
.funnel-step.is-leaving-back {
  animation: stepInBack var(--dur-normal) var(--ease-out) both;
}
@keyframes stepIn {
  from { opacity: 0; transform: translateX(18px); }
  to   { opacity: 1; transform: translateX(0); }
}
@keyframes stepInBack {
  from { opacity: 0; transform: translateX(-18px); }
  to   { opacity: 1; transform: translateX(0); }
}

.step-progress-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
  gap: 12px;
}
.step-progress-label {
  font-size: 0.76rem;
  font-weight: 700;
  color: var(--gray-500);
  white-space: nowrap;
}
.step-progress {
  display: flex;
  gap: 6px;
  flex: 1;
}
.step-progress .dot {
  flex: 1;
  height: 5px;
  border-radius: var(--r-pill);
  background: var(--gray-100);
  overflow: hidden;
  position: relative;
}
.step-progress .dot::after {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(90deg, var(--coral-500), var(--coral-700));
  transform: scaleX(0);
  transform-origin: left;
  transition: transform var(--dur-slow) var(--ease-out);
}
.step-progress .dot.is-active::after,
.step-progress .dot.is-done::after { transform: scaleX(1); }

.chip-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 9px;
  margin: 14px 0 22px;
}
@media (min-width: 480px) {
  .chip-grid { grid-template-columns: 1fr 1fr; }
}
.chip {
  border: 1.5px solid var(--gray-200);
  border-radius: var(--r-md);
  padding: 13px 15px;
  font-size: 0.93rem;
  font-weight: 600;
  color: var(--gray-700);
  background: #fff;
  cursor: pointer;
  text-align: left;
  transition: border-color var(--dur-fast) var(--ease-standard),
              background var(--dur-fast) var(--ease-standard),
              transform var(--dur-fast) var(--ease-out),
              box-shadow var(--dur-fast) var(--ease-standard);
  min-height: 48px;
}
.chip:hover { border-color: var(--gray-300); transform: translateY(-1px); box-shadow: var(--shadow-xs); }
.chip:active { transform: translateY(0) scale(0.98); }
.chip.is-selected {
  border-color: var(--coral-600);
  background: #fff4f0;
  color: var(--coral-800);
  box-shadow: 0 0 0 3px rgba(255, 122, 82, 0.12);
}

.funnel-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  margin-top: 8px;
}

.error-banner {
  background: #fdecea;
  border: 1px solid #f3b6b0;
  color: #9c2b21;
  border-radius: var(--r-md);
  padding: 11px 15px;
  font-size: 0.88rem;
  margin-bottom: 14px;
  animation: shake 320ms var(--ease-out);
}
@keyframes shake {
  10%, 90% { transform: translateX(-2px); }
  30%, 70% { transform: translateX(3px); }
  50% { transform: translateX(-3px); }
}

/* ---------------------------------------------------------------------
   Home page: how-it-works / value props / FAQ
   --------------------------------------------------------------------- */
#zip-funnel, #how-it-works, #faq { scroll-margin-top: 72px; }

.section-heading {
  text-align: center;
  max-width: 46ch;
  margin: 0 auto 32px;
}
.section-heading h2 {
  font-size: clamp(1.4rem, 4vw, 1.9rem);
  margin: 0 0 8px;
}
.section-heading p {
  color: var(--gray-500);
  margin: 0;
  font-size: 0.96rem;
}

.how-it-works {
  background: var(--gray-50);
  padding: 54px 0;
}
.steps-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
}
@media (min-width: 768px) {
  .steps-grid { grid-template-columns: repeat(3, 1fr); }
}
.step-card {
  background: #fff;
  border: 1px solid var(--gray-100);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-sm);
  padding: 24px 20px;
  text-align: center;
}
.step-num {
  width: 40px;
  height: 40px;
  margin: 0 auto 14px;
  border-radius: 50%;
  background: linear-gradient(150deg, var(--coral-500), var(--coral-700));
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Lexend', sans-serif;
  font-weight: 700;
  font-size: 1.05rem;
  box-shadow: var(--shadow-coral);
}
.step-card h3 {
  font-size: 1.02rem;
  margin: 0 0 8px;
}
.step-card p {
  font-size: 0.9rem;
  color: var(--gray-500);
  margin: 0;
}

.value-props {
  background: var(--navy-950);
  padding: 54px 0;
}
.value-props .section-heading h2 { color: #fff; }
.value-props .section-heading p { color: var(--gray-300); }
.value-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}
@media (min-width: 560px) {
  .value-grid { grid-template-columns: 1fr 1fr; }
}
.value-card {
  background: var(--navy-850);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: var(--r-lg);
  padding: 22px 20px;
}
.value-ico {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px; height: 38px;
  border-radius: var(--r-sm);
  background: rgba(255,255,255,0.08);
  font-size: 1.05rem;
  margin-bottom: 12px;
}
.value-card h3 {
  color: #fff;
  font-size: 1rem;
  margin: 0 0 6px;
}
.value-card p {
  color: var(--gray-300);
  font-size: 0.88rem;
  margin: 0;
}

.faq {
  background: var(--gray-50);
  padding: 54px 0 64px;
}
.faq-list {
  max-width: 720px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.faq-item {
  background: #fff;
  border: 1px solid var(--gray-100);
  border-radius: var(--r-md);
  box-shadow: var(--shadow-xs);
  padding: 4px 4px;
}
.faq-item summary {
  list-style: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 16px;
  font-weight: 700;
  color: var(--navy-900);
  font-size: 0.95rem;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-plus {
  flex-shrink: 0;
  color: var(--coral-600);
  font-size: 1.1rem;
  font-weight: 700;
  transition: transform var(--dur-fast) var(--ease-standard);
}
.faq-item[open] .faq-plus { transform: rotate(45deg); }
.faq-item p {
  margin: 0;
  padding: 0 16px 16px;
  font-size: 0.9rem;
  color: var(--gray-500);
}

/* ---------------------------------------------------------------------
   Matching / loading overlay — the "we're doing real work" beat
   --------------------------------------------------------------------- */
.matching-overlay {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: none;
  align-items: center;
  justify-content: center;
  background: linear-gradient(175deg, var(--navy-950) 0%, var(--navy-850) 100%);
  color: #fff;
  text-align: center;
  padding: 24px;
}
.matching-overlay.is-visible {
  display: flex;
  animation: fadeIn var(--dur-normal) var(--ease-standard) both;
}
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }

.matching-panel { max-width: 340px; width: 100%; }
.matching-spinner {
  width: 56px; height: 56px;
  margin: 0 auto 26px;
  border-radius: 50%;
  background: conic-gradient(from 0deg, var(--coral-600), transparent 65%);
  animation: spin 1.1s linear infinite;
  position: relative;
}
.matching-spinner::after {
  content: '';
  position: absolute; inset: 6px;
  border-radius: 50%;
  background: var(--navy-900);
}
.matching-title {
  font-family: 'Lexend', sans-serif;
  font-size: 1.15rem;
  font-weight: 700;
  margin: 0 0 8px;
  color: #fff;
}
.matching-status {
  font-size: 0.9rem;
  color: var(--gray-300);
  height: 22px;
  margin: 0 0 20px;
  position: relative;
}
.matching-status span {
  position: absolute; inset: 0;
  opacity: 0;
  animation: statusCycle 4.5s ease-in-out infinite;
}
.matching-status span:nth-child(1) { animation-delay: 0s; }
.matching-status span:nth-child(2) { animation-delay: 1.5s; }
.matching-status span:nth-child(3) { animation-delay: 3s; }
@keyframes statusCycle {
  0%, 4% { opacity: 0; transform: translateY(4px); }
  10%, 28% { opacity: 1; transform: translateY(0); }
  34%, 100% { opacity: 0; transform: translateY(-4px); }
}
.matching-bar {
  height: 6px;
  border-radius: var(--r-pill);
  background: rgba(255,255,255,0.12);
  overflow: hidden;
}
.matching-bar::after {
  content: '';
  display: block;
  height: 100%;
  width: 0%;
  border-radius: var(--r-pill);
  background: linear-gradient(90deg, var(--coral-500), var(--coral-700));
}
.matching-overlay.is-visible .matching-bar::after {
  animation: fillBar 4.5s var(--ease-standard) forwards;
}
@keyframes fillBar { from { width: 4%; } to { width: 100%; } }

/* ---------------------------------------------------------------------
   Results page
   --------------------------------------------------------------------- */
.results-header {
  background: linear-gradient(175deg, var(--navy-950), var(--navy-850));
  color: #fff;
  padding: 24px 0 30px;
}
.results-header h1 {
  font-family: 'Lexend', sans-serif;
  font-size: 1.35rem;
  color: #fff;
  margin: 0 0 5px;
}
.results-header .meta {
  color: var(--gray-300);
  font-size: 0.88rem;
}
.results-header .meta a { color: var(--coral-500); font-weight: 700; transition: color var(--dur-fast); }
.results-header .meta a:hover { color: var(--coral-600); }

.contact-top3-bar {
  background: #fff;
  border-radius: var(--r-xl);
  box-shadow: var(--shadow-lg);
  padding: 18px;
  margin: -18px 0 22px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  transition: background var(--dur-normal) var(--ease-standard);
}
@media (min-width: 640px) {
  .contact-top3-bar {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    padding: 20px 24px;
  }
}
.contact-top3-bar.is-sent {
  background: linear-gradient(135deg, #f2fbf6, #fff);
}
.contact-top3-bar .copy strong { color: var(--navy-900); display: block; font-size: 1.04rem; font-family: 'Lexend', sans-serif; }
.contact-top3-bar .copy span { font-size: 0.85rem; color: var(--gray-500); }
#contactTop3Btn { min-width: 168px; }

.confirm-banner {
  display: flex;
  background: #eafaf0;
  border-style: solid;
  border-color: #b7e6c7;
  color: #196b3c;
  border-radius: var(--r-md);
  font-size: 0.9rem;
  align-items: flex-start;
  gap: 9px;
  max-height: 0;
  opacity: 0;
  padding: 0 16px;
  margin-bottom: 0;
  border-width: 0;
  overflow: hidden;
  transition: max-height var(--dur-slow) var(--ease-out), opacity var(--dur-normal),
              padding var(--dur-slow) var(--ease-out), margin var(--dur-slow) var(--ease-out);
}
.confirm-banner.is-visible {
  max-height: 200px;
  opacity: 1;
  padding: 13px 16px;
  margin-bottom: 22px;
  border-width: 1px;
}
.confirm-check {
  display: inline-flex;
  animation: pop var(--dur-slow) var(--ease-out);
  flex-shrink: 0;
}

.firm-list {
  display: grid;
  gap: 16px;
  margin: 0 0 30px;
  padding: 0;
  list-style: none;
}

.firm-card {
  background: #fff;
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-sm);
  padding: 18px;
  display: block;
  border: 1px solid var(--gray-100);
  transition: box-shadow var(--dur-normal) var(--ease-out),
              border-color var(--dur-normal) var(--ease-out),
              transform var(--dur-normal) var(--ease-out);
  opacity: 0;
  animation: cardIn var(--dur-slow) var(--ease-out) both;
}
.firm-list li:nth-child(1) .firm-card { animation-delay: 60ms; }
.firm-list li:nth-child(2) .firm-card { animation-delay: 140ms; }
.firm-list li:nth-child(3) .firm-card { animation-delay: 220ms; }
.firm-list li:nth-child(4) .firm-card { animation-delay: 300ms; }
.firm-list li:nth-child(5) .firm-card { animation-delay: 380ms; }
@keyframes cardIn {
  from { opacity: 0; transform: translateY(14px); }
  to   { opacity: 1; transform: translateY(0); }
}
.firm-card:hover { box-shadow: var(--shadow-md); border-color: var(--gray-200); transform: translateY(-2px); }

.firm-card-top {
  display: flex;
  gap: 13px;
  align-items: flex-start;
}
.firm-avatar {
  width: 52px;
  height: 52px;
  border-radius: var(--r-md);
  background: var(--navy-100);
  color: var(--navy-900);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Lexend', sans-serif;
  font-weight: 700;
  font-size: 1.1rem;
  flex-shrink: 0;
}
.firm-name-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
  flex-wrap: wrap;
}
.firm-name {
  font-family: 'Lexend', sans-serif;
  font-size: 1.06rem;
  font-weight: 700;
  color: var(--navy-900);
  margin: 0;
}
.rank-pill {
  font-size: 0.7rem;
  font-weight: 700;
  color: var(--coral-800);
  background: #fff4f0;
  border-radius: var(--r-pill);
  padding: 3px 10px;
  white-space: nowrap;
}
.contacted-pill {
  font-size: 0.7rem;
  font-weight: 700;
  color: var(--green-700);
  background: #eafaf0;
  border-radius: var(--r-pill);
  padding: 3px 10px;
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  animation: pop var(--dur-slow) var(--ease-out);
}
.rating-row {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 0.85rem;
  color: var(--gray-500);
  margin-top: 3px;
  flex-wrap: wrap;
}

/* fractional star rating: gray base row + gold overlay clipped to % */
.star-rating {
  position: relative;
  display: inline-block;
  font-size: 0.95rem;
  line-height: 1;
  letter-spacing: 2px;
  color: var(--gray-200);
}
.star-rating::before {
  content: '★★★★★';
  position: absolute;
  inset: 0;
  width: var(--pct, 0%);
  overflow: hidden;
  white-space: nowrap;
  color: var(--gold-500);
}
.star-rating.sm { font-size: 0.78rem; letter-spacing: 1.5px; }

.firm-tagline {
  font-size: 0.88rem;
  color: var(--gray-500);
  margin: 3px 0 0;
}
.firm-blurb {
  font-size: 0.92rem;
  color: var(--gray-700);
  margin: 12px 0 13px;
}
.badge-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 0 0 14px;
}
.badge {
  font-size: 0.72rem;
  font-weight: 700;
  border-radius: var(--r-sm);
  padding: 4px 9px;
  background: var(--navy-100);
  color: var(--navy-800);
  letter-spacing: 0.01em;
}
.badge.badge-top { background: linear-gradient(135deg, #fff2df, #ffe6c2); color: #9a6300; }
.badge.badge-verified {
  background: #e3f7ec;
  color: #157a4a;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.badge-check {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 13px;
  height: 13px;
  border-radius: 50%;
  background: #2ec48e;
  color: #fff;
  font-size: 0.6rem;
  line-height: 1;
}
.firm-card-actions {
  display: flex;
  flex-direction: column;
  gap: 9px;
}
.firm-card-actions .btn { width: 100%; }
@media (min-width: 480px) {
  .firm-card-actions { flex-direction: row; flex-wrap: wrap; }
  .firm-card-actions .btn { flex: 1; min-width: 120px; width: auto; }
}

.results-footnote {
  font-size: 0.75rem;
  color: var(--gray-500);
  text-align: center;
  padding: 18px 0 8px;
}

/* ---------------------------------------------------------------------
   Profile page
   --------------------------------------------------------------------- */
.profile-hero {
  background: linear-gradient(175deg, var(--navy-950), var(--navy-850));
  color: #fff;
  padding: 24px 0 32px;
}
.back-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--gray-300);
  font-size: 0.85rem;
  margin-bottom: 16px;
  transition: color var(--dur-fast), transform var(--dur-fast);
}
.back-link:hover { color: #fff; transform: translateX(-2px); }
.profile-hero-top {
  display: flex;
  gap: 15px;
  align-items: flex-start;
}
.profile-avatar {
  width: 62px;
  height: 62px;
  border-radius: var(--r-md);
  background: linear-gradient(150deg, var(--coral-500), var(--coral-700));
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Lexend', sans-serif;
  font-weight: 700;
  font-size: 1.35rem;
  flex-shrink: 0;
  box-shadow: 0 6px 18px rgba(232, 98, 60, 0.32);
}
.profile-hero h1 { margin: 0 0 5px; font-size: 1.4rem; color: #fff; font-family: 'Lexend', sans-serif; }
.profile-hero .tagline { color: var(--gray-300); font-size: 0.92rem; margin: 0 0 9px; }

.section {
  background: #fff;
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-sm);
  padding: 20px;
  margin-bottom: 16px;
  border: 1px solid var(--gray-100);
}
.section h2 {
  font-family: 'Lexend', sans-serif;
  font-size: 1.04rem;
  color: var(--navy-900);
  margin: 0 0 12px;
}
.detail-grid {
  display: grid;
  gap: 12px;
  grid-template-columns: 1fr;
  font-size: 0.9rem;
}
@media (min-width: 640px) {
  .detail-grid { grid-template-columns: 1fr 1fr; }
}
.detail-grid dt { font-weight: 700; color: var(--navy-800); }
.detail-grid dd { margin: 2px 0 10px; color: var(--gray-500); }

.review {
  border-top: 1px solid var(--gray-100);
  padding: 14px 0;
}
.review:first-child { border-top: none; padding-top: 0; }
.review-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 8px;
}
.review-name { font-weight: 700; color: var(--navy-900); font-size: 0.92rem; }
.review-date { font-size: 0.78rem; color: var(--gray-500); }
.review-text { font-size: 0.9rem; margin: 7px 0 0; }

.sticky-cta {
  position: fixed;
  left: 0; right: 0; bottom: 0;
  z-index: 60;
  background: rgba(255,255,255,0.92);
  backdrop-filter: blur(10px);
  border-top: 1px solid var(--gray-100);
  padding: 12px 18px;
  padding-bottom: max(12px, env(safe-area-inset-bottom));
  box-shadow: 0 -8px 24px rgba(13,26,48,0.10);
}
.sticky-cta-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: flex;
  gap: 12px;
  align-items: center;
}
body.has-sticky-cta { padding-bottom: 84px; }

/* ---------------------------------------------------------------------
   Footer
   --------------------------------------------------------------------- */
.site-footer {
  background: var(--navy-950);
  color: var(--gray-300);
  padding: 44px 0 28px;
  font-size: 0.88rem;
}
.site-footer .brand { color: #fff; }
.footer-top {
  display: flex;
  flex-direction: column;
  gap: 32px;
}
@media (min-width: 768px) {
  .footer-top { flex-direction: row; justify-content: space-between; gap: 40px; }
}
.footer-brand { max-width: 340px; }
.footer-desc {
  margin: 12px 0 0;
  font-size: 0.86rem;
  color: var(--gray-300);
}
.footer-contact {
  display: flex;
  flex-direction: column;
  gap: 9px;
  margin-top: 16px;
  font-size: 0.86rem;
}
.footer-contact a {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  color: var(--gray-300);
  transition: color var(--dur-fast) var(--ease-standard);
}
.footer-contact a:hover { color: #fff; }
.footer-ico {
  flex-shrink: 0;
  width: 18px;
  text-align: center;
}
.footer-cols {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}
@media (min-width: 480px) {
  .footer-cols { grid-template-columns: repeat(3, 1fr); }
}
@media (min-width: 768px) {
  .footer-cols { gap: 40px; }
}
.footer-col-title {
  color: #fff;
  font-weight: 700;
  font-size: 0.86rem;
  margin: 0 0 12px;
}
.footer-col ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 9px;
}
.footer-col a {
  color: var(--gray-300);
  font-size: 0.86rem;
  transition: color var(--dur-fast) var(--ease-standard);
}
.footer-col a:hover { color: #fff; }

.footer-bottom {
  margin-top: 36px;
  padding-top: 22px;
  border-top: 1px solid rgba(255,255,255,0.1);
}
.footer-disclaimer {
  font-size: 0.76rem;
  color: var(--gray-500);
  line-height: 1.6;
  margin: 0 0 12px;
}
.footer-copyright {
  font-size: 0.76rem;
  color: var(--gray-500);
  margin: 0;
}

/* ---------------------------------------------------------------------
   Simple content pages (about / contact / terms / privacy)
   --------------------------------------------------------------------- */
.page-hero {
  background: linear-gradient(175deg, var(--navy-950), var(--navy-850));
  color: #fff;
  padding: 32px 0 36px;
}
.page-hero h1 {
  color: #fff;
  font-size: 1.6rem;
  margin: 0 0 8px;
}
.page-hero .tagline {
  color: var(--gray-300);
  font-size: 0.94rem;
  margin: 0;
  max-width: 56ch;
}

.legal-content h2 {
  font-family: 'Lexend', sans-serif;
  font-size: 1rem;
  color: var(--navy-900);
  margin: 22px 0 8px;
}
.legal-content h2:first-child { margin-top: 0; }
.legal-content p {
  font-size: 0.92rem;
  color: var(--gray-600);
  margin: 0 0 4px;
  line-height: 1.65;
}

.contact-block {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin: 16px 0 4px;
}
.contact-block a {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-weight: 700;
  color: var(--navy-900);
  font-size: 0.95rem;
  transition: color var(--dur-fast) var(--ease-standard);
}
.contact-block a:hover { color: var(--coral-600); }
.contact-block .footer-ico { width: 20px; text-align: center; flex-shrink: 0; }

.visually-hidden {
  position: absolute;
  width: 1px; height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
}

/* ---------------------------------------------------------------------
   Funnel question pages (each qualifying question is its own page)
   --------------------------------------------------------------------- */
.hero-compact { padding: 36px 0 56px; }
.funnel-eyebrow {
  color: var(--coral-500);
  font-weight: 700;
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin: 0 0 14px;
}
.question-title {
  font-size: 1.15rem;
  margin-bottom: 4px;
}

/* ---------------------------------------------------------------------
   Trust showcase (phone mockup section)
   --------------------------------------------------------------------- */
.trust-showcase {
  background: #fff;
  padding: 56px 0;
}
.trust-showcase .container {
  display: grid;
  grid-template-columns: 1fr;
  gap: 40px;
  align-items: center;
}
@media (min-width: 900px) {
  .trust-showcase .container {
    grid-template-columns: 1fr 300px;
    gap: 64px;
  }
}
.trust-copy h2 {
  font-size: clamp(1.5rem, 3.6vw, 2.1rem);
  color: var(--navy-900);
  margin: 0 0 10px;
}
.trust-copy > p.lead {
  color: var(--gray-500);
  margin: 0 0 30px;
  max-width: 48ch;
  font-size: 1rem;
}
.trust-point {
  display: flex;
  gap: 14px;
  margin-bottom: 24px;
}
.trust-point:last-child { margin-bottom: 0; }
.trust-point .num {
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--navy-100);
  color: var(--coral-700);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 0.9rem;
}
.trust-point h3 {
  margin: 0 0 4px;
  font-size: 1.02rem;
  color: var(--navy-900);
}
.trust-point p {
  margin: 0;
  color: var(--gray-500);
  font-size: 0.9rem;
  line-height: 1.55;
}

.phone-mock-wrap { display: flex; justify-content: center; }
.phone-frame {
  width: 230px;
  height: 470px;
  border-radius: 34px;
  background: var(--navy-950);
  padding: 10px;
  box-shadow: var(--shadow-lg);
  position: relative;
  animation: phoneFloat 5.2s ease-in-out infinite;
}
@keyframes phoneFloat {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-9px); }
}
.phone-frame::before {
  content: '';
  position: absolute;
  top: 10px;
  left: 50%;
  transform: translateX(-50%);
  width: 64px;
  height: 15px;
  background: var(--navy-950);
  border-radius: 0 0 10px 10px;
  z-index: 2;
}
.phone-screen-area {
  position: relative;
  width: 100%;
  height: 100%;
  background: var(--gray-25);
  border-radius: 24px;
  overflow: hidden;
}
.phone-screen {
  position: absolute;
  inset: 0;
  padding: 32px 14px 14px;
  opacity: 0;
  transform: translateX(14px);
  transition: opacity 0.5s var(--ease-out), transform 0.5s var(--ease-out);
  pointer-events: none;
}
.phone-screen.is-active {
  opacity: 1;
  transform: translateX(0);
  pointer-events: auto;
}
.phone-mini-label {
  font-size: 0.62rem;
  font-weight: 700;
  color: var(--navy-900);
  text-transform: uppercase;
  letter-spacing: 0.03em;
  margin-bottom: 6px;
}
.phone-mini-input {
  background: #fff;
  border: 1px solid var(--gray-200);
  border-radius: var(--r-sm);
  padding: 8px 10px;
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--gray-700);
}
.phone-mini-locked {
  background: var(--navy-100);
  border: 1px dashed var(--gray-200);
  border-radius: var(--r-sm);
  padding: 8px 10px;
  font-size: 0.74rem;
  font-weight: 700;
  color: var(--navy-900);
}
.phone-mini-btn {
  margin-top: 18px;
  background: linear-gradient(135deg, var(--coral-500), var(--coral-700));
  color: #fff;
  text-align: center;
  border-radius: var(--r-sm);
  padding: 9px;
  font-size: 0.78rem;
  font-weight: 700;
}
.phone-mini-firm {
  display: flex;
  align-items: center;
  gap: 8px;
  background: #fff;
  border: 1px solid var(--gray-100);
  border-radius: var(--r-sm);
  padding: 7px 9px;
  margin-bottom: 7px;
  font-size: 0.68rem;
  font-weight: 700;
  color: var(--navy-900);
}
.phone-mini-firm small { font-weight: 500; color: var(--gray-500); }
.phone-mini-avatar {
  flex-shrink: 0;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--navy-800);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.6rem;
  font-weight: 800;
}
.phone-mini-success {
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 4px;
}
.phone-mini-check {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: #2ec48e;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  margin-bottom: 8px;
}
.phone-mini-success p {
  margin: 0;
  font-weight: 700;
  color: var(--navy-900);
  font-size: 0.82rem;
}
.phone-mini-success small { color: var(--gray-500); font-size: 0.7rem; }

@media (prefers-reduced-motion: reduce) {
  .phone-frame { animation: none; }
  .phone-screen { transition: opacity 0.2s linear; }
}

/* ---------------------------------------------------------------------
   Lead-capture modal (shown before any "Contact" / "Contact Top 3" send)
   --------------------------------------------------------------------- */
.lead-modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(13, 21, 38, 0.55);
  display: flex;
  align-items: flex-end;
  justify-content: center;
  z-index: 100;
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--dur-normal) var(--ease-standard);
  padding: 0;
}
@media (min-width: 640px) {
  .lead-modal-backdrop { align-items: center; padding: 20px; }
}
.lead-modal-backdrop.is-open {
  opacity: 1;
  pointer-events: auto;
}
.lead-modal {
  background: #fff;
  width: 100%;
  max-width: 440px;
  border-radius: var(--r-xl) var(--r-xl) 0 0;
  padding: 24px 22px calc(24px + env(safe-area-inset-bottom, 0px));
  box-shadow: var(--shadow-lg);
  transform: translateY(24px);
  transition: transform var(--dur-normal) var(--ease-out);
  max-height: 90vh;
  overflow-y: auto;
}
@media (min-width: 640px) {
  .lead-modal { border-radius: var(--r-xl); padding: 28px 28px 24px; }
}
.lead-modal-backdrop.is-open .lead-modal { transform: translateY(0); }
.lead-modal-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 4px;
}
.lead-modal-head h3 {
  margin: 0;
  font-size: 1.08rem;
  color: var(--navy-900);
}
.lead-modal-close {
  background: none;
  border: none;
  font-size: 1.3rem;
  line-height: 1;
  color: var(--gray-500);
  cursor: pointer;
  padding: 4px;
  margin: -4px -4px 0 0;
}
.lead-modal-sub {
  color: var(--gray-500);
  font-size: 0.86rem;
  margin: 4px 0 18px;
}
.lead-modal-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 12px;
}
.lead-modal-field { margin-bottom: 12px; }
.lead-modal-field label {
  display: block;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--navy-900);
  margin-bottom: 5px;
}
.lead-modal-field input {
  width: 100%;
  border: 1.5px solid var(--gray-200);
  border-radius: var(--r-md);
  padding: 11px 12px;
  font-size: 0.95rem;
  font-family: inherit;
  color: var(--gray-700);
  background: var(--gray-25);
}
.lead-modal-field input:focus {
  outline: none;
  border-color: var(--coral-600);
  background: #fff;
  box-shadow: 0 0 0 4px rgba(255, 122, 82, 0.14);
}
.lead-modal-actions { margin-top: 6px; }
