/* SAFF marketing site — hand-authored, no framework/runtime dependency. */

/* Fonts load from <link> tags in each page's <head> (faster than an @import here). */

:root {
    --cream: #F7F1EA;
    --cream-soft: #EFE0DA;
    --ink: #18211F;
    --ink-soft: rgba(24, 33, 31, 0.66);
    /* 0.45 read as #979b9a on white, 2.81:1 (Lighthouse a11y audit,
       2026-09-23) — under the 4.5:1 WCAG AA floor for this text's size
       everywhere it's used (footer headings, price suffixes, timestamps).
       0.65 clears it on both white (5.1:1) and --cream (4.9:1, the tightest
       case: .directory-count and .demo-caption sit directly on cream) while
       staying visibly fainter than --ink-soft. */
    --ink-faint: rgba(24, 33, 31, 0.65);
    /* Matches the app's --s-accent / --s-accent-h (app/frontend/src/index.css)
       exactly, so app.saffq.com and saffq.com read as the same brand color. */
    --maroon: #6B1530;
    --logo-orange: #FFAD00;
    --logo-orange-deep: #E09600;
    --logo-cyan: #0FD2FF;
    --maroon-deep: #4F0F24;
    --sage: #7EA891;
    --sage-soft: rgba(126, 168, 145, 0.22);
    --white: #FFFFFF;
    --border: rgba(24, 33, 31, 0.12);
    --border-on-maroon: rgba(247, 241, 234, 0.18);
    --radius-lg: 20px;
    --radius-md: 14px;
    --radius-sm: 10px;
    --max-w: 1180px;
    --shadow-card: 0 20px 50px -25px rgba(24, 33, 31, 0.35);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
.sr-only {
    position: absolute;
    width: 1px; height: 1px;
    padding: 0; margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

body {
    margin: 0;
    /* Short pages: keep the footer at the bottom of the window, not mid-screen. */
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    background: var(--cream);
    color: var(--ink);
    font-family: "Plus Jakarta Sans", system-ui, sans-serif;
    font-size: 16px;
    line-height: 1.55;
    -webkit-font-smoothing: antialiased;
}

img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
ul { margin: 0; padding: 0; list-style: none; }
button { font: inherit; cursor: pointer; }

h1, h2, h3 {
    font-family: "Anton", sans-serif;
    font-weight: 400;
    line-height: 1.02;
    letter-spacing: -0.01em;
    margin: 0;
    text-wrap: balance;
}

.mono {
    font-family: "IBM Plex Mono", ui-monospace, monospace;
    font-weight: 700;
    letter-spacing: -0.02em;
}

.eyebrow {
    display: block;
    font-size: 12.5px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.wrap {
    max-width: var(--max-w);
    margin: 0 auto;
    padding: 0 24px;
}

/* ---------- Header ---------- */
.site-header {
    background: var(--white);
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 40;
}
.site-header .wrap {
    height: 68px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}
.brand {
    display: flex;
    align-items: center;
    gap: 9px;
    font-weight: 800;
    font-size: 18px;
    letter-spacing: -0.01em;
}
.brand-mark { width: 30px; height: 30px; flex-shrink: 0; object-fit: contain; }
.brand .q-letter { color: var(--maroon); }

.main-nav { display: flex; align-items: center; gap: 30px; }
.main-nav ul { display: flex; gap: 26px; }
.main-nav :where(a) {
    font-size: 13.5px;
    font-weight: 600;
    color: var(--ink-soft);
    transition: color .15s ease;
}
.main-nav :where(a):hover, .main-nav :where(a)[aria-current="page"] { color: var(--maroon); }

.nav-toggle {
    display: none;
    background: none;
    border: none;
    padding: 8px;
}
.nav-toggle svg { width: 22px; height: 22px; }

/* ---------- Buttons ---------- */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    font-weight: 600;
    padding: 13px 22px;
    border-radius: var(--radius-md);
    border: 1px solid transparent;
    transition: transform .15s ease, opacity .15s ease, background-color .15s ease;
    white-space: nowrap;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: var(--logo-orange); color: var(--ink); }
.btn-primary:hover { background: var(--logo-orange-deep); }
.btn-on-maroon { background: var(--cream); color: var(--maroon-deep); }
.btn-on-maroon:hover { background: #fff; }
.btn-ghost-on-maroon {
    background: rgba(247,241,234,0.12);
    color: var(--cream);
    border-color: var(--border-on-maroon);
}
.btn-ghost-on-maroon:hover { background: rgba(247,241,234,0.2); }
.btn-outline {
    background: transparent;
    color: var(--ink);
    border-color: var(--border);
}
.btn-outline:hover { border-color: var(--ink); }
.btn svg { width: 14px; height: 14px; }

/* ---------- Hero ---------- */
.hero {
    background: linear-gradient(160deg, var(--maroon) 0%, var(--maroon-deep) 100%);
    color: var(--cream);
    position: relative;
    overflow: hidden;
    padding: 76px 0 90px;
}
.hero::before {
    content: "";
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 85% 8%, rgba(255,255,255,0.10), transparent 40%),
        radial-gradient(circle at 8% 95%, rgba(255,255,255,0.06), transparent 35%);
    pointer-events: none;
}
.hero .wrap {
    position: relative;
    display: grid;
    grid-template-columns: 1.05fr 0.95fr;
    gap: 56px;
    align-items: center;
}
.hero-copy .eyebrow { color: rgba(247,241,234,0.72); margin-bottom: 14px; }
.hero h1 { font-size: clamp(2.4rem, 4.6vw, 3.6rem); margin-bottom: 18px; }
.hero-lede { font-size: 17px; color: rgba(247,241,234,0.82); max-width: 460px; margin: 0 0 30px; }
.hero-ctas { display: flex; gap: 12px; flex-wrap: wrap; }

/* Small rounded label (Find a Doctor department tags) */
.pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 11.5px;
    font-weight: 700;
    padding: 5px 11px;
    border-radius: 999px;
    background: var(--sage-soft);
    color: var(--sage);
}
.pill .dot { width: 6px; height: 6px; border-radius: 50%; background: currentColor; }

/* ---------- Sections ---------- */
section { padding: 84px 0; }
section.tight { padding: 64px 0; }
.section-head { max-width: 640px; margin: 0 0 44px; }
.section-head .eyebrow { color: var(--maroon); margin-bottom: 12px; }
.section-head h2 { font-size: clamp(1.9rem, 3.2vw, 2.6rem); margin-bottom: 14px; }
.section-head p { color: var(--ink-soft); font-size: 16px; }
.section-alt { background: var(--white); }

/* Steps strip */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; list-style: none; margin: 0; padding: 0; }
.steps-4 { grid-template-columns: repeat(4, 1fr); }
.step p { color: var(--ink-soft); font-size: 14.5px; line-height: 1.55; margin: 8px 0 0; }
/* Step-by-step walkthrough (healthcare providers page): a slider, 3 steps at a time on
   desktop, 2 on tablets, 1 and a peek on phones. Scroll-snap does the sliding; the
   arrows and dots in main.js only scroll it. */
.walkthrough { margin-top: 56px; }
.walk-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; margin-bottom: 18px; }
.walk-head h2 { font-family: "Plus Jakarta Sans", sans-serif; font-weight: 700; font-size: 24px; margin: 0 0 6px; }
.walk-head p { color: var(--ink-soft); font-size: 15px; margin: 0; max-width: 60ch; }
.walk-nav { display: flex; gap: 8px; flex-shrink: 0; }
.walk-btn { width: 42px; height: 42px; border-radius: 50%; border: 1px solid var(--border); background: var(--white); color: var(--ink); font-size: 18px; cursor: pointer; }
.walk-btn:hover { border-color: var(--maroon); color: var(--maroon); }
.walk-btn:disabled { opacity: .35; cursor: default; }
.walk-track { list-style: none; margin: 0; padding: 4px 2px 12px; display: grid; grid-auto-flow: column; grid-auto-columns: calc((100% - 40px) / 3); gap: 20px; overflow-x: auto; scroll-snap-type: x mandatory; scroll-behavior: smooth; scrollbar-width: none; }
.walk-track::-webkit-scrollbar { display: none; }
.walk-track:focus-visible { outline: 2px solid var(--maroon); outline-offset: 4px; border-radius: var(--radius-lg); }
.walk-slide { scroll-snap-align: start; min-width: 0; }
.walk-shot { display: flex; align-items: center; justify-content: center; height: 330px; padding: 16px; background: var(--cream-soft); border-radius: var(--radius-lg); margin-bottom: 14px; }
.walk-shot img { display: block; max-height: 100%; max-width: 100%; width: auto; height: auto; border-radius: 14px; box-shadow: var(--shadow-card); background: var(--white); }
.walk-shot-wide img { border-radius: 8px; }
.walk-slide h3 { font-family: "Plus Jakarta Sans", sans-serif; font-weight: 700; font-size: 17px; margin: 10px 0 6px; }
.walk-slide p { color: var(--ink-soft); font-size: 14px; line-height: 1.5; margin: 0; }
.walk-tag { display: inline-block; font: 600 11px/1 "IBM Plex Mono", monospace; letter-spacing: .04em; text-transform: uppercase; padding: 5px 9px; border-radius: 999px; }
.walk-tag-patient { color: var(--maroon); background: var(--cream-soft); }
.walk-tag-desk { color: #8a4a12; background: #fdf0e3; }
.walk-dots { display: flex; justify-content: center; gap: 8px; margin-top: 6px; }
.walk-dots button { width: 8px; height: 8px; padding: 0; border: 0; border-radius: 50%; background: var(--border); cursor: pointer; }
.walk-dots button[aria-current="true"] { background: var(--maroon); width: 22px; border-radius: 99px; }
@media (max-width: 900px) { .walk-track { grid-auto-columns: calc((100% - 20px) / 2); } }
@media (max-width: 600px) {
    .walk-head { align-items: flex-start; flex-direction: column; }
    .walk-nav { display: none; }
    .walk-track { grid-auto-columns: 82%; gap: 14px; }
    .walk-shot { height: 300px; }
}
@media (prefers-reduced-motion: reduce) { .walk-track { scroll-behavior: auto; } }
.home-faq { border-top: 0; }
.step {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 26px;
}
.step .step-num { font-family: "IBM Plex Mono", monospace; font-weight: 700; color: var(--maroon); font-size: 13px; margin-bottom: 10px; }
.step h3 { font-family: "Plus Jakarta Sans", sans-serif; font-weight: 700; font-size: 18px; }

/* Problem/solution */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; align-items: start; }
.split-card {
    border-radius: var(--radius-lg);
    padding: 32px;
}
.split-card.problem { background: var(--cream-soft); }
.split-card.solution { background: var(--ink); color: var(--cream); }
.split-card h2 { font-family: "Plus Jakarta Sans", sans-serif; font-weight: 700; font-size: 21px; margin-bottom: 12px; }
.split-card p { margin: 0 0 16px; }
.split-card ul { display: flex; flex-direction: column; gap: 8px; }
.split-card.problem li { color: var(--ink-soft); font-size: 14.5px; }
.split-card.problem li::before { content: "— "; color: var(--maroon); font-weight: 700; }
.split-card.solution p { color: rgba(247,241,234,0.82); }

/* Feature grid */
.feature-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.feature-card {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 26px;
}
.feature-icon {
    width: 42px; height: 42px;
    border-radius: 12px;
    background: var(--sage-soft);
    display: flex; align-items: center; justify-content: center;
    margin-bottom: 16px;
}
.feature-icon svg { width: 22px; height: 22px; stroke: var(--maroon-deep); }
/* Styled by class, not tag: .feature-card is shared with the patients page,
   where these are the first heading after an sr-only h1 (must be h2 there to
   avoid a heading-order skip) but sit under a real h2 on the providers page
   (must stay h3 there, or that page would skip in the other direction). */
.feature-card-title { font-family: "Plus Jakarta Sans", sans-serif; font-weight: 700; font-size: 17px; margin-bottom: 8px; }
.feature-card p { color: var(--ink-soft); font-size: 14.5px; margin: 0; }

/* Feature detail rows (features.html) */
.feature-detail {
    display: grid;
    grid-template-columns: 1fr 0.85fr;
    gap: 48px;
    align-items: center;
    padding: 48px 0;
    border-top: 1px solid var(--border);
}
.feature-detail:first-of-type { border-top: none; }
.feature-detail.reverse { grid-template-columns: 0.85fr 1fr; }
.feature-detail.reverse .feature-visual { order: -1; }
.feature-detail h2 { font-family: "Plus Jakarta Sans", sans-serif; font-weight: 700; font-size: 24px; margin-bottom: 12px; }
.feature-detail p { color: var(--ink-soft); font-size: 15.5px; }
.feature-visual {
    background: var(--cream-soft);
    border-radius: var(--radius-lg);
    padding: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 200px;
}
/* --- Real app screenshots (features page, providers hero) --- */
.shot-phone {
    width: 100%;
    max-width: 250px;
    background: var(--ink);
    border-radius: 30px;
    padding: 8px;
    box-shadow: var(--shadow-card);
}
.shot-phone img { display: block; width: 100%; height: auto; border-radius: 23px; }
.shot-screen { margin: 0; width: 100%; }
.shot-screen img {
    display: block;
    width: 100%;
    height: auto;
    border-radius: var(--radius-md);
    border: 1px solid var(--border);
    background: var(--white);
    box-shadow: var(--shadow-card);
}
.hero-shot { display: flex; justify-content: center; }
@media (max-width: 620px) {
    .feature-visual { padding: 16px; }
}
.hero-shot .shot-phone { max-width: 290px; background: #120b0e; box-shadow: 0 34px 70px -24px rgba(0,0,0,0.55); }

/* TV frame around the waiting-room screenshot */
.mock-tv-frame { width: 100%; max-width: 460px; }
.mock-tv-screen {
    background: var(--ink);
    border-radius: 12px 12px 4px 4px;
    padding: 8px;
    box-shadow: var(--shadow-card);
}
.mock-tv-screen img { display: block; width: 100%; height: auto; border-radius: 6px; }
.mock-tv-stand { width: 64px; height: 8px; background: var(--ink); margin: 0 auto; border-radius: 0 0 4px 4px; opacity: 0.8; }
.mock-tv-base { width: 110px; height: 5px; background: rgba(24,33,31,0.35); margin: 2px auto 0; border-radius: 999px; }


/* Pricing */
.price-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.price-teaser {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    overflow: hidden;
}
.price-teaser-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 18px 24px;
    border-bottom: 1px solid var(--border);
    font-size: 14.5px;
    font-weight: 600;
}
.price-teaser-row:last-child { border-bottom: none; }
.price-teaser-row .mono { font-size: 15px; color: var(--maroon-deep); }
.price-teaser-row .mono small { font-size: 11px; color: var(--ink-faint); font-weight: 500; }
.price-card {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 30px;
    display: flex;
    flex-direction: column;
    cursor: pointer;
    transition: background-color .15s ease, color .15s ease, border-color .15s ease;
}
.price-card.featured { background: var(--ink); color: var(--cream); border-color: var(--ink); }
.price-card:focus-visible { outline: 2px solid var(--maroon); outline-offset: 2px; }
.price-card h2 { font-family: "Plus Jakarta Sans", sans-serif; font-weight: 700; font-size: 19px; margin-bottom: 10px; }
.price-amount { font-family: "IBM Plex Mono", monospace; font-weight: 700; font-size: 26px; margin-bottom: 16px; }
.price-card.featured .price-amount { color: var(--cream); }
/* Was a hardcoded inline color per card before — broke when clicking a card
   toggled which one is .featured (dark bg), since the suffix color didn't
   follow. Now it just follows whichever card is currently selected. */
.price-suffix { font-size: 13px; font-weight: 600; color: var(--ink-faint); }
.price-card.featured .price-suffix { color: rgba(247, 241, 234, 0.6); }
.price-card ul { display: flex; flex-direction: column; gap: 8px; margin-bottom: 24px; flex: 1; }
.price-card li { font-size: 13.5px; color: var(--ink-soft); }
.price-card.featured li { color: rgba(247,241,234,0.75); }
.price-card li::before { content: "✓ "; color: var(--sage); font-weight: 700; }
.price-card.featured .btn-outline { background: var(--cream); color: var(--maroon-deep); border-color: transparent; }
.price-card.featured .btn-outline:hover { background: #fff; }

/* CTA band */
.cta-band {
    background: var(--maroon);
    color: var(--cream);
    border-radius: var(--radius-lg);
    padding: 56px;
    text-align: center;
}
.cta-band h2 { font-size: clamp(1.8rem, 3vw, 2.4rem); margin-bottom: 14px; }
.cta-band p { color: rgba(247,241,234,0.8); max-width: 480px; margin: 0 auto 26px; }
.cta-actions { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 14px 20px; }
.cta-alt { color: rgba(247,241,234,0.8); font-size: 15px; }
.cta-alt a { color: var(--cream); font-weight: 600; text-decoration: underline; text-underline-offset: 3px; }

/* Legal pages */
.legal-notice {
    background: var(--cream-soft);
    border: 1px solid rgba(122,38,53,0.25);
    border-radius: var(--radius-md);
    padding: 16px 20px;
    color: var(--maroon-deep);
    font-weight: 600;
    font-size: 14px;
    margin-bottom: 30px;
}
.legal-body h1 { font-size: clamp(2.1rem, 4vw, 2.8rem); margin-bottom: 30px; }
.legal-body h2 {
    font-family: "Plus Jakarta Sans", sans-serif;
    font-weight: 700;
    font-size: 19px;
    margin: 34px 0 10px;
}
.legal-body p { color: var(--ink-soft); font-size: 15px; margin: 0 0 14px; }
.legal-body ul { color: var(--ink-soft); font-size: 15px; margin: 0 0 14px; padding-left: 20px; }
.legal-body li { margin-bottom: 6px; }
.legal-body { max-width: 760px; }

.legal-body h2.doc-title {
    font-family: "Anton", sans-serif;
    font-weight: 400;
    font-size: clamp(1.7rem, 3.2vw, 2.3rem);
    margin: 70px 0 6px;
    scroll-margin-top: 90px;
}
.legal-body h2.doc-title:first-of-type { margin-top: 0; }
.doc-meta { font-family: "IBM Plex Mono", monospace; font-size: 12.5px; color: var(--ink-faint); margin-bottom: 26px; }
.back-to-list { display: inline-block; font-size: 13px; font-weight: 600; color: var(--maroon-deep); margin-top: 8px; }

/* Only the selected legal doc shows below the list — plain CSS :target, no
   JS needed. Clicking a doc-list-item link (href="#eula" etc) navigates the
   hash and this toggles visibility; "back to all documents" clears it via
   href="#legal-docs", which matches no .legal-doc so all hide again. */
.legal-doc { display: none; }
.legal-doc:target { display: block; }

.doc-list {
    max-width: 760px;
    margin: 0 auto;
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    overflow: hidden;
}
.doc-list-item {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 24px;
    padding: 26px 30px;
    border-bottom: 1px solid var(--border);
    text-decoration: none;
    color: inherit;
    transition: background-color .15s ease;
    scroll-margin-top: 90px;
}
.doc-list-item:last-child { border-bottom: none; }
.doc-list-item:hover { background: var(--cream-soft); }
.doc-list-item-head { display: flex; align-items: baseline; gap: 12px; margin-bottom: 8px; }
.doc-num { font-family: "IBM Plex Mono", monospace; color: var(--maroon); font-size: 13px; font-weight: 600; }
.doc-list-item h3 { font-family: "Plus Jakarta Sans", sans-serif; font-weight: 700; font-size: 18px; }
.doc-list-item p { color: var(--ink-soft); font-size: 14px; margin: 0; max-width: 480px; }
.doc-date { font-family: "IBM Plex Mono", monospace; font-size: 12.5px; color: var(--ink-faint); white-space: nowrap; margin-top: 2px; }
@media (max-width: 640px) {
    .doc-list-item { flex-direction: column; }
    .doc-date { margin-top: 0; }
}

/* About */
.about-lede { font-size: clamp(1.6rem, 3vw, 2.1rem); font-family: "Anton", sans-serif; max-width: 780px; margin-bottom: 20px; }
.about-body { color: var(--ink-soft); font-size: 16.5px; max-width: 720px; }
.team-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; margin-top: 44px; }
.team-card { text-align: center; }
.team-avatar {
    width: 84px; height: 84px;
    border-radius: 50%;
    background: var(--cream-soft);
    margin: 0 auto 14px;
    display: flex; align-items: center; justify-content: center;
}
.team-avatar svg { width: 34px; height: 34px; stroke: var(--maroon); }
.team-card strong { display: block; font-size: 14px; margin-bottom: 3px; }
.team-card span { font-size: 12.5px; color: var(--ink-faint); }

/* Contact */
.contact-grid { display: grid; grid-template-columns: 0.9fr 1.1fr; gap: 48px; align-items: start; }
.contact-info h1 { font-size: clamp(2.1rem, 4vw, 2.9rem); margin-bottom: 16px; }
.contact-info p { color: var(--ink-soft); font-size: 15.5px; margin-bottom: 20px; }
.contact-email {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-weight: 700;
    color: var(--maroon-deep);
    font-size: 14.5px;
}
.contact-methods { margin-top: 8px; padding-top: 18px; border-top: 1px solid var(--border); }
.contact-methods p { font-size: 15.5px; color: var(--ink-soft); margin-bottom: 10px; }
.contact-methods p:last-child { margin-bottom: 0; }
.form-card {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 30px;
}
.form-card h2 { font-family: "Plus Jakarta Sans", sans-serif; font-weight: 700; font-size: 18px; margin-bottom: 20px; }
.field { margin-bottom: 16px; }
.field label { display: block; font-size: 12.5px; font-weight: 700; margin-bottom: 6px; color: var(--ink-soft); }
.field input, .field textarea {
    width: 100%;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 11px 14px;
    font: inherit;
    font-size: 14px;
    background: var(--cream);
    color: var(--ink);
}
.field input:focus, .field textarea:focus {
    outline: 2px solid var(--maroon);
    outline-offset: 1px;
}
.field textarea { min-height: 100px; resize: vertical; }
.form-note { font-size: 12.5px; color: var(--ink-faint); margin-top: 14px; }
/* Contact form spam trap: off-screen for people, still in the form for bots. */
.hp-field { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

/* Find a Doctor directory */
.directory-toolbar { display: flex; gap: 12px; margin-bottom: 10px; }
.directory-toolbar input[type="search"] {
    flex: 1;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 11px 14px;
    font: inherit;
    font-size: 14px;
    background: var(--white);
    color: var(--ink);
}
.directory-toolbar select {
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 11px 14px;
    font: inherit;
    font-size: 14px;
    background: var(--white);
    color: var(--ink);
}
.directory-toolbar input[type="search"]:focus, .directory-toolbar select:focus {
    outline: 2px solid var(--maroon);
    outline-offset: 1px;
}
.directory-count { font-size: 12.5px; color: var(--ink-faint); margin-bottom: 24px; }
.directory-results { display: flex; flex-direction: column; gap: 16px; }
.directory-empty {
    background: var(--cream-soft);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 24px;
    text-align: center;
    color: var(--ink-soft);
    font-size: 14.5px;
}
/* Find a Doctor: placeholder cards while the directory loads, and "Try again" */
.clinic-card-placeholder { display: flex; flex-direction: column; gap: 10px; }
.clinic-card-placeholder .ph { display: block; height: 12px; border-radius: 6px; background: var(--cream-soft); animation: ph-pulse 1.4s ease-in-out infinite; }
.clinic-card-placeholder .ph-title { height: 18px; width: 45%; }
.clinic-card-placeholder .ph-line { width: 80%; }
.clinic-card-placeholder .ph-line.short { width: 55%; }
@keyframes ph-pulse { 50% { opacity: 0.5; } }
@media (prefers-reduced-motion: reduce) { .clinic-card-placeholder .ph { animation: none; } }
.directory-retry { background: none; border: 0; padding: 0; font: inherit; font-weight: 700; color: var(--maroon); text-decoration: underline; cursor: pointer; }

.clinic-card {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 24px 26px;
}
.clinic-card-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 16px;
}
.clinic-card-head h3 { font-family: "Plus Jakarta Sans", sans-serif; font-weight: 700; font-size: 19px; margin-bottom: 4px; }
.demo-badge {
    display: inline-block;
    font-family: "Plus Jakarta Sans", sans-serif;
    font-size: 10.5px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--logo-orange-deep);
    background: rgba(255, 173, 0, 0.16);
    border-radius: 999px;
    padding: 3px 9px;
    vertical-align: middle;
}
.clinic-meta { font-size: 13.5px; color: var(--ink-soft); margin: 0; }
.doctor-list { display: flex; flex-direction: column; gap: 4px; border-top: 1px solid var(--border); padding-top: 14px; }
.doctor-row {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 8px 0;
    flex-wrap: wrap;
}
.doctor-name { font-size: 14px; font-weight: 600; flex: 1; min-width: 140px; }
.doctor-timing { font-size: 12.5px; color: var(--ink-faint); }
.doctor-timing.is-missing { font-family: inherit; font-style: italic; }

/* Audience gate (root landing) */
.gate {
    min-height: 100vh;
    background: linear-gradient(160deg, var(--maroon) 0%, var(--maroon-deep) 100%);
    color: var(--cream);
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px 24px 16vh;
    text-align: center;
}
.gate::before {
    content: "";
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 85% 8%, rgba(255,255,255,0.10), transparent 40%),
        radial-gradient(circle at 8% 95%, rgba(255,255,255,0.06), transparent 35%);
    pointer-events: none;
}
@keyframes gate-rise {
    from { opacity: 0; transform: translateY(14px); }
    to { opacity: 1; transform: translateY(0); }
}
.gate-brand {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    font-weight: 800;
    font-size: 26px;
    color: var(--cream);
    margin-bottom: 20px;
    animation: gate-rise .6s ease both;
}
.gate-brand .brand-mark { width: 42px; height: 42px; display: block; }
.gate-brand span { line-height: 1; }
.gate-head {
    position: relative;
    max-width: 560px;
    margin-bottom: 40px;
    animation: gate-rise .6s ease .08s both;
}
.gate-head .eyebrow { color: rgba(247,241,234,0.72); margin-bottom: 12px; }
.gate-head h1 { font-size: clamp(1.9rem, 3.6vw, 2.7rem); margin-bottom: 12px; }
.gate-head p { color: rgba(247,241,234,0.8); font-size: 15.5px; }
.gate-options {
    position: relative;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    max-width: 680px;
    width: 100%;
}
.gate-option {
    background: rgba(247,241,234,0.08);
    border: 1px solid var(--border-on-maroon);
    border-radius: var(--radius-lg);
    padding: 32px 26px;
    text-align: left;
    color: inherit;
    text-decoration: none;
    transition: background-color .15s ease, transform .15s ease, box-shadow .15s ease;
    backdrop-filter: blur(2px);
    animation: gate-rise .6s ease both;
}
.gate-options .gate-option:nth-child(2) { animation-delay: .12s; }
.gate-option:hover {
    background: rgba(247,241,234,0.14);
    transform: translateY(-3px);
    box-shadow: 0 16px 34px -18px rgba(0,0,0,0.45);
}
.gate-option:hover .gate-option-icon { transform: scale(1.08); }
.gate-option:hover .gate-option-cta svg,
.gate-option:hover .gate-option-cta { transform: translateX(3px); }
.gate-option-icon {
    width: 44px; height: 44px;
    border-radius: 12px;
    background: rgba(247,241,234,0.14);
    display: flex; align-items: center; justify-content: center;
    margin-bottom: 18px;
    transition: transform .2s ease;
}
.gate-option-icon svg { width: 24px; height: 24px; stroke: var(--cream); }
.gate-option-patient .gate-option-icon { background: var(--sage-soft); }
.gate-option-patient .gate-option-icon svg { stroke: var(--sage); }
.gate-option-provider .gate-option-icon { background: rgba(255,173,0,0.18); }
.gate-option-provider .gate-option-icon svg { stroke: var(--logo-orange); }
.gate-option h2 { font-family: "Plus Jakarta Sans", sans-serif; font-weight: 700; font-size: 18px; margin-bottom: 8px; }
.gate-option p { font-size: 13.5px; color: rgba(247,241,234,0.75); margin: 0 0 16px; }
.gate-option .gate-option-cta { font-size: 13px; font-weight: 700; color: var(--cream); display: inline-flex; align-items: center; gap: 6px; transition: transform .2s ease; }
@media (max-width: 620px) {
    .gate-options { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) {
    .gate-brand, .gate-head, .gate-option { animation: none; }
}

/* Patient hub service grid */
.patient-services {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    max-width: 760px;
    margin: 0 auto;
}
@media (max-width: 620px) {
    .patient-services { grid-template-columns: 1fr; }
}

/* Footer */
.site-footer { background: var(--white); border-top: 1px solid var(--border); padding: 54px 0 28px; margin-top: auto; }
.footer-top {
    display: grid;
    grid-template-columns: 1.4fr 1fr 1fr 1fr;
    gap: 40px;
    padding-bottom: 36px;
}
.footer-brand .brand { margin-bottom: 12px; }
.footer-brand p { color: var(--ink-soft); font-size: 14px; max-width: 300px; }
/* h2, not h4: whatever level the page's own content headings end on, a
   footer nav label one level below the page's own h1 never skips a level
   (Lighthouse heading-order audit, 2026-09-23) - h4 did on pages with no h2/h3
   of their own before the footer (about, faq, 404, find-a-doctor, patients). */
.footer-col h2 { font-size: 12.5px; font-weight: 700; letter-spacing: 0.05em; text-transform: uppercase; color: var(--ink-faint); margin-bottom: 14px; }
.footer-col ul { display: flex; flex-direction: column; gap: 10px; }
.footer-col a { font-size: 14px; color: var(--ink-soft); }
.footer-col a:hover { color: var(--maroon); }
/* A heading that is also a link ("Legal") must look like the other column headings. */
.footer-col h2 a { font-size: inherit; color: inherit; }
.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 24px;
    border-top: 1px solid var(--border);
    font-size: 12.5px;
    color: var(--ink-faint);
    flex-wrap: wrap;
    gap: 10px;
}

/* ---------- Floating WhatsApp button (clinic pages) ---------- */
/* WhatsApp's dark teal: white on it is 7.7:1. */
.wa-float {
    position: fixed; right: 16px; bottom: max(16px, env(safe-area-inset-bottom)); z-index: 900;
    display: inline-flex; align-items: center; gap: 8px; min-height: 48px; padding: 0 18px 0 14px;
    background: #075E54; color: var(--white); border-radius: 999px; box-shadow: var(--shadow-card);
    font-weight: 700; font-size: 14.5px; text-decoration: none;
}
.wa-float svg { width: 22px; height: 22px; flex: none; }
.wa-float:hover { background: #054A42; }
.wa-float:focus-visible { outline: 3px solid var(--maroon); outline-offset: 3px; }
body:has(.wa-float) .site-footer { padding-bottom: 96px; }
@media (max-width: 600px) {
    .steps-4 { grid-template-columns: 1fr; }
    .wa-float { width: 56px; height: 56px; padding: 0; justify-content: center; }
    .wa-float svg { width: 26px; height: 26px; }
    .wa-float-label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
}
@media print { .wa-float { display: none; } }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
    .hero .wrap { grid-template-columns: 1fr; }
    .split, .feature-grid, .steps, .price-grid, .contact-grid, .team-grid, .footer-top {
        grid-template-columns: 1fr;
    }
    .steps-4 { grid-template-columns: repeat(2, 1fr); }
    .team-grid { grid-template-columns: repeat(2, 1fr); }
    .feature-detail, .feature-detail.reverse { grid-template-columns: 1fr; }
    .feature-detail.reverse .feature-visual { order: 0; }
    .cta-band { padding: 40px 24px; }
    .directory-toolbar { flex-direction: column; }
    .clinic-card-head { flex-direction: column; }
}

/* The desktop nav (brand + 6 links + CTA) needs ~760px with zero spare room;
   collapse to the menu button at 800px so it never gets squeezed into the
   screen edge, even before the web font has loaded. */
@media (max-width: 800px) {
    .main-nav ul, .main-nav .header-cta { display: none; }
    .main-nav.open {
        display: flex;
        flex-direction: column;
        align-items: stretch;
        position: absolute;
        top: 68px; left: 0; right: 0;
        background: var(--white);
        padding: 20px 24px 24px;
        border-bottom: 1px solid var(--border);
        gap: 16px;
    }
    .main-nav.open ul {
        display: flex;
        flex-direction: column;
        gap: 16px;
    }
    .main-nav.open .header-cta {
        display: flex;
        justify-content: center;
    }
    .nav-toggle { display: block; }
}

@media (max-width: 680px) {
    section { padding: 56px 0; }
    .hero { padding: 48px 0 60px; }
}

/* ---------- FAQ page (/faq) ---------- */
.faq-page h1 { font-size: clamp(34px, 5vw, 52px); margin: 10px 0 12px; }
.faq-lead { color: var(--ink-soft); font-size: 17px; line-height: 1.6; margin: 0; }
.faq-formula {
    max-width: 720px; margin: 0 0 28px; padding: 18px 22px;
    border-radius: var(--radius-md); background: var(--maroon); color: var(--cream);
    display: flex; flex-direction: column; gap: 6px;
}
.faq-formula span { font-size: 12px; text-transform: uppercase; letter-spacing: .08em; opacity: .75; }
.faq-formula strong { font-family: "IBM Plex Mono", monospace; font-weight: 600; font-size: 15px; line-height: 1.5; }
.faq { max-width: 720px; border-top: 1px solid var(--border); }
.faq details { border-bottom: 1px solid var(--border); padding: 4px 0; }
.faq summary {
    cursor: pointer; list-style: none; padding: 16px 32px 16px 0; position: relative;
    font-weight: 700; font-size: 17px; color: var(--ink);
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
    content: "+"; position: absolute; right: 4px; top: 12px;
    font-size: 24px; font-weight: 400; color: var(--maroon);
}
.faq details[open] summary::after { content: "\2013"; }
.faq summary:focus-visible { outline: 2px solid var(--maroon); outline-offset: 2px; border-radius: 4px; }
.faq details p, .faq details ul { color: var(--ink-soft); line-height: 1.65; margin: 0 0 14px; }
.faq details ul { padding-left: 20px; }
.faq details li { margin: 4px 0; }
.faq details .faq-formula { margin: 2px 0 14px; }
.faq-foot { max-width: 720px; margin-top: 28px; color: var(--ink-soft); }
.faq-foot a { color: var(--maroon); font-weight: 600; }

/* Inline "read more" link inside cards */
.text-link { color: var(--maroon); font-weight: 600; white-space: nowrap; }
.text-link:hover { text-decoration: underline; }

/* Patient-side footer: brand + Help + Legal (no provider "Pages" column).
   Kept in the stylesheet, not inline, so it still stacks on phones. */
.footer-top--patient { grid-template-columns: 1.4fr 1fr 1fr; }
@media (max-width: 900px) {
    .footer-top--patient { grid-template-columns: 1fr; }
}

/* Sample panels on the features page (drawn in HTML, marked as examples) */
.mock-card { width: 100%; max-width: 420px; background: var(--white); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 22px; }
.mock-label { font-size: 12px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--ink-soft); margin-bottom: 14px; }
.mock-tiles { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.mock-tiles div { background: var(--sage-soft); border-radius: 12px; padding: 14px; }
.mock-tiles span { display: block; font-size: 12.5px; color: var(--ink-soft); margin-bottom: 4px; }
.mock-tiles b { font-size: 22px; color: var(--maroon-deep); }
.mock-bubble { background: var(--sage-soft); border-radius: 14px 14px 14px 4px; padding: 12px 14px; font-size: 15px; margin-bottom: 10px; max-width: 85%; }
.mock-replies { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.mock-replies span { text-align: center; border: 1px solid var(--border); border-radius: 10px; padding: 9px 4px; font-size: 14px; font-weight: 600; color: var(--maroon-deep); }
.mock-listing { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; }
.mock-listing strong { display: block; font-size: 16px; margin-bottom: 4px; }
.mock-listing span { font-size: 13.5px; color: var(--ink-soft); }
.mock-listing em { font-style: normal; font-weight: 700; font-size: 14px; background: var(--maroon); color: #fff; border-radius: 10px; padding: 9px 14px; }

/* More sample panels on the features page */
.mock-downloads { display: flex; gap: 6px; margin: -6px 0 12px; }
.mock-downloads span { font-size: 12px; font-weight: 700; color: var(--maroon-deep); border: 1px solid var(--border); border-radius: 8px; padding: 3px 10px; }
.mock-row { display: flex; align-items: center; gap: 12px; padding: 10px 0; border-top: 1px solid var(--border); font-size: 14.5px; }
.mock-row:first-of-type { border-top: 0; }
.mock-row strong { min-width: 42px; }
.mock-row span { flex: 1; color: var(--ink-soft); }
.mock-pill { font-style: normal; font-weight: 700; font-size: 13px; border-radius: 999px; padding: 4px 12px; white-space: nowrap; }
.mock-pill-paid { background: rgba(126, 168, 145, 0.28); color: #1f4d36; }
.mock-pill-due { background: #FBE9C8; color: #7A4B00; }
.mock-strip { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 12px; }
.mock-num { width: 42px; height: 42px; display: grid; place-items: center; border-radius: 10px; border: 1px solid var(--border); font-weight: 700; font-size: 16px; }
.mock-num-kept { background: var(--maroon); color: #fff; border-color: var(--maroon); }
.mock-legend { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; font-size: 13px; color: var(--ink-soft); }
.mock-key { width: 14px; height: 14px; border-radius: 4px; border: 1px solid var(--border); display: inline-block; }
.mock-key.mock-num-kept { border-color: var(--maroon); }
