/* Med-Mind — the calm sibling of Med-Action.
   Med-Action is dark blue and red because it is about emergencies. This is
   about the end of an ordinary day, so it is warm, light-first, and quiet. */
:root{
  --bg:#FBF9F7; --surface:#FFFFFF; --surface-2:#F3F0EC;
  --ink:#1C1B1F; --ink-dim:#6B6870; --hair:#E6E2DE;
  --accent:#4C6B54; --accent-soft:#E8EDE7; --warn:#8A5A1E;
  --measure:34rem;
}
@media (prefers-color-scheme:dark){
  :root{
    --bg:#121114; --surface:#1D1B20; --surface-2:#26232B;
    --ink:#ECE9E6; --ink-dim:#9E9AA3; --hair:#33303A;
    --accent:#9CC2A5; --accent-soft:#2A3730; --warn:#E0B87A;
  }
}
*{box-sizing:border-box}
html{scroll-behavior:smooth}
@media (prefers-reduced-motion:reduce){html{scroll-behavior:auto}*{animation:none!important;transition:none!important}}
body{
  margin:0;background:var(--bg);color:var(--ink);
  font-family:-apple-system,BlinkMacSystemFont,"SF Pro Text","Segoe UI",Roboto,sans-serif;
  font-size:17px;line-height:1.65;-webkit-font-smoothing:antialiased;
}
.wrap{max-width:64rem;margin:0 auto;padding:0 1.5rem}
.prose{max-width:44rem}
a{color:var(--accent)}
header{padding:1.4rem 0;border-bottom:1px solid var(--hair)}
.bar{display:flex;align-items:center;justify-content:space-between;gap:1rem;flex-wrap:wrap}
.brand{display:flex;align-items:center;gap:.6rem;font-weight:700;font-size:1.1rem;text-decoration:none;color:var(--ink)}
.mark{width:32px;height:32px;border-radius:9px;background:var(--accent);display:grid;place-items:center;color:var(--bg);font-weight:700;font-size:.95rem}
nav a{margin-left:1.3rem;text-decoration:none;color:var(--ink-dim);font-size:.95rem}
nav a:hover,nav a:focus-visible{color:var(--accent)}
h1{font-size:clamp(2rem,5vw,3.1rem);line-height:1.1;margin:0 0 1rem;letter-spacing:-.02em;text-wrap:balance}
h2{font-size:1.5rem;margin:2.6rem 0 .8rem;letter-spacing:-.01em}
h3{font-size:1.12rem;margin:1.8rem 0 .5rem}
.lede{font-size:1.2rem;color:var(--ink-dim);max-width:var(--measure);margin:0 0 1.6rem}
.hero{padding:4rem 0 2.5rem}
.pill{display:inline-flex;align-items:center;gap:.45rem;background:var(--accent-soft);
  border:1px solid var(--accent);color:var(--accent);border-radius:999px;
  padding:.3rem .8rem;font-size:.8rem;font-weight:600;margin-bottom:1.1rem}
.grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(15rem,1fr));gap:1.1rem;margin:1.6rem 0}
.card{background:var(--surface);border:1px solid var(--hair);border-radius:14px;padding:1.3rem}
.card h3{margin:0 0 .4rem;font-size:1.05rem}
.card p{margin:0;color:var(--ink-dim);font-size:.96rem}
.note{background:var(--surface);border:1px solid var(--hair);border-left:3px solid var(--warn);
  border-radius:10px;padding:1rem 1.2rem;margin:2rem 0;color:var(--ink-dim);font-size:.96rem}
.btn{display:inline-flex;align-items:center;gap:.5rem;border-radius:13px;padding:.8rem 1.3rem;
  font-weight:600;text-decoration:none;font-size:1rem;border:2px solid transparent}
.btn-primary{background:var(--accent);color:var(--bg)}
.btn-ghost{border-color:var(--hair);color:var(--ink)}
.btn-ghost:hover,.btn-ghost:focus-visible{border-color:var(--accent)}
.cta{display:flex;flex-wrap:wrap;gap:.8rem;align-items:center;margin-top:1.4rem}
.soon{font-size:.88rem;color:var(--ink-dim)}
table{border-collapse:collapse;width:100%;margin:1rem 0;font-size:.95rem;display:block;overflow-x:auto}
th,td{text-align:left;padding:.6rem .8rem;border-bottom:1px solid var(--hair);vertical-align:top}
th{color:var(--ink-dim);font-weight:600;font-size:.85rem;text-transform:uppercase;letter-spacing:.04em}
code{background:var(--surface-2);padding:.12rem .38rem;border-radius:5px;font-size:.88em}
pre{background:var(--surface);border:1px solid var(--hair);border-radius:10px;padding:1rem;
  overflow-x:auto;font-size:.85rem;line-height:1.5}
footer{border-top:1px solid var(--hair);margin-top:4rem;padding:2rem 0 3rem;color:var(--ink-dim);font-size:.92rem}

/* ── Narrow screens ──────────────────────────────────────────────────────
   At 375px the four nav links wrapped onto a second line, which pushed the
   hero down and made the header look accidental. Below 30rem the nav becomes
   its own evenly-spaced row under the brand rather than trying to sit beside
   it. Tap targets stay above 44px: the vertical padding is what guarantees
   that, not the text size. */
@media (max-width:30rem){
  .bar{flex-direction:column;align-items:flex-start;gap:.35rem}
  nav{display:flex;width:100%;justify-content:space-between}
  /* .7rem, not .55rem: measured, the smaller value produced a 42px tap
     target and the iOS minimum is 44. Padding is what buys the height here,
     not font-size, so the link text stays legible. */
  nav a{margin-left:0;padding:.7rem 0;font-size:.92rem}
  .hero{padding:2.5rem 0 2rem}
  .wrap{padding:0 1.15rem}
}
footer a{margin-right:1.2rem}
ul{padding-left:1.2rem}li{margin:.4rem 0}
