/* ============================================================
   Synapse — marketing site
   Brand: clinical blue -> teal (#1D4FD9 -> #06B5D4)
   ============================================================ */

:root {
  --blue: #1D4FD9;
  --teal: #06B5D4;
  --grad: linear-gradient(135deg, #1D4FD9 0%, #06B5D4 100%);
  --ink: #0b1530;
  --body: #3a4661;
  --muted: #6b7892;
  --bg: #ffffff;
  --bg-soft: #f4f8fd;
  --bg-deep: #0b1530;
  --line: #e4ecf6;
  --radius: 16px;
  --shadow: 0 18px 50px -24px rgba(13, 38, 95, 0.35);
  --container: 1120px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  color: var(--body);
  background: var(--bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 { color: var(--ink); line-height: 1.15; margin: 0 0 .4em; letter-spacing: -0.02em; }
h1 { font-size: clamp(2.2rem, 5vw, 3.6rem); font-weight: 800; }
h2 { font-size: clamp(1.7rem, 3.4vw, 2.5rem); font-weight: 800; }
h3 { font-size: 1.2rem; font-weight: 700; }
p { margin: 0 0 1rem; }
a { color: var(--blue); text-decoration: none; }

.container { max-width: var(--container); margin: 0 auto; padding: 0 24px; }
.gradient-text {
  background: var(--grad);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
}
.eyebrow {
  text-transform: uppercase; letter-spacing: .12em; font-size: .8rem;
  font-weight: 700; color: var(--blue); margin-bottom: .6rem;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: .5rem;
  padding: 13px 24px; border-radius: 999px; font-weight: 650;
  font-size: 1rem; cursor: pointer; border: 1px solid transparent;
  transition: transform .15s ease, box-shadow .15s ease, background .15s ease;
}
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--grad); color: #fff; box-shadow: 0 12px 24px -10px rgba(29,79,217,.6); }
.btn-primary:hover { box-shadow: 0 16px 30px -10px rgba(29,79,217,.7); transform: translateY(-1px); }
.btn-ghost { background: #fff; color: var(--ink); border-color: var(--line); }
.btn-ghost:hover { border-color: #c9d8ee; }
.btn-white { background: #fff; color: var(--blue); }
.btn-lg { padding: 16px 30px; font-size: 1.05rem; }

/* ---------- Nav ---------- */
header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255,255,255,.82);
  backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid var(--line);
}
nav { display: flex; align-items: center; justify-content: space-between; height: 68px; }
.brand-lockup { display: flex; align-items: center; gap: 9px; font-weight: 800; color: var(--ink); font-size: 1.2rem; letter-spacing: -.02em; }
.brand-lockup img { width: 30px; height: 30px; }
.nav-links { display: flex; align-items: center; gap: 28px; list-style: none; margin: 0; padding: 0; }
.nav-links a { color: var(--body); font-weight: 550; font-size: .98rem; }
.nav-links a:hover { color: var(--ink); }
.nav-cta { margin-left: 8px; }
.nav-toggle { display: none; }

/* ---------- Hero ---------- */
.hero { position: relative; overflow: hidden; padding: 72px 0 40px; }
.hero::before {
  content: ""; position: absolute; inset: 0;
  background:
    radial-gradient(60% 50% at 80% 0%, rgba(6,181,212,.12), transparent 70%),
    radial-gradient(50% 50% at 0% 20%, rgba(29,79,217,.10), transparent 70%);
  pointer-events: none;
}
.hero-grid {
  position: relative; display: grid; grid-template-columns: 1.05fr .95fr;
  gap: 40px; align-items: center;
}
.hero h1 { margin-bottom: .3em; }
.hero .lede { font-size: 1.2rem; color: var(--body); max-width: 36ch; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 28px; }
.hero-note { margin-top: 18px; font-size: .9rem; color: var(--muted); }
.hero-stage { display: flex; justify-content: center; }

/* ---------- Phone mockups ---------- */
.phone {
  width: 290px; background: #0b1530; border-radius: 42px; padding: 10px;
  box-shadow: var(--shadow); border: 1px solid rgba(255,255,255,.08);
}
.phone .screen {
  background: var(--bg); border-radius: 33px; overflow: hidden;
  height: 590px; display: flex; flex-direction: column; position: relative;
}
.phone .notch {
  position: absolute; top: 0; left: 50%; transform: translateX(-50%);
  width: 120px; height: 26px; background: #0b1530; border-radius: 0 0 16px 16px; z-index: 3;
}
.scr-bar { display: flex; align-items: center; justify-content: space-between; padding: 16px 18px 10px; border-bottom: 1px solid var(--line); }
.scr-bar .ttl { font-weight: 700; color: var(--ink); font-size: .95rem; }
.scr-bar .sub { font-size: .72rem; color: var(--muted); }
.scr-body { flex: 1; padding: 18px; overflow: hidden; }

/* study screen */
.study-card {
  background: var(--bg-soft); border: 1px solid var(--line); border-radius: 14px;
  padding: 22px 18px; min-height: 230px; display: flex; flex-direction: column;
  align-items: center; justify-content: center; text-align: center; gap: 10px;
}
.study-card .q { color: var(--ink); font-weight: 600; font-size: 1rem; }
.study-card .hr { width: 60%; height: 1px; background: var(--line); }
.study-card .a { color: var(--blue); font-weight: 600; font-size: .92rem; }
.grade-row { display: grid; grid-template-columns: repeat(4,1fr); gap: 7px; margin-top: 14px; }
.grade { border-radius: 10px; padding: 9px 0 7px; text-align: center; font-size: .72rem; font-weight: 700; border: 1px solid; }
.grade small { display: block; font-weight: 500; font-size: .6rem; opacity: .8; }
.g-again { color: #d23b4e; border-color: #f3c6cd; background: #fdf2f4; }
.g-hard  { color: #c5781b; border-color: #f1d8b6; background: #fcf6ec; }
.g-good  { color: #1f9d57; border-color: #bfe6cd; background: #f0faf3; }
.g-easy  { color: var(--blue); border-color: #c5d6f6; background: #eef3fd; }

/* chat screen */
.chat { display: flex; flex-direction: column; gap: 10px; }
.bubble { max-width: 82%; padding: 10px 13px; border-radius: 16px; font-size: .82rem; line-height: 1.45; }
.bubble.ai { align-self: flex-start; background: #eef2f8; color: var(--ink); border-bottom-left-radius: 5px; }
.bubble.me { align-self: flex-end; background: var(--grad); color: #fff; border-bottom-right-radius: 5px; }
.chat-hint { margin-top: auto; display: flex; align-items: center; gap: 6px; font-size: .72rem; color: var(--muted); }
.chip { display:inline-block; padding: 6px 11px; border:1px solid var(--line); border-radius:999px; font-size:.72rem; color:var(--body); }

/* stats screen */
.stat-row { display: flex; gap: 10px; margin-bottom: 16px; }
.stat-box { flex: 1; background: var(--bg-soft); border: 1px solid var(--line); border-radius: 12px; padding: 12px; text-align: center; }
.stat-box b { display: block; font-size: 1.5rem; color: var(--ink); line-height: 1; }
.stat-box span { font-size: .68rem; color: var(--muted); }
.bars { display: flex; align-items: flex-end; gap: 10px; height: 150px; padding: 12px; background: var(--bg-soft); border: 1px solid var(--line); border-radius: 12px; }
.bars i { flex: 1; background: var(--grad); border-radius: 6px 6px 0 0; display: block; }

/* ---------- Generic section ---------- */
section { padding: 76px 0; }
.section-head { text-align: center; max-width: 640px; margin: 0 auto 52px; }
.section-head p { color: var(--muted); font-size: 1.1rem; }
.bg-soft { background: var(--bg-soft); }

/* ---------- Feature grid ---------- */
.features { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.feature {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 26px; transition: transform .18s ease, box-shadow .18s ease;
}
.feature:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.feature .ic {
  width: 46px; height: 46px; border-radius: 12px; display: grid; place-items: center;
  background: linear-gradient(135deg, rgba(29,79,217,.12), rgba(6,181,212,.12)); margin-bottom: 14px;
}
.feature .ic svg { width: 24px; height: 24px; }
.feature h3 { margin-bottom: .3em; }
.feature p { font-size: .96rem; margin: 0; }

/* ---------- AI band ---------- */
.ai-band { position: relative; overflow: hidden; background: var(--bg-deep); color: #cdd8ee; }
.ai-band h2, .ai-band h3 { color: #fff; }
.ai-band::before {
  content:""; position:absolute; inset:0;
  background: radial-gradient(50% 60% at 85% 10%, rgba(6,181,212,.22), transparent 70%),
             radial-gradient(45% 55% at 5% 90%, rgba(29,79,217,.28), transparent 70%);
}
.ai-grid { position: relative; display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: center; }
.ai-points { list-style: none; padding: 0; margin: 22px 0 0; display: grid; gap: 16px; }
.ai-points li { display: flex; gap: 12px; align-items: flex-start; }
.ai-points .dot { flex: none; width: 26px; height: 26px; border-radius: 8px; background: var(--grad); display: grid; place-items: center; }
.ai-points .dot svg { width: 15px; height: 15px; }
.ai-points b { color: #fff; }
.privacy-pill {
  display: inline-flex; align-items: center; gap: 8px; margin-top: 26px;
  padding: 9px 16px; border-radius: 999px; font-size: .88rem; font-weight: 600;
  color: #d7f4fb; background: rgba(6,181,212,.14); border: 1px solid rgba(6,181,212,.4);
}

/* ---------- Screens showcase ---------- */
.screens { display: flex; justify-content: center; gap: 30px; flex-wrap: wrap; }
.screens .phone { width: 250px; }
.screens .phone .screen { height: 510px; }
.screen-cap { text-align: center; margin-top: 16px; }
.screen-cap b { color: var(--ink); display: block; }
.screen-cap span { font-size: .9rem; color: var(--muted); }

/* ---------- Steps ---------- */
.steps { display: grid; grid-template-columns: repeat(3,1fr); gap: 24px; counter-reset: step; }
.step { padding: 8px; }
.step .n {
  width: 40px; height: 40px; border-radius: 11px; background: var(--grad); color: #fff;
  font-weight: 800; display: grid; place-items: center; margin-bottom: 12px;
}

/* ---------- FAQ ---------- */
.faq { max-width: 760px; margin: 0 auto; }
.faq details { border: 1px solid var(--line); border-radius: 12px; padding: 4px 18px; margin-bottom: 12px; background: #fff; }
.faq summary { cursor: pointer; font-weight: 650; color: var(--ink); padding: 14px 0; list-style: none; display: flex; justify-content: space-between; align-items: center; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; color: var(--blue); font-size: 1.4rem; font-weight: 400; }
.faq details[open] summary::after { content: "\2013"; }
.faq details p { color: var(--body); margin: 0 0 16px; }

/* ---------- CTA band ---------- */
.cta-band { background: var(--grad); color: #fff; text-align: center; }
.cta-band h2 { color: #fff; }
.cta-band p { color: rgba(255,255,255,.9); max-width: 52ch; margin: 0 auto 24px; font-size: 1.1rem; }

/* ---------- Footer ---------- */
footer { background: var(--bg-deep); color: #9fb0cc; padding: 56px 0 28px; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 32px; }
.footer-brand .brand-lockup { color: #fff; margin-bottom: 12px; }
.footer-brand p { font-size: .92rem; max-width: 34ch; }
footer h4 { color: #fff; font-size: .9rem; text-transform: uppercase; letter-spacing: .08em; margin-bottom: 14px; }
footer ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 9px; }
footer a { color: #9fb0cc; font-size: .95rem; }
footer a:hover { color: #fff; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.1); margin-top: 40px; padding-top: 20px; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px; font-size: .85rem; color: #74849f; }

/* ---------- Legal / content pages ---------- */
.page { padding: 56px 0 72px; }
.prose { max-width: 760px; margin: 0 auto; }
.prose h1 { margin-bottom: .2em; }
.prose .updated { color: var(--muted); font-size: .92rem; margin-bottom: 32px; }
.prose h2 { font-size: 1.35rem; margin-top: 36px; }
.prose ul { padding-left: 20px; }
.prose li { margin-bottom: 8px; }
.back-link { display: inline-flex; gap: 6px; align-items: center; font-weight: 600; margin-bottom: 24px; }

/* ---------- Pricing ---------- */
.pricing {
  display: grid; grid-template-columns: repeat(2, minmax(0, 380px));
  gap: 24px; justify-content: center; align-items: stretch;
}
.plan {
  position: relative; background: #fff; border: 1px solid var(--line);
  border-radius: var(--radius); padding: 30px 28px; display: flex; flex-direction: column;
}
.plan-featured { border-color: transparent; box-shadow: var(--shadow); outline: 2px solid var(--blue); }
.plan-badge {
  position: absolute; top: -12px; left: 28px; background: var(--grad); color: #fff;
  font-size: .74rem; font-weight: 700; letter-spacing: .03em; text-transform: uppercase;
  padding: 5px 12px; border-radius: 999px;
}
.plan h3 { font-size: 1.3rem; margin-bottom: 6px; }
.plan .price { display: flex; align-items: baseline; gap: 4px; margin: 6px 0 2px; }
.plan .price .amt { font-size: 2.4rem; font-weight: 800; color: var(--ink); letter-spacing: -.02em; }
.plan .price .per { font-size: 1rem; color: var(--muted); font-weight: 600; }
.plan-sub { color: var(--muted); font-size: .92rem; margin: 0 0 18px; }
.plan-options { display: flex; align-items: center; gap: 14px; margin: 2px 0 20px; }
.popt { flex: 1; }
.popt-price { display: flex; align-items: baseline; gap: 3px; }
.popt-price .amt { font-size: 1.9rem; font-weight: 800; color: var(--ink); letter-spacing: -.02em; }
.popt-price .per { font-size: .88rem; color: var(--muted); font-weight: 600; }
.popt-note { font-size: .82rem; color: var(--muted); margin-top: 3px; }
.popt-or { color: var(--muted); font-size: .82rem; font-weight: 700; text-transform: uppercase; }
.plan-feats { list-style: none; padding: 0; margin: 0 0 24px; display: grid; gap: 11px; flex: 1; }
.plan-feats li { position: relative; padding-left: 28px; font-size: .96rem; color: var(--body); }
.plan-feats li::before {
  content: ""; position: absolute; left: 0; top: 3px; width: 18px; height: 18px; border-radius: 50%;
  background: var(--grad) center/12px no-repeat;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='none' stroke='%23000' stroke-width='3' stroke-linecap='round' stroke-linejoin='round' d='m5 13 4 4L19 7'/%3E%3C/svg%3E") center/12px no-repeat, linear-gradient(#000,#000);
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='none' stroke='%23000' stroke-width='3' stroke-linecap='round' stroke-linejoin='round' d='m5 13 4 4L19 7'/%3E%3C/svg%3E") center/12px no-repeat;
}
.plan .btn { width: 100%; justify-content: center; }
.pricing-note { text-align: center; color: var(--muted); font-size: .82rem; max-width: 560px; margin: 26px auto 0; }

/* ---------- Mobile nav toggle (hamburger) ---------- */
.nav-toggle span { display: block; width: 24px; height: 2px; background: var(--ink); border-radius: 2px; transition: transform .2s ease, opacity .2s ease; }
.nav-toggle-cb:checked ~ .nav-toggle span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle-cb:checked ~ .nav-toggle span:nth-child(2) { opacity: 0; }
.nav-toggle-cb:checked ~ .nav-toggle span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Responsive ---------- */
@media (max-width: 880px) {
  .hero-grid, .ai-grid { grid-template-columns: 1fr; }
  .features, .steps { grid-template-columns: 1fr 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .pricing { grid-template-columns: minmax(0, 420px); }

  .nav-toggle { display: flex; flex-direction: column; gap: 5px; cursor: pointer; padding: 8px; margin: -8px; }
  .nav-links {
    display: none; position: absolute; top: 68px; left: 0; right: 0;
    flex-direction: column; align-items: stretch; gap: 2px;
    background: rgba(255,255,255,.98); backdrop-filter: saturate(180%) blur(14px);
    border-bottom: 1px solid var(--line); box-shadow: var(--shadow);
    padding: 10px 24px 18px;
  }
  .nav-toggle-cb:checked ~ .nav-links { display: flex; }
  .nav-links li { padding: 8px 0; }
  .nav-cta { margin-left: 0; padding-top: 10px; }
}
@media (max-width: 560px) {
  .features, .steps, .footer-grid { grid-template-columns: 1fr; }
  section { padding: 56px 0; }
  .hero { padding: 48px 0 24px; }
}
