/* ==================================================================
   Crevara AI — shared design system
   Theme: LIGHT, locked page-wide. One accent: deep emerald (verified /
   confirmed / evidence). Neutrals are warm-cool ink greys.
   Radius: soft family (cards 14px, tags 6px) + pill for interactive.
   Type: Geist 400/500/600 + Geist Mono 400 (self-hosted).
   Motion: CSS transitions + scroll reveal, reduced-motion honored.
================================================================== */

@font-face { font-family: "Geist"; src: url("fonts/geist-latin-400-normal.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Geist"; src: url("fonts/geist-latin-500-normal.woff2") format("woff2"); font-weight: 500; font-display: swap; }
@font-face { font-family: "Geist"; src: url("fonts/geist-latin-600-normal.woff2") format("woff2"); font-weight: 600; font-display: swap; }
@font-face { font-family: "Geist Mono"; src: url("fonts/geist-mono-latin-400-normal.woff2") format("woff2"); font-weight: 400; font-display: swap; }

:root {
  --bg: #fcfdfc;
  --bg-2: #f3f6f4;
  --surface: #ffffff;
  --ink: #10201a;
  --text: #16241e;
  --muted: #5d6b64;
  --faint: #8a958f;
  --line: rgba(16, 32, 26, 0.10);
  --line-2: rgba(16, 32, 26, 0.06);
  --accent: #0a7d55;
  --accent-strong: #086b49;
  --accent-tint: #e6f3ec;
  --accent-tint-2: #f1f8f4;
  --shadow-sm: 0 1px 2px rgba(16, 32, 26, 0.05);
  --shadow-md: 0 18px 44px -22px rgba(16, 32, 26, 0.30);
  --shadow-lg: 0 40px 90px -40px rgba(16, 32, 26, 0.38);
  --radius: 14px;
  --radius-sm: 8px;
  --tag: 6px;
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
  --wrap: 1120px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: "Geist", system-ui, -apple-system, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
::selection { background: rgba(10, 125, 85, 0.18); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 4px; }

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 24px; width: 100%; }
.mono { font-family: "Geist Mono", ui-monospace, monospace; }
.accent { color: var(--accent); }

/* ---------- eyebrow (rationed: max 1 per 3 sections) ---------- */
.eyebrow {
  font-family: "Geist Mono", ui-monospace, monospace;
  font-size: 0.72rem; letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--accent); font-weight: 400;
}

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  border-radius: 999px;
  font-size: 0.96rem; font-weight: 500;
  padding: 12px 22px;
  white-space: nowrap;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.18s var(--ease), background 0.18s, box-shadow 0.18s, border-color 0.18s;
}
.btn svg { display: block; }
.btn-primary { background: var(--accent); color: #fff; box-shadow: 0 6px 18px -8px rgba(10, 125, 85, 0.6); }
.btn-primary:hover { background: var(--accent-strong); transform: translateY(-1px); box-shadow: 0 12px 26px -10px rgba(10, 125, 85, 0.55); }
.btn-ghost { background: var(--surface); color: var(--ink); border-color: var(--line); box-shadow: var(--shadow-sm); }
.btn-ghost:hover { border-color: rgba(16, 32, 26, 0.22); transform: translateY(-1px); }
.btn:active { transform: scale(0.98); }
.btn-sm { padding: 9px 18px; font-size: 0.9rem; }

.arrow { transition: transform 0.2s var(--ease); }
.btn:hover .arrow, .textlink:hover .arrow { transform: translateX(3px); }
.textlink { color: var(--accent); font-weight: 500; display: inline-flex; align-items: center; gap: 6px; }
.textlink:hover { color: var(--accent-strong); }

/* ---------- nav ---------- */
nav.site {
  position: sticky; top: 0; z-index: 40;
  height: 66px;
  border-bottom: 1px solid var(--line-2);
  background: rgba(252, 253, 252, 0.82);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}
.nav-inner { display: flex; align-items: center; justify-content: space-between; height: 100%; gap: 20px; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 600; font-size: 1.04rem; letter-spacing: -0.01em; color: var(--ink); }
.nav-links { display: flex; align-items: center; gap: 30px; }
.nav-links a { color: var(--muted); font-size: 0.94rem; font-weight: 500; transition: color 0.16s; }
.nav-links a:hover, .nav-links a.here { color: var(--ink); }
.nav-cta { display: flex; align-items: center; gap: 14px; }

/* ---------- section scaffolding ---------- */
.section { padding: 104px 0; }
.section.tight { padding: 84px 0; }
.section.alt { background: var(--bg-2); border-top: 1px solid var(--line-2); border-bottom: 1px solid var(--line-2); }
.section.ink { background: var(--ink); color: #dfe8e3; border: 0; }
.section-head { max-width: 40ch; }
.section-head.center { margin: 0 auto; text-align: center; }
h1, h2, h3 { color: var(--ink); letter-spacing: -0.028em; font-weight: 600; line-height: 1.08; }
.section h2 { font-size: clamp(1.9rem, 3.4vw, 2.7rem); }
.lead { color: var(--muted); font-size: 1.12rem; max-width: 58ch; }
.section .lead { margin-top: 18px; }
.ink h1, .ink h2, .ink h3 { color: #fff; }
.ink .lead, .ink p { color: #a9b8b0; }

/* ---------- hero ---------- */
.hero { position: relative; overflow: hidden; padding: 92px 0 96px; }
.hero::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background:
    radial-gradient(680px 380px at 88% -6%, rgba(10, 125, 85, 0.10), transparent 62%),
    radial-gradient(520px 320px at 4% 108%, rgba(10, 125, 85, 0.05), transparent 60%);
}
.hero .wrap { position: relative; }
.hero-grid { display: grid; grid-template-columns: 1.02fr 0.98fr; gap: 56px; align-items: center; }
.hero h1 { font-size: clamp(2.5rem, 5vw, 3.9rem); letter-spacing: -0.035em; line-height: 1.03; max-width: 15ch; }
.hero .sub { margin-top: 22px; font-size: 1.17rem; color: var(--muted); max-width: 40ch; }
.hero-ctas { margin-top: 32px; display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.hero-tag { margin-top: 26px; display: inline-flex; align-items: center; gap: 9px; font-size: 0.86rem; color: var(--muted); }
.pulse { width: 8px; height: 8px; border-radius: 999px; background: var(--accent); box-shadow: 0 0 0 0 rgba(10, 125, 85, 0.4); }
/* solo hero (no side asset) */
.hero-solo { text-align: center; padding: 116px 0 108px; }
.hero-solo-inner { max-width: 780px; margin: 0 auto; }
.hero-solo h1 { max-width: 17ch; margin: 0 auto; }
.hero-solo .sub { margin: 24px auto 0; max-width: 50ch; }
.hero-solo .hero-ctas { justify-content: center; margin-top: 34px; }

.page-compact .hero { padding: 66px 0 40px; }
.page-compact .hero h1 { font-size: clamp(2.15rem, 3.6vw, 3rem); max-width: 17ch; }
.page-compact .hero .section-head { max-width: 660px; }

/* ---------- digest artifact (the real deliverable, rendered on-brand) ---------- */
.digest {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
}
.digest-cap { font-size: 0.8rem; color: var(--faint); margin-top: 12px; text-align: right; }
.digest-hd { padding: 20px 22px 16px; border-bottom: 1px solid var(--line-2); }
.digest-hd .app { font-weight: 600; color: var(--ink); font-size: 1.02rem; letter-spacing: -0.01em; }
.digest-hd .meta { font-size: 0.78rem; color: var(--faint); margin-top: 3px; }
.digest-one {
  margin: 0; padding: 15px 22px; background: var(--accent-tint-2);
  border-bottom: 1px solid var(--line-2);
  font-size: 0.92rem; color: var(--text); line-height: 1.5;
}
.digest-one b { color: var(--ink); }
.finding { padding: 17px 22px; border-bottom: 1px solid var(--line-2); }
.finding:last-of-type { border-bottom: 0; }
.f-top { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; }
.sev {
  font-family: "Geist Mono", ui-monospace, monospace;
  font-size: 0.64rem; font-weight: 400; letter-spacing: 0.08em;
  padding: 3px 8px; border-radius: var(--tag); text-transform: uppercase; white-space: nowrap;
}
.sev-crit { background: var(--ink); color: #fff; }
.sev-high { color: var(--ink); border: 1px solid rgba(16, 32, 26, 0.4); }
.sev-med { color: var(--muted); border: 1px solid var(--line); }
.f-title { font-weight: 600; color: var(--ink); font-size: 0.98rem; letter-spacing: -0.01em; line-height: 1.3; }
.f-stat { font-size: 0.85rem; color: var(--muted); margin-bottom: 5px; }
.f-stat b { color: var(--ink); font-weight: 600; }
.f-repro { font-family: "Geist Mono", ui-monospace, monospace; font-size: 0.76rem; color: var(--muted); line-height: 1.5; margin-bottom: 10px; }
.f-repro .code { background: var(--bg-2); border: 1px solid var(--line-2); border-radius: 4px; padding: 0 5px; color: var(--ink); }
.f-evidence { display: inline-flex; align-items: center; gap: 7px; font-size: 0.85rem; color: var(--accent); font-weight: 500; }
.f-evidence .play { width: 20px; height: 20px; border-radius: 999px; background: var(--accent-tint); display: inline-flex; align-items: center; justify-content: center; }
.f-more { font-size: 0.83rem; color: var(--faint); margin-left: 12px; }
.digest-ft { padding: 14px 22px; background: var(--bg-2); font-family: "Geist Mono", ui-monospace, monospace; font-size: 0.72rem; color: var(--faint); line-height: 1.6; }
.digest-ft b { color: var(--muted); font-weight: 400; }

/* ---------- value grid (bento, asymmetric) ---------- */
.bento { display: grid; grid-template-columns: repeat(6, 1fr); gap: 16px; }
.tile {
  border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface);
  padding: 30px; box-shadow: var(--shadow-sm);
  display: flex; flex-direction: column;
  transition: transform 0.2s var(--ease), box-shadow 0.2s var(--ease), border-color 0.2s;
}
.tile:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); border-color: rgba(16, 32, 26, 0.16); }
.tile h3 { font-size: 1.24rem; letter-spacing: -0.018em; line-height: 1.24; }
.tile p { margin-top: 10px; color: var(--muted); font-size: 0.97rem; max-width: 44ch; }
.tile .ico { width: 40px; height: 40px; border-radius: 10px; background: var(--accent-tint); color: var(--accent); display: inline-flex; align-items: center; justify-content: center; margin-bottom: 18px; }
.tile.feature { background: linear-gradient(168deg, var(--accent-tint) 0%, var(--accent-tint-2) 46%, var(--surface) 100%); }
.span-3 { grid-column: span 3; }
.span-2 { grid-column: span 2; }
.span-6 { grid-column: span 6; }
.tile.wide { flex-direction: row; align-items: center; gap: 34px; }
.tile.wide .ico { margin-bottom: 0; flex: 0 0 auto; }
.tile.wide .body { flex: 1; min-width: 0; }

/* ---------- steps ---------- */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 40px; counter-reset: step; }
.step { position: relative; }
.step .num { font-family: "Geist Mono", ui-monospace, monospace; font-size: 0.8rem; color: var(--accent); margin-bottom: 14px; }
.step h3 { font-size: 1.2rem; letter-spacing: -0.015em; }
.step p { margin-top: 10px; color: var(--muted); font-size: 0.97rem; }
.step .rule { height: 2px; background: var(--line); margin-bottom: 22px; position: relative; overflow: hidden; }
.step .rule::after { content: ""; position: absolute; left: 0; top: 0; height: 100%; width: 34%; background: var(--accent); }
.step:nth-child(2) .rule::after { width: 67%; }
.step:nth-child(3) .rule::after { width: 100%; }

/* ---------- split feature rows ---------- */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 60px; align-items: center; }
.split.flip .split-media { order: 2; }
.split .kicker { color: var(--accent); font-weight: 600; font-size: 0.92rem; margin-bottom: 12px; }
.split h2 { font-size: clamp(1.7rem, 2.8vw, 2.3rem); }
.split p { margin-top: 16px; color: var(--muted); font-size: 1.05rem; max-width: 46ch; }
.checks { margin-top: 22px; display: grid; gap: 12px; }
.check { display: flex; gap: 11px; align-items: flex-start; font-size: 0.98rem; color: var(--text); }
.check .ck { flex: 0 0 auto; width: 22px; height: 22px; border-radius: 999px; background: var(--accent-tint); color: var(--accent); display: inline-flex; align-items: center; justify-content: center; margin-top: 1px; }

/* ---------- audience cards ---------- */
.audience { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.aud { border: 1px solid var(--line); border-radius: var(--radius); padding: 30px; background: var(--surface); box-shadow: var(--shadow-sm); }
.aud .role { font-family: "Geist Mono", ui-monospace, monospace; font-size: 0.74rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--accent); }
.aud h3 { margin-top: 12px; font-size: 1.18rem; letter-spacing: -0.015em; }
.aud p { margin-top: 10px; color: var(--muted); font-size: 0.96rem; }

/* ---------- stat strip ---------- */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 30px; }
.stat .n { font-size: clamp(2rem, 3.4vw, 2.9rem); font-weight: 600; letter-spacing: -0.03em; color: var(--ink); font-family: "Geist Mono", ui-monospace, monospace; }
.ink .stat .n { color: #fff; }
.stat .l { margin-top: 8px; color: var(--muted); font-size: 0.94rem; max-width: 24ch; }
.ink .stat .l { color: #93a49b; }

/* ---------- funnel (pipeline transparency) ---------- */
.funnel { display: flex; align-items: stretch; gap: 12px; flex-wrap: wrap; }
.fstep { flex: 1; min-width: 150px; border: 1px solid rgba(255,255,255,0.14); border-radius: var(--radius); padding: 20px 18px; background: rgba(255,255,255,0.03); }
.fstep .fn { font-family: "Geist Mono", ui-monospace, monospace; font-size: 1.6rem; color: #fff; letter-spacing: -0.02em; }
.fstep .fl { margin-top: 6px; font-size: 0.86rem; color: #93a49b; }
.fstep.win { border-color: rgba(10, 125, 85, 0.55); background: rgba(10, 125, 85, 0.14); }
.fstep.win .fn { color: #4ecb98; }
.fstep.win .fl { color: #b7d6c8; }

/* ---------- founder note ---------- */
.note { max-width: 720px; }
.note p { font-size: 1.15rem; line-height: 1.62; color: var(--text); }
.note p + p { margin-top: 18px; }
.note .sig { margin-top: 22px; font-size: 0.95rem; color: var(--muted); }
.note .sig b { color: var(--ink); font-weight: 600; }

/* ---------- faq ---------- */
.faq { max-width: 820px; margin: 0 auto; border-top: 1px solid var(--line); }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary { list-style: none; cursor: pointer; padding: 22px 4px; display: flex; justify-content: space-between; align-items: center; gap: 20px; font-weight: 600; color: var(--ink); font-size: 1.06rem; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary .pm { flex: 0 0 auto; width: 22px; height: 22px; position: relative; transition: transform 0.2s var(--ease); color: var(--accent); }
.faq details[open] summary .pm { transform: rotate(45deg); }
.faq .ans { padding: 0 4px 24px; color: var(--muted); font-size: 1rem; max-width: 68ch; }

/* ---------- cta band ---------- */
.cta-band { text-align: center; }
.cta-band h2 { font-size: clamp(2rem, 4vw, 3.1rem); letter-spacing: -0.032em; max-width: 18ch; margin: 0 auto; }
.cta-band .lead { margin: 18px auto 0; text-align: center; }
.cta-band .hero-ctas { justify-content: center; margin-top: 30px; }
.cal-frame { margin-top: 42px; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; background: var(--surface); box-shadow: var(--shadow-md); }
.cal-frame iframe { display: block; width: 100%; height: 700px; border: 0; }

/* ---------- footer ---------- */
footer.site { border-top: 1px solid var(--line); padding: 54px 0 40px; background: var(--bg-2); }
.foot-grid { display: flex; justify-content: space-between; gap: 40px; flex-wrap: wrap; }
.foot-brand { max-width: 30ch; }
.foot-brand p { color: var(--muted); font-size: 0.92rem; margin-top: 12px; }
.foot-cols { display: flex; gap: 64px; flex-wrap: wrap; }
.foot-col h4 { font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.1em; color: var(--faint); font-weight: 500; margin-bottom: 14px; font-family: "Geist Mono", ui-monospace, monospace; }
.foot-col a { display: block; color: var(--muted); font-size: 0.94rem; padding: 5px 0; transition: color 0.16s; }
.foot-col a:hover { color: var(--ink); }
.foot-base { margin-top: 40px; padding-top: 22px; border-top: 1px solid var(--line); display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; font-size: 0.86rem; color: var(--faint); }

/* ---------- reveal (only with JS + no reduced-motion) ---------- */
@keyframes fadeUp { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: none; } }
.anim .hero h1 { animation: fadeUp 0.7s var(--ease) both; }
.anim .hero .sub { animation: fadeUp 0.7s var(--ease) 0.08s both; }
.anim .hero .hero-ctas { animation: fadeUp 0.7s var(--ease) 0.16s both; }
.anim .hero .hero-tag { animation: fadeUp 0.7s var(--ease) 0.22s both; }
.anim .hero-media { animation: fadeUp 0.8s var(--ease) 0.18s both; }
.anim .reveal { opacity: 0; transform: translateY(22px); transition: opacity 0.7s var(--ease), transform 0.7s var(--ease); }
.anim .reveal.in { opacity: 1; transform: none; }
.anim .pulse { animation: ping 2.4s var(--ease) infinite; }
@keyframes ping { 0% { box-shadow: 0 0 0 0 rgba(10,125,85,0.35); } 70% { box-shadow: 0 0 0 8px rgba(10,125,85,0); } 100% { box-shadow: 0 0 0 0 rgba(10,125,85,0); } }

/* ---------- responsive ---------- */
@media (max-width: 940px) {
  .section { padding: 76px 0; }
  .hero { padding: 60px 0 64px; }
  .hero-grid { grid-template-columns: 1fr; gap: 44px; }
  .hero h1, .hero .sub { max-width: 22ch; }
  .hero .sub { max-width: 46ch; }
  .split { grid-template-columns: 1fr; gap: 34px; }
  .split.flip .split-media { order: 0; }
  .steps { grid-template-columns: 1fr; gap: 30px; }
  .audience { grid-template-columns: 1fr; }
  .stats { grid-template-columns: repeat(2, 1fr); gap: 26px; }
  .bento { grid-template-columns: repeat(2, 1fr); }
  .span-3, .span-2, .span-6 { grid-column: span 2; }
  .tile.wide { flex-direction: column; align-items: flex-start; gap: 18px; }
}
@media (max-width: 620px) {
  .nav-links { display: none; }
  .bento { grid-template-columns: 1fr; }
  .span-3, .span-2, .span-6 { grid-column: span 1; }
  .stats { grid-template-columns: 1fr 1fr; }
  .foot-cols { gap: 36px; }
  .cal-frame iframe { height: 820px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}
