/* HealthCARE Lab · Investigation. Tokens mirror the HealthCARE Lab design system (v2). */
:root {
  --white: #ffffff; --ink: #1f2d3b; --slate: #2d3f50; --signal: #c8102e; --sky: #98d9ed; --mute: #4b5866; --rule: #d5dbe1; --wash: #f4f6f8;
  --sans: "Schibsted Grotesk", "Helvetica Neue", Arial, sans-serif;
  --mono: "IBM Plex Mono", "SFMono-Regular", Menlo, monospace;
  --wrap: 1280px; --pad: clamp(16px, 4vw, 40px); --section: clamp(48px, 6vw, 80px);
  color-scheme: light;
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--white); color: var(--ink); font-family: var(--sans); font-size: 17px; line-height: 1.6; }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--ink); }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--ink); outline-offset: 3px; }
h1, h2, h3 { margin: 0; text-wrap: balance; }
p { margin: 0; }
.wrap { max-width: var(--wrap); margin: 0 auto; padding-left: max(var(--pad), env(safe-area-inset-left, 0px)); padding-right: max(var(--pad), env(safe-area-inset-right, 0px)); }
.skip { position: absolute; left: -9999px; }
.skip:focus { left: 16px; top: 16px; z-index: 20; background: var(--white); padding: 8px 12px; }

/* Lab labels */
.label { font-family: var(--mono); font-size: 12px; font-weight: 500; letter-spacing: 0.08em; text-transform: uppercase; }
.meta { font-family: var(--mono); font-size: 13px; line-height: 1.5; color: var(--mute); }
.signal { color: var(--signal); }
.tag { display: inline-block; padding: 4px 10px; border-radius: 4px; background: var(--sky); color: var(--slate); font-size: 13px; font-weight: 600; text-decoration: none; }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: 0 24px; border: 2px solid var(--ink); font-family: var(--sans); font-size: 16px; font-weight: 600; text-decoration: none; cursor: pointer; }
.btn-primary { background: var(--ink); color: var(--white); }
.btn-primary:hover { background: var(--slate); border-color: var(--slate); }
.btn-secondary { background: var(--white); color: var(--ink); }
.btn-secondary:hover { background: var(--ink); color: var(--white); }
/* light blue from the logo mark, with the mark's navy for text (contrast about 8:1) */
.btn-sky { background: var(--sky); border-color: var(--sky); color: var(--slate); }
.btn-sky:hover { background: var(--slate); border-color: var(--slate); color: var(--white); }
.more { font-weight: 600; text-decoration: none; }
.more:hover { text-decoration: underline; }

/* Header */
.site-header { border-bottom: 3px solid var(--ink); background: var(--white); }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 24px; min-height: 76px; }
.logo img { height: 42px; width: auto; }
.nav { display: flex; align-items: center; gap: 26px; font-size: 15px; font-weight: 500; }
.nav a { text-decoration: none; }
.nav a:hover, .nav a[aria-current="page"] { text-decoration: underline; text-underline-offset: 6px; text-decoration-thickness: 2px; }
.nav .btn { min-height: 42px; padding: 0 18px; font-size: 15px; }
.menu { display: none; }
@media (max-width: 960px) {
  .nav { display: none; }
  .menu { display: block; position: relative; }
  .menu summary { list-style: none; cursor: pointer; font-family: var(--mono); font-size: 13px; letter-spacing: 0.08em; text-transform: uppercase; border: 2px solid var(--ink); padding: 10px 14px; }
  .menu summary::-webkit-details-marker { display: none; }
  .menu nav { position: absolute; right: 0; top: calc(100% + 8px); z-index: 10; display: flex; flex-direction: column; gap: 4px; min-width: 240px; padding: 12px; background: var(--white); border: 2px solid var(--ink); }
  .menu nav a { padding: 10px 8px; text-decoration: none; font-weight: 500; }
  .logo img { height: 34px; }
}

/* Hero */
.hero { border-bottom: 1px solid var(--ink); }
.hero .wrap { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 56px; align-items: end; padding-top: clamp(36px, 5vw, 64px); padding-bottom: clamp(36px, 4vw, 52px); }
.hero h1 { font-size: clamp(44px, 6.6vw, 96px); font-weight: 900; line-height: 0.96; letter-spacing: -0.04em; text-wrap: pretty; }
.hero .stack { display: flex; flex-direction: column; gap: 28px; min-width: 0; }
.lede { font-size: clamp(18px, 2vw, 21px); line-height: 1.45; max-width: 600px; }
.actions { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; }
@media (max-width: 860px) { .hero .wrap { grid-template-columns: 1fr; } }

.page-head { border-bottom: 1px solid var(--ink); }
.page-head .wrap { display: flex; flex-direction: column; gap: 22px; padding-top: clamp(40px, 6vw, 72px); padding-bottom: clamp(36px, 5vw, 52px); }
.page-head h1 { font-size: clamp(44px, 7vw, 96px); font-weight: 900; line-height: 0.96; letter-spacing: -0.04em; max-width: 1100px; }

/* Figure */
.figure { margin: 0; display: flex; flex-direction: column; gap: 12px; padding: 18px; border: 2px solid var(--ink); }
.figure .num { font-size: 58px; font-weight: 900; line-height: 1; letter-spacing: -0.04em; }
.figure .bar { height: 8px; background: var(--sky); }
.figure figcaption { font-size: 14px; line-height: 1.45; border-top: 1px solid var(--ink); padding-top: 10px; }
.figure a { font-weight: 600; }

/* Research strip */
.strip { border-bottom: 1px solid var(--ink); }
.strip .label { padding-top: 20px; display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.cells { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); }
.cells > div { display: flex; flex-direction: column; gap: 10px; padding: 16px 20px 26px; min-width: 0; }
.cells > div:first-child { padding-left: 0; }
.cells > div:last-child { padding-right: 0; }
.cells > div + div { border-left: 1px solid var(--ink); }
.stat { font-size: clamp(34px, 3.6vw, 52px); font-weight: 900; line-height: 1; letter-spacing: -0.035em; white-space: nowrap; }
.cells span:last-child { font-size: 15px; line-height: 1.4; }
@media (max-width: 960px) { .cells { grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 20px; } .cells > div, .cells > div + div, .cells > div:first-child, .cells > div:last-child { padding: 16px 0 20px; border-left: 0; border-top: 1px solid var(--rule); } .cells > div:last-child { grid-column: 1 / -1; } }

/* Sections */
.section { padding-top: var(--section); padding-bottom: var(--section); }
.section + .section { border-top: 1px solid var(--ink); }
.section-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: end; gap: 20px; margin-bottom: 28px; }
.section-head h2 { font-size: clamp(36px, 5vw, 64px); font-weight: 900; line-height: 1; letter-spacing: -0.035em; max-width: 900px; }
.section-head .label { display: block; margin-bottom: 14px; }
.prose { max-width: 66ch; display: flex; flex-direction: column; gap: 18px; }
.prose p { font-size: 18px; line-height: 1.7; }

/* Area rows */
.rows { border-top: 2px solid var(--ink); }
.row { display: grid; grid-template-columns: 220px minmax(0, 1fr) minmax(0, 0.8fr); gap: 24px 40px; padding: 28px 0; border-bottom: 1px solid var(--rule); text-decoration: none; align-items: baseline; }
.row h3 { font-size: 15px; font-family: var(--mono); font-weight: 500; letter-spacing: 0.06em; text-transform: uppercase; }
.row .q { font-size: clamp(22px, 2.4vw, 30px); font-weight: 800; line-height: 1.2; letter-spacing: -0.02em; }
.row p { color: var(--slate); font-size: 16px; }
a.row:hover .q { text-decoration: underline; text-decoration-thickness: 2px; }
@media (max-width: 860px) { .row { grid-template-columns: 1fr; gap: 10px; } }

/* Publications */
.pubs { border-top: 2px solid var(--ink); }
.pub { display: grid; gap: 8px; padding: 20px 0; border-bottom: 1px solid var(--rule); }
.pub .title { font-size: 20px; font-weight: 700; line-height: 1.3; text-decoration: none; }
.pub a.title:hover { text-decoration: underline; }
.pub .line { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.pub .abstract { font-size: 15px; color: var(--slate); max-width: 80ch; }
.pub .abstract summary { cursor: pointer; font-family: var(--mono); font-size: 12px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--mute); }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 28px; }
.chip { font-family: var(--mono); font-size: 13px; padding: 8px 14px; border: 2px solid var(--ink); background: var(--white); color: var(--ink); cursor: pointer; }
.chip[aria-pressed="true"] { background: var(--ink); color: var(--white); }
.year { font-family: var(--mono); font-size: 13px; letter-spacing: 0.08em; padding: 28px 0 0; color: var(--mute); }
.note { font-family: var(--mono); font-size: 12px; color: var(--mute); }

/* Live feed (filled by the worker) */
.live-wrap { display: none; margin-bottom: 40px; }
.live-wrap:has(.live-list) { display: block; }
.live-list { list-style: none; margin: 0; padding: 0; border-top: 2px solid var(--ink); }
.live-item { display: grid; gap: 6px; padding: 18px 0; border-bottom: 1px solid var(--rule); }
.live-meta { font-family: var(--mono); font-size: 12px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--signal); }
.live-title { font-size: 20px; font-weight: 700; line-height: 1.3; text-decoration: none; }
.live-title:hover { text-decoration: underline; }
.live-people, .live-summary { font-family: var(--mono); font-size: 13px; color: var(--mute); }
.feed { list-style: none; margin: 0; padding: 0; border-top: 2px solid var(--ink); }
.feed li { display: grid; gap: 6px; padding: 18px 0; border-bottom: 1px solid var(--rule); }
.feed .t { font-size: 20px; font-weight: 700; line-height: 1.3; text-decoration: none; }
.feed .t:hover { text-decoration: underline; }

/* Stories */
.stories { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 36px 28px; }
.story { display: flex; flex-direction: column; gap: 12px; text-decoration: none; }
.story img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border: 1px solid var(--rule); }
.story .t { font-size: 21px; font-weight: 800; line-height: 1.2; letter-spacing: -0.015em; }
.story:hover .t { text-decoration: underline; }
@media (max-width: 860px) { .stories { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 520px) { .stories { grid-template-columns: 1fr; } }
.post { display: grid; grid-template-columns: minmax(0, 1fr); gap: 32px; max-width: 760px; }
.post img.cover { width: 100%; height: auto; border: 1px solid var(--rule); }
.post .body p { font-size: 19px; line-height: 1.75; margin-bottom: 1.1em; }
.pager { display: flex; justify-content: space-between; gap: 20px; flex-wrap: wrap; border-top: 2px solid var(--ink); padding-top: 20px; }

/* People */
.people { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 40px; }
.person { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 24px; align-items: start; }
.person img, .person .ph { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; object-position: top; background: var(--wash); }
.person h3 { font-size: 28px; font-weight: 900; letter-spacing: -0.02em; }
.person .bio { font-size: 16px; line-height: 1.6; margin-top: 10px; }
.team { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 24px; }
.member { display: grid; gap: 8px; }
.member .ph { aspect-ratio: 4 / 5; background: var(--wash); display: flex; align-items: center; justify-content: center; font-size: 40px; font-weight: 900; color: var(--slate); }
.member h3 { font-size: 20px; font-weight: 800; }
.alumni { columns: 3 260px; column-gap: 40px; margin: 0; padding: 0; list-style: none; }
.alumni li { break-inside: avoid; padding: 10px 0; border-bottom: 1px solid var(--rule); }
.alumni b { display: block; font-size: 16px; }
@media (max-width: 960px) { .people { grid-template-columns: 1fr; } .team { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 520px) { .person { grid-template-columns: 1fr; } .person img, .person .ph { max-width: 260px; } }

/* Two doors */
.doors { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; }
.door { display: flex; flex-direction: column; gap: 14px; padding: 32px; border: 2px solid var(--ink); }
.door h3 { font-size: clamp(26px, 3vw, 36px); font-weight: 900; line-height: 1.05; letter-spacing: -0.025em; }
.door p { font-size: 16px; }
@media (max-width: 760px) { .doors { grid-template-columns: 1fr; } }
.grid-2 { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 48px; align-items: start; }
@media (max-width: 860px) { .grid-2 { grid-template-columns: 1fr; } }
.list { margin: 0; padding: 0; list-style: none; border-top: 2px solid var(--ink); }
.list li { padding: 16px 0; border-bottom: 1px solid var(--rule); font-size: 17px; }
.list b { display: block; font-size: 19px; }
.quote { margin: 0; padding: 24px 0; border-top: 2px solid var(--ink); }
.quote p { font-size: clamp(20px, 2.2vw, 26px); font-weight: 700; line-height: 1.35; letter-spacing: -0.01em; }
.quote cite { display: block; margin-top: 12px; font-style: normal; }
.photo { width: 100%; height: auto; border: 1px solid var(--rule); }

/* Forms */
.form { display: grid; gap: 18px; max-width: 720px; }
.form .two { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
@media (max-width: 620px) { .form .two { grid-template-columns: 1fr; } }
.field { display: grid; gap: 6px; }
.field label { font-family: var(--mono); font-size: 12px; letter-spacing: 0.08em; text-transform: uppercase; }
.field input, .field select, .field textarea { font: inherit; font-size: 17px; padding: 12px 14px; border: 2px solid var(--ink); border-radius: 0; background: var(--white); color: var(--ink); width: 100%; }
.field textarea { min-height: 160px; resize: vertical; }
.hp { position: absolute; left: -9999px; }
.status { font-family: var(--mono); font-size: 14px; min-height: 1.5em; }
.status.ok { color: var(--ink); } .status.err { color: var(--signal); }

/* Footer */
.site-footer { border-top: 3px solid var(--ink); margin-top: 0; }
.site-footer .wrap { display: grid; grid-template-columns: minmax(0, 1.2fr) repeat(3, minmax(0, 1fr)); gap: 32px; padding-top: 48px; padding-bottom: 40px; }
.site-footer img { height: 40px; width: auto; }
.site-footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; font-size: 15px; }
.site-footer a { text-decoration: none; } .site-footer a:hover { text-decoration: underline; }
.fine { border-top: 1px solid var(--rule); padding-top: 18px; padding-bottom: 28px; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; }
@media (max-width: 860px) { .site-footer .wrap { grid-template-columns: 1fr 1fr; } }

/* Who we are (home) */
.team-photo { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 48px; align-items: end; }
.team-photo figure { margin: 0; display: grid; gap: 10px; }
.team-photo img, .team-photo .slot { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; }
.team-photo .slot { display: flex; align-items: center; justify-content: center; text-align: center; padding: 24px; background: var(--wash); border: 2px dashed var(--rule); font-family: var(--mono); font-size: 13px; color: var(--mute); }
.team-photo h2 { font-size: clamp(28px, 3vw, 42px); font-weight: 900; line-height: 1.02; letter-spacing: -0.03em; }
@media (max-width: 860px) { .team-photo { grid-template-columns: 1fr; gap: 28px; } }
