/* Mesio Learn — shares the homepage's palette, type and density. */
:root{
  /* Surface scale — identical values to the marketing site (--bg-0..3) and
     to the app's --color-surface-0..3, so the three read as one product. */
  --bg-0:#080C16; --bg:#0E1420; --card:#161E2C; --bg-3:#202A3A;
  --rule:rgb(96 112 140/.22); --rule-2:rgb(96 112 140/.4);
  --fg:#F0F4FC; --fg-muted:#A8B4C8; --fg-dim:#78869F;
  --teal:#5AD1C1; --teal-strong:#7DDDD0; --warm:#FF9966; --warn:#EAB308;
  /* Corner scale — the site and the app both center on 8px. */
  --r:8px; --r-sm:6px; --r-xs:4px;
}
*{box-sizing:border-box}
html{scroll-behavior:smooth}
/* Same ground as the homepage and the app (surface-0), with the homepage's two
   soft glows across the top instead of a lighter navy band. */
body{margin:0;background:
    radial-gradient(ellipse 760px 460px at 8% 0%,rgb(90 209 193/.10),transparent 70%),
    radial-gradient(ellipse 620px 400px at 92% 0%,rgb(255 153 102/.06),transparent 70%),
    var(--bg-0);
  color:var(--fg);
  font-family:Manrope,ui-sans-serif,system-ui,-apple-system,sans-serif;
  font-size:17px;line-height:1.65;-webkit-font-smoothing:antialiased}
a{color:var(--teal);text-decoration:none}
a:hover{color:var(--teal-strong);text-decoration:underline;text-underline-offset:3px}
a:focus-visible{outline:2px solid var(--teal);outline-offset:3px;border-radius:3px}
.wrap{max-width:820px;margin:0 auto;padding:0 20px}

/* ---- masthead ---- */
.top{position:sticky;top:0;z-index:50;background:rgb(8 12 22/.7);
  backdrop-filter:blur(16px);border-bottom:1px solid var(--rule)}
.top .wrap{display:flex;align-items:center;justify-content:space-between;gap:16px;
  height:62px}
.brand{display:flex;align-items:center;gap:8px;font-weight:800;font-size:17px;color:var(--fg)}
.brand:hover{text-decoration:none;color:var(--fg)}
.brand svg{flex:0 0 26px}
.brand .bn{display:inline}
.brand .dot{color:var(--teal)}
.brand span.l{font-family:"JetBrains Mono",monospace;font-size:10.5px;font-weight:600;
  letter-spacing:.2em;text-transform:uppercase;color:var(--teal);margin-left:1px}
.top nav{display:flex;gap:20px;font-size:14.5px;color:var(--fg-muted)}
.top nav a{color:var(--fg-muted)}
.top nav a:hover{color:var(--teal)}

/* ---- article ---- */
article{padding:44px 0 20px}
.eyebrow{font-family:"JetBrains Mono",monospace;font-size:10.5px;font-weight:600;
  letter-spacing:.2em;text-transform:uppercase;color:var(--teal);margin:0 0 14px}
/* Headings are Manrope, as in the app and the homepage; the serif is reserved
   for italic accents there and is not used here. */
h1{font-weight:500;font-size:clamp(30px,4.6vw,44px);
  line-height:1.1;margin:0 0 14px;letter-spacing:-.03em;text-wrap:balance}
.dek{margin:0 0 22px;font-size:19px;color:var(--fg-muted);max-width:60ch}
h2{font-weight:600;font-size:24px;line-height:1.2;
  margin:44px 0 10px;letter-spacing:-.02em;text-wrap:balance}
h3{font-size:17px;font-weight:700;margin:28px 0 6px}
p{margin:0 0 17px;max-width:66ch}
ul,ol{max-width:66ch;padding-left:22px;margin:0 0 17px}
li{margin:0 0 9px}
li::marker{color:var(--fg-dim)}
strong,b{font-weight:700;color:var(--fg)}
hr{border:none;border-top:1px solid var(--rule);margin:40px 0}

.say{font-family:"JetBrains Mono",monospace;font-size:.88em;
  background:rgb(90 209 193/.12);color:var(--teal-strong);padding:2px 7px;border-radius:var(--r-xs);
  white-space:nowrap}
.ui{font-weight:700;color:var(--fg)}

/* ---- figures ----------------------------------------------------------
   Every diagram is inline SVG or plain markup: no image files, no external
   requests, and it themes off the same tokens as the page. Each one sits in
   a <figure> with a caption that says what to look at, because a diagram a
   reader has to decode is slower than the sentence it replaced. */
figure{margin:30px 0;max-width:66ch}
/* wider than the 66ch prose measure, never wider than the page: the box
   scrolls internally instead of pushing the whole document sideways. */
figure.wide{max-width:100%}
table.fig{min-width:420px}
.fig-box{border:1px solid var(--rule);border-radius:var(--r);background:var(--card);
  padding:20px 22px;overflow-x:auto}
figcaption{margin-top:10px;font-size:14px;color:var(--fg-muted);line-height:1.5}
figcaption b{color:var(--fg);font-weight:600}
figure svg{display:block;max-width:100%;height:auto}
.fig-lbl{font-family:"JetBrains Mono",monospace;font-size:10px;font-weight:600;
  letter-spacing:.14em;text-transform:uppercase;fill:var(--fg-dim)}
.fig-txt{font-family:Manrope,system-ui,sans-serif;font-size:12.5px;fill:var(--fg-muted)}
.fig-num{font-family:"JetBrains Mono",monospace;font-size:12px;fill:var(--fg)}
.fig-key{font-family:Manrope,system-ui,sans-serif;font-size:13px;font-weight:600;fill:var(--fg)}

/* ladder: an ordered list where the ORDER is the content */
.ladder{list-style:none;margin:0;padding:0;counter-reset:rung;max-width:none}
.ladder li{counter-increment:rung;display:grid;grid-template-columns:26px 1fr auto;
  gap:14px;align-items:baseline;padding:11px 0;border-bottom:1px solid var(--rule)}
.ladder li:last-child{border-bottom:none}
.ladder li::before{content:counter(rung);font-family:"JetBrains Mono",monospace;
  font-size:11px;font-weight:600;color:var(--teal);background:rgb(90 209 193/.12);
  width:22px;height:22px;border-radius:6px;display:grid;place-items:center}
.ladder .what{color:var(--fg);font-weight:600;font-size:15px}
.ladder .what span{display:block;font-weight:400;font-size:14px;color:var(--fg-muted);margin-top:2px}
.ladder .tag{font-family:"JetBrains Mono",monospace;font-size:10px;letter-spacing:.1em;
  text-transform:uppercase;color:var(--fg-dim);white-space:nowrap;padding-left:10px}
.ladder li.floor::before{color:var(--warm);background:rgb(255 153 102/.14)}
.ladder li.floor .tag{color:var(--warm)}

/* comparison + legend tables */
table.fig{border-collapse:collapse;width:100%;font-size:14px}
table.fig th{text-align:left;font-family:"JetBrains Mono",monospace;font-size:10px;
  letter-spacing:.12em;text-transform:uppercase;color:var(--fg-dim);font-weight:600;
  padding:0 16px 9px 0;border-bottom:1px solid var(--rule);white-space:nowrap}
table.fig td{padding:11px 16px 11px 0;border-bottom:1px solid var(--rule);
  color:var(--fg-muted);vertical-align:top;line-height:1.5}
table.fig tr:last-child td{border-bottom:none}
table.fig td.k{color:var(--fg);font-weight:600;white-space:nowrap}
.swatch{display:inline-block;width:11px;height:11px;border-radius:3px;margin-right:8px;
  vertical-align:baseline}

/* screenshots: real product, synthetic patients. A frame so a screenshot never
   reads as part of the page's own chrome. */
figure.shot .fig-box{padding:0;border:none;background:none}
figure.shot img{display:block;width:100%;border:1px solid var(--rule-2);border-radius:var(--r)}
figure.shot.tall img{max-width:380px;margin:0 auto}

/* "go do it" — the article's exit into the product. Reading about a screen and
   then being handed the next article is a closed loop; an article that describes
   a screen should end AT that screen. */
.act{margin:34px 0 0;padding:16px 18px;border-radius:var(--r);
  background:rgb(90 209 193/.09);border-left:3px solid var(--teal)}
.act .lbl{display:block;font-family:"JetBrains Mono",monospace;font-size:10px;
  font-weight:600;letter-spacing:.16em;text-transform:uppercase;color:var(--teal);
  margin-bottom:5px}
.act a{font-size:16px;font-weight:600}
.act p{margin:4px 0 0;font-size:14px;color:var(--fg-muted);max-width:60ch}

/* callout */

.note{border-left:3px solid var(--teal);background:rgb(90 209 193/.07);
  border-radius:0 var(--r) var(--r) 0;padding:16px 20px;margin:26px 0;max-width:66ch}
.note.warn{border-left-color:var(--warm);background:rgb(255 153 102/.08)}
.note > :last-child{margin-bottom:0}
.note p{font-size:16px}

/* phrase table */
.table{border:1px solid var(--rule);border-radius:var(--r);overflow:hidden;margin:24px 0;max-width:66ch}
table{width:100%;border-collapse:collapse;font-size:15.5px}
th{text-align:left;font-family:"JetBrains Mono",monospace;font-size:9.5px;font-weight:600;
  letter-spacing:.14em;text-transform:uppercase;color:var(--fg-dim);
  padding:12px 16px 8px;border-bottom:1px solid var(--rule)}
td{padding:11px 16px;border-top:1px solid var(--rule);vertical-align:top;color:var(--fg-muted)}
tr:first-child td{border-top:none}
td.q{width:47%;font-family:"JetBrains Mono",monospace;font-size:14px;color:var(--fg)}

/* ---- next / footer ---- */
.next{margin:52px 0 0;padding:20px 22px;border:1px solid var(--rule);border-radius:var(--r);
  background:var(--card);display:flex;justify-content:space-between;align-items:center;gap:16px;
  flex-wrap:wrap}
.next .lbl{font-family:"JetBrains Mono",monospace;font-size:9.5px;font-weight:600;
  letter-spacing:.14em;text-transform:uppercase;color:var(--fg-dim);display:block;margin-bottom:3px}
.next a{font-weight:700;font-size:17px}
footer.site{margin-top:60px;border-top:1px solid var(--rule);padding:26px 0 60px;
  color:var(--fg-dim);font-size:14.5px}
footer.site .wrap{display:flex;justify-content:space-between;gap:16px;flex-wrap:wrap}

/* ---- hub ---- */
.hub-hero{padding:56px 0 8px}

.tracks{display:flex;flex-direction:column;gap:18px;margin:34px 0 0}
.track{background:var(--card);border:1px solid var(--rule);border-radius:var(--r);padding:22px 24px}
.track header{display:flex;align-items:baseline;gap:11px;flex-wrap:wrap;margin-bottom:3px}
.track h2{font-size:22px;margin:0}
.badge{font-family:"JetBrains Mono",monospace;font-size:9.5px;font-weight:600;
  letter-spacing:.14em;text-transform:uppercase;color:var(--warm);border:1px solid currentColor;
  border-radius:99px;padding:3px 9px;white-space:nowrap;opacity:.85}
.track > p{color:var(--fg-dim);font-size:15px;margin:0 0 14px;max-width:64ch}
.track ol{list-style:none;counter-reset:a;padding:0;margin:0;max-width:none}
.track ol li{counter-increment:a;position:relative;padding:10px 0 10px 38px;
  border-top:1px solid var(--rule);margin:0;font-size:16px}
.track ol li:first-child{border-top:none}
.track ol li::before{content:counter(a);position:absolute;left:0;top:11px;
  width:23px;height:23px;display:grid;place-items:center;border-radius:var(--r-sm);
  background:rgb(90 209 193/.13);color:var(--teal);
  font-family:"JetBrains Mono",monospace;font-size:11px;font-weight:600}
.track li.soon{color:var(--fg-dim)}
.track li.soon::before{background:rgb(96 112 140/.16);color:var(--fg-dim)}
.soon-tag{font-family:"JetBrains Mono",monospace;font-size:9.5px;letter-spacing:.12em;
  text-transform:uppercase;color:var(--fg-dim);margin-left:8px}
.track li p{margin:2px 0 0;font-size:14.5px;color:var(--fg-dim);max-width:62ch}

@media (max-width:560px){
  body{font-size:16px}
  article{padding:32px 0 16px}
  /* A fixed-height flex row with a brand plus three links is tight on a narrow
     phone, so let it wrap rather than rely on it just fitting. Defensive: not
     a fix for an observed break. */
  .top .wrap{height:auto;flex-wrap:wrap;padding-top:12px;padding-bottom:12px;gap:6px 16px}
  .top nav{gap:16px;font-size:13.5px;flex-wrap:wrap}
  .brand{font-size:16px}
  .brand svg{width:22px;height:22px;flex:0 0 22px}
  h1{font-size:clamp(26px,7vw,34px)}
  .dek{font-size:17px}
  .fig-box{padding:16px 14px}
}
@media (prefers-reduced-motion:reduce){html{scroll-behavior:auto}*{transition:none!important}}
