/* ==========================================================================
   ClientPulse — landing page styles
   Design tokens live in :root so the whole look can be retuned in one place.
   ========================================================================== */

:root {
  /* Palette */
  --bg:            #ffffff;
  --bg-tint:       #f8fafc;
  --bg-tint-2:     #f1f5f9;
  --ink:           #0f172a;   /* near-black headings */
  --body:          #475569;   /* muted grey body text */
  --muted:         #64748b;
  --border:        #e2e8f0;
  --accent:        #2563eb;
  --accent-hover:  #1d4ed8;
  --accent-soft:   #eff6ff;
  --good:          #16a34a;
  --warn:          #d97706;
  --bad:           #dc2626;

  /* Type */
  --font: system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;

  /* Shape */
  --radius:    12px;
  --radius-sm: 8px;
  --radius-pill: 999px;
  --shadow-sm: 0 1px 3px rgba(15, 23, 42, .08);
  --shadow-md: 0 8px 24px rgba(15, 23, 42, .10);
  --shadow-lg: 0 20px 50px rgba(15, 23, 42, .14);

  /* Layout */
  --maxw: 1080px;
  --maxw-narrow: 720px;
  --section-y: clamp(3.5rem, 8vw, 6rem);
}

/* ---------- Reset-ish ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font);
  color: var(--body);
  background: var(--bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3, h4, h5 { color: var(--ink); line-height: 1.15; margin: 0 0 .5em; letter-spacing: -.01em; }
p { margin: 0 0 1rem; }
a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-hover); }
img, svg { max-width: 100%; }
ul { margin: 0; padding: 0; list-style: none; }

.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;
}

/* ---------- Layout helpers ---------- */
.container { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 1.25rem; }
.container--narrow { max-width: var(--maxw-narrow); }
.muted { color: var(--muted); }

.eyebrow {
  text-transform: uppercase;
  letter-spacing: .14em;
  font-size: .72rem;
  font-weight: 700;
  color: var(--accent);
  margin: 0 0 .75rem;
}
.eyebrow--light { color: rgba(255,255,255,.8); }

.section-head { max-width: 640px; margin: 0 auto clamp(2rem, 5vw, 3rem); text-align: center; }
.section-head h2 { font-size: clamp(1.5rem, 3.5vw, 2.1rem); }
.section-head__sub { color: var(--muted); margin: 0; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  font-weight: 600; font-size: .95rem; line-height: 1;
  padding: .8rem 1.3rem; border-radius: var(--radius-pill);
  border: 1px solid transparent; cursor: pointer; transition: all .15s ease;
  white-space: nowrap;
}
.btn--primary { background: var(--accent); color: #fff; }
.btn--primary:hover { background: var(--accent-hover); color: #fff; box-shadow: var(--shadow-md); }
.btn--ghost { background: #fff; color: var(--ink); border-color: var(--border); }
.btn--ghost:hover { border-color: var(--accent); color: var(--accent); }
.btn--lg { padding: 1rem 1.7rem; font-size: 1rem; }
.btn--sm { padding: .55rem 1rem; font-size: .85rem; }
.btn--block { width: 100%; }

/* ---------- Header / nav ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255,255,255,.85);
  backdrop-filter: saturate(180%) blur(10px);
  border-bottom: 1px solid var(--border);
}
.nav { display: flex; align-items: center; justify-content: space-between; height: 64px; }
.brand { display: inline-flex; align-items: center; gap: .55rem; color: var(--ink); font-weight: 700; }
.brand__name { font-size: 1.05rem; letter-spacing: -.02em; }
.nav__menu { display: flex; align-items: center; gap: 1.6rem; }
.nav__menu a { color: var(--body); font-weight: 500; font-size: .95rem; }
.nav__menu a:hover { color: var(--ink); }
.nav__menu a.btn { color: #fff; }
.nav__toggle {
  display: none; flex-direction: column; gap: 5px; background: none; border: 0;
  cursor: pointer; padding: 8px;
}
.nav__toggle span { width: 22px; height: 2px; background: var(--ink); border-radius: 2px; transition: .2s; }
.nav__toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav__toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav__toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Hero ---------- */
.hero { padding: clamp(3rem, 7vw, 5.5rem) 0 clamp(2rem, 5vw, 3rem); background: radial-gradient(60% 60% at 50% 0%, var(--accent-soft) 0%, #fff 70%); }
.hero__inner { text-align: center; max-width: 760px; margin: 0 auto; }
.hero__title { font-size: clamp(2.1rem, 6vw, 3.4rem); font-weight: 800; letter-spacing: -.03em; }
.hero__title em { color: var(--accent); font-style: italic; }
.hero__sub { font-size: clamp(1.05rem, 2.5vw, 1.25rem); color: var(--body); max-width: 620px; margin: 1rem auto 1.75rem; }
.hero__cta { display: flex; gap: .75rem; justify-content: center; flex-wrap: wrap; }
.hero__note { margin-top: 1rem; font-size: .85rem; color: var(--muted); }

.pain-quote {
  position: relative; margin: 2.75rem auto 0; max-width: 560px;
  background: var(--bg-tint); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 1.4rem 1.6rem; text-align: left; color: var(--ink); font-size: 1.02rem;
  box-shadow: var(--shadow-sm);
}
.pain-quote__mark { position: absolute; top: -.2rem; left: .6rem; font-size: 3rem; color: var(--border); line-height: 1; }
.pain-quote cite { display: block; margin-top: .6rem; font-style: normal; font-size: .85rem; color: var(--muted); }

/* ---------- Sample report showcase ---------- */
.report-showcase { padding: 0 0 var(--section-y); }
.report-card {
  max-width: 640px; margin: 0 auto; background: #fff;
  border: 1px solid var(--border); border-radius: 16px; box-shadow: var(--shadow-lg);
  padding: clamp(1.25rem, 3vw, 2rem); transform: translateY(-1.5rem);
}
.report-card__head { display: flex; justify-content: space-between; align-items: flex-start; gap: 1rem; padding-bottom: 1rem; border-bottom: 2px solid var(--accent); }
.report-card__logo { font-weight: 800; color: var(--accent); letter-spacing: -.02em; }
.report-card__doc { display: block; font-size: .8rem; color: var(--muted); text-transform: uppercase; letter-spacing: .1em; margin-top: .25rem; }
.report-card__meta { text-align: right; font-weight: 600; color: var(--ink); }
.report-card__meta .muted { font-weight: 400; font-size: .85rem; }

.report-card__stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: .5rem; margin: 1.25rem 0; }
.stat { text-align: center; background: var(--bg-tint); border-radius: var(--radius-sm); padding: .9rem .5rem; }
.stat__num { display: block; font-size: 1.8rem; font-weight: 800; color: var(--ink); }
.stat__num--good { color: var(--good); }
.stat__label { font-size: .75rem; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }

.doc-badge {
  display: inline-block; vertical-align: middle; margin-left: .4rem;
  font-size: .62rem; font-weight: 800; letter-spacing: .08em;
  color: var(--accent); background: var(--accent-soft);
  border: 1px solid #dbeafe; border-radius: 4px; padding: .12rem .35rem;
}
.report-card__summary {
  margin: 1.1rem 0; padding: .9rem 1rem;
  background: var(--accent-soft); border-left: 3px solid var(--accent);
  border-radius: var(--radius-sm); font-size: .9rem; color: var(--ink);
}
.report-card__summary-label {
  display: block; font-size: .68rem; font-weight: 800; letter-spacing: .1em;
  text-transform: uppercase; color: var(--accent); margin-bottom: .3rem;
}
.report-card__section { margin-top: 1.25rem; }
.report-card__section h4 { font-size: .8rem; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); margin-bottom: .5rem; }
.log li { display: grid; grid-template-columns: 1fr auto auto; gap: .75rem; padding: .5rem 0; border-bottom: 1px solid var(--border); font-size: .9rem; align-items: center; }
.log li:last-child { border-bottom: 0; }
.log--changes li { grid-template-columns: minmax(6rem, auto) 1fr; }
.log--changes li > span:first-child { font-weight: 600; color: var(--ink); }
.report-card__foot { margin-top: 1.25rem; padding-top: 1rem; border-top: 1px solid var(--border); font-size: .8rem; text-align: center; }
.report-showcase__caption { text-align: center; max-width: 500px; margin: .5rem auto 0; color: var(--muted); }

/* ---------- Features ---------- */
.features { padding: var(--section-y) 0; background: var(--bg-tint); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.feature-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.25rem; }
.card { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow-sm); padding: 1.5rem; }
.feature__kicker { text-transform: uppercase; letter-spacing: .12em; font-size: .7rem; font-weight: 700; color: var(--accent); margin: 0 0 .6rem; }
.feature h3 { font-size: 1.1rem; }
.feature p { margin: 0; font-size: .95rem; }
.feature--muted { background: var(--bg-tint-2); box-shadow: none; }

/* ---------- Report anatomy ---------- */
.anatomy { padding: var(--section-y) 0; }
.anatomy__inner { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(2rem, 5vw, 4rem); align-items: center; }
.anatomy__copy h2 { font-size: clamp(1.5rem, 3.5vw, 2.1rem); }
.checklist li { position: relative; padding-left: 1.9rem; margin-bottom: .7rem; color: var(--body); }
.checklist li::before {
  content: "✓"; position: absolute; left: 0; top: 0;
  width: 1.35rem; height: 1.35rem; display: grid; place-items: center;
  background: var(--accent-soft); color: var(--accent); border-radius: 50%;
  font-size: .75rem; font-weight: 700;
}
.anatomy__visual { display: flex; justify-content: center; }
.anatomy__page {
  width: 100%; max-width: 320px; aspect-ratio: 3/4; background: #fff;
  border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow-md);
  padding: 1.5rem; transform: rotate(-2deg); transition: transform .3s ease;
}
.anatomy__page:hover { transform: rotate(0deg); }
.anatomy__bar { height: 10px; border-radius: 4px; background: var(--border); margin-bottom: 1.25rem; }
.anatomy__bar--brand { background: var(--accent); width: 55%; }
.anatomy__row { display: grid; grid-template-columns: repeat(3,1fr); gap: .5rem; margin-bottom: 1.25rem; }
.anatomy__row span { height: 42px; background: var(--bg-tint-2); border-radius: 6px; }
.anatomy__lines div { height: 9px; background: var(--bg-tint-2); border-radius: 4px; margin-bottom: .7rem; }
.anatomy__lines div.short { width: 60%; }

/* ---------- Comparison ---------- */
.comparison { padding: var(--section-y) 0; background: var(--bg-tint); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.table-wrap { overflow-x: auto; max-width: 780px; margin: 0 auto; }
.cmp { width: 100%; border-collapse: collapse; background: #fff; border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; }
.cmp th, .cmp td { padding: .9rem 1.1rem; text-align: left; border-bottom: 1px solid var(--border); font-size: .95rem; }
.cmp thead th { background: var(--bg-tint-2); color: var(--ink); font-weight: 700; }
.cmp__us { background: var(--accent-soft) !important; color: var(--accent) !important; }
.cmp tbody tr:last-child td { border-bottom: 0; }
.cmp td.yes { color: var(--good); font-weight: 600; }
.cmp td.no { color: var(--bad); font-weight: 600; }
.cmp td.partial { color: var(--warn); font-weight: 600; }

/* ---------- Pricing ---------- */
.pricing { padding: var(--section-y) 0; }
.price-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; align-items: stretch; }
.price { display: flex; flex-direction: column; text-align: center; position: relative; }
.price__name { font-size: 1.05rem; margin-bottom: .5rem; }
.price__amount { font-size: 2rem; font-weight: 800; color: var(--ink); margin: 0; }
.price__amount span { font-size: .9rem; font-weight: 500; color: var(--muted); }
.price__desc { color: var(--muted); margin: .35rem 0 1.25rem; font-size: .9rem; }
.price .btn { margin-top: auto; }
.price--featured { border-color: var(--accent); box-shadow: var(--shadow-md); }
.price__badge {
  position: absolute; top: -.75rem; left: 50%; transform: translateX(-50%);
  background: var(--accent); color: #fff; font-size: .7rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: .08em; padding: .3rem .8rem; border-radius: var(--radius-pill);
}

/* ---------- FAQ ---------- */
.faq { padding: var(--section-y) 0; background: var(--bg-tint); border-top: 1px solid var(--border); }
.accordion { display: flex; flex-direction: column; gap: .75rem; }
.acc { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow-sm); overflow: hidden; }
.acc summary {
  cursor: pointer; list-style: none; padding: 1.1rem 1.3rem; font-weight: 600; color: var(--ink);
  display: flex; justify-content: space-between; align-items: center; gap: 1rem;
}
.acc summary::-webkit-details-marker { display: none; }
.acc summary::after { content: "+"; font-size: 1.4rem; color: var(--accent); font-weight: 400; line-height: 1; transition: transform .2s; }
.acc[open] summary::after { transform: rotate(45deg); }
.acc p { margin: 0; padding: 0 1.3rem 1.2rem; color: var(--body); }

/* ---------- Order / final CTA ---------- */
.order { padding: var(--section-y) 0; background: linear-gradient(135deg, var(--accent) 0%, var(--accent-hover) 100%); }
.order__inner { text-align: center; color: #fff; }
.order__inner h2 { color: #fff; font-size: clamp(1.6rem, 4vw, 2.3rem); }
.order__sub { color: rgba(255,255,255,.85); margin-bottom: 1.75rem; }
.order__form { display: flex; gap: .6rem; justify-content: center; flex-wrap: wrap; max-width: 480px; margin: 0 auto; }
.order__form input {
  flex: 1 1 240px; padding: 1rem 1.1rem; border-radius: var(--radius-pill);
  border: 1px solid transparent; font-size: 1rem; font-family: inherit;
}
.order__form input:focus { outline: 3px solid rgba(255,255,255,.5); }
.order__form .btn--primary { background: #fff; color: var(--accent); }
.order__form .btn--primary:hover { background: var(--bg-tint); }
.order__note { color: rgba(255,255,255,.8); font-size: .82rem; margin-top: 1rem; }

/* ---------- Footer ---------- */
.site-footer { background: var(--ink); color: #cbd5e1; padding: 3rem 0 1.5rem; }
.footer__inner { display: grid; grid-template-columns: 1.5fr 2fr; gap: 2.5rem; padding-bottom: 2rem; }
.site-footer .brand__name { color: #fff; font-size: 1.15rem; font-weight: 700; }
.footer__brand p { margin-top: .6rem; max-width: 320px; }
.site-footer .muted { color: #94a3b8; }
.footer__cols { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem; }
.footer__cols h5 { color: #fff; font-size: .8rem; text-transform: uppercase; letter-spacing: .1em; margin-bottom: .75rem; }
.footer__cols a { display: block; color: #cbd5e1; padding: .25rem 0; font-size: .92rem; }
.footer__cols a:hover { color: #fff; }
.footer__bottom { display: flex; justify-content: space-between; flex-wrap: wrap; gap: .5rem; padding-top: 1.5rem; border-top: 1px solid rgba(255,255,255,.1); font-size: .82rem; }

/* ==========================================================================
   Responsive
   ========================================================================== */
@media (max-width: 900px) {
  .feature-grid { grid-template-columns: repeat(2, 1fr); }
  .price-grid { grid-template-columns: repeat(2, 1fr); }
  .anatomy__inner { grid-template-columns: 1fr; }
  .anatomy__visual { order: -1; }
}

@media (max-width: 640px) {
  .nav__toggle { display: flex; }
  .nav__menu {
    position: absolute; top: 64px; left: 0; right: 0;
    flex-direction: column; align-items: stretch; gap: 0;
    background: #fff; border-bottom: 1px solid var(--border);
    padding: .5rem 1.25rem 1rem; box-shadow: var(--shadow-md);
    display: none;
  }
  .nav__menu.is-open { display: flex; }
  .nav__menu a { padding: .8rem 0; border-bottom: 1px solid var(--border); }
  .nav__menu a.btn { margin-top: .6rem; border-bottom: 0; }

  .feature-grid { grid-template-columns: 1fr; }
  .price-grid { grid-template-columns: 1fr; }
  .footer__inner { grid-template-columns: 1fr; gap: 1.75rem; }
  .footer__cols { grid-template-columns: repeat(3, 1fr); }
  .report-card__head { flex-direction: column; }
  .report-card__meta { text-align: left; }
}

/* Respect reduced motion */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}
