/* Meditron site. Blue and sky are the two blues of the LiGHT logo; amber marks MOOVE sites. */
:root {
  --paper: #faf9f5;         /* warm ivory, as on anthropic.com */
  --ink: #14202e;
  --muted: #5a6676;
  --rule: #d3dae3;
  --blue: #0c43a0;
  --blue-wash: #eaf0fa;
  --sky: #68afe7;          /* LiGHT light blue */
  --sky-wash: #dcebf8;
  --amber: #eba548;
  --folder: #eef5fc;
  --band: #1e429a;         /* footer band, as on light-laboratory.org */
  --red: #ae3256;
  --green: #2f6b2f;
  --grey-bar: #b9c1cb;
  --globe-ink: #0c43a0;
  --marker: #efcd5f;        /* the Meditron cube's yellow */
  --dawn-low: #5b81c9;      /* the sky just above the horizon */
  --shot-dim: none;         /* screenshots of light pages: dimmed on a dark page */
  color-scheme: light dark;

  --font: 'Manrope', system-ui, sans-serif;

  --font-read: 'Source Serif 4', Georgia, serif;   /* quoted material: MOOVE questions, answers, quotes */
  --display: 'DM Serif Display', Georgia, serif;   /* stand-in for LiGHT's IvyPresto Headline SemiBold until the kit has that weight (its only weight, 400, matches Ivy 600); to switch back: 'ivypresto-headline' + the use.typekit.net/ssi4ehi.css link in index.html and meditronfo/index.html */
  --gutter: clamp(16px, 3.2vw, 46px);   /* LiGHT's page margin */
  --page: min(1500px, 100% - 2 * var(--gutter));   /* LiGHT's column */
  /* the type scale, the only text sizes on the site (display headings excepted): labels, secondary text,
     tool-page body (tracker, leaderboard, viewers), prose body, headings */
  --t-xs: 0.75rem;
  --t-sm: 0.875rem;
  --t-dense: 0.9375rem;
  --t-base: 1.0625rem;
  --t-md: 1.3125rem;
  --t-lg: 1.75rem;
  --t-xl: 2.375rem;
  --measure: 40rem;
  --col: 46rem;   /* the column every section below the globe shares: its text, figures, cards and the chat */
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --paper: #0d1724; --ink: #e6ebf2; --muted: #9aa7b8; --rule: #2a3a4f;
    --blue: #7fa6ec; --blue-wash: #16243a; --sky: #68afe7; --sky-wash: #19324f; --folder: #13233a; --band: #0a2a63;
    --red: #e0708f; --green: #7cc27c; --grey-bar: #4a596c; --marker: #efcd5f; --dawn-low: #33559f; --shot-dim: brightness(0.85);
  }
}
:root[data-theme="light"] { color-scheme: light; }
:root[data-theme="dark"] {
  color-scheme: dark;
  --paper: #0d1724; --ink: #e6ebf2; --muted: #9aa7b8; --rule: #2a3a4f;
  --blue: #7fa6ec; --blue-wash: #16243a; --sky: #68afe7; --sky-wash: #19324f; --folder: #13233a; --band: #0a2a63;
  --red: #e0708f; --green: #7cc27c; --grey-bar: #4a596c; --marker: #efcd5f; --dawn-low: #33559f; --shot-dim: brightness(0.85);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
body {
  margin: 0; background: var(--paper); color: var(--ink);
  font-family: var(--font); font-size: var(--t-base); line-height: 1.6;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: var(--blue); text-underline-offset: 0.15em; }
:focus-visible { outline: 3px solid var(--blue); outline-offset: 3px; }
h1, h2, h3 { line-height: 1.15; margin: 0; }
p { margin: 0 0 1rem; }
button { font: inherit; color: inherit; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -9999px; }
.skip:focus { left: 1rem; top: 0.5rem; z-index: 50; background: var(--paper); padding: 0.4rem 0.8rem; }

/* ---------- top line ---------- */
.top {
  position: absolute; inset: 0 0 auto 0; z-index: 5;
  display: flex; justify-content: space-between; align-items: center;
  padding: 1rem 1.25rem; font-size: var(--t-sm);
}
.top a { color: var(--muted); text-decoration: none; }
.top a:hover { color: var(--blue); }
.top-links a:hover { text-decoration: underline; text-decoration-thickness: 1.5px; }
.top-brand { display: flex; align-items: center; gap: 1rem; }
.top-lab img { height: 1.9rem; width: auto; }
/* LiGHT's four hosts, one ink like the footer's white logos; only EPFL where the line is short */
.top-hosts { list-style: none; margin: 0; padding: 0 0 0 1rem; border-left: 1px solid var(--rule); display: flex; align-items: center; gap: 1.1rem; }
.top-hosts img { display: block; width: auto; filter: brightness(0); opacity: 0.85; }
.top-hosts a:hover img { opacity: 1; }
.th-epfl { height: 1.05rem; } .th-ariadne { height: 1.8rem; } .th-ashoka { height: 1.8rem; } .th-c4ir { height: 2rem; }
@media (max-width: 1149px) { .top-hosts .th-more { display: none; } }
.top-lab .logo-mono { display: none; filter: invert(1); }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .top-lab .logo-color { display: none; }
  :root:not([data-theme="light"]) .top-lab .logo-mono { display: block; }
  :root:not([data-theme="light"]) .top-hosts img { filter: brightness(0) invert(1); }
}
:root[data-theme="dark"] .top-lab .logo-color { display: none; }
:root[data-theme="dark"] .top-lab .logo-mono { display: block; }
:root[data-theme="dark"] .top-hosts img { filter: brightness(0) invert(1); }
@media (max-width: 560px) { .top { padding-inline: 16px; } .top-brand { gap: 0.5rem; } .top-hosts { padding-left: 0.5rem; } .th-epfl { height: 0.72rem; } .top-lab img { height: 1.2rem; } .top-links { gap: 0.8rem; } .top-links a { font-size: var(--t-xs); } .top-code { display: none; } }
/* phones: the downloads stay one tap away, in the Openness section and the footer */
@media (max-width: 420px) { .top-download { display: none; } }
@media (max-width: 360px) { .top-lab img { height: 1.1rem; } .top-links { gap: 0.7rem; } }
.top-links { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 0.4rem 1.25rem; }
/* the main page: in the flow, so the cube starts under it */
.top-flow { position: relative; inset: auto; }
/* phones: the four links need the whole line, so they go under the logo */
@media (max-width: 480px) { .top-flow { flex-direction: column; gap: 0.5rem; } .top-flow .top-links { justify-content: center; flex-wrap: nowrap; gap: 0.9rem; white-space: nowrap; } }

/* ---------- the LiGHT header: logo left, the lab's menu right; a menu button on phones ---------- */
.lh {
  position: relative; z-index: 5; width: var(--page); margin: 0 auto;
  display: flex; justify-content: space-between; align-items: center; gap: 1rem;
  padding: 4.85rem 0 2.1rem;
}
.lh-logo img { height: 58px; width: auto; }
.lh-logo .logo-mono { display: none; filter: invert(1); }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .lh-logo .logo-color { display: none; }
  :root:not([data-theme="light"]) .lh-logo .logo-mono { display: block; }
}
:root[data-theme="dark"] .lh-logo .logo-color { display: none; }
:root[data-theme="dark"] .lh-logo .logo-mono { display: block; }
.lh-links { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 0.4rem 1.9rem; font-size: var(--t-base); }
.lh-links a { color: var(--ink); text-decoration: none; }
.lh-links a:hover, .lh-links a.is-here { color: var(--sky); }
.lh-links a.is-here { text-decoration: underline; text-underline-offset: 0.3em; }
.lh-links a { transition: color 0.2s; }
.lh-menu { display: none; }
@media (max-width: 900px) {
  .lh { padding-top: 1.5rem; padding-bottom: 1rem; }
  .lh-logo img { height: 2.2rem; }
  .lh-menu {
    display: grid; place-items: center; width: 2.75rem; height: 2.75rem; padding: 0;
    border: 0; background: none; cursor: pointer;
  }
  .lh-menu .bars, .lh-menu .bars::before, .lh-menu .bars::after {
    display: block; width: 1.9rem; height: 2px; background: var(--ink); content: ''; position: relative;
  }
  .lh-menu .bars::before { position: absolute; top: -0.6rem; }
  .lh-menu .bars::after { position: absolute; top: 0.6rem; }
  .lh-links {
    display: none; position: absolute; top: 100%; right: 0; z-index: 6;
    flex-direction: column; gap: 0; min-width: 12rem; padding: 0.5rem 0;
    background: var(--paper); border: 1px solid var(--rule); box-shadow: 0 12px 32px rgb(20 32 46 / 0.16);
  }
  .lh-links a { padding: 0.55rem 1.25rem; }
  .lh.open .lh-links { display: flex; }
}

/* ---------- the beam: LiGHT's two-blue banner with a typed function ---------- */
.beam {
  position: relative; overflow: hidden; width: var(--page); margin: 0 auto; border-radius: 12px;
  min-height: 342px; display: flex; align-items: center;
  padding: 2rem 13.2%;
}
.beam-bg { position: absolute; inset: 0; width: 100%; height: 100%; }
:root:not(.withbeam) .beam { display: none; }
.beam-eq { position: relative; margin: 0; color: #fff; font-family: var(--display); line-height: 1.15; }
.beam-lhs { display: block; font-weight: 700; font-size: clamp(2.2rem, 4vw, 3.6rem); }
.beam-fx { display: block; margin-top: 0.35rem; font-size: clamp(2rem, 3vw, 2.7rem); white-space: nowrap; }
.beam-fx i { font-weight: 700; margin-right: 0.15em; }
.beam-cursor { font-family: var(--font); font-weight: 300; margin-left: 0.05em; animation: beam-blink 0.85s steps(1) infinite; }
@keyframes beam-blink { 50% { opacity: 0; } }
@media (max-width: 900px) { .beam { min-height: 21rem; align-items: flex-end; padding: 1.75rem 1.5rem 3.5rem; } }
@media (max-width: 420px) { .beam-fx { font-size: var(--t-lg); } }
@media (prefers-reduced-motion: reduce) { .beam-cursor { display: none; } .beam-fx { white-space: normal; } }

/* buttons (the join section) */
.btn {
  display: inline-flex; align-items: center; padding: 0.5rem 1.15rem; border-radius: 999px;
  border: 1.5px solid var(--blue); color: var(--blue); background: transparent;
  font-weight: 700; font-size: var(--t-dense); text-decoration: none;
}
.btn:hover { background: var(--blue-wash); }
.btn-solid { background: var(--blue); color: var(--paper); }
.btn-solid:hover { background: var(--ink); border-color: var(--ink); }

/* ---------- hero: the cube, the name, then the globe rising from under the fold ---------- */
.hero {
  /* clipped sideways only; --gs: the globe's size */
  position: relative; overflow-x: clip; padding-bottom: 3.5rem; --gs: min(96svh, 96vw, 70rem);
}
/* on landing the globe's middle is level with the bottom of the screen (app.js); the name, the line and the buttons
   sit in the middle of the room above it */
.hero-center {
  display: flex; flex-direction: column; justify-content: center; min-height: calc(100svh - var(--gs) / 2 - 4rem);
  text-align: center; padding: 0 16px clamp(1.25rem, 4vh, 2.75rem);
}
/* the Meditron cube beside the name, in capitals in the font of the Meditron logo (static/img/meditron-logo.png), a little tighter */
@font-face { font-family: 'Chillax'; src: url('fonts/chillax-700.woff2') format('woff2'); font-weight: 700; font-style: normal; font-display: swap; }
.wordmark {
  display: flex; align-items: center; justify-content: center; gap: 0.2em;
  font-size: clamp(2.6rem, min(7.6vw, 11vh), 5.4rem); line-height: 1; color: var(--ink);
  font-family: 'Chillax', var(--font); font-weight: 700; letter-spacing: -0.035em; text-transform: uppercase;
}
.wordmark .cube { height: 1em; flex: none; }
.wordmark .cube img { height: 100%; width: auto; }
.tagline { margin: 1.4rem auto 1.1rem; max-width: 34rem; font-size: var(--t-md); font-weight: 600; line-height: 1.35; color: var(--ink); }
.talk {
  display: inline-block; padding: 0.8rem 1.4rem; border-radius: 999px;
  background: var(--blue); color: var(--paper); text-decoration: none; font-weight: 800; font-size: var(--t-base);
}
.talk { transition: background-color 0.2s, color 0.2s; }
.talk:hover { background: var(--ink); }
.hero-cta { display: flex; flex-wrap: wrap; justify-content: center; gap: 0.6rem; margin: 0; }
.talk-alt { background: transparent; color: var(--blue); box-shadow: inset 0 0 0 1.5px var(--blue); }
.talk-alt:hover { background: var(--blue-wash); }

/* ---------- the story: one screen, the globe running on its own clock (app.js) ---------- */
.story { position: relative; }
.story-stage { position: relative; height: 100svh; }
#globe {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%, calc(-50% + var(--drop, 0px)));   /* --drop: lower on landing (app.js) */
  width: var(--gs); height: var(--gs); touch-action: pan-y; cursor: grab;
  transition: opacity 0.6s ease;
}
#globe.pending { opacity: 0; }
#globe.dragging { cursor: grabbing; }
.story-rail { position: absolute; z-index: 3; left: var(--gutter); top: 50%; transform: translateY(-50%); width: 14rem; }
.story-rail h2 { font-size: var(--t-md); font-weight: 800; letter-spacing: -0.01em; margin-bottom: 0.9rem; }
.story-stops { list-style: none; margin: 0 0 0.9rem; padding: 0; }
.story-stops button {
  display: block; width: 100%; padding: 0.1rem 0 0.1rem 0.7rem; border: 0; border-left: 2px solid var(--rule); background: none;
  text-align: left; font-size: var(--t-sm); line-height: 1.45; color: var(--muted); cursor: pointer;
  transition: color 0.2s, border-color 0.2s;
}
.story-stops .lit button { color: var(--ink); border-left-color: var(--marker); }
.story-stops [aria-current] button { color: var(--blue); border-left-color: var(--blue); font-weight: 800; }
.story-stops button:hover { color: var(--blue); }
.story-tally { margin: 0 0 0.5rem; font-size: var(--t-sm); line-height: 1.4; color: var(--muted); }
.story-tally b { display: block; font-size: var(--t-md); font-weight: 800; color: var(--ink); }
.story-bar { display: none; }
.story-ctl { display: flex; align-items: center; gap: 1rem; margin: 0; font-size: var(--t-sm); }
.story-ctl button { padding: 0; border: 0; background: none; font-weight: 800; color: var(--blue); cursor: pointer; text-decoration: underline; text-underline-offset: 0.15em; }
.story-card {
  position: absolute; z-index: 4; left: 0; top: 0; width: max-content; max-width: min(23rem, 100% - 32px);
  background: var(--paper); border: 1.5px solid var(--ink); border-radius: 6px;
  padding: 0.7rem 0.95rem; font-size: var(--t-sm); line-height: 1.4;
  box-shadow: 0 6px 16px rgb(20 32 46 / 0.18); pointer-events: none;
}
.story-card small { display: block; font-size: var(--t-xs); font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; color: var(--blue); }
.story-card strong { display: block; margin: 0.1rem 0 0.25rem; font-size: var(--t-md); font-weight: 800; line-height: 1.2; }
.story-card b { display: block; font-weight: 800; }
/* a year's sites and their votes, when its year is clicked on the rail */
.story-card .sites { display: none; grid-template-columns: auto auto; gap: 0 1rem; margin-top: 0.4rem; color: var(--muted); font-style: normal; }
.story-card .sites i { font-style: normal; }
.story-card .sites i:nth-child(even) { text-align: right; font-variant-numeric: tabular-nums; }
.story-card.open .sites { display: grid; }
/* the text, and MOOVE under it as a card like the page's other links (.feature-thumb) */
.ocean-card {
  position: absolute; z-index: 4; left: 0; top: 0; width: min(30rem, 100% - 32px); visibility: hidden;
  background: var(--paper); border: 1.5px solid var(--ink); border-radius: 6px;
  padding: 1.1rem 1.2rem 1.2rem; box-shadow: 0 10px 28px rgb(9 18 40 / 0.35);
}
.ocean-card h2 { font-size: var(--t-lg); font-weight: 800; letter-spacing: -0.02em; margin-bottom: 0.4rem; }
.ocean-card p { font-size: var(--t-dense); line-height: 1.5; margin: 0; }
/* MOOVE's logo as the call to action: the logo is a mask over a gradient, and a glint sweeps across it (faster on hover) */
.moove-cta { display: flex; flex-direction: column; align-items: flex-start; gap: 0.45rem; margin-top: 1.1rem; color: var(--ink); text-decoration: none; }
.moove-logo {
  display: block; width: min(15rem, 100%); aspect-ratio: 1146.99 / 187.89;
  background: linear-gradient(105deg, var(--ink) 0 40%, var(--sky) 46%, #fff 50%, var(--sky) 54%, var(--ink) 60% 100%) 100% 0 / 300% 100%;
  -webkit-mask: url(img/moove-logo.svg) left center / contain no-repeat; mask: url(img/moove-logo.svg) left center / contain no-repeat;
  animation: moove-glint 4.5s ease-in-out infinite; transition: transform 0.2s ease;
}
.moove-cta-label { font-size: var(--t-sm); font-weight: 700; color: var(--blue); }
.moove-cta:hover .moove-logo, .moove-cta:focus-visible .moove-logo { animation-duration: 1.4s; transform: translateY(-1px); }
.moove-cta:hover .moove-cta-label, .moove-cta:focus-visible .moove-cta-label { text-decoration: underline; text-underline-offset: 3px; }
@keyframes moove-glint { 0%, 55% { background-position: 100% 0; } 100% { background-position: 0 0; } }
@media (prefers-reduced-motion: reduce) { .moove-logo { animation: none; } }
/* no room beside the globe: the rail folds to a line and a bar over it */
@media (max-aspect-ratio: 3/2), (max-width: 900px) {
  .story-rail { top: 0.75rem; left: 50%; transform: translateX(-50%); width: min(32rem, 100% - 32px); text-align: center; padding: 0.4rem 0.7rem 0.5rem; background: color-mix(in srgb, var(--paper) 88%, transparent); border-radius: 6px; }
  .story-rail h2 { font-size: var(--t-base); margin-bottom: 0.15rem; }
  .story-stops { display: none; }
  .story-tally { margin: 0; font-size: var(--t-xs); }
  .story-tally b { display: inline; font-size: inherit; }
  .story-bar { display: block; height: 3px; margin: 0.3rem 0; background: var(--rule); }
  .story-bar::after { content: ''; display: block; height: 100%; background: var(--blue); transform: scaleX(var(--p, 0)); transform-origin: left; }
  .story-ctl { justify-content: center; font-size: var(--t-xs); }
}
/* phones: a globe wider than the screen, the site's card docked under it */
@media (max-width: 900px) {
  .hero { --gs: min(135vw, 84svh); }
  #globe { top: 47%; }
  .story-card { left: 16px; top: auto; right: 16px; bottom: 1rem; width: auto; max-width: none; }
  .ocean-card { left: 16px; top: auto; right: 16px; bottom: 1rem; width: auto; }
}
/* reduced motion: no tour, the globe rests on its last view with every site lit */
.story.still .story-ctl { display: none; }
.story.still .story-stops { display: none; }
.story.still .ocean-card { visibility: visible; }

.mini-bars { display: grid; gap: 0.35rem; margin-top: 0.4rem; font-size: var(--t-sm); }
.mini { display: grid; grid-template-columns: 6.2rem 1fr 2.4rem; gap: 0.5rem; align-items: center; }
.mini-track { height: 0.7rem; }
.mini-track span { display: block; height: 100%; background: var(--grey-bar); }
.mini.ours .mini-track span { background: var(--blue); }
.mini-val { text-align: right; font-weight: 800; font-variant-numeric: tabular-nums; }

/* Small screens */
@media (max-width: 900px) {
  .hero { padding: 0 0 2rem; }
}

.hosts img { filter: brightness(0) invert(1); width: auto; }
.hosts-label { margin: 0; }
.hosts-list {
  list-style: none; margin: 0; padding: 0;
  display: flex; flex-wrap: wrap; align-items: center; gap: 1rem 2.25rem;
}
.h-epfl { height: 0.95rem; } .h-ariadne { height: 1.6rem; } .h-ashoka { height: 1.6rem; } .h-c4ir { height: 1.75rem; }
.h-epfl-ai { height: 1.75rem; } .h-eth-ai { height: 1.9rem; } .h-cscs { height: 1.5rem; }
.foot-logos { display: grid; grid-template-columns: auto auto; align-items: center; gap: 1.1rem 1.25rem; }
.foot-logos .hosts { display: contents; }

.site-tip {
  position: absolute; z-index: 4; pointer-events: none;
  transform: translate(-50%, calc(-100% - 14px));
  background: var(--paper); border: 1.5px solid var(--ink); border-radius: 6px;
  padding: 0.5rem 0.75rem; font-size: var(--t-sm); line-height: 1.4; white-space: nowrap;
  box-shadow: 0 6px 16px rgb(20 32 46 / 0.18);
}
.site-tip strong { display: block; font-size: var(--t-dense); font-weight: 800; }
.site-tip span { display: block; color: var(--muted); }

/* ---------- what is Meditron, and its timeline ---------- */
/* every section below the globe has the same padding above and below its content, bands included, so the space between any two is the same */
:root { --sec: 6.5rem; }
@media (max-width: 560px) { :root { --sec: 4rem; } }
.why-section { padding: var(--sec) 16px; }
.why-wrap { max-width: var(--col); margin: 0 auto; }
/* every section below the hero: one heading size, one text size and colour (the citation stays small and grey) */
.why-section h2, .chat-section h2, .feature-section h2, .cite-section h2, .credits h2 { font-size: var(--t-xl); font-weight: 800; letter-spacing: -0.02em; color: var(--ink); margin-bottom: 0.75rem; }
.why-section p, .feature-section p, .credits p { font-size: var(--t-base); line-height: 1.5; color: var(--ink); }
.why-wrap p + p { margin-top: 0.9rem; }
/* four steps on one line from 900px; below that a vertical list on a left rule */
.timeline { list-style: none; margin: 3rem auto 0; padding: 0; max-width: var(--col); display: grid; gap: 1.5rem; }
.timeline li { position: relative; padding-left: 1.5rem; border-left: 2px solid var(--rule); }
.timeline li::before {
  content: ""; position: absolute; left: -7px; top: 0.3rem; width: 12px; height: 12px;
  background: var(--paper); border: 2px solid var(--blue);
}
.timeline .tl-now::before { background: var(--marker); border-color: var(--ink); }
.tl-year { display: block; font-size: var(--t-sm); font-weight: 800; letter-spacing: 0.06em; color: var(--muted); }
.timeline strong { display: block; margin-top: 0.15rem; font-size: var(--t-base); font-weight: 800; }
.timeline strong a { text-decoration: none; }
.timeline strong a:hover { text-decoration: underline; }
.tl-tag { display: inline-block; margin-top: 0.35rem; padding: 0.05rem 0.5rem; font-size: var(--t-xs); font-weight: 700; background: var(--blue-wash); color: var(--blue); }
.tl-now .tl-tag { background: var(--marker); color: #14202e; }
.timeline p { margin-top: 0.4rem; font-size: var(--t-dense); line-height: 1.45; color: var(--ink); }
@media (min-width: 900px) {
  .timeline { grid-template-columns: repeat(4, 1fr); gap: 0 1.25rem; }
  .timeline li { padding: 1.4rem 0 0; border-left: 0; border-top: 2px solid var(--rule); }
  .timeline li::before { left: 0; top: -7px; }
}

/* ---------- chat ---------- */
/* the chat is a band across the page, like Join us; on the column, the heading and the cube on its left edge,
   and everything else (the answers, the questions, the box and the lines under it) on one line right of the cube */
.chat-section { padding: var(--sec) 16px; background: var(--blue-wash); --indent: 2.6rem; }
.chat-section > h2 { max-width: var(--col); margin: 0 auto 1.25rem; }
.chat-wrap {
  position: relative; max-width: var(--col); margin: 0 auto; padding-left: var(--indent);
}
.chat-log { display: flex; flex-direction: column; gap: 1rem; margin: 0 0 1rem; }
.msg { max-width: 92%; padding: 0.75rem 1rem; border-radius: 12px; line-height: 1.55; }
.msg p { margin: 0 0 0.5rem; } .msg p:last-child { margin: 0; }
.msg.bot :is(h1, h2, h3, h4) { font-size: var(--t-base); font-weight: 800; margin: 1rem 0 0.4rem; }
.msg.bot ul, .msg.bot ol { margin: 0.3rem 0 0.6rem; padding-left: 1.3rem; }
.msg.bot li { margin: 0.15rem 0; }
.msg.bot hr { border: 0; border-top: 1px solid var(--rule); margin: 0.9rem 0; }
.msg.bot blockquote { margin: 0.6rem 0; padding-left: 0.8rem; border-left: 3px solid var(--sky); }
.msg.bot table { min-width: 0; width: 100%; font-size: var(--t-sm); margin: 0.5rem 0 0.8rem; display: block; overflow-x: auto; }
.msg.bot th, .msg.bot td { padding: 0.3rem 0.5rem; vertical-align: top; }
.msg.user { align-self: flex-end; background: var(--blue); color: var(--paper); border-bottom-right-radius: 3px; white-space: pre-wrap; }
.msg-row { align-self: flex-start; display: flex; gap: 0.6rem; align-items: flex-start; max-width: calc(100% + var(--indent)); margin-left: calc(-1 * var(--indent)); }
.msg-row .msg { min-width: 0; max-width: calc(100% - var(--indent)); }   /* up to the box's right edge */
.chat-cube { flex: none; width: calc(var(--indent) - 0.6rem); margin-top: 0.15rem; }
.chat-cube img { width: 100%; height: auto; }
/* the Meditron cube, in its own colours on every background */
.cube { display: inline-block; }
/* the sharp corner points at the cube, which sits at the top left of the answer */
.msg.bot { align-self: flex-start; background: var(--paper); border-top-left-radius: 3px; }
.msg.bot.error { background: none; border: 1.5px solid var(--red); color: var(--ink); }
/* the example questions, as pills under the greeting */
.chat-suggest { display: flex; flex-wrap: wrap; gap: 0.5rem; margin: 0 0 1.25rem; }
.chat-suggest[hidden] { display: none; }
.chat-suggest button {
  background: var(--paper); border: 1.5px solid var(--sky); border-radius: 999px; padding: 0.45rem 1rem;
  font-size: var(--t-sm); text-align: left; cursor: pointer; line-height: 1.35; color: var(--blue);
}
.chat-suggest button:hover { background: var(--sky-wash); border-color: var(--blue); }
.chat-form { display: flex; gap: 0.6rem; align-items: stretch; }   /* Send as tall as the box */
.chat-form textarea {
  flex: 1; font: inherit; color: inherit; background: var(--paper); resize: vertical; min-height: 3.6rem;
  border: 2px solid var(--blue); border-radius: 12px; padding: 0.8rem 1rem;
}
.send {
  border: 0; border-radius: 12px; padding: 0 1.5rem; background: var(--blue); color: var(--paper);
  font-weight: 800; cursor: pointer;
}
.send:disabled, .chat-form textarea:disabled { opacity: 0.5; cursor: not-allowed; }
.chat-disclaimer { display: flex; align-items: center; gap: 0.35rem; font-size: var(--t-xs); color: var(--muted); margin: 0.6rem 0 0; }
.chat-disclaimer svg { flex: none; }
.chat-status { font-size: var(--t-sm); color: var(--muted); margin: 0.6rem 0 0; min-height: 1.4em; }
.chat-status:empty { margin: 0; min-height: 0; }   /* nothing to say: no room taken under the band's content */
.chat-model { font-size: var(--t-sm); color: var(--muted); margin: 0.4rem 0 0.8rem; }
.chat-model a { font-weight: 700; }
@media (max-width: 560px) { .chat-section { --indent: 2.1rem; } }

/* ---------- the commitments and the game: a heading, a line, a figure and a linked thumbnail ---------- */
.feature-section { padding: var(--sec) 16px; }
.feature-wrap { max-width: var(--col); margin: 0 auto; }
.feature-wrap > .feature-fig { margin: 2rem 0 0; }
.feature-fig + .feature-thumb { margin-top: 2.5rem; }
/* a link as a card, like a Substack post's: the picture across the top, a band under it with the title in the headline
   face, a grey line and a small line in capitals; the whole card is the link, with no button or link text */
.feature-thumb {
  display: block; margin-top: 1.5rem; overflow: hidden; text-decoration: none; color: var(--ink);
  background: var(--paper); border: 1px solid var(--rule); border-radius: 12px; box-shadow: 0 4px 18px rgb(20 32 46 / 0.08);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.feature-thumb:hover, .feature-thumb:focus-visible { transform: translateY(-3px); box-shadow: 0 12px 32px rgb(20 32 46 / 0.14); }
.feature-thumb img { display: block; width: 100%; height: auto; border-bottom: 1px solid var(--rule); filter: var(--shot-dim); }
.feature-body { display: block; padding: 1.1rem 1.35rem 1.25rem; }
.feature-body strong { display: block; font-size: var(--t-md); line-height: 1.25; }
.feature-body > span { display: block; margin-top: 0.35rem; font-size: var(--t-dense); line-height: 1.5; color: var(--muted); }
.feature-body small { display: block; margin-top: 0.6rem; font-size: var(--t-xs); font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted); text-decoration: none; }
@media (max-width: 560px) { .feature-body { padding: 0.9rem 1rem 1rem; } }
/* a commitment comes in as the scroll reaches it (app.js); it lights up while the beam types its name */
.commitment h2 { transition: color 0.3s; }
.commitment.is-lit h2 { color: var(--blue); }
@media (prefers-reduced-motion: no-preference) {
  .commitment :is(h2, p) { transition: color 0.3s, opacity 0.5s, translate 0.5s; }
  .commitment .feature-fig { transition: opacity 0.5s 0.15s, translate 0.5s 0.15s; }
  .commitment .feature-thumb { transition: transform 0.2s ease, box-shadow 0.2s ease, opacity 0.5s 0.15s, translate 0.5s 0.15s; }
  .commitment.reveal:not(.is-in) :is(h2, p, .feature-fig, .feature-thumb) { opacity: 0; translate: 0 1.5rem; }
}
@media (prefers-reduced-motion: reduce) { .feature-thumb { transition: none; } .feature-thumb:hover { transform: none; } }

/* ---------- tables and figures, on the main page and the MeditronFO page ---------- */
/* chart hues by openness, validated (dataviz validate_palette.js) against --paper in each mode */
:root { --c-fully: #2557b8; --c-weights: #c77406; --c-arrow: #9aa3ad; --c-ci: #8d98a6; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) { --c-fully: #5f8fe0; --c-weights: #bb8233; --c-arrow: #5d6b7d; --c-ci: #6d7b8e; }
}
:root[data-theme="dark"] { --c-fully: #5f8fe0; --c-weights: #bb8233; --c-arrow: #5d6b7d; --c-ci: #6d7b8e; }

.m-scroll { overflow-x: auto; }
.m-table { border-collapse: collapse; width: 100%; font-size: 0.92rem; font-variant-numeric: tabular-nums; }
.m-table th, .m-table td { padding: 0.5rem 0.65rem; text-align: right; border-bottom: 1px solid var(--rule); white-space: nowrap; }
.m-table th:first-child { text-align: left; }
.m-table thead th { font-size: 0.8rem; color: var(--muted); font-weight: 700; border-bottom: 1.5px solid var(--ink); vertical-align: bottom; }
.m-table tbody th { font-weight: 600; }
.m-table tr.ours th { font-weight: 800; }
.m-table tr.ours { background: var(--blue-wash); }
.m-open td { text-align: center; }
.m-open thead th:not(:first-child) { text-align: center; white-space: normal; min-width: 5.5rem; }
.m-open td.yes { color: var(--ink); font-weight: 700; }
.m-open td.yes::before { content: "\2713\00a0"; color: var(--green); }
.m-open td.no { color: var(--muted); }
.m-open td.no::before { content: "\2014\00a0"; }


/* figures: a bordered card per chart, text tabs above, centred caption */
.m-fig { margin: 2rem 0 0; }
.m-fig figcaption { font-size: 0.85rem; color: var(--muted); max-width: 46rem; margin: 0.9rem auto 0; text-align: center; }
.m-tabs { display: flex; flex-wrap: wrap; gap: 0.25rem 1.25rem; margin-bottom: 0.85rem; }
.m-tabs button { border: 0; background: none; padding: 0.2rem 0; font-weight: 700; color: var(--muted); cursor: pointer; }
.m-tabs button.on { color: var(--ink); }
.m-tabs button:hover { color: var(--ink); }
.m-card { border: 1px solid var(--ink); padding: 1.25rem 1.5rem 1rem; background: var(--paper); }
.m-card-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 0.25rem 1rem; }
.m-card-head h4 { margin: 0; font-size: 1.12rem; font-weight: 700; }
.m-card-head span { font-size: 0.9rem; color: var(--muted); }
.m-legend { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 0.35rem 1.25rem; font-size: 0.88rem; font-weight: 700; margin: 1rem 0 0.75rem; }
.m-legend span { display: inline-flex; align-items: center; gap: 0.45rem; }
.k-dot { width: 0.85rem; height: 0.85rem; border-radius: 50%; display: inline-block; border: 1.25px solid var(--ink); }
.k-dot.fully { background: var(--c-fully); } .k-dot.weights { background: var(--c-weights); }
.k-circle { width: 0.8rem; height: 0.8rem; border-radius: 50%; background: var(--ink); display: inline-block; }
.k-hollow { width: 0.85rem; height: 0.85rem; border-radius: 50%; border: 1.25px solid var(--ink); background: var(--paper); display: inline-block; }
.k-star { width: 1rem; height: 1rem; display: inline-block; background: var(--ink);
  clip-path: polygon(50% 0, 61% 35%, 98% 35%, 68% 57%, 79% 91%, 50% 70%, 21% 91%, 32% 57%, 2% 35%, 39% 35%); }
.k-line { width: 1.4rem; height: 0; border-top: 2px solid var(--c-fully); display: inline-block; }
@media (max-width: 560px) {
  .m-card { padding: 1rem 0.75rem 0.75rem; margin: 0 -4px; }
  .m-legend { justify-content: flex-start; font-size: 0.8rem; gap: 0.3rem 0.9rem; }
}
.m-chart { width: 100%; }
.m-chart svg { display: block; width: 100%; height: auto; overflow: visible; }
.m-chart text { font-family: var(--font); }
.m-chart .grid { stroke: var(--rule); }
.m-chart .axis { stroke: var(--ink); stroke-width: 1; }
.m-chart .tick { fill: var(--ink); font-size: 12px; opacity: 0.8; }
.m-chart .axlab { fill: var(--ink); font-size: 13px; }
.m-chart .lbl { fill: var(--ink); font-size: 11px; }
.m-chart .lbl.fo { font-weight: 700; }
.m-chart .lbl.dim { fill: var(--muted); }
.m-chart .front { fill: none; stroke-width: 2.5; stroke-linejoin: round; }
.m-chart .pt { cursor: default; }
.m-chart .pt .mk { stroke: var(--ink); stroke-width: 1.25; }
.m-chart .pt.dim { opacity: 0.4; }
.m-chart .pt:hover .mk, .m-chart .pt:focus .mk { stroke-width: 2.5; }
.m-chart .hit { fill: transparent; }
.m-details { margin-top: 0.75rem; font-size: var(--t-sm); text-align: center; }
.m-details summary { cursor: pointer; color: var(--blue); font-weight: 700; }
.m-details .m-table { margin-top: 0.5rem; text-align: left; }

.m-tip {
  position: fixed; z-index: 60; pointer-events: none; max-width: 18rem;
  background: var(--ink); color: var(--paper); border-radius: 6px; padding: 0.55rem 0.7rem;
  font-size: 0.8rem; line-height: 1.4; box-shadow: 0 4px 14px rgb(0 0 0 / 0.2);
}
.m-tip b { font-weight: 800; }
.m-tip .row { display: flex; justify-content: space-between; gap: 1rem; font-variant-numeric: tabular-nums; }

/* ---------- cite ---------- */
.cite-section { padding: var(--sec) 16px; }
.cite-wrap { max-width: var(--col); margin: 0 auto; }
.cite-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 0.75rem 1rem; margin-bottom: 0.75rem; }
.cite-head h2 { margin-bottom: 0; }
.cite-copy {
  border: 2px solid var(--blue); background: var(--paper); color: var(--blue);
  border-radius: 999px; padding: 0.35rem 1rem; font-weight: 800; font-size: var(--t-sm); cursor: pointer;
}
.cite-copy:hover { background: var(--blue-wash); }
.cite-ref { color: var(--muted); font-size: var(--t-dense); }
.bibtex {
  margin: 0; padding: 1rem 1.2rem; overflow-x: auto;
  background: var(--folder); border-left: 4px solid var(--sky);
  font-size: var(--t-xs); line-height: 1.5;
}

/* ---------- join: one path per kind of contributor ---------- */
.join-section { padding: var(--sec) 16px; background: var(--blue-wash); }
.join-wrap { max-width: var(--col); margin: 0 auto; }
.join-text h2 { font-size: var(--t-xl); margin-bottom: 0.75rem; }
.join-text > p { font-size: var(--t-base); line-height: 1.5; margin: 0; }
/* the two ways in, side by side and as tall as each other, their buttons on one line at the bottom */
.join-paths { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.25rem; margin-top: 1.5rem; }
.join-path { display: flex; flex-direction: column; align-items: flex-start; padding: 1.25rem 1.35rem 1.35rem; background: var(--paper); border: 1px solid var(--rule); border-radius: 12px; }
.join-path h3 { font-size: var(--t-md); margin-bottom: 0.4rem; }
.join-path p { font-size: var(--t-dense); line-height: 1.5; color: var(--muted); flex: 1; margin-bottom: 1.25rem; }
@media (max-width: 560px) { .join-paths { grid-template-columns: 1fr; } }

/* ---------- contact and credits, just above the footer ---------- */
.credits {
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.3fr); gap: 1.5rem 2.5rem;
  max-width: calc(var(--col) + 32px); margin: 0 auto; padding: var(--sec) 16px;
}
.credits p { margin: 0; }
/* the team panel: a row of faces and a plain link under the contact line */
.team-link { display: inline-block; margin-top: 1.1rem; text-decoration: none; }
.team-faces { display: flex; }
.team-faces img { width: 2.6rem; height: 2.6rem; border-radius: 50%; object-fit: cover; border: 2px solid var(--paper); background: var(--paper); transition: translate 0.2s ease; }
.team-faces img + img { margin-left: -0.7rem; }
.team-label { display: inline-block; margin-top: 0.5rem; font-weight: 800; color: var(--blue); }
.team-label::after { content: " →"; }
.team-link:hover .team-label, .team-link:focus-visible .team-label { text-decoration: underline; }
.team-link:hover .team-faces img, .team-link:focus-visible .team-faces img { translate: 0 -2px; }
@media (prefers-reduced-motion: reduce) { .team-faces img { transition: none; } .team-link:hover .team-faces img { translate: none; } }
.credits a { white-space: nowrap; }
@media (max-width: 640px) { .credits { grid-template-columns: 1fr; } }
/* the Swiss AI Initiative, in ink */
.credit-logos { list-style: none; margin: 1.1rem 0 0; padding: 0; display: flex; flex-wrap: wrap; align-items: center; gap: 1rem 1.75rem; }
.credit-logos img { width: auto; filter: brightness(0); opacity: 0.8; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .credit-logos img { filter: brightness(0) invert(1); } }
:root[data-theme="dark"] .credit-logos img { filter: brightness(0) invert(1); }

/* ---------- footer: a LiGHT navy band ---------- */
.foot { background: var(--band); color: rgb(255 255 255 / 0.75); padding: 2.25rem 2.5rem; font-size: var(--t-sm); }
.foot a { color: #fff; text-underline-offset: 0.2em; }
.foot :focus-visible { outline-color: var(--sky); }
.foot-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1.25rem 2.5rem; }
.foot-logo { height: 1.9rem; width: auto; filter: invert(1); }
.foot-links { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 0.4rem 1.25rem; max-width: 21rem; }
.foot-copy { flex-basis: 100%; margin: 0.4rem 0 0; text-align: right; color: #fff; }
.foot-links a { color: var(--sky); }
.foot-links a:hover { color: #fff; }
.hosts { display: flex; align-items: center; gap: 1.25rem; }
@media (max-width: 1099px) { .foot-links { justify-content: flex-start; max-width: none; } .foot-copy { text-align: left; } }
@media (min-width: 1100px) {
  .foot-row { display: grid; grid-template-columns: auto 1fr auto; }
  .hosts { justify-content: center; }
  .foot-logos { justify-content: center; }
}
@media (max-width: 640px) {
  .foot { padding-inline: 16px; }
  .hosts-label { display: none; }  /* the section keeps it as its aria-label */
  .foot-logos { grid-template-columns: auto; }
  .hosts-list { flex-wrap: nowrap; gap: 1rem; }
  .foot-row { gap: 1.1rem; }
}

/* ---------- the LiGHT footer, as on light-laboratory.org: logo, the four host tiles from about a quarter in, three links right ---------- */
.lf { background: var(--band); color: #fff; padding: 2.4rem 0; }
.lf :focus-visible { outline-color: var(--sky); }
/* the hosts start where the page's text column does; -5px is the EPFL tile's transparent margin, so its ink lines up */
.lf-row { width: var(--page); margin: 0 auto; display: grid; grid-template-columns: calc((100% - var(--col)) / 2) auto 1fr; align-items: center; gap: 1.5rem 0; }
.lf-logo img { width: 166px; height: auto; }
.lf-hosts { list-style: none; margin: 0 0 0 -5px; padding: 0; display: flex; gap: 10px; }
.lf-hosts img { width: 130px; height: auto; }
.lf-links { justify-self: end; display: flex; flex-direction: column; align-items: flex-end; font-size: var(--t-base); line-height: 1.6; }
.lf-links a { color: var(--sky); text-underline-offset: 0.15em; }
.lf-links a:hover { color: #fff; }
.lf-copy { margin: 1.9rem 0 0; font-size: var(--t-sm); }
@media (max-width: 1100px) {
  .lf-row { grid-template-columns: auto 1fr; }
  .lf-hosts { grid-column: 1 / -1; grid-row: 2; flex-wrap: wrap; }
}
@media (max-width: 560px) {
  .lf-row { grid-template-columns: 1fr; justify-items: start; }
  .lf-hosts img { width: 80px; }
  .lf-links { justify-self: start; align-items: flex-start; }
}

/* ---------- /400 (?w400): every title at regular weight, on both pages, as the two names already are ---------- */
:root.w400 :is(.why-section, .chat-section, .feature-section, .join-section, .cite-section, .credits) :is(h2, h3),
:root.w400 :is(.timeline strong, .team-label, .panel-tab, .pubs a),
:root.w400 .panel-body :is(h2, h3, h4, .pub-gen),
:root.w400 :is(.m-sec h2, .m-h3, .m-card-head h4) { font-weight: 400; }

/* ---------- panel (opened folder) ---------- */
.panel {
  width: min(62rem, calc(100vw - 2rem)); max-height: calc(100svh - 2rem); padding: 0;
  border: 1.5px solid var(--blue); border-radius: 0; background: var(--paper); color: var(--ink);
  box-shadow: 0 24px 60px rgb(20 32 46 / 0.3);
}
.panel::backdrop { background: rgb(13 23 36 / 0.45); }
.panel[open] { display: flex; flex-direction: column; }
@media (prefers-reduced-motion: no-preference) {
  .panel[open] { animation: open-up 0.28s cubic-bezier(.2,.8,.3,1) both; }
  @keyframes open-up { from { opacity: 0; translate: 0 2rem; } }
}
.panel-head {
  display: flex; justify-content: space-between; align-items: center;
  padding: 0.6rem 0.8rem 0.6rem 1.25rem; background: var(--blue); color: var(--paper);
}
.panel-tab { font-weight: 800; }
.panel-close { background: none; color: inherit; border: 1.5px solid currentColor; padding: 0.25rem 0.8rem; cursor: pointer; font-weight: 700; font-size: var(--t-sm); }
.panel-close:hover { background: var(--paper); color: var(--blue); }
.panel-body { overflow-y: auto; padding: 1.75rem clamp(1rem, 4vw, 2.75rem) 2.5rem; }
.panel-body > * { max-width: var(--measure); }
.panel-body h2 { font-size: var(--t-xl); font-weight: 800; letter-spacing: -0.02em; margin-bottom: 0.9rem; }
.panel-body h3 { font-size: var(--t-md); font-weight: 800; margin: 2.5rem 0 0.75rem; }
.panel-body h4 { font-size: var(--t-base); font-weight: 800; margin: 1.5rem 0 0.6rem; }
.lead { font-size: var(--t-base); }
.note { font-size: var(--t-sm); color: var(--muted); }
.links { display: flex; flex-wrap: wrap; gap: 1.25rem; margin-top: 1.5rem; font-weight: 700; }
.points { padding-left: 1.2rem; } .points li { margin: 0.3rem 0; }

.bars { list-style: none; margin: 1.25rem 0; padding: 0; }
.bars li { display: grid; grid-template-columns: minmax(0, 15rem) minmax(0, 1fr) 3rem; gap: 0.75rem; align-items: center; padding: 0.45rem 0; border-top: 1px solid var(--rule); }
.bars li:last-child { border-bottom: 1px solid var(--rule); }
.bars .who { font-size: var(--t-dense); line-height: 1.3; }
.bars .who small { display: block; color: var(--muted); font-size: var(--t-xs); }
.bars .track { height: 0.9rem; position: relative; }
.bars .fill { display: block; height: 100%; background: var(--grey-bar); }
.bars li.ours .fill { background: var(--blue); }
.bars li.ours .who { font-weight: 700; }
.bars .val { text-align: right; font-weight: 800; font-variant-numeric: tabular-nums; }
.bars.half .track::after { content: ""; position: absolute; left: 50%; top: -0.3rem; bottom: -0.3rem; border-left: 1.5px dashed var(--muted); }
@media (max-width: 560px) {
  .bars li { grid-template-columns: 1fr 3rem; }
  .bars .track { grid-column: 1 / -1; grid-row: 2; }
}

.table-scroll { overflow-x: auto; }
table { border-collapse: collapse; font-size: var(--t-dense); min-width: 34rem; }
th, td { padding: 0.45rem 0.7rem; border-bottom: 1px solid var(--rule); text-align: left; }
th { font-size: var(--t-sm); color: var(--muted); font-weight: 700; vertical-align: bottom; }
td.yes { color: var(--green); font-weight: 700; } td.no { color: var(--muted); }
tr.ours td { font-weight: 700; background: var(--blue-wash); }

/* team panel: one short line per person, as on metagov.org/people */
.panel-body > .people-cols { max-width: none; display: grid; grid-template-columns: repeat(auto-fit, minmax(16rem, 1fr)); gap: 0 3rem; }
.people-cols h3 { font-size: var(--t-base); margin: 1.5rem 0 0.6rem; }
.people { list-style: none; padding: 0; margin: 0; font-size: var(--t-dense); }
.people li { margin: 0.3rem 0; }
.people a { text-decoration: none; }
.people a:hover { text-decoration: underline; }
.people li > :is(a, .name) + span { margin-left: 0.35rem; font-size: var(--t-sm); font-style: italic; color: var(--muted); }
/* a small round photo before each name: LiGHT's headshots, its blue backdrop where there is none */
.people .face { display: inline-block; width: 2.6rem; height: 2.6rem; margin-right: 0.7rem; vertical-align: middle; border-radius: 50%; object-fit: cover; }
.people li:has(.face) { margin: 0.45rem 0; }
.pubs { list-style: none; padding: 0; margin: 1.5rem 0 0; }
.pubs li { padding: 1.1rem 0; border-top: 1px solid var(--rule); }
.pubs li:last-child { border-bottom: 1px solid var(--rule); }
.pub-gen { display: block; font-size: var(--t-xs); font-weight: 800; letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted); }
.pubs a { display: block; margin-top: 0.3rem; font-weight: 800; font-size: var(--t-base); text-decoration: none; }
.pubs a:hover { text-decoration: underline; }
.pub-meta { display: block; margin-top: 0.15rem; font-size: var(--t-sm); font-style: italic; color: var(--muted); }
.pubs p { margin: 0.45rem 0 0; font-size: var(--t-dense); }
.steps { padding-left: 1.4rem; } .steps li { margin: 0.4rem 0; padding-left: 0.3rem; }

/* leaderboards */
.board-tabs { display: flex; flex-wrap: wrap; gap: 0.5rem; margin: 1.25rem 0 0.75rem; }
.board-tabs button {
  border: 2px solid var(--blue); background: var(--paper); color: var(--blue);
  border-radius: 999px; padding: 0.4rem 1rem; font-weight: 800; cursor: pointer;
}
.board-tabs button[aria-pressed="true"] { background: var(--blue); color: var(--paper); }
.board-note { color: var(--muted); font-size: var(--t-dense); }
.lb { list-style: none; margin: 1rem 0; padding: 0; }
.lb li {
  display: grid; grid-template-columns: 1.6rem minmax(0, 13rem) minmax(0, 1fr) 3rem;
  gap: 0.75rem; align-items: center; padding: 0.45rem 0; border-top: 1px solid var(--rule);
}
.lb li:nth-last-child(2) { border-bottom: 1px solid var(--rule); }
.lb li.lb-axis { border-top: 0; padding-top: 0.2rem; }
.lb-ticks { display: flex; justify-content: space-between; font-size: var(--t-xs); color: var(--muted); }
.lb-ticks span:first-child { transform: translateX(-50%); } .lb-ticks span:last-child { transform: translateX(50%); }
.lb-rank { font-weight: 800; color: var(--muted); font-variant-numeric: tabular-nums; }
.lb .who { font-size: var(--t-dense); line-height: 1.3; }
.lb .who small { display: block; color: var(--muted); font-size: var(--t-xs); }
.lb li.ours .who { font-weight: 700; }
.lb-track { position: relative; height: 1rem; }
.lb-track::before { content: ""; position: absolute; left: 50%; top: -0.35rem; bottom: -0.35rem; border-left: 1.5px dashed var(--muted); }
.lb-ci { position: absolute; top: 0.3rem; height: 0.4rem; border-radius: 2px; background: var(--grey-bar); }
.lb-dot { position: absolute; top: 0; width: 1rem; height: 1rem; margin-left: -0.5rem; background: var(--grey-bar); border: 2px solid var(--paper); border-radius: 50%; }
.lb li.ours .lb-ci { background: color-mix(in srgb, var(--blue) 35%, transparent); }
.lb li.ours .lb-dot { background: var(--blue); }
.lb .val { text-align: right; font-weight: 800; font-variant-numeric: tabular-nums; }
@media (max-width: 560px) {
  .lb li { grid-template-columns: 1.6rem 1fr 3rem; }
  .lb-track, .lb-ticks { grid-column: 2 / -1; grid-row: 2; }
}

/* the training example, laid out like a record form */
.specimen { border: 2px solid var(--ink); border-radius: 4px; font-size: var(--t-dense); line-height: 1.55; margin: 1.25rem 0; }
.specimen-head { display: flex; justify-content: space-between; gap: 1rem; padding: 0.55rem 1rem; border-bottom: 2px solid var(--ink); }
.specimen-head span { color: var(--muted); font-size: var(--t-sm); }
.field { padding: 0.8rem 1rem; border-bottom: 1px solid var(--rule); }
.field-label { font-size: var(--t-sm); font-weight: 700; color: var(--muted); margin-bottom: 0.3rem; }
.field p { margin: 0 0 0.4rem; }
.opts { margin: 0.2rem 0 0; padding-left: 1.6rem; list-style: upper-alpha; }
.opts .key { font-weight: 700; }
.field ul { margin: 0.3rem 0 0.4rem; padding-left: 1.2rem; }
.record { background: var(--folder); border-top: 3px solid var(--sky); padding: 0.8rem 1rem 0.9rem; }
.record ul { list-style: none; margin: 0; padding: 0; }
.record li { padding-left: 1.5rem; position: relative; margin: 0.3rem 0; }
.record li::before { position: absolute; left: 0; font-weight: 800; }
.record li.ok::before { content: "\2713"; color: var(--green); }
.record li.drop::before { content: "\00D7"; color: var(--red); font-size: 1.15em; line-height: 1.2; }

/* ---------- the AutoMOOVE game ---------- */
.panel-body #game { max-width: none; }
.game-narrow { max-width: var(--measure); }
.game-progress { display: flex; gap: 0.35rem; margin-bottom: 1.25rem; }
.game-progress span { width: 2.2rem; height: 0.4rem; background: var(--rule); }
.game-progress span.done { background: var(--blue); }
.game-progress span.now { background: var(--amber); }
.case-setting { font-size: var(--t-sm); color: var(--muted); font-weight: 700; margin-bottom: 0.4rem; }
.case-q {
  font-size: var(--t-base); line-height: 1.5; padding: 1rem 1.2rem; margin-bottom: 1.25rem;
  background: var(--folder); border-left: 4px solid var(--sky); max-width: 48rem;
}
.answers { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; align-items: start; }
@media (max-width: 760px) { .answers { grid-template-columns: 1fr; } }
.answer { border: 1.5px solid var(--rule); border-radius: 8px; padding: 0.9rem 1.1rem; font-size: var(--t-dense); line-height: 1.55; position: relative; }
.answer h4 { margin: 0 0 0.5rem; font-size: var(--t-base); font-weight: 800; display: flex; justify-content: space-between; gap: 0.5rem; }
.answer h4 small { font-weight: 600; color: var(--muted); }
.answer p { margin: 0 0 0.45rem; }
.answer p.li { padding-left: 1rem; position: relative; margin-bottom: 0.25rem; }
.answer p.li::before { content: "\2022"; position: absolute; left: 0.1rem; color: var(--muted); }
.answer.clin { border-color: var(--blue); box-shadow: inset 0 0 0 1.5px var(--blue); }
.answer .badge { font-size: var(--t-xs); font-weight: 800; color: var(--paper); background: var(--blue); padding: 0.1rem 0.55rem; border-radius: 999px; }

.vote {
  position: sticky; bottom: -2.5rem; margin: 1.25rem -0.5rem -2.5rem; padding: 1rem 0.5rem 1.5rem;
  background: linear-gradient(to bottom, transparent, var(--paper) 1rem);
  display: flex; flex-wrap: wrap; gap: 0.6rem; justify-content: center;
}
.vote button, .game-btn {
  border: 2px solid var(--blue); background: var(--paper); color: var(--blue);
  border-radius: 999px; padding: 0.6rem 1.3rem; font-weight: 800; cursor: pointer;
}
.vote button:hover, .game-btn:hover { background: var(--blue-wash); }
.game-btn.primary { background: var(--blue); color: var(--paper); }
.game-btn.primary:hover { background: var(--ink); border-color: var(--ink); }

.verdicts { margin: 1.5rem 0 0.75rem; border-top: 2px solid var(--ink); max-width: 44rem; }
.verdict { display: grid; grid-template-columns: 8rem 1fr; gap: 1rem; padding: 0.6rem 0; border-bottom: 1px solid var(--rule); align-items: center; }
.verdict-who { font-weight: 800; }
.verdict-what .match { color: var(--green); font-weight: 700; }
.verdict-what .miss { color: var(--red); font-weight: 700; }
.conf { display: flex; height: 0.7rem; margin-top: 0.35rem; max-width: 22rem; }
.conf span { display: block; height: 100%; }
.conf .ca { background: var(--blue); } .conf .ct { background: var(--grey-bar); } .conf .cb { background: var(--amber); }
.conf-key { font-size: var(--t-xs); color: var(--muted); }
.case-note { max-width: 44rem; margin: 1rem 0 0; }

.score { font-size: 3.4rem; font-weight: 800; line-height: 1; margin: 0.5rem 0 0.75rem; }
.tally { display: grid; grid-template-columns: repeat(5, 2.4rem); gap: 0.35rem; margin: 0.25rem 0 0; }
.tally span { height: 2.4rem; display: grid; place-items: center; font-weight: 800; border: 1.5px solid var(--rule); border-radius: 4px; font-size: var(--t-sm); }
.tally span.hit { background: var(--blue); border-color: var(--blue); color: var(--paper); }
.tally-row { display: grid; grid-template-columns: 7rem auto; gap: 1rem; align-items: center; margin: 0.6rem 0; }
.game-actions { display: flex; flex-wrap: wrap; gap: 0.6rem; margin-top: 1.5rem; }

/* ---------- headlines: Ivy Presto Headline, Regular (the Adobe Fonts kit has Regular and Bold) ---------- */
.ocean-card h2, .story-rail h2, .story-card strong, .m-card-head h4, .feature-body strong,
:is(.why-section, .chat-section, .feature-section, .join-section, .cite-section, .credits) :is(h2, h3),
.panel-body :is(h2, h3, h4) { font-family: var(--display); font-weight: 400; letter-spacing: 0; }

/* ---------- the dawn of the MeditronFO page behind the header and the title; it fades into the page behind the globe (app.js) ---------- */
#sky {
  position: absolute; top: 0; left: 0; z-index: -1; width: 100%; height: 100svh;
  -webkit-mask-image: linear-gradient(#000 62%, transparent); mask-image: linear-gradient(#000 62%, transparent);
}
.dawn .top a { color: rgb(255 255 255 / 0.82); }
.dawn .top a:hover { color: #fff; }
.dawn .top-lab .logo-color { display: none; }
.dawn .top-lab .logo-mono { display: block; }
.dawn .wordmark { color: #fbf7ef; text-shadow: 0 2px 30px rgb(10 22 48 / 0.35); }
.dawn .tagline { color: #fbf7ef; }
.dawn .hero-cta .talk { background: #fbf7ef; color: #0c43a0; }
.dawn .hero-cta .talk:hover { background: #fff; }
.dawn .hero-cta .talk-alt { background: rgb(10 26 68 / 0.6); color: #fbf7ef; box-shadow: inset 0 0 0 2px #fbf7ef; }
.dawn .hero-cta .talk-alt:hover { background: rgb(10 26 68 / 0.85); }
/* the rail can sit on the sky: on a card of its own, as it already is on phones */
@media (min-aspect-ratio: 3/2) and (min-width: 901px) {
  .dawn .story-rail { width: 15.5rem; padding: 0.9rem; border-radius: 6px; background: color-mix(in srgb, var(--paper) 92%, transparent); }
}

/* ---------- ?withbeam, ?chillax: room between the beam and the name ---------- */
.withbeam .hero-center { padding-top: 2.25rem; }
/* ?chillax: the beam in the font of the Meditron logo too, like the name */
.chillax .beam-eq { font-family: 'Chillax', var(--font); }
.chillax .beam-lhs { font-weight: 700; font-size: clamp(1.9rem, 3.4vw, 3.1rem); }
.chillax .beam-fx { font-weight: 500; }
/* ?ivy: the name in Ivy Presto, Regular like the headlines; ?manrope: in the site's text font, as in v6 */
.ivy .wordmark { font-family: var(--display); font-weight: 400; letter-spacing: 0; text-transform: none; font-size: clamp(3.25rem, min(9.5vw, 13vh), 6.5rem); }
.manrope .wordmark { font-family: var(--font); font-weight: 800; letter-spacing: -0.035em; text-transform: none; font-size: clamp(3.25rem, min(9.5vw, 13vh), 6.5rem); }
