/* ============================================================
   FuneralBuddy — newsite design system
   Brand: Navy #1E2A4A | Teal #1FA0A8 | Green #2EB484
          Mint #A8DEC9 | Blue #2D9CDB | Grey #5B6B82 | BG #F4F7FA
   Audience note: most users are 60+. Body text is 18px+,
   contrast clears WCAG AA, tap targets are 48px minimum.
   ============================================================ */

:root {
  /* Brand */
  --navy: #1E2A4A;
  --navy-deep: #141d36;
  --navy-soft: #2c3a60;
  --teal: #1FA0A8;
  --teal-deep: #137179;       /* AA-safe on light backgrounds */
  --green: #2EB484;
  --green-deep: #1d7f5c;      /* AA-safe on light backgrounds */
  --mint: #A8DEC9;
  --blue: #2D9CDB;
  --grey: #5B6B82;

  /* Surfaces */
  --bg: #F4F7FA;
  --bg-alt: #ffffff;
  --bg-tint: #e9f4ef;          /* mint-washed */
  --bg-tint-blue: #e8f1f8;
  --card: #ffffff;
  --border: #d8e0ea;
  --border-strong: #b9c5d4;

  /* Text — high contrast by default */
  --text: #1c2740;             /* near-navy, 13.4:1 on --bg */
  --text-secondary: #44536e;   /* 7.4:1 on --bg */
  --text-muted: #5B6B82;       /* 5.2:1 — decorative labels only */
  --text-on-dark: #f2f6fa;
  --text-on-dark-soft: #c3cfde;

  /* Type */
  --font-display: "Fraunces", Georgia, "Times New Roman", serif;
  --font-body: "Inter", "Segoe UI", Helvetica, Arial, sans-serif;

  /* Scale (generous for older eyes) */
  --text-base: 1.125rem;       /* 18px body */
  --text-sm: 1rem;             /* 16px — smallest interactive size */
  --text-xs: 0.875rem;         /* 14px — fine print only */
  --text-lg: 1.25rem;
  --text-xl: 1.5rem;
  --text-2xl: 1.875rem;
  --text-3xl: 2.375rem;
  --text-4xl: clamp(2.5rem, 5.5vw, 3.75rem);

  /* Rhythm */
  --space-1: 0.25rem; --space-2: 0.5rem; --space-3: 0.75rem;
  --space-4: 1rem;    --space-5: 1.5rem; --space-6: 2rem;
  --space-8: 3rem;    --space-10: 4rem;  --space-12: 5.5rem;

  --radius: 12px;
  --radius-lg: 20px;
  --radius-pill: 999px;

  --shadow-sm: 0 1px 3px rgba(20, 29, 54, 0.08);
  --shadow-md: 0 6px 24px rgba(20, 29, 54, 0.10);
  --shadow-lg: 0 18px 48px rgba(20, 29, 54, 0.16);

  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
  --header-h: 76px;
}

/* ---------- Reset / base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 16px); }
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: var(--text-base);
  line-height: 1.65;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img, svg { max-width: 100%; display: block; }
h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.15;
  color: var(--navy);
  margin: 0 0 var(--space-4);
  letter-spacing: -0.01em;
}
h1 { font-size: var(--text-4xl); }
h2 { font-size: var(--text-3xl); }
h3 { font-size: var(--text-xl); }
p { margin: 0 0 var(--space-4); }
a { color: var(--teal-deep); text-decoration-thickness: 1.5px; text-underline-offset: 3px; }
a:hover { color: var(--navy); }
:focus-visible {
  outline: 3px solid var(--blue);
  outline-offset: 3px;
  border-radius: 4px;
}
::selection { background: var(--mint); color: var(--navy); }

.container { width: min(1180px, 100% - 3rem); margin-inline: auto; }
.container-narrow { width: min(860px, 100% - 3rem); margin-inline: auto; }

.skip-link {
  position: absolute; left: -9999px; top: 0; z-index: 200;
  background: var(--navy); color: #fff; padding: 12px 20px;
  border-radius: 0 0 var(--radius) 0; font-weight: 600;
}
.skip-link:focus { left: 0; }

/* ---------- Buttons (big, obvious — per older-user feedback) ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 52px; padding: 14px 30px;
  font-family: var(--font-body); font-size: var(--text-base); font-weight: 600;
  border-radius: var(--radius-pill); border: 2px solid transparent;
  cursor: pointer; text-decoration: none; white-space: nowrap;
  transition: transform 0.18s var(--ease), box-shadow 0.18s var(--ease),
              background-color 0.18s var(--ease), color 0.18s var(--ease),
              border-color 0.18s var(--ease);
}
.btn:active { transform: translateY(1px) scale(0.99); }
.btn .arrow { transition: transform 0.18s var(--ease); }
.btn:hover .arrow { transform: translateX(4px); }

.btn-primary {
  background: var(--navy); color: #fff; box-shadow: var(--shadow-sm);
}
.btn-primary:hover {
  background: var(--navy-deep); color: #fff;
  transform: translateY(-2px); box-shadow: var(--shadow-md);
}
.btn-green {
  background: var(--green-deep); color: #fff; box-shadow: var(--shadow-sm);
}
.btn-green:hover {
  background: #166548; color: #fff;
  transform: translateY(-2px); box-shadow: var(--shadow-md);
}
.btn-outline {
  background: #fff; color: var(--navy); border-color: var(--border-strong);
}
.btn-outline:hover {
  border-color: var(--navy); color: var(--navy); transform: translateY(-2px);
  box-shadow: var(--shadow-sm);
}
.btn-on-dark {
  background: #fff; color: var(--navy);
}
.btn-on-dark:hover { background: var(--mint); color: var(--navy); transform: translateY(-2px); }
.btn-ghost-on-dark {
  background: transparent; color: #fff; border-color: rgba(255,255,255,0.45);
}
.btn-ghost-on-dark:hover { border-color: #fff; color: #fff; background: rgba(255,255,255,0.08); }
.btn-lg { min-height: 58px; padding: 16px 36px; font-size: var(--text-lg); }

/* ---------- Header ---------- */
.site-header {
  position: fixed; inset: 0 0 auto 0; z-index: 100;
  height: var(--header-h);
  background: rgba(244, 247, 250, 0.85);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.25s var(--ease), background-color 0.25s var(--ease),
              box-shadow 0.25s var(--ease);
}
.site-header.scrolled {
  background: rgba(255, 255, 255, 0.92);
  border-bottom-color: var(--border);
  box-shadow: 0 2px 16px rgba(20,29,54,0.06);
}
.nav-inner {
  display: flex; align-items: center; justify-content: space-between;
  height: var(--header-h); gap: var(--space-5);
}
.nav-logo img { height: 44px; width: auto; }
.nav-links {
  display: flex; align-items: center; gap: var(--space-2);
}
.nav-link {
  display: inline-flex; align-items: center;
  min-height: 44px; padding: 8px 16px;
  font-size: var(--text-sm); font-weight: 600; color: var(--text);
  text-decoration: none; border-radius: var(--radius-pill);
  border: 1.5px solid transparent;
  transition: background-color 0.15s var(--ease), border-color 0.15s var(--ease), color 0.15s var(--ease);
}
.nav-link:hover { background: #fff; border-color: var(--border-strong); color: var(--navy); }
.nav-link.active { background: var(--bg-tint); border-color: var(--mint); color: var(--green-deep); }
.nav-cta { display: inline-flex; align-items: center; gap: var(--space-2); margin-left: var(--space-3); }
.nav-cta .btn { min-height: 46px; padding: 10px 24px; font-size: var(--text-sm); }

.nav-toggle {
  display: none; align-items: center; justify-content: center;
  width: 52px; height: 52px; border: 1.5px solid var(--border-strong);
  border-radius: var(--radius); background: #fff; cursor: pointer; color: var(--navy);
}
.nav-toggle svg { width: 26px; height: 26px; stroke: currentColor; stroke-width: 2.2; fill: none; stroke-linecap: round; }

/* Scroll progress */
.scroll-progress {
  position: absolute; left: 0; bottom: -1px; height: 3px; width: 0;
  background: linear-gradient(90deg, var(--teal), var(--green));
  transition: width 0.1s linear;
}

@media (max-width: 920px) {
  .nav-toggle { display: inline-flex; }
  .nav-links {
    position: fixed; top: var(--header-h); left: 0; right: 0;
    flex-direction: column; align-items: stretch; gap: var(--space-2);
    background: #fff; padding: var(--space-5);
    border-bottom: 1px solid var(--border); box-shadow: var(--shadow-md);
    transform: translateY(-12px); opacity: 0; visibility: hidden;
    transition: transform 0.22s var(--ease), opacity 0.22s var(--ease), visibility 0.22s;
  }
  .nav-links.open { transform: translateY(0); opacity: 1; visibility: visible; }
  .nav-link { min-height: 52px; font-size: var(--text-base); justify-content: center; border-color: var(--border); }
  .nav-cta { display: flex; flex-direction: column; gap: var(--space-2); margin: var(--space-2) 0 0; }
  .nav-cta .btn { width: 100%; min-height: 54px; font-size: var(--text-base); }
}

/* ---------- Hero ---------- */
.hero {
  position: relative; overflow: hidden;
  padding: calc(var(--header-h) + var(--space-12)) 0 var(--space-12);
}
.hero::before {
  content: ""; position: absolute; inset: 0; z-index: -2;
  background:
    radial-gradient(900px 480px at 12% -10%, rgba(168, 222, 201, 0.45), transparent 65%),
    radial-gradient(820px 520px at 95% 8%, rgba(45, 156, 219, 0.16), transparent 60%),
    radial-gradient(700px 480px at 70% 105%, rgba(31, 160, 168, 0.14), transparent 60%);
}
.hero-dove {
  position: absolute; z-index: -1; right: -4%; top: 6%;
  width: clamp(280px, 36vw, 560px); opacity: 0.10;
  animation: doveFloat 9s ease-in-out infinite;
  pointer-events: none;
}
@keyframes doveFloat {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  50% { transform: translateY(-18px) rotate(-1.2deg); }
}
.hero-grid {
  display: grid; grid-template-columns: 1.05fr 0.95fr;
  gap: var(--space-10); align-items: center;
}
.hero-eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  background: #fff; border: 1.5px solid var(--mint);
  color: var(--green-deep); font-weight: 600; font-size: var(--text-sm);
  padding: 8px 18px; border-radius: var(--radius-pill);
  margin-bottom: var(--space-5); box-shadow: var(--shadow-sm);
}
.hero-eyebrow .dot {
  width: 9px; height: 9px; border-radius: 50%; background: var(--green);
  animation: pulse 2.4s ease-in-out infinite;
}
@keyframes pulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(46, 180, 132, 0.5); }
  60% { box-shadow: 0 0 0 9px rgba(46, 180, 132, 0); }
}
.hero h1 { margin-bottom: var(--space-5); }
.hero h1 em {
  font-style: italic; color: var(--teal-deep);
}
.hero-subtitle {
  font-size: var(--text-lg); color: var(--text-secondary);
  max-width: 34em; margin-bottom: var(--space-6);
}
.hero-actions { display: flex; flex-wrap: wrap; gap: var(--space-4); margin-bottom: var(--space-6); }
.hero-notes {
  display: flex; flex-wrap: wrap; gap: var(--space-3) var(--space-5);
  font-size: var(--text-sm); color: var(--text-secondary); font-weight: 500;
}
.hero-notes span { display: inline-flex; align-items: center; gap: 8px; }
.hero-notes svg { width: 18px; height: 18px; stroke: var(--green-deep); stroke-width: 2.6; fill: none; stroke-linecap: round; stroke-linejoin: round; flex: none; }

/* Hero product mock */
.hero-visual { position: relative; }
.mock-window {
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius-lg); box-shadow: var(--shadow-lg);
  overflow: hidden;
  transform: rotate(0.6deg);
}
.mock-titlebar {
  display: flex; align-items: center; gap: 8px;
  background: var(--navy); padding: 12px 18px;
}
.mock-titlebar .m-dot { width: 11px; height: 11px; border-radius: 50%; }
.mock-titlebar .m-dot:nth-child(1) { background: #f87171; }
.mock-titlebar .m-dot:nth-child(2) { background: #fbbf24; }
.mock-titlebar .m-dot:nth-child(3) { background: var(--green); }
.mock-titlebar .m-title { margin-left: 10px; color: var(--text-on-dark-soft); font-size: 0.85rem; font-weight: 500; }
.mock-body { padding: var(--space-5); }
.mock-heading {
  display: flex; justify-content: space-between; align-items: baseline;
  margin-bottom: var(--space-4);
}
.mock-heading strong { font-family: var(--font-display); font-size: 1.15rem; color: var(--navy); }
.mock-heading span { font-size: 0.85rem; color: var(--text-muted); font-weight: 500; }
.mock-case {
  display: grid; grid-template-columns: 44px 1fr auto; gap: 14px; align-items: center;
  padding: 13px 14px; border: 1px solid var(--border); border-radius: var(--radius);
  background: #fff; margin-bottom: 10px;
  opacity: 0; transform: translateY(14px);
  animation: caseIn 0.7s var(--ease) forwards;
}
.mock-case:nth-child(2) { animation-delay: 0.55s; }
.mock-case:nth-child(3) { animation-delay: 0.85s; }
.mock-case:nth-child(4) { animation-delay: 1.15s; }
@keyframes caseIn { to { opacity: 1; transform: translateY(0); } }
.mock-avatar {
  width: 44px; height: 44px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 0.9rem; color: var(--navy);
  background: var(--mint);
}
.mock-case:nth-child(3) .mock-avatar { background: var(--bg-tint-blue); color: var(--navy); }
.mock-case:nth-child(4) .mock-avatar { background: #fdecd3; color: #8a5a16; }
.mock-case-name { font-weight: 600; font-size: 0.98rem; color: var(--text); }
.mock-case-meta { font-size: 0.82rem; color: var(--text-muted); margin-top: 2px; }
.mock-bar { height: 6px; border-radius: 3px; background: var(--bg); margin-top: 8px; overflow: hidden; }
.mock-bar i {
  display: block; height: 100%; border-radius: 3px; width: 0;
  background: linear-gradient(90deg, var(--teal), var(--green));
  animation: barFill 1.2s 1.2s var(--ease) forwards;
}
.mock-case:nth-child(2) .mock-bar i { --w: 78%; }
.mock-case:nth-child(3) .mock-bar i { --w: 45%; animation-delay: 1.45s; }
.mock-case:nth-child(4) .mock-bar i { --w: 22%; animation-delay: 1.7s; }
@keyframes barFill { to { width: var(--w, 60%); } }
.mock-pill {
  font-size: 0.78rem; font-weight: 700; padding: 5px 12px; border-radius: var(--radius-pill);
  white-space: nowrap;
}
.pill-green { background: var(--bg-tint); color: var(--green-deep); }
.pill-blue  { background: var(--bg-tint-blue); color: #1565a0; }
.pill-amber { background: #fdecd3; color: #8a5a16; }

.float-chip {
  position: absolute; display: flex; align-items: center; gap: 12px;
  background: #fff; border: 1px solid var(--border);
  border-radius: var(--radius-lg); box-shadow: var(--shadow-md);
  padding: 14px 18px; font-size: 0.9rem; font-weight: 600; color: var(--text);
  animation: chipFloat 7s ease-in-out infinite;
}
.float-chip .chip-icon {
  width: 38px; height: 38px; border-radius: 10px; flex: none;
  display: flex; align-items: center; justify-content: center;
}
.float-chip .chip-icon svg { width: 20px; height: 20px; stroke-width: 2.2; fill: none; stroke-linecap: round; stroke-linejoin: round; }
.float-chip small { display: block; font-weight: 500; color: var(--text-muted); font-size: 0.78rem; }
.chip-compliance { top: -26px; left: -34px; animation-delay: 0.8s; }
.chip-compliance .chip-icon { background: var(--bg-tint); }
.chip-compliance .chip-icon svg { stroke: var(--green-deep); }
.chip-portal { bottom: -24px; right: -18px; }
.chip-portal .chip-icon { background: var(--bg-tint-blue); }
.chip-portal .chip-icon svg { stroke: #1565a0; }
@keyframes chipFloat {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}

@media (max-width: 980px) {
  .hero-grid { grid-template-columns: 1fr; gap: var(--space-8); }
  .hero-dove { right: -22%; opacity: 0.07; }
  .float-chip { display: none; }
  .mock-window { transform: none; }
}

/* ---------- Trust bar ---------- */
.trust-bar { padding: var(--space-6) 0; border-block: 1px solid var(--border); background: #fff; }
.trust-inner {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: center;
  gap: var(--space-3) var(--space-4); text-align: center;
}
.trust-label { font-size: var(--text-sm); font-weight: 600; color: var(--text-secondary); margin-right: var(--space-3); }
.state-badge {
  font-size: var(--text-xs); font-weight: 700; letter-spacing: 0.06em;
  color: var(--navy); background: var(--bg); border: 1.5px solid var(--border-strong);
  padding: 7px 14px; border-radius: var(--radius-pill);
}

/* ---------- Sections ---------- */
.section { padding: var(--space-12) 0; }
.section-alt { background: #fff; border-block: 1px solid var(--border); }
.section-header { max-width: 760px; margin: 0 auto var(--space-10); text-align: center; }
.section-label {
  display: inline-block; font-size: var(--text-sm); font-weight: 700;
  letter-spacing: 0.10em; text-transform: uppercase;
  color: var(--teal-deep); margin-bottom: var(--space-3);
}
.section-header p { color: var(--text-secondary); font-size: var(--text-lg); margin: 0; }

/* ---------- Before / after ---------- */
.compare-grid { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-6); }
.compare-card {
  border-radius: var(--radius-lg); padding: var(--space-6);
  border: 1px solid var(--border); background: #fff;
}
.compare-card.bad { background: #fbf7f4; border-color: #ecdcd2; }
.compare-card.good { background: var(--bg-tint); border-color: var(--mint); }
.compare-card h3 { display: flex; align-items: center; gap: 12px; margin-bottom: var(--space-5); }
.compare-card h3 .tag {
  font-family: var(--font-body); font-size: var(--text-xs); font-weight: 700;
  letter-spacing: 0.06em; text-transform: uppercase; padding: 5px 12px; border-radius: var(--radius-pill);
}
.compare-card.bad h3 .tag { background: #f3e1d6; color: #8c4a23; }
.compare-card.good h3 .tag { background: #cdebdd; color: var(--green-deep); }
.compare-item { display: flex; gap: 14px; padding: var(--space-3) 0; }
.compare-item + .compare-item { border-top: 1px solid rgba(20,29,54,0.07); }
.compare-icon {
  flex: none; width: 30px; height: 30px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center; margin-top: 2px;
}
.compare-icon svg { width: 16px; height: 16px; fill: none; stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; }
.bad .compare-icon { background: #f3e1d6; }
.bad .compare-icon svg { stroke: #a4561f; }
.good .compare-icon { background: #cdebdd; }
.good .compare-icon svg { stroke: var(--green-deep); }
.compare-item strong { display: block; color: var(--navy); margin-bottom: 2px; }
.compare-item p { font-size: var(--text-sm); color: var(--text-secondary); margin: 0; }
@media (max-width: 880px) { .compare-grid { grid-template-columns: 1fr; } }

/* ---------- Feature grid ---------- */
.feature-grid {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--space-5);
}
.feature-card {
  background: var(--card); border: 1px solid var(--border); border-radius: var(--radius-lg);
  padding: var(--space-6);
  transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease), border-color 0.25s var(--ease);
}
.feature-card:hover {
  transform: translateY(-6px); box-shadow: var(--shadow-md); border-color: var(--mint);
}
.feature-icon {
  width: 56px; height: 56px; border-radius: 14px;
  display: flex; align-items: center; justify-content: center;
  background: linear-gradient(135deg, var(--bg-tint), var(--bg-tint-blue));
  margin-bottom: var(--space-4);
}
.feature-icon svg { width: 28px; height: 28px; stroke: var(--teal-deep); stroke-width: 1.9; fill: none; stroke-linecap: round; stroke-linejoin: round; }
.feature-card h3 { font-size: var(--text-lg); margin-bottom: var(--space-2); }
.feature-card p { font-size: var(--text-sm); color: var(--text-secondary); margin: 0; }
@media (max-width: 980px) { .feature-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px)  { .feature-grid { grid-template-columns: 1fr; } }

/* ---------- Workflow timeline ---------- */
.workflow { position: relative; display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--space-5); }
.workflow::before {
  content: ""; position: absolute; top: 34px; left: 12%; right: 12%;
  height: 3px; border-radius: 2px;
  background: linear-gradient(90deg, var(--mint), var(--teal), var(--blue));
  opacity: 0.45;
}
.workflow-step { position: relative; text-align: center; padding: 0 var(--space-3); }
.workflow-num {
  position: relative; z-index: 1;
  width: 68px; height: 68px; margin: 0 auto var(--space-4);
  display: flex; align-items: center; justify-content: center;
  border-radius: 50%; background: #fff; border: 3px solid var(--teal);
  font-family: var(--font-display); font-weight: 700; font-size: var(--text-xl); color: var(--navy);
  box-shadow: var(--shadow-sm);
  transition: transform 0.25s var(--ease), border-color 0.25s var(--ease), background-color 0.25s var(--ease);
}
.workflow-step:hover .workflow-num { transform: scale(1.1); border-color: var(--green); background: var(--bg-tint); }
.workflow-step h3 { font-size: var(--text-lg); margin-bottom: var(--space-2); }
.workflow-step p { font-size: var(--text-sm); color: var(--text-secondary); margin: 0; }
@media (max-width: 880px) {
  .workflow { grid-template-columns: 1fr 1fr; }
  .workflow::before { display: none; }
}
@media (max-width: 520px) { .workflow { grid-template-columns: 1fr; } }

/* ---------- Portal spotlight ---------- */
.spotlight {
  display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-10); align-items: center;
}
.spotlight-copy .section-label { margin-bottom: var(--space-3); }
.spotlight-copy h2 { text-align: left; }
.spotlight-list { list-style: none; margin: var(--space-5) 0 var(--space-6); padding: 0; }
.spotlight-list li {
  display: flex; gap: 14px; align-items: flex-start; padding: var(--space-3) 0;
  font-size: var(--text-base); color: var(--text-secondary);
}
.spotlight-list li strong { color: var(--navy); }
.spotlight-list svg {
  flex: none; width: 26px; height: 26px; margin-top: 2px;
  stroke: var(--green-deep); stroke-width: 2.4; fill: none; stroke-linecap: round; stroke-linejoin: round;
  background: var(--bg-tint); border-radius: 50%; padding: 4px;
}
/* portal phone mock */
.portal-mock-wrap { position: relative; display: flex; justify-content: center; }
.portal-mock-wrap::before {
  content: ""; position: absolute; inset: 8% -4% 0;
  background: radial-gradient(closest-side, rgba(168,222,201,0.5), transparent);
  z-index: 0;
}
.phone {
  position: relative; z-index: 1; width: min(330px, 86vw);
  background: var(--navy); border-radius: 38px; padding: 12px;
  box-shadow: var(--shadow-lg);
  transform: rotate(-1.4deg);
}
.phone-screen { background: var(--bg); border-radius: 28px; overflow: hidden; }
.phone-head {
  background: linear-gradient(135deg, var(--navy), var(--navy-soft));
  color: #fff; padding: 22px 20px 18px; text-align: left;
}
.phone-head small { color: var(--text-on-dark-soft); font-size: 0.78rem; font-weight: 500; }
.phone-head strong { display: block; font-family: var(--font-display); font-size: 1.12rem; margin-top: 2px; }
.phone-body { padding: 16px; }
.phone-card {
  background: #fff; border: 1px solid var(--border); border-radius: 14px;
  padding: 13px 14px; margin-bottom: 10px; font-size: 0.85rem;
}
.phone-card strong { display: block; color: var(--navy); font-size: 0.9rem; margin-bottom: 2px; }
.phone-card span { color: var(--text-muted); font-size: 0.78rem; }
.phone-approve {
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
}
.phone-approve .mock-pill { animation: approvePulse 3.2s ease-in-out infinite; }
@keyframes approvePulse {
  0%, 100% { transform: scale(1); }
  12% { transform: scale(1.07); }
  24% { transform: scale(1); }
}
.phone-photos { display: flex; gap: 8px; margin-top: 8px; }
.phone-photos i {
  flex: 1; aspect-ratio: 1; border-radius: 9px;
  background: linear-gradient(135deg, var(--mint), var(--teal));
  opacity: 0.85;
}
.phone-photos i:nth-child(2) { background: linear-gradient(135deg, var(--bg-tint-blue), var(--blue)); }
.phone-photos i:nth-child(3) { background: linear-gradient(135deg, #fdecd3, #e8a657); }
@media (max-width: 880px) {
  .spotlight { grid-template-columns: 1fr; gap: var(--space-8); }
}

/* ---------- Pricing ---------- */
.plans-grid {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--space-5);
  align-items: stretch; margin-bottom: var(--space-6);
}
.plan-card { display: flex; flex-direction: column; }
.plan-card .pricing-includes { margin-bottom: var(--space-5); }
.plan-card .form-submit { margin-top: auto; }
.plan-badge {
  position: absolute; top: 18px; right: 20px;
  background: var(--green-deep); color: #fff;
  font-size: var(--text-xs); font-weight: 700; letter-spacing: 0.04em;
  padding: 6px 14px; border-radius: var(--radius-pill);
}
.calc-wide { width: 100%; }
.calc-results.calc-results-3 { grid-template-columns: repeat(3, 1fr); }
.calc-result-sub {
  font-size: var(--text-xs); color: var(--text-muted); margin-top: 4px;
  font-variant-numeric: tabular-nums;
}
.calc-result { position: relative; transition: border-color 0.2s var(--ease), background-color 0.2s var(--ease), transform 0.2s var(--ease); }
.calc-result.best {
  background: var(--bg-tint); border-color: var(--green); transform: translateY(-3px);
}
.calc-result.best .calc-result-value { color: var(--green-deep); }
.calc-result .best-tag {
  display: none; position: absolute; top: -13px; left: 50%; transform: translateX(-50%);
  background: var(--green-deep); color: #fff; font-size: 0.72rem; font-weight: 700;
  letter-spacing: 0.04em; padding: 3px 12px; border-radius: var(--radius-pill); white-space: nowrap;
}
.calc-result.best .best-tag { display: block; }
@media (max-width: 880px) {
  .plans-grid { grid-template-columns: 1fr; }
  .calc-results.calc-results-3 { grid-template-columns: 1fr; }
}
.pricing-wrap { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-6); align-items: stretch; }
.pricing-card {
  background: var(--card); border: 1px solid var(--border); border-radius: var(--radius-lg);
  padding: var(--space-8); position: relative; overflow: hidden;
}
.pricing-card.main { border: 2px solid var(--teal); box-shadow: var(--shadow-md); }
.pricing-card.main::before {
  content: ""; position: absolute; inset: 0 0 auto; height: 6px;
  background: linear-gradient(90deg, var(--teal), var(--green));
}
.pricing-amount {
  font-family: var(--font-display); font-size: 3.4rem; font-weight: 700; color: var(--navy);
  line-height: 1; margin: var(--space-3) 0 var(--space-1);
}
.pricing-amount small { font-family: var(--font-body); font-size: var(--text-base); font-weight: 500; color: var(--text-secondary); }
.pricing-sub { color: var(--text-secondary); font-size: var(--text-sm); margin-bottom: var(--space-5); }
.tier-table { width: 100%; border-collapse: collapse; margin-bottom: var(--space-5); }
.tier-table th {
  text-align: left; font-size: var(--text-xs); font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.06em; color: var(--text-secondary); padding: 10px 4px;
  border-bottom: 2px solid var(--border);
}
.tier-table th:last-child, .tier-table td:last-child { text-align: right; }
.tier-table td { padding: 13px 4px; border-bottom: 1px solid var(--border); font-size: var(--text-base); }
.tier-table td:last-child { font-weight: 700; color: var(--navy); font-variant-numeric: tabular-nums; }
.tier-table tr:last-child td:last-child { color: var(--green-deep); }
.pricing-includes { list-style: none; margin: 0; padding: 0; }
.pricing-includes li {
  display: flex; align-items: center; gap: 12px; padding: 9px 0;
  font-size: var(--text-base); color: var(--text);
}
.pricing-includes svg {
  flex: none; width: 24px; height: 24px;
  stroke: var(--green-deep); stroke-width: 2.6; fill: none; stroke-linecap: round; stroke-linejoin: round;
  background: var(--bg-tint); border-radius: 50%; padding: 4px;
}
.setup-note {
  margin-top: var(--space-5); padding: var(--space-4);
  background: var(--bg); border: 1px dashed var(--border-strong); border-radius: var(--radius);
  font-size: var(--text-sm); color: var(--text-secondary);
}
.setup-note strong { color: var(--navy); }

/* calculator */
.calc-card { display: flex; flex-direction: column; }
.calc-label { font-weight: 600; color: var(--navy); display: flex; justify-content: space-between; align-items: baseline; margin-bottom: var(--space-3); }
.calc-label output {
  font-family: var(--font-display); font-size: var(--text-2xl); font-weight: 700; color: var(--teal-deep);
  font-variant-numeric: tabular-nums;
}
input[type="range"].calc-slider {
  width: 100%; height: 48px; margin: 0 0 var(--space-5); cursor: pointer;
  -webkit-appearance: none; appearance: none; background: transparent;
}
.calc-slider::-webkit-slider-runnable-track {
  height: 10px; border-radius: 5px;
  background: linear-gradient(90deg, var(--teal) var(--fill, 30%), var(--border) var(--fill, 30%));
}
.calc-slider::-webkit-slider-thumb {
  -webkit-appearance: none; width: 32px; height: 32px; margin-top: -11px;
  border-radius: 50%; background: #fff; border: 4px solid var(--teal);
  box-shadow: var(--shadow-sm); transition: transform 0.15s var(--ease);
}
.calc-slider::-webkit-slider-thumb:hover { transform: scale(1.12); }
.calc-slider::-moz-range-track { height: 10px; border-radius: 5px; background: var(--border); }
.calc-slider::-moz-range-progress { height: 10px; border-radius: 5px; background: var(--teal); }
.calc-slider::-moz-range-thumb {
  width: 26px; height: 26px; border-radius: 50%; background: #fff; border: 4px solid var(--teal);
}
.calc-results { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-4); margin-top: auto; }
.calc-result {
  background: var(--bg); border: 1px solid var(--border); border-radius: var(--radius);
  padding: var(--space-4); text-align: center;
}
.calc-result.highlight { background: var(--bg-tint); border-color: var(--mint); }
.calc-result-label { font-size: var(--text-xs); font-weight: 700; text-transform: uppercase; letter-spacing: 0.06em; color: var(--text-secondary); margin-bottom: 6px; }
.calc-result-value {
  font-family: var(--font-display); font-size: var(--text-2xl); font-weight: 700; color: var(--navy);
  font-variant-numeric: tabular-nums;
}
.calc-result.highlight .calc-result-value { color: var(--green-deep); }
.calc-breakdown { font-size: var(--text-xs); color: var(--text-muted); margin-top: var(--space-4); text-align: center; }
@media (max-width: 880px) { .pricing-wrap { grid-template-columns: 1fr; } }

/* ---------- Testimonials ---------- */
.testimonial-grid { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-6); }
.testimonial-card {
  background: var(--card); border: 1px solid var(--border); border-radius: var(--radius-lg);
  padding: var(--space-6); position: relative;
}
.testimonial-card::before {
  content: "\201C"; position: absolute; top: 6px; left: 22px;
  font-family: var(--font-display); font-size: 5.5rem; line-height: 1;
  color: var(--mint); pointer-events: none;
}
.testimonial-stars { display: flex; gap: 4px; margin: var(--space-4) 0 var(--space-4); }
.testimonial-stars svg { width: 20px; height: 20px; fill: #e8a30e; }
.testimonial-text {
  font-family: var(--font-display); font-size: var(--text-lg); font-style: italic;
  color: var(--navy); line-height: 1.5; margin: 0 0 var(--space-5); border: 0; padding: 0;
}
.testimonial-author { display: flex; align-items: center; gap: 14px; }
.testimonial-avatar {
  width: 50px; height: 50px; border-radius: 50%; flex: none;
  display: flex; align-items: center; justify-content: center;
  background: var(--navy); color: #fff; font-weight: 700;
}
.testimonial-name { font-weight: 700; color: var(--navy); }
.testimonial-role { font-size: var(--text-sm); color: var(--text-secondary); }
@media (max-width: 760px) { .testimonial-grid { grid-template-columns: 1fr; } }

/* ---------- FAQ ---------- */
.faq-list { max-width: 820px; margin: 0 auto; }
.faq-item {
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  margin-bottom: var(--space-3); overflow: hidden;
  transition: border-color 0.2s var(--ease), box-shadow 0.2s var(--ease);
}
.faq-item[open] { border-color: var(--teal); box-shadow: var(--shadow-sm); }
.faq-q {
  display: flex; align-items: center; justify-content: space-between; gap: var(--space-4);
  padding: var(--space-5); cursor: pointer; list-style: none;
  font-weight: 600; font-size: var(--text-base); color: var(--navy);
  min-height: 56px;
}
.faq-q::-webkit-details-marker { display: none; }
.faq-q:hover { color: var(--teal-deep); }
.faq-q .faq-chevron {
  flex: none; width: 34px; height: 34px; border-radius: 50%;
  border: 1.5px solid var(--border-strong); background: var(--bg);
  display: flex; align-items: center; justify-content: center;
  transition: transform 0.25s var(--ease), background-color 0.25s var(--ease), border-color 0.25s var(--ease);
}
.faq-chevron svg { width: 16px; height: 16px; stroke: var(--navy); stroke-width: 2.6; fill: none; stroke-linecap: round; stroke-linejoin: round; }
.faq-item[open] .faq-chevron { transform: rotate(180deg); background: var(--bg-tint); border-color: var(--mint); }
.faq-a { padding: 0 var(--space-5) var(--space-5); color: var(--text-secondary); }
.faq-a p { margin: 0; }

/* ---------- Final CTA ---------- */
.cta-final {
  position: relative; overflow: hidden;
  background: linear-gradient(135deg, var(--navy-deep) 0%, var(--navy) 55%, #1d3a52 100%);
  color: var(--text-on-dark);
  padding: var(--space-12) 0; text-align: center;
}
.cta-final::before {
  content: ""; position: absolute; inset: 0;
  background:
    radial-gradient(640px 360px at 18% 110%, rgba(46,180,132,0.22), transparent 60%),
    radial-gradient(620px 360px at 86% -16%, rgba(31,160,168,0.25), transparent 60%);
}
.cta-final .container { position: relative; }
.cta-final h2 { color: #fff; }
.cta-final p { color: var(--text-on-dark-soft); font-size: var(--text-lg); max-width: 38em; margin: 0 auto var(--space-6); }
.cta-final .cta-dove {
  width: 84px; margin: 0 auto var(--space-5); opacity: 0.95;
  animation: doveFloat 7s ease-in-out infinite;
}
.cta-actions { display: flex; flex-wrap: wrap; gap: var(--space-4); justify-content: center; }

/* ---------- Footer ---------- */
.site-footer { background: var(--navy-deep); color: var(--text-on-dark-soft); padding: var(--space-10) 0 var(--space-6); }
.footer-grid {
  display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: var(--space-8);
  padding-bottom: var(--space-8); border-bottom: 1px solid rgba(255,255,255,0.12);
}
.footer-brand img { height: 46px; margin-bottom: var(--space-4); }
.footer-brand p { font-size: var(--text-sm); max-width: 30em; margin: 0; }
.footer-col-title {
  font-family: var(--font-body); font-size: var(--text-xs); font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.08em; color: #fff; margin-bottom: var(--space-4);
}
.footer-links { display: flex; flex-direction: column; gap: 4px; }
.footer-link {
  display: inline-flex; min-height: 40px; align-items: center;
  color: var(--text-on-dark-soft); text-decoration: none; font-size: var(--text-sm); font-weight: 500;
}
.footer-link:hover { color: #fff; text-decoration: underline; text-underline-offset: 3px; }
.footer-bottom {
  display: flex; flex-wrap: wrap; gap: var(--space-3) var(--space-6);
  justify-content: space-between; align-items: center;
  padding-top: var(--space-6); font-size: var(--text-xs);
}
.footer-bottom a { color: var(--text-on-dark-soft); }
.footer-bottom a:hover { color: #fff; }
@media (max-width: 880px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .footer-grid { grid-template-columns: 1fr; } }

/* ---------- Signup page ---------- */
.signup-hero { padding: calc(var(--header-h) + var(--space-10)) 0 var(--space-8); text-align: center; position: relative; overflow: hidden; }
.signup-hero::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background:
    radial-gradient(760px 420px at 18% -20%, rgba(168, 222, 201, 0.42), transparent 65%),
    radial-gradient(720px 420px at 88% 0%, rgba(45, 156, 219, 0.15), transparent 60%);
}
.signup-grid {
  display: grid; grid-template-columns: 1fr 1.15fr; gap: var(--space-10);
  align-items: start; padding-bottom: var(--space-12);
}
.signup-aside h2 { font-size: var(--text-2xl); }
.next-steps { list-style: none; counter-reset: step; margin: var(--space-6) 0; padding: 0; }
.next-steps li {
  counter-increment: step; display: flex; gap: 16px; padding: var(--space-4) 0;
  border-bottom: 1px solid var(--border);
}
.next-steps li::before {
  content: counter(step);
  flex: none; width: 44px; height: 44px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  background: #fff; border: 2.5px solid var(--teal);
  font-family: var(--font-display); font-weight: 700; font-size: var(--text-lg); color: var(--navy);
}
.next-steps strong { display: block; color: var(--navy); margin-bottom: 2px; }
.next-steps p { font-size: var(--text-sm); color: var(--text-secondary); margin: 0; }
.signup-reassure {
  background: var(--bg-tint); border: 1px solid var(--mint); border-radius: var(--radius-lg);
  padding: var(--space-5); font-size: var(--text-sm); color: var(--text-secondary);
}
.signup-reassure strong { color: var(--green-deep); }

.form-card {
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md); padding: var(--space-8);
}
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-4); }
.form-group { margin-bottom: var(--space-5); }
.form-label {
  display: block; font-weight: 600; font-size: var(--text-sm); color: var(--navy);
  margin-bottom: var(--space-2);
}
.form-label .req { color: #b3261e; }
.form-label .opt { color: var(--text-muted); font-weight: 400; }
.form-input, .form-select, .form-textarea {
  width: 100%; min-height: 54px; padding: 13px 16px;
  font-family: var(--font-body); font-size: var(--text-base); color: var(--text);
  background: var(--bg); border: 1.5px solid var(--border-strong); border-radius: var(--radius);
  transition: border-color 0.15s var(--ease), box-shadow 0.15s var(--ease), background-color 0.15s var(--ease);
}
.form-textarea { min-height: 120px; resize: vertical; }
.form-input:focus, .form-select:focus, .form-textarea:focus {
  outline: none; border-color: var(--teal); background: #fff;
  box-shadow: 0 0 0 4px rgba(31, 160, 168, 0.18);
}
.form-select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='18' viewBox='0 0 24 24' fill='none' stroke='%231E2A4A' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 16px center;
  padding-right: 48px;
}
.form-submit { width: 100%; margin-top: var(--space-2); }
.form-finePrint { font-size: var(--text-xs); color: var(--text-muted); text-align: center; margin: var(--space-4) 0 0; }
.form-success {
  display: none; text-align: center; padding: var(--space-8) var(--space-4);
}
.form-success.show { display: block; }
.form-success .success-ring {
  width: 84px; height: 84px; margin: 0 auto var(--space-5); border-radius: 50%;
  background: var(--bg-tint); border: 3px solid var(--green);
  display: flex; align-items: center; justify-content: center;
  animation: popIn 0.45s var(--ease);
}
.form-success .success-ring svg { width: 40px; height: 40px; stroke: var(--green-deep); stroke-width: 3; fill: none; stroke-linecap: round; stroke-linejoin: round; }
@keyframes popIn { from { transform: scale(0.4); opacity: 0; } to { transform: scale(1); opacity: 1; } }
@media (max-width: 920px) {
  .signup-grid { grid-template-columns: 1fr; }
  .form-row { grid-template-columns: 1fr; gap: 0; }
}

/* ---------- Scroll-reveal animation ---------- */
.reveal {
  opacity: 0; transform: translateY(26px);
  transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
  transition-delay: var(--reveal-delay, 0s);
}
.reveal.visible { opacity: 1; transform: none; }

/* Stat counters */
.stat-row { display: flex; flex-wrap: wrap; gap: var(--space-6) var(--space-10); justify-content: center; margin-top: var(--space-8); }
.stat { text-align: center; min-width: 150px; }
.stat-value {
  font-family: var(--font-display); font-size: var(--text-3xl); font-weight: 700; color: var(--navy);
  font-variant-numeric: tabular-nums;
}
.stat-label { font-size: var(--text-sm); font-weight: 600; color: var(--text-secondary); margin-top: 4px; }

/* ---------- Legal modals (Terms / Privacy) ---------- */
.legal-modal {
  width: min(780px, calc(100vw - 2rem));
  max-height: min(85vh, 900px);
  padding: 0; border: none; border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  background: var(--bg-alt); color: var(--text);
}
.legal-modal::backdrop {
  background: rgba(20, 29, 54, 0.55);
  backdrop-filter: blur(3px);
  -webkit-backdrop-filter: blur(3px);
}
.legal-modal[open] { animation: modalIn 0.28s var(--ease); }
@keyframes modalIn {
  from { opacity: 0; transform: translateY(22px) scale(0.985); }
  to { opacity: 1; transform: none; }
}
.legal-modal-head {
  position: sticky; top: 0; z-index: 1;
  display: flex; align-items: center; justify-content: space-between; gap: var(--space-4);
  background: var(--navy); color: #fff;
  padding: var(--space-4) var(--space-6);
}
.legal-modal-head h2 {
  color: #fff; font-size: var(--text-xl); margin: 0;
}
.legal-modal-close {
  flex: none; width: 48px; height: 48px;
  display: flex; align-items: center; justify-content: center;
  background: rgba(255,255,255,0.12); color: #fff;
  border: 1.5px solid rgba(255,255,255,0.35); border-radius: 50%;
  cursor: pointer; transition: background-color 0.15s var(--ease), transform 0.15s var(--ease);
}
.legal-modal-close:hover { background: rgba(255,255,255,0.24); transform: scale(1.06); }
.legal-modal-close svg { width: 22px; height: 22px; stroke: currentColor; stroke-width: 2.4; fill: none; stroke-linecap: round; }
.legal-modal-body {
  padding: var(--space-6) var(--space-6) var(--space-8);
  overflow-y: auto; max-height: calc(min(85vh, 900px) - 80px);
  font-size: var(--text-base); line-height: 1.7;
}
.legal-modal-body h3 {
  font-size: var(--text-lg); margin: var(--space-6) 0 var(--space-3);
}
.legal-modal-body h3:first-child { margin-top: 0; }
.legal-modal-body p { color: var(--text-secondary); }
.legal-modal-body .legal-updated {
  font-size: var(--text-sm); color: var(--text-muted);
  border-top: 1px solid var(--border); padding-top: var(--space-4); margin-top: var(--space-6);
}
.legal-modal-body address { font-style: normal; color: var(--text-secondary); }

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  .reveal { opacity: 1; transform: none; }
  .mock-case { opacity: 1; transform: none; }
  .mock-bar i { width: var(--w, 60%); }
}
