/* =====================================================================
   Centrum Badań Klinicznych UMB – Pracownia Medycyny Personalizowanej
   Wspólny arkusz stylów (PL/EN) · wersja 2: minimalistyczna, kontrastowa
   ===================================================================== */

:root {
  /* kolory – każda para tekst/tło ≥ 4.5:1 (sprawdzone) */
  --bg: #FFFFFF;
  --surface: #F5F7F8;
  --tint: #EEF6F1;
  --ink: #0B0F14;          /* nagłówki */
  --text: #2B3138;         /* akapity */
  --muted: #5B636D;        /* tekst pomocniczy */
  --line: #E2E5E9;
  --line-strong: #C9CFD6;
  --dark: #0E1A2B;         /* panele ciemne */
  --dark-2: #14243A;
  --on-dark: #FFFFFF;
  --on-dark-p: rgba(255, 255, 255, .84);
  --on-dark-muted: rgba(255, 255, 255, .66);
  --on-dark-line: rgba(255, 255, 255, .12);
  --accent: #0C763B;       /* zieleń UMB */
  --accent-hover: #095C2E;
  --accent-on-dark: #5DCB93;
  --polred: #2049B9;

  --font: "Epilogue", system-ui, sans-serif;
  --wrap: 1180px;
  --pad-x: 40px;
  --sec-y: 112px;
  --header-h: 72px;
  --ease: cubic-bezier(.2, .7, .2, 1);
  --ease-out: cubic-bezier(.16, 1, .3, 1);
}
@media (max-width: 1024px) { :root { --pad-x: 24px; --sec-y: 80px; } }
@media (max-width: 640px)  { :root { --pad-x: 18px; --sec-y: 60px; --header-h: 64px; } }

/* ---------- Podstawy ---------- */
*, *::before, *::after { box-sizing: border-box; }
html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 12px);
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  margin: 0; background: var(--bg); color: var(--text);
  font-family: var(--font); font-size: 1rem; line-height: 1.65;
  overflow-x: hidden; -webkit-font-smoothing: antialiased;
}
body.is-locked { overflow: hidden; }
img { display: block; max-width: 100%; height: auto; }
h1, h2, h3, h4, h5 { margin: 0; color: var(--ink); text-wrap: balance; }
p { margin: 0; text-wrap: pretty; }
ul { margin: 0; padding: 0; list-style: none; }
a { color: var(--accent); text-underline-offset: .2em; }
button { font: inherit; color: inherit; }
::selection { background: var(--accent); color: #fff; }

:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.polred :focus-visible { outline-color: #fff; }

.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.skip-link {
  position: absolute; left: 16px; top: -60px; z-index: 300;
  background: var(--ink); color: #fff; padding: 12px 18px; text-decoration: none; font-weight: 600;
}
.skip-link:focus { top: 12px; }

/* ---------- Układ ---------- */
.wrap { width: 100%; max-width: calc(var(--wrap) + 2 * var(--pad-x)); margin-inline: auto; padding-inline: var(--pad-x); }
.sec { padding-block: var(--sec-y); }
.sec--alt { background: var(--surface); }
.sec--dark { background: var(--dark); color: var(--on-dark-p); }
.sec--tint { background: var(--tint); }
/* dwie białe sekcje obok siebie – cienka linia zamiast koloru */
.sec:not(.sec--alt):not(.sec--dark):not(.sec--tint) + .sec:not(.sec--alt):not(.sec--dark):not(.sec--tint) { border-top: 1px solid var(--line); }

h2 {
  font-size: clamp(2rem, 1.15rem + 2.7vw, 3.35rem);
  font-weight: 500; line-height: 1.06; letter-spacing: -.035em;
}
.on-dark h2, .on-dark h3, .on-dark h4 { color: var(--on-dark); }
.lead { max-width: 60ch; font-size: clamp(1.02rem, .96rem + .25vw, 1.15rem); line-height: 1.7; color: var(--text); }
.on-dark .lead, .on-dark p { color: var(--on-dark-p); }

/* nagłówek sekcji: tytuł po lewej, opis po prawej */
.sec-head { margin-bottom: clamp(36px, 4vw, 60px); }
.sec-head:has(.lead) {
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 24px 64px; align-items: end;
}
@media (max-width: 860px) { .sec-head:has(.lead) { grid-template-columns: minmax(0, 1fr); } }

/* ---------- Przyciski ---------- */
.btn {
  position: relative; display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 48px; padding: 12px 24px; border: 1px solid transparent; border-radius: 2px;
  font-weight: 600; font-size: 1rem; line-height: 1.2; text-decoration: none; cursor: pointer; white-space: nowrap;
  transition: background-color .25s var(--ease), color .25s var(--ease), border-color .25s var(--ease), transform .25s var(--ease);
}
.btn--lg { min-height: 56px; padding: 14px 28px; font-size: 1.06rem; }
.btn--accent, .btn--green { background: var(--accent); color: #fff; }
.btn--accent:hover, .btn--green:hover { background: var(--accent-hover); }
.btn--white { background: #fff; color: var(--polred); }
.btn--white:hover { background: #E6ECFB; }
.btn:disabled { opacity: .6; cursor: progress; }

.text-link {
  display: inline-flex; align-items: center; gap: 6px; min-height: 44px;
  font-weight: 600; color: var(--accent); text-decoration: none;
  background: linear-gradient(currentColor, currentColor) 0 calc(100% - 10px) / 0 1px no-repeat;
  transition: background-size .35s var(--ease-out);
}
.text-link:hover { background-size: 100% 1px; }

/* =====================================================================
   Nagłówek
   ===================================================================== */
.site-header {
  position: fixed; inset: 0 0 auto 0; z-index: 100; height: var(--header-h);
  color: var(--ink); background: transparent; border-bottom: 1px solid transparent;
  transition: background-color .3s var(--ease), color .3s var(--ease), border-color .3s var(--ease);
}
.site-header.is-solid, .site-header.menu-open {
  background: rgba(255, 255, 255, .94); color: var(--ink); border-bottom-color: var(--line);
  -webkit-backdrop-filter: saturate(1.4) blur(14px); backdrop-filter: saturate(1.4) blur(14px);
}
.progress { position: absolute; left: 0; right: 0; bottom: -1px; height: 2px; pointer-events: none; }
.progress span { display: block; height: 100%; background: var(--accent); transform-origin: left; transform: scaleX(0); }
.site-header:not(.is-solid) .progress { opacity: 0; }
.hdr { height: 100%; display: flex; align-items: center; gap: 20px; }
.hdr-brand {
  display: inline-flex; align-items: center; gap: 12px; min-height: 44px; min-width: 0; margin-right: auto;
  color: inherit; text-decoration: none; font-weight: 700; font-size: 1.02rem; letter-spacing: -.015em; white-space: nowrap;
}
.hdr-brand svg { width: 22px; height: 40px; flex: none; color: var(--accent); transition: color .3s, transform .5s var(--ease-out); }
.hdr-brand:hover svg { transform: rotate(-8deg); }
.is-solid .hdr-brand svg, .menu-open .hdr-brand svg { color: var(--accent); }
.hdr-nav { display: flex; align-items: center; gap: 2px; }
.hdr-nav a {
  position: relative; display: inline-flex; align-items: center; min-height: 44px; padding: 0 10px;
  color: inherit; text-decoration: none; font-size: .94rem; font-weight: 500; white-space: nowrap;
}
.hdr-nav a::after {
  content: ""; position: absolute; left: 10px; right: 10px; bottom: 8px; height: 2px;
  background: currentColor; transform: scaleX(0); transform-origin: right; transition: transform .35s var(--ease-out);
}
.hdr-nav a:hover::after, .hdr-nav a.is-active::after { transform: scaleX(1); transform-origin: left; }
.hdr-nav a.is-active { color: var(--accent); }
.hdr-cta { min-height: 44px; padding: 10px 18px; font-size: .94rem; background: var(--accent); color: #fff; }
.hdr-cta:hover { background: var(--accent-hover); }
.lang { display: flex; flex: none; align-items: center; font-size: .9rem; font-weight: 600; }
.lang a {
  display: inline-flex; align-items: center; justify-content: center; min-width: 36px; min-height: 44px;
  color: inherit; text-decoration: none; opacity: .7;
}
.lang a[aria-current="true"] { opacity: 1; text-decoration: underline; text-underline-offset: .35em; }
.lang a:hover { opacity: 1; }
.hdr-burger {
  display: none; flex: none; width: 44px; height: 44px; padding: 0; border: 0; background: transparent; cursor: pointer;
  align-items: center; justify-content: center;
}
.hdr-burger span, .hdr-burger span::before, .hdr-burger span::after {
  display: block; width: 22px; height: 2px; background: currentColor; position: relative;
  transition: transform .3s var(--ease-out), background-color .2s;
}
.hdr-burger span::before, .hdr-burger span::after { content: ""; position: absolute; left: 0; }
.hdr-burger span::before { top: -7px; }
.hdr-burger span::after { top: 7px; }
.menu-open .hdr-burger span { background: transparent; }
.menu-open .hdr-burger span::before { transform: translateY(7px) rotate(45deg); }
.menu-open .hdr-burger span::after { transform: translateY(-7px) rotate(-45deg); }
.hdr-nav .nav-cta { display: none; }

@media (max-width: 1120px) {
  .hdr { gap: 12px; }
  .hdr-burger { display: inline-flex; }
  .hdr-nav {
    position: absolute; top: var(--header-h); left: 0; right: 0;
    flex-direction: column; align-items: stretch; gap: 0; padding: 8px var(--pad-x) 24px;
    background: #fff; color: var(--ink); border-bottom: 1px solid var(--line);
    max-height: calc(100vh - var(--header-h)); overflow-y: auto;
  }
  .hdr-nav:not(.is-open) { display: none; }
  .hdr-nav.is-open a { animation: nav-in .35s var(--ease-out) both; }
  .hdr-nav.is-open a:nth-child(2) { animation-delay: .03s; } .hdr-nav.is-open a:nth-child(3) { animation-delay: .06s; }
  .hdr-nav.is-open a:nth-child(4) { animation-delay: .09s; } .hdr-nav.is-open a:nth-child(5) { animation-delay: .12s; }
  .hdr-nav.is-open a:nth-child(6) { animation-delay: .15s; } .hdr-nav.is-open a:nth-child(7) { animation-delay: .18s; }
  .hdr-nav a { min-height: 54px; padding: 0; border-bottom: 1px solid var(--line); font-size: 1.15rem; font-weight: 600; }
  .hdr-nav a::after { display: none; }
  .hdr-nav a.is-active { color: var(--accent); }
}
@keyframes nav-in { from { opacity: 0; transform: translateY(-8px); } to { opacity: 1; transform: none; } }
@media (max-width: 640px) {
  .hdr-brand .hdr-word { font-size: .92rem; }
  .hdr-cta { display: none; }
  .hdr-nav .nav-cta { display: inline-flex; margin-top: 18px; border-bottom: 0; justify-content: center; color: #fff; }
}
@media (max-width: 380px) { .hdr-brand .hdr-word { font-size: .84rem; } }
@media (max-width: 380px) { .hdr-brand .hdr-word { white-space: normal; max-width: 9.5em; line-height: 1.1; } }

/* =====================================================================
   Hero – pełne zdjęcie + sieć laboratoriów (otwierana z logo UMB na fladze)
   ===================================================================== */
.heroB {
  position: relative; overflow: hidden; isolation: isolate; background: #fff;
  min-height: clamp(580px, 90vh, 880px); display: flex; align-items: flex-end;
  padding: calc(var(--header-h) + 40px) 0 clamp(64px, 8vw, 104px);
}
.heroB-bg { position: absolute; inset: 0; z-index: 0; }
.heroB-bg img { width: 100%; height: 100%; object-fit: cover; object-position: 70% 40%; filter: contrast(1.06) saturate(1.1); animation: heroB-zoom 2.4s var(--ease-out) both; }
@keyframes heroB-zoom { from { transform: scale(1.08); opacity: 0; } to { transform: none; opacity: 1; } }
.heroB-bg::after {
  content: ""; position: absolute; inset: 0;
  /* biel tylko pod napisem – zdjęcie z flagą zostaje wyraźne */
  background: linear-gradient(90deg, #fff 0%, rgba(255,255,255,.9) 24%, rgba(255,255,255,.35) 42%, rgba(255,255,255,0) 56%),
              linear-gradient(0deg, #fff 0%, rgba(255,255,255,0) 12%),
              linear-gradient(180deg, rgba(255,255,255,.75) 0%, rgba(255,255,255,0) 13%);
}
.heroB-veil {
  position: absolute; inset: 0; z-index: 2; pointer-events: none; opacity: 0;
  background: linear-gradient(90deg, rgba(255,255,255,.55) 0%, rgba(255,255,255,.9) 40%, rgba(255,255,255,.92) 100%);
  -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); transition: opacity .6s var(--ease-out);
}
.heroB.is-open .heroB-veil { opacity: 1; }
.heroB .cbkn-canvas { position: absolute; inset: 0; z-index: 3; width: 100%; height: 100%; pointer-events: none; }
.heroB .cbkn-nodes { position: absolute; inset: 0; z-index: 4; pointer-events: none; }
.heroB.is-open .cbkn-nodes .cbkn-node { pointer-events: auto; }
.heroB-inner { position: relative; z-index: 5; pointer-events: none; }
.heroB-inner > * { pointer-events: auto; }
.heroB h1 {
  max-width: 10ch; font-size: clamp(3rem, 1.1rem + 6vw, 6.75rem); font-weight: 500;
  line-height: .95; letter-spacing: -.052em; color: #1C2A36;
  animation: fade-up .9s .15s var(--ease-out) backwards; transition: opacity .4s;
}
.heroB-unit {
  margin: 0 0 20px; font-size: clamp(1.05rem, .9rem + .5vw, 1.4rem); font-weight: 500; line-height: 1.25; letter-spacing: -.01em; color: var(--ink);
}
/* napis Pracowni pojawia się delikatnie po ekranie ładowania */
.js .heroB-unit { opacity: 0; transform: translateY(6px); transition: opacity .8s ease, transform .8s var(--ease-out); }
.js .heroB.is-born .heroB-unit { opacity: 1; transform: none; }
.heroB-unit em { font-style: normal; color: var(--accent); }
/* miękka poświata – napisy czytelne także tam, gdzie zachodzą na zdjęcie */
.heroB h1, .heroB-unit { text-shadow: 0 0 18px rgba(255,255,255,.95), 0 0 42px rgba(255,255,255,.75); }
/* logo UMB na fladze w zdjęciu – aktywne miejsce otwierające sieć (pozycję ustawia network.js) */
.heroB-spot {
  position: absolute; z-index: 6; left: 0; top: 0; width: 0; height: 0; padding: 0; border: 0; border-radius: 50%;
  background: transparent; cursor: pointer; visibility: hidden;
}
.heroB-spot.is-placed { visibility: visible; }
.heroB-spot:focus-visible { outline: 2px solid var(--accent); outline-offset: 6px; }
.cbkn-close {
  position: absolute; z-index: 6; top: calc(var(--header-h) + 16px); right: max(var(--pad-x), calc((100% - var(--wrap)) / 2));
  width: 44px; height: 44px; border: 1px solid var(--line-strong); border-radius: 50%; background: #fff; color: var(--ink);
  font-size: 1.6rem; line-height: 1; cursor: pointer; transition: transform .3s var(--ease-out), background-color .2s;
}
.cbkn-close:hover { transform: rotate(90deg); background: var(--surface); }
@media (max-width: 760px) {
  /* telefon: napis z lewej, zdjęcie z flagą z prawej, płynne przejście w białe tło */
  .heroB { min-height: max(560px, 84vh); align-items: center; padding-top: calc(var(--header-h) + 24px); padding-bottom: 56px; }
  .heroB-bg img { object-position: 68% 35%; }
  .heroB-bg::after {
    background: linear-gradient(90deg, #fff 0%, rgba(255,255,255,.9) 28%, rgba(255,255,255,.4) 48%, rgba(255,255,255,0) 62%),
                linear-gradient(0deg, #fff 0%, rgba(255,255,255,0) 10%),
                linear-gradient(180deg, rgba(255,255,255,.75) 0%, rgba(255,255,255,0) 12%);
  }
  .heroB h1 { font-size: clamp(2.2rem, 10.4vw, 3rem); max-width: 10ch; }
  .heroB-unit { max-width: 13em; margin-bottom: 14px; font-size: 1rem; }
  .heroB-veil { background: rgba(255,255,255,.92); }
}
@media (prefers-reduced-motion: reduce) {
  .heroB-bg img, .heroB h1 { animation: none; }
  .heroB-unit { transition: none !important; }
  .heroB-veil { transition: none; }
}

@keyframes line-up { from { transform: translateY(105%); } to { transform: none; } }
@keyframes fade-up { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: none; } }

/* =====================================================================
   Pasek PolReD
   ===================================================================== */
.polred { background: var(--polred); color: #fff; overflow: hidden; }
.polred-inner { display: flex; align-items: center; gap: 28px; min-height: 104px; }
.polred-art { align-self: flex-end; height: 104px; width: auto; flex: none; transition: transform .6s var(--ease-out); }
.polred:hover .polred-art { transform: translateY(-6px); }
.polred-brand { display: flex; align-items: center; gap: 20px; flex: 1; min-width: 0; }
.polred-logo { height: 56px; width: auto; flex: none; }
.polred-name { font-size: clamp(1.2rem, .95rem + .9vw, 1.6rem); font-weight: 700; line-height: 1.15; letter-spacing: -.02em; color: #fff; }
.polred .btn { flex: none; min-height: 46px; padding-inline: 24px; font-size: 1rem; }
@media (max-width: 1024px) {
  .polred-brand { gap: 14px; }
  .polred-logo { height: 48px; }
  .polred-art { height: 96px; }
}
@media (max-width: 700px) {
  .polred-inner { flex-wrap: wrap; gap: 12px 16px; padding-block: 16px 0; min-height: 0; }
  .polred-brand { flex: 1 1 60%; }
  .polred-logo { height: 40px; }
  .polred-art { order: 3; height: 84px; margin-left: auto; }
  .polred .btn { order: 2; flex: 1 1 100%; max-width: none; }
}

/* =====================================================================
   O Pracowni – sieć + Facebook
   ===================================================================== */
/* Aktualności: lista wpisów + Facebook w prawej kolumnie */
.news-layout { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 48px; align-items: start; }
.news-layout .post { grid-template-columns: minmax(0, 1fr) 220px; gap: 14px 28px; }
.news-layout .post-meta { grid-column: 1 / -1; flex-direction: row; flex-wrap: wrap; gap: 4px 14px; }
.fb-side { position: sticky; top: calc(var(--header-h) + 24px); display: flex; flex-direction: column; gap: 8px; height: 640px; }
.fb-embed { flex: 1; min-height: 0; width: 100%; border: 1px solid var(--line); background: var(--surface); overflow: hidden; }
.fb-embed iframe { display: block; width: 100%; height: 100%; border: 0; }
.fb-side .text-link { flex: none; }
@media (max-width: 1024px) {
  .news-layout { grid-template-columns: minmax(0, 1fr); }
  .fb-side { position: static; height: 560px; max-width: 500px; }
}
@media (max-width: 640px) { .news-layout .post { grid-template-columns: minmax(0, 1fr); } }

/* ---------- Sieć laboratoriów (network.js, canvas) – prefiks cbkn- ---------- */
.cbkn-node {
  position: absolute; left: 0; top: 0; padding: 0;
  border: 0; border-radius: 50%; background: transparent; cursor: pointer; text-decoration: none;
  -webkit-user-drag: none;
  font: 400 13px/1.2 var(--font); letter-spacing: -.005em; color: var(--ink); text-align: center;
  white-space: normal; overflow-wrap: normal; hyphens: none;
  opacity: 0; will-change: transform; touch-action: none;
  transition: color .3s, opacity .3s;
}
.cbkn-node:hover { color: #000; }
.cbkn-node.is-us { color: var(--ink); }
.cbkn-node:active, .cbkn-node.is-dragging { cursor: grabbing; }
.cbkn-node:focus-visible { outline: 2px solid var(--c, var(--accent)); outline-offset: 8px; }
.cbkn-node.is-selected { color: #000; }
.cbkn-node.is-dim { color: rgba(11, 15, 20, .38); }
.cbkn-node { visibility: hidden; }
.heroB.is-open .cbkn-node { visibility: visible; }

/* =====================================================================
   Projekty (ciemny panel)
   ===================================================================== */
.cards4 { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 20px; }
.pcard {
  display: flex; flex-direction: column; background: #fff;
  border: 1px solid var(--line);
  transition: border-color .35s var(--ease), background-color .35s var(--ease), transform .45s var(--ease-out);
}
.pcard:hover { border-color: var(--line-strong); transform: translateY(-4px); }
.pcard-img { height: 196px; overflow: hidden; background: var(--surface); }
.pcard-img img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s var(--ease-out); }
.pcard:hover .pcard-img img { transform: scale(1.06); }
.pcard-body { padding: 24px 22px 28px; }
.pcard h3 { font-size: 1.18rem; font-weight: 600; line-height: 1.28; letter-spacing: -.015em; margin-bottom: 12px; }
.pcard p { font-size: .97rem; line-height: 1.65; color: var(--text); }
@media (max-width: 1100px) { .cards4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 620px)  { .cards4 { grid-template-columns: minmax(0, 1fr); } }

/* ---------- Pasek logotypów partnerów (na dole panelu z projektami) ---------- */
.partners {
  margin-top: clamp(48px, 5vw, 72px); padding-top: 32px; border-top: 1px solid var(--line); overflow: hidden;
  -webkit-mask-image: linear-gradient(to right, transparent 0, #000 7%, #000 93%, transparent 100%);
          mask-image: linear-gradient(to right, transparent 0, #000 7%, #000 93%, transparent 100%);
}
.partners-track { display: flex; width: max-content; animation: partners-flow 70s linear infinite; }
.partners:hover .partners-track, .partners:focus-within .partners-track { animation-play-state: paused; }
.partners-set { display: flex; align-items: center; gap: clamp(40px, 5vw, 72px); padding-right: clamp(40px, 5vw, 72px); margin: 0; list-style: none; }
.partner { display: flex; align-items: center; min-height: 64px; opacity: .8; transition: opacity .3s, transform .3s var(--ease-out); }
.partner:hover, .partner:focus-visible { opacity: 1; transform: translateY(-2px); }
.partner img { display: block; width: auto; max-width: none; }
.partner--text { font: 700 26px/1 Arial, "Helvetica Neue", Helvetica, sans-serif; letter-spacing: -.01em; color: #646464; white-space: nowrap; text-decoration: none; }
@media (max-width: 640px) { .partner--text { font-size: 21px; } }
.partner.is-wide img { height: 34px; }
.partner.is-mid img { height: 42px; }
.partner.is-square img { height: 56px; }
@keyframes partners-flow { from { transform: translateX(0); } to { transform: translateX(-50%); } }
@media (max-width: 640px) {
  .partner.is-wide img { height: 28px; } .partner.is-mid img { height: 34px; } .partner.is-square img { height: 46px; }
}
@media (prefers-reduced-motion: reduce) {
  .partners { -webkit-mask-image: none; mask-image: none; }
  .partners-track { animation: none; width: auto; }
  .partners-set { flex-wrap: wrap; justify-content: center; row-gap: 24px; padding-right: 0; }
  .partners-set[aria-hidden="true"] { display: none; }
}

/* =====================================================================
   Aktualności (jasne, lista)
   ===================================================================== */
.posts { border-top: 1px solid var(--ink); }
.post {
  display: grid; grid-template-columns: 140px minmax(0, 1fr) 300px; gap: 40px;
  padding-block: 40px; border-bottom: 1px solid var(--line);
}
.post-meta { display: flex; flex-direction: column; gap: 6px; font-size: .88rem; line-height: 1.4; }
.post-date { color: var(--accent); font-weight: 600; }
.post-src { color: var(--muted); }
.post h3 { font-size: clamp(1.25rem, 1.05rem + .6vw, 1.6rem); font-weight: 600; line-height: 1.2; letter-spacing: -.02em; margin-bottom: 14px; }
.post p { line-height: 1.7; max-width: 66ch; color: var(--text); }
.post p + p { margin-top: 12px; }
.post-img { aspect-ratio: 3 / 2; overflow: hidden; background: var(--surface); }
.post-img img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s var(--ease-out); }
.post:hover .post-img img { transform: scale(1.05); }
@media (max-width: 960px) {
  .post { grid-template-columns: minmax(0, 1fr) 240px; gap: 16px 32px; }
  .post-meta { grid-column: 1 / -1; flex-direction: row; flex-wrap: wrap; gap: 4px 14px; }
}
@media (max-width: 640px) {
  .post { grid-template-columns: minmax(0, 1fr); padding-block: 28px; }
  .post-img { order: -1; }
}

/* =====================================================================
   Zdjęcie + tekst
   ===================================================================== */
.split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(32px, 6vw, 88px); align-items: center; }
.split h2 + .lead { margin-top: 24px; }
.split-media { aspect-ratio: 4 / 3; overflow: hidden; background: var(--surface); }
.split-media img { width: 100%; height: 100%; object-fit: cover; transform: scale(1.08); transition: transform 1.4s var(--ease-out); }
.split-media.is-in img, .no-motion .split-media img { transform: scale(1); }
.split--rev .split-media { order: 2; }
@media (max-width: 640px) {
  .split { grid-template-columns: minmax(0, 1fr); }
  .split--rev .split-media { order: 0; }
}

/* =====================================================================
   Gabinety
   ===================================================================== */
.tiles { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.tile {
  position: relative; display: block; width: 100%; aspect-ratio: 1 / 1; padding: 0; border: 0; border-radius: 0;
  overflow: hidden; cursor: pointer; text-align: left; background: var(--dark);
}
.tile img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform 1s var(--ease-out); }
.tile::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(8, 12, 18, .9) 0%, rgba(8, 12, 18, .45) 40%, rgba(8, 12, 18, 0) 70%);
  transition: opacity .4s var(--ease);
}
.tile-title {
  position: absolute; z-index: 1; left: 24px; right: 24px; bottom: 22px;
  display: block;
  color: #fff; font-size: 1.24rem; font-weight: 600; line-height: 1.22; letter-spacing: -.015em;
}
.tile-name { display: block; }
.tile:hover img { transform: scale(1.07); }
.tile:hover .tile-more, .tile:focus-visible .tile:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }
@media (max-width: 960px) { .tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .tiles { grid-template-columns: minmax(0, 1fr); } .tile { aspect-ratio: 3 / 2; } }

/* =====================================================================
   Materiały dla pacjentów
   ===================================================================== */
.doclist { border-top: 1px solid var(--ink); }
.doclist a {
  position: relative; display: flex; align-items: center; justify-content: space-between; gap: 24px;
  min-height: 76px; padding: 18px 0; border-bottom: 1px solid var(--line); text-decoration: none; color: var(--ink);
  transition: padding .35s var(--ease-out), color .25s;
}
.doclist a:hover { padding-inline: 16px; color: var(--accent); }
.doc-t { font-weight: 600; font-size: clamp(1.05rem, 1rem + .35vw, 1.3rem); line-height: 1.3; letter-spacing: -.015em; }
.doc-s { flex: none; color: var(--muted); font-size: .92rem; font-weight: 500; text-align: right; }
.doclist a:hover .doc-s { color: var(--accent); }
.doc-note { margin-top: 20px; font-size: .9rem; color: var(--muted); max-width: 66ch; }
@media (max-width: 640px) {
  .doclist a { flex-direction: column; align-items: flex-start; gap: 4px; }
  .doc-s { text-align: left; }
}

/* =====================================================================
   Kierownictwo i Liderzy
   ===================================================================== */
.exec { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 40px; padding: 36px; background: #fff; border: 1px solid var(--line); }
.exec-photo { width: 100%; aspect-ratio: 1 / 1; object-fit: cover; background: var(--surface); }
.exec-role { font-size: .8rem; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--accent); margin-bottom: 10px; }
.exec-name { font-size: clamp(1.25rem, 1rem + .8vw, 1.6rem); font-weight: 600; line-height: 1.2; letter-spacing: -.02em; margin-bottom: 16px; }
.exec-bio { color: var(--text); line-height: 1.7; max-width: 66ch; }
.exec-bio + .exec-bio { margin-top: 12px; }
.pubs-h { margin: 24px 0 8px; font-size: .8rem; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.pubs li { border-top: 1px solid var(--line); }
.pubs li:last-child { border-bottom: 1px solid var(--line); }
.pubs a { display: block; padding: 11px 0; color: var(--ink); text-decoration: none; font-size: .95rem; line-height: 1.45; transition: color .2s, padding .3s var(--ease-out); }
.pubs a:hover { color: var(--accent); padding-left: 8px; }
.pubs .meta { display: block; margin-top: 2px; font-size: .84rem; color: var(--muted); }
.exec .text-link { margin-top: 12px; }
.exec-actions { display: flex; flex-wrap: wrap; gap: 4px 28px; align-items: center; }
.leaders-h { margin: 56px 0 20px; font-size: 1.4rem; font-weight: 600; letter-spacing: -.02em; }
.leaders { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.leaders .exec { grid-template-columns: 132px minmax(0, 1fr); gap: 26px; padding: 28px; }
@media (max-width: 960px) {
  .leaders { grid-template-columns: minmax(0, 1fr); }
  .exec { grid-template-columns: 180px minmax(0, 1fr); gap: 28px; }
}
@media (max-width: 640px) {
  .exec, .leaders .exec { grid-template-columns: minmax(0, 1fr); padding: 22px 20px; gap: 18px; }
  .exec-photo { width: 140px; }
}

/* =====================================================================
   Zespół badawczy
   ===================================================================== */
.team-group + .team-group { margin-top: 64px; }
.team-group-h { margin-bottom: 24px; padding-bottom: 14px; border-bottom: 1px solid var(--ink); font-size: 1.3rem; font-weight: 600; letter-spacing: -.02em; }
.team-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 34px 28px; }
.member { display: grid; grid-template-columns: 118px minmax(0, 1fr); gap: 18px; align-items: start; }
.member-photo, .member-initials { width: 118px; height: 118px; object-fit: cover; background: var(--surface); transition: transform .5s var(--ease-out); }
.member:hover .member-photo, .member:hover .member-initials { transform: translateY(-4px); }
.member-initials {
  display: flex; align-items: center; justify-content: center;
  background: #E4E7EB; color: var(--muted); font-weight: 600; font-size: 1.7rem;
}
.member-name { font-size: 1.03rem; font-weight: 600; line-height: 1.3; color: var(--ink); margin-bottom: 4px; letter-spacing: -.01em; }
.member-role { font-size: .87rem; font-weight: 500; color: var(--accent); line-height: 1.4; margin-bottom: 6px; }
.member-org { font-size: .82rem; font-weight: 600; color: var(--muted); line-height: 1.4; margin-bottom: 6px; }
.member-desc { font-size: .92rem; line-height: 1.6; color: var(--text); }
.member { outline: none; }
.member:focus-visible { outline: 2px solid var(--accent); outline-offset: 6px; }
@media (hover: hover) and (pointer: fine) {
  .member-desc { max-height: 0; overflow: hidden; opacity: 0; transform: translateY(-4px);
    transition: max-height .45s var(--ease-out), opacity .3s ease, transform .35s var(--ease-out); }
  .member:hover .member-desc, .member:focus-within .member-desc, .member:focus .member-desc { max-height: 40em; opacity: 1; transform: none; }
  .member-name { transition: color .2s; }
  .member:hover .member-name, .member:focus .member-name { color: var(--accent); }
}
@media (prefers-reduced-motion: reduce) { .member-desc { transition: none !important; } }
@media (max-width: 1100px) { .team-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px) {
  .team-grid { grid-template-columns: minmax(0, 1fr); gap: 26px; }
  .member { grid-template-columns: 96px minmax(0, 1fr); gap: 16px; }
  .member-photo, .member-initials { width: 96px; height: 96px; }
}

/* =====================================================================
   Współpraca naukowa (ciemny panel)
   ===================================================================== */
.sci-grid { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: clamp(40px, 6vw, 80px); align-items: start; }
.sci h2 + .lead { margin-top: 24px; }
.sci-more { margin-top: 32px; }

/* ---------- Podstrona: publikacje ---------- */
.pubs-who { display: block; margin-top: 6px; font-size: .5em; font-weight: 500; letter-spacing: -.01em; color: var(--muted); }
.pub-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); margin: 0 0 36px; border-block: 1px solid var(--ink); }
.pub-stats div { padding: 22px 20px 20px 0; }
.pub-stats div + div { padding-left: 20px; border-left: 1px solid var(--line); }
.pub-stats dt { font-size: .82rem; font-weight: 500; color: var(--muted); }
.pub-stats dd { margin: 4px 0 0; font-size: clamp(1.8rem, 1.3rem + 1.6vw, 2.8rem); font-weight: 600; letter-spacing: -.03em; color: var(--ink); line-height: 1.1; }
.pub-tools {
  position: sticky; top: var(--header-h); z-index: 5; display: flex; flex-wrap: wrap; align-items: center; gap: 12px 20px;
  padding: 14px 0; margin-bottom: 8px; background: rgba(255, 255, 255, .95);
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line);
}
.pub-search { flex: 1 1 260px; }
.pub-search input { width: 100%; min-height: 46px; padding: 10px 14px; border: 1px solid var(--line-strong); border-radius: 2px; font: inherit; color: var(--ink); background: #fff; }
.pub-search input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px rgba(12, 118, 59, .18); }
.pub-filters { display: flex; flex-wrap: wrap; gap: 6px; }
.pub-filter { min-height: 40px; padding: 8px 14px; border: 1px solid var(--line-strong); border-radius: 999px; background: #fff; color: var(--ink); font-size: .9rem; font-weight: 500; cursor: pointer; transition: background-color .2s, color .2s, border-color .2s; }
.pub-filter:hover { border-color: var(--ink); }
.pub-filter[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: #fff; }
.pub-count { margin-left: auto; font-size: .88rem; color: var(--muted); white-space: nowrap; }
.pub-group { display: grid; grid-template-columns: 120px minmax(0, 1fr); gap: 0 32px; border-bottom: 1px solid var(--line); }
.pub-year { padding-top: 26px; font-size: 1.6rem; font-weight: 600; letter-spacing: -.03em; color: var(--ink); }
.pub-year span { display: block; margin-top: 2px; font-size: .8rem; font-weight: 500; letter-spacing: 0; color: var(--muted); }
.pub-list { margin: 0; padding: 0; list-style: none; }
.pub { padding: 22px 0; border-bottom: 1px solid var(--line); }
.pub:last-child { border-bottom: 0; }
.pub-title { font-size: 1.05rem; font-weight: 600; line-height: 1.4; letter-spacing: -.01em; }
.pub-title a { color: var(--ink); text-decoration: none; background: linear-gradient(currentColor, currentColor) 0 100% / 0 1px no-repeat; transition: background-size .35s var(--ease-out), color .2s; }
.pub-title a:hover { color: var(--accent); background-size: 100% 1px; }
.pub-authors { margin-top: 6px; font-size: .9rem; line-height: 1.55; color: var(--muted); }
.pub-authors strong { color: var(--ink); font-weight: 600; }
.pub-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; margin-top: 8px; font-size: .88rem; color: var(--text); }
.pub-journal { font-style: italic; font-weight: 500; }
.pub-sep { color: var(--line-strong); }
.pub-badge { padding: 2px 9px; border: 1px solid var(--line-strong); border-radius: 999px; font-size: .76rem; font-weight: 600; color: var(--muted); }
.pub-badge.is-pre { border-style: dashed; }
.pub-links { display: inline-flex; gap: 12px; margin-left: auto; }
.pub-links a { font-weight: 600; font-size: .84rem; color: var(--accent); text-decoration: none; }
.pub-links a:hover { text-decoration: underline; }
.pub-empty { padding: 40px 0; color: var(--muted); }
.pub-foot { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px 24px; margin-top: 24px; }
.pub-src { font-size: .85rem; color: var(--muted); }
.pub-out { display: flex; flex-wrap: wrap; gap: 4px 24px; }
@media (max-width: 760px) {
  .pub-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .pub-stats div:nth-child(3) { padding-left: 0; border-left: 0; border-top: 1px solid var(--line); }
  .pub-stats div:nth-child(4) { border-top: 1px solid var(--line); }
  .pub-group { grid-template-columns: minmax(0, 1fr); }
  .pub-year { padding-top: 22px; }
  .pub-count, .pub-links { margin-left: 0; }
  .pub-tools { position: static; }
}

/* przycisk „Więcej o współpracy naukowej” pod gabinetami */
.sec-more { margin-top: 40px; display: flex; justify-content: center; }

/* ---------- Podstrona: Współpraca naukowa ---------- */
.studies { border-top: 1px solid var(--ink); }
.study {
  display: grid; grid-template-columns: minmax(0, .85fr) minmax(0, 1.15fr); gap: 24px clamp(32px, 5vw, 72px);
  padding-block: clamp(32px, 4vw, 48px); border-bottom: 1px solid var(--line);
}
.study-num { display: block; margin-bottom: 6px; font-size: clamp(4rem, 2.8rem + 4vw, 7rem); font-weight: 700; line-height: .85; letter-spacing: -.06em; color: var(--accent); opacity: .16; }
.study-head h3 { font-size: clamp(1.35rem, 1.1rem + .8vw, 1.8rem); font-weight: 600; line-height: 1.15; letter-spacing: -.025em; }
.study-head p { margin-top: 14px; line-height: 1.7; color: var(--text); max-width: 52ch; }
.study-kit-h { margin-bottom: 6px; font-size: .78rem; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.study-kit li { padding-block: 16px; border-bottom: 1px solid var(--line); }
.study-kit li:last-child { border-bottom: 0; }
.study-kit h4 { font-size: 1.05rem; font-weight: 600; color: var(--ink); letter-spacing: -.01em; }
.study-kit p { margin-top: 6px; font-size: .97rem; line-height: 1.65; color: var(--text); }
@media (max-width: 860px) { .study { grid-template-columns: minmax(0, 1fr); } }
.partners--page { margin-top: 0; padding-top: 8px; border-top: 0; margin-bottom: 40px; }
.collabs { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr)); gap: 16px; }
.collab a {
  display: flex; flex-direction: column; gap: 8px; height: 100%; padding: 24px 24px 26px;
  background: #fff; border: 1px solid var(--line); text-decoration: none; color: inherit;
  transition: border-color .3s, transform .45s var(--ease-out);
}
.collab a:hover, .collab a:focus-visible { border-color: var(--line-strong); transform: translateY(-3px); }
.collab-logo { display: flex; align-items: center; height: 52px; margin-bottom: 8px; }
.collab-logo img { max-height: 44px; max-width: 220px; width: auto; height: auto; }
.pcard-wordmark { font: 700 24px/1 Arial, "Helvetica Neue", Helvetica, sans-serif; color: #646464; letter-spacing: -.01em; }
.collab-name { font-weight: 600; color: var(--ink); line-height: 1.3; }
.collab-desc { font-size: .95rem; line-height: 1.6; color: var(--text); }
@media (prefers-reduced-motion: reduce) { .collab a { transition: none; } .collab a:hover { transform: none; } }


.page-hero { padding-top: calc(var(--header-h) + clamp(40px, 6vw, 88px)); }
.page-hero h1 { font-size: clamp(2.4rem, 1.2rem + 4vw, 4.4rem); font-weight: 600; line-height: 1; letter-spacing: -.04em; }
.page-hero .lead { margin-top: 0; max-width: 62ch; }
.page-hero-grid { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr); gap: 32px clamp(40px, 6vw, 96px); align-items: start; margin-top: 32px; }
.hero-quote { margin: 0; }
.hero-quote blockquote { margin: 0; }
.hero-quote p { font-size: clamp(1.45rem, 1.05rem + 1.4vw, 2.2rem); font-weight: 500; line-height: 1.3; letter-spacing: -.02em; color: var(--accent); }
.hero-quote figcaption { margin-top: 18px; font-size: .9rem; line-height: 1.5; color: var(--muted); }
.contact-box--solo { grid-column: 1 / -1; }
@media (max-width: 860px) { .page-hero-grid { grid-template-columns: minmax(0, 1fr); } }
.crumbs { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 24px; font-size: .9rem; color: var(--muted); }
.crumbs a { color: var(--accent); text-decoration: none; }
.crumbs a:hover { text-decoration: underline; }
.h3like { font-size: clamp(1.3rem, 1.05rem + .8vw, 1.7rem); font-weight: 600; letter-spacing: -.02em; }
.h3like + .lead { margin-top: 14px; }
.kit-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 340px), 1fr)); gap: 20px; }
.kit-card { padding: 28px; background: #fff; border: 1px solid var(--line); transition: border-color .3s, transform .45s var(--ease-out); }
.kit-card:hover { border-color: var(--line-strong); transform: translateY(-3px); }
.kit-card h3 { margin-bottom: 14px; padding-bottom: 12px; border-bottom: 1px solid var(--line); font-size: 1.2rem; font-weight: 600; letter-spacing: -.015em; }
.kit-card li + li { margin-top: 14px; }
.kit-card h4 { font-size: 1rem; font-weight: 600; color: var(--ink); }
.kit-card p { margin-top: 4px; font-size: .95rem; line-height: 1.6; color: var(--text); }
.contact-box .lead { margin-top: 0; }
.contact-mail { display: inline-block; margin-top: 8px; font-size: clamp(1.2rem, 1rem + .8vw, 1.6rem); font-weight: 600; color: var(--accent); text-decoration: none; }
.contact-mail:hover { text-decoration: underline; }
@media (prefers-reduced-motion: reduce) { .kit-card { transition: none; } .kit-card:hover { transform: none; } }
.sci-block { margin-top: 36px; padding-top: 22px; border-top: 1px solid rgba(12, 118, 59, .18); }
.sci-block h3 { font-size: 1.12rem; font-weight: 600; margin-bottom: 10px; }
.sci-block p { line-height: 1.7; max-width: 66ch; }
.sci-block a { color: var(--accent); }
.sci-quote { margin: 44px 0 0; }
.sci-quote blockquote { margin: 0; }
.sci-quote p { font-size: clamp(1.25rem, 1.05rem + .7vw, 1.6rem); line-height: 1.35; font-weight: 500; letter-spacing: -.02em; color: var(--ink); }
.sci-quote figcaption { margin-top: 14px; font-size: .9rem; color: var(--muted); }
.apar-h { font-size: 1.12rem; font-weight: 600; margin-bottom: 14px; }
.table-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; border: 1px solid var(--line); background: #fff; }
.apar { width: 100%; min-width: 520px; border-collapse: collapse; font-size: .92rem; line-height: 1.5; }
.apar th, .apar td { padding: 13px 16px; text-align: left; vertical-align: top; border-bottom: 1px solid var(--line); }
.apar thead th { background: var(--surface); color: var(--ink); font-weight: 600; font-size: .8rem; letter-spacing: .07em; text-transform: uppercase; }
.apar tbody th { color: var(--ink); font-weight: 600; width: 42%; }
.apar td { color: var(--text); }
.apar tbody tr { transition: background-color .2s; }
.apar tbody tr:hover { background: var(--tint); }
.apar tbody tr:last-child > * { border-bottom: 0; }
@media (max-width: 960px) { .sci-grid { grid-template-columns: minmax(0, 1fr); } }

/* =====================================================================
   W mediach (jasne, lista)
   ===================================================================== */
.media-list { border-top: 1px solid var(--ink); }
.mitem {
  position: relative; display: grid; grid-template-columns: 200px minmax(0, 1fr); gap: 40px;
  padding-block: 32px; border-bottom: 1px solid var(--line-strong);
  transition: padding .35s var(--ease-out), background-color .3s;
}
.mitem-meta { font-size: .88rem; line-height: 1.45; }
.mitem .mitem-date { color: var(--accent); font-weight: 600; }
.mitem .mitem-src { margin-top: 4px; color: var(--muted); }
.mitem h3 { font-size: clamp(1.15rem, 1rem + .5vw, 1.45rem); font-weight: 600; line-height: 1.25; letter-spacing: -.02em; margin-bottom: 10px; }
.mitem p { line-height: 1.7; max-width: 66ch; color: var(--text); }
.mlinks { display: flex; flex-wrap: wrap; gap: 0 22px; margin-top: 8px; }
.mlinks a { display: inline-flex; align-items: center; min-height: 44px; color: var(--accent); font-weight: 600; text-decoration: none; }
.mlinks a:hover { text-decoration: underline; }
.mitem--single .mlinks a::after { content: ""; position: absolute; inset: 0; }
.mitem--single:hover { padding-inline: 16px; background: #fff; }
@media (max-width: 640px) {
  .mitem { grid-template-columns: minmax(0, 1fr); gap: 8px; padding-block: 26px; }
  .mitem-meta { display: flex; flex-wrap: wrap; gap: 2px 12px; }
  .mitem .mitem-src { margin-top: 0; }
  .mitem--single:hover { padding-inline: 0; background: none; }
}

/* =====================================================================
   Stopka (ciemna)
   ===================================================================== */
.site-footer { background: #fff; color: var(--text); border-top: 1px solid var(--line); }
.foot-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, .8fr) minmax(0, 1.7fr); gap: 40px; padding-block: 72px 48px; }
.foot-brand { display: flex; gap: 18px; align-items: center; }
.foot-brand img { width: 84px; height: 84px; flex: none; }
.foot-org { font-weight: 700; color: var(--ink); line-height: 1.35; }
.foot-org span { display: block; font-weight: 500; color: var(--muted); font-size: .92rem; }
.foot-h { margin-bottom: 12px; font-size: .78rem; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--ink); }
.foot-col address { font-style: normal; line-height: 1.7; }
.foot-links { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 2px 24px; align-items: start; }
.foot-links a, .foot-col a {
  display: inline-flex; align-items: center; min-height: 36px; padding-block: 4px; line-height: 1.4;
  color: var(--accent); text-decoration: none; font-size: .95rem;
}
.foot-links a:hover, .foot-col a:hover { text-decoration: underline; }
.foot-bottom { padding-block: 20px; border-top: 1px solid var(--line); font-size: .86rem; color: var(--muted); }
@media (max-width: 960px) { .foot-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .foot-brand { grid-column: 1 / -1; } }
@media (max-width: 640px) {
  .foot-grid { grid-template-columns: minmax(0, 1fr); gap: 28px; padding-block: 52px 32px; }
  .foot-links { grid-template-columns: minmax(0, 1fr); }
  .foot-links a, .foot-col a { min-height: 44px; }
}

/* =====================================================================
   Modale (natywny <dialog>)
   ===================================================================== */
.modal {
  width: min(720px, calc(100vw - 32px)); max-height: calc(100vh - 32px); max-height: calc(100dvh - 32px);
  padding: 0; border: 0; border-radius: 0; background: #fff; color: var(--text); overflow: hidden;
}
.modal::backdrop { background: rgba(11, 15, 20, .66); -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px); }
.modal[open] { display: flex; flex-direction: column; animation: modal-in .35s var(--ease-out); }
@keyframes modal-in { from { opacity: 0; transform: translateY(20px) scale(.98); } to { opacity: 1; transform: none; } }
.modal-scroll { overflow-y: auto; overscroll-behavior: contain; }
.modal-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; padding: 30px 32px 0; }
.modal-head h2, .modal-body h2 { font-size: clamp(1.5rem, 1.1rem + 1.2vw, 2rem); }
.modal-close {
  flex: none; width: 44px; height: 44px; margin: -8px -10px 0 0; border: 0; background: transparent; cursor: pointer;
  font-size: 1.9rem; line-height: 1; color: var(--muted); transition: transform .3s var(--ease-out), color .2s;
}
.modal-close:hover { color: var(--ink); transform: rotate(90deg); }
.modal-body { padding: 20px 32px 32px; }
.modal--lab { width: min(860px, calc(100vw - 32px)); }
.lab-modal-img { aspect-ratio: 16 / 9; background: var(--surface); overflow: hidden; }
.lab-modal-img img { width: 100%; height: 100%; object-fit: cover; }
.modal--lab .modal-close { position: absolute; top: 12px; right: 12px; margin: 0; background: #fff; color: var(--ink); border-radius: 50%; }
.modal--lab .modal-body p { font-size: 1.06rem; line-height: 1.7; color: var(--text); max-width: 66ch; }
.modal--lab .modal-body h2 { margin-bottom: 14px; }
.lab-lists { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px 32px; margin-top: 24px; padding-top: 22px; border-top: 1px solid var(--line); }
.lab-lists h3 { margin-bottom: 10px; font-size: .8rem; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--accent); }
.lab-lists li { padding: 7px 0; line-height: 1.5; color: var(--text); border-bottom: 1px solid var(--line); }
.lab-lists li:last-child { border-bottom: 0; }
@media (max-width: 640px) { .lab-lists { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 640px) {
  .modal-head { padding: 22px 20px 0; }
  .modal-body { padding: 16px 20px 24px; }
}
@media (prefers-reduced-motion: reduce) { .modal[open] { animation: none; } }

/* ---------- Formularz ---------- */
.form-intro { color: var(--text); margin-bottom: 22px; max-width: 60ch; }
.fgroup { margin: 0 0 20px; padding: 0; border: 0; min-width: 0; }
.fgroup legend, .flabel { display: block; padding: 0; margin-bottom: 8px; font-weight: 600; color: var(--ink); font-size: .98rem; }
.req { color: #B3261E; }
.fopts { display: flex; flex-wrap: wrap; gap: 8px; }
.fopt { position: relative; }
.fopt input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.fopt span {
  display: inline-flex; align-items: center; min-height: 44px; padding: 8px 16px;
  border: 1px solid #959DA6; border-radius: 2px; background: #fff; color: var(--ink); cursor: pointer;
  transition: background-color .2s, border-color .2s, color .2s;
}
.fopt input:hover + span { border-color: var(--ink); }
.fopt input:checked + span { background: var(--ink); border-color: var(--ink); color: #fff; }
.fopt input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 2px; }
.frow { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.frow--2 { grid-template-columns: 140px minmax(0, 1fr); }
.field { display: flex; flex-direction: column; min-width: 0; margin-bottom: 4px; }
.field input[type="text"], .field input[type="tel"], .field input[type="email"], .field input[type="number"] {
  width: 100%; min-height: 48px; padding: 10px 14px; border: 1px solid #8A939C; border-radius: 2px;
  background: #fff; color: var(--ink); font: inherit; transition: border-color .2s, box-shadow .2s;
}
.field input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px rgba(12, 118, 59, .2); }
.field input[aria-invalid="true"] { border-color: #B3261E; }
.ferr { min-height: 1.3em; margin-top: 4px; font-size: .85rem; line-height: 1.3; color: #B3261E; }
.ferr:empty { min-height: 0; }
.fhint { margin-top: 4px; font-size: .85rem; color: var(--muted); }
.ftype[hidden] { display: none; }
.consent { display: grid; grid-template-columns: 24px minmax(0, 1fr); gap: 12px; align-items: start; margin-top: 10px; font-size: .86rem; line-height: 1.55; color: var(--text); cursor: pointer; }
.consent input { width: 22px; height: 22px; margin: 1px 0 0; accent-color: var(--accent); cursor: pointer; }
.form-note { margin: 16px 0 22px; font-size: .88rem; color: var(--muted); }
.form-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 20px; }
.form-status { font-size: .92rem; color: #B3261E; }
.form-done { padding: 8px 0 4px; }
.form-done h3 { font-size: 1.35rem; margin-bottom: 8px; }
.form-done p { color: var(--text); }
.hp { position: absolute !important; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
@media (max-width: 640px) {
  .frow, .frow--2 { grid-template-columns: minmax(0, 1fr); gap: 0; }
  .form-actions .btn { width: 100%; }
}

/* =====================================================================
   Animacje wejścia (raz, maks. 400 ms; elementy w siatkach z opóźnieniem)
   ===================================================================== */
.js .reveal { opacity: 0; transform: translateY(14px); transition: opacity .4s var(--ease-out), transform .4s var(--ease-out); transition-delay: var(--d, 0ms); }
.js .reveal.is-in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .js .reveal { opacity: 1; transform: none; transition: none; }
  .hero-media img, .hl > span, .hero-lead, .hero-cta { animation: none; }
  .hero-scroll span { animation: none; }
  .split-media img { transform: none; transition: none; }
  .tile img, .pcard, .pcard-img img, .post-img img, .member-photo, .member-initials, .doclist a, .mitem, .pubs a { transition: none; }
  .tile:hover img, .pcard:hover .pcard-img img, .post:hover .post-img img { transform: none; }
  .pcard:hover, .member:hover .member-photo, .member:hover .member-initials { transform: none; }
  .hdr-nav.is-open a { animation: none; }
}

/* =====================================================================
   Ekran ładowania (strona główna): logo UMB → znak CBK → kolorowe kropki
   ===================================================================== */
.loader { display: none; }
@media (prefers-reduced-motion: no-preference) {
  .js .loader { display: block; position: fixed; inset: 0; z-index: 1000; background: #fff; transition: background-color .8s ease; }
  html.is-loading { overflow: hidden; }
}
.loader.is-revealing { background-color: rgba(255, 255, 255, 0); pointer-events: none; }
.is-loaded .loader { display: none !important; }
.loader-umb { position: absolute; left: 50%; top: 50%; width: min(140px, 34vw); height: auto; transform: translate(-50%, -50%); animation: loader-in .6s ease both; }
@keyframes loader-in { from { opacity: 0; transform: translate(-50%, -50%) scale(.94); } }
.loader-canvas { position: absolute; inset: 0; width: 100%; height: 100%; }

/* =====================================================================
   Nasze badania – kafelki: zdjęcie na całym kafelku, gradient w ciemnym kolorze projektu,
   emblemat, tytuł i status rekrutacji na kafelku; opis i kryteria w oknie po kliknięciu
   ===================================================================== */
.studies-head { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 18px 56px; align-items: end; }
.studies-slogan { margin-top: 14px; font-size: clamp(1.25rem, 1rem + .9vw, 1.75rem); font-weight: 500; line-height: 1.25; letter-spacing: -.02em; color: var(--ink); }
.studies-slogan em { font-style: normal; color: var(--accent); }
.studies-lead { font-size: 1.02rem; line-height: 1.65; color: var(--text); }
.studies-head .text-link { margin-top: 6px; }
@media (max-width: 860px) { .studies-head { grid-template-columns: minmax(0, 1fr); } }

.studies-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 2px; }
.scard { --navy: #101D3B; --navy-rgb: 16, 29, 59; --acc: #8BE3B1; --acc-ink: var(--accent); --acc-tint: var(--tint); --pos: center; position: relative; min-width: 0; background: var(--navy); }
.scard-head { position: relative; isolation: isolate; aspect-ratio: 16 / 9; overflow: hidden; background: var(--navy); color: #fff; }
.scard-photo { position: absolute; inset: 0; z-index: -2; width: 100%; height: 100%; object-fit: cover; object-position: var(--pos); transition: transform 1.2s var(--ease-out); }
.scard:hover .scard-photo { transform: scale(1.03); }
.scard.is-closed .scard-photo, .modal--study.is-closed .scard-photo { filter: grayscale(.7); }
/* gradient: ciemny kolor projektu od lewej (pod napisami) i delikatnie od dołu */
.scard-head::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background:
    linear-gradient(90deg, rgba(var(--navy-rgb), .96) 0%, rgba(var(--navy-rgb), .9) 34%, rgba(var(--navy-rgb), .5) 62%, rgba(var(--navy-rgb), .12) 100%),
    linear-gradient(0deg, rgba(var(--navy-rgb), .6) 0%, rgba(var(--navy-rgb), 0) 48%);
}
.scard-head::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; z-index: 1; height: 3px; background: var(--acc);
  transform: scaleX(0); transform-origin: left center; transition: transform .5s var(--ease-out);
}
.scard:hover .scard-head::after, .scard:focus-within .scard-head::after { transform: scaleX(1); }
.scard-headin { position: absolute; inset: 0; display: flex; flex-direction: column; justify-content: space-between; gap: 10px; padding: 20px 22px 20px; pointer-events: none; }
.scard-headin > div { max-width: 70%; }
.scard-emblem { display: inline-flex; align-items: center; gap: 9px; height: 26px; color: #fff; }
.scard-emblem img { display: block; width: auto; height: 26px; }
.scard-emblem svg { width: 16px; height: 29px; color: #fff; }
.scard-emblem span { font-size: .8rem; font-weight: 600; letter-spacing: .06em; }
.studies-grid .scard-kicker { display: none; }
.scard-kicker { margin: 0 0 8px; font-size: .78rem; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--acc); }
.scard-title { margin: 0; font-size: clamp(1.2rem, 1rem + .45vw, 1.45rem); font-weight: 600; line-height: 1.25; letter-spacing: -.005em; color: #fff; }
.scard-sub { margin: 8px 0 0; font-size: .92rem; font-weight: 400; line-height: 1.45; letter-spacing: .005em; color: rgba(255, 255, 255, .82); }
/* status rekrutacji: prawy górny róg, bez kropki */
.scard-state { position: absolute; top: 20px; right: 20px; margin: 0; padding: 5px 10px; border: 1px solid rgba(255, 255, 255, .7); font-size: .76rem; font-weight: 600; line-height: 1.2; letter-spacing: .03em; color: #fff; white-space: nowrap; }
.scard-state-dot { display: none; }
.scard-state-dot { flex: none; width: 9px; height: 9px; border-radius: 50%; }
.scard-state.is-open .scard-state-dot { background: #7CF0A9; box-shadow: 0 0 0 3px rgba(124, 240, 169, .25); }
.scard-state.is-closed { color: rgba(255, 255, 255, .55); border-color: rgba(255, 255, 255, .25); }
.scard-state.is-clinic { color: rgba(255, 255, 255, .85); border-color: rgba(255, 255, 255, .45); }
.scard-state.is-closed .scard-state-dot { background: rgba(255, 255, 255, .55); }
.scard-state.is-clinic .scard-state-dot { border: 1.5px solid #fff; }
.scard-hit { position: absolute; inset: 0; z-index: 2; width: 100%; height: 100%; padding: 0; border: 0; background: transparent; cursor: pointer; }
.scard-hit:focus-visible { outline: 2px solid #fff; outline-offset: -5px; }
.scard-details[hidden] { display: none; }

/* okno szczegółów badania */
.scard-status {
  display: flex; align-items: center; gap: 10px; width: 100%; min-height: 48px; padding: 10px 16px;
  border: 1px solid transparent; border-radius: 2px; font: 600 .95rem/1.2 var(--font); text-align: left;
}
.scard-status.is-closed { background: #E5E8EC; color: #4B5560; }
.scard-notify {
  align-self: center; min-height: 40px; padding: 0; border: 0; background: none; cursor: pointer;
  font: 500 .92rem/1.3 var(--font); color: var(--muted); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 4px;
}
.scard-notify:hover { color: var(--accent); }
.scard-notify:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.scard-crit { display: flex; gap: 8px; margin: 0; }
.scard-crit div { flex: 1 1 0; min-width: 0; padding: 12px 14px 13px; background: var(--acc-tint); }
.scard-crit dt { font-size: .76rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--acc-ink); }
.scard-crit dd { margin: 4px 0 0; font-size: 1.75rem; font-weight: 600; line-height: 1.05; letter-spacing: -.02em; color: var(--ink); white-space: nowrap; }
.scard-crit dd small { display: block; margin-top: 4px; font-size: .8rem; font-weight: 500; letter-spacing: 0; color: var(--muted); }

.modal--study { --navy: #101D3B; --navy-rgb: 16, 29, 59; width: min(800px, calc(100vw - 32px)); }
.modal--study .modal-scroll { position: relative; }
.modal--study .modal-close { position: absolute; top: 14px; right: 14px; z-index: 3; margin: 0; background: #fff; color: var(--ink); border-radius: 50%; }
.sm-head .scard-head { aspect-ratio: auto; height: 270px; }
.sm-head .scard-head::after { display: none; }
.sm-head .scard-headin { max-width: 62%; padding: 28px 32px 26px; }
.sm-head .scard-emblem, .sm-head .scard-emblem img { height: 34px; }
.sm-head .scard-title { font-size: clamp(1.6rem, 1.25rem + 1vw, 2.15rem); }
.sm-head .scard-sub { font-size: 1.04rem; }
.sm-head .scard-hit { display: none; }
.sm-head .scard-state { position: static; display: inline-block; margin-top: 14px; }
.sm-body { padding: 26px 32px 32px; }
.sm-desc { font-size: 1.06rem; line-height: 1.68; color: var(--text); }
.sm-h { margin: 30px 0 12px; font-size: 1.16rem; font-weight: 600; letter-spacing: -.01em; color: var(--ink); }
.sm-list { display: grid; gap: 9px; margin-top: 14px; }
.sm-crit + .sm-list { margin-top: 16px; }
.sm-list li { font-size: 1rem; line-height: 1.55; color: var(--text); }
.sm-list b { font-weight: 600; color: var(--ink); }
.sm-gains { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px 28px; }
.sm-gains b { display: block; font-size: 1.02rem; font-weight: 600; color: var(--acc-ink); }
.sm-gains span { display: block; margin-top: 2px; font-size: .95rem; color: var(--muted); }
.sm-coord { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 16px 28px; margin-top: 30px; padding: 22px 24px; background: var(--navy); color: #fff; }
.sm-coord-k { margin-bottom: 4px; font-size: .82rem; color: rgba(255, 255, 255, .72); }
.sm-coord-n { font-size: 1.1rem; font-weight: 600; }
.sm-coord a { color: var(--acc); font-weight: 600; text-decoration: none; overflow-wrap: anywhere; }
.sm-coord a:hover { text-decoration: underline; }
.sm-coord-tel { text-align: right; }
.sm-coord-tel a { font-size: 1.65rem; font-weight: 600; letter-spacing: -.01em; white-space: nowrap; }
.sm-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 18px; margin-top: 24px; }
.sm-actions .scard-status { width: auto; flex: 1 1 240px; }
.sm-clinic { padding: 14px 16px; border: 1px solid var(--line-strong); font-size: 1rem; line-height: 1.5; color: var(--ink); }
.sm-fine { margin-top: 16px; font-size: .9rem; line-height: 1.55; color: var(--muted); }
.sm-fine a { color: var(--accent); font-weight: 600; text-decoration: none; }
.sm-fine a:hover { text-decoration: underline; }

@media (max-width: 1100px) { .scard-head { aspect-ratio: 4 / 3; } .scard-headin { padding: 16px 18px 14px; } .scard-state { top: 16px; right: 16px; padding: 4px 8px; font-size: .7rem; letter-spacing: .02em; } .scard-emblem, .scard-emblem img { height: 22px; } }
@media (max-width: 860px) { .studies-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .scard-head { aspect-ratio: 16 / 10; } }
@media (max-width: 640px) {
  .studies-grid { grid-template-columns: minmax(0, 1fr); }
  .scard-head { aspect-ratio: auto; min-height: 210px; }
  .scard-headin { position: relative; inset: auto; min-height: 210px; padding: 18px 18px 18px; }
  .scard-headin > div { max-width: 76%; }
  .scard-state { top: 18px; right: 18px; }
  .scard-title { font-size: 1.3rem; }
  .sm-head .scard-head { height: 230px; }
  .sm-head .scard-headin { max-width: 74%; padding: 22px 20px; }
  .sm-body { padding: 22px 20px 24px; }
  .scard-crit dd { font-size: 1.4rem; }
  .sm-gains { grid-template-columns: minmax(0, 1fr); }
  .sm-coord-tel { text-align: left; }
}
@media (prefers-reduced-motion: reduce) { .scard-photo, .scard-head::after { transition: none; } }

/* formularz: pola zależne od badania */
.fstudy[hidden] { display: none; }
.fopts--col { flex-direction: column; align-items: stretch; }
.fopts--col .fopt span { width: 100%; }
.frow--1 { grid-template-columns: minmax(0, 220px); }
.frow--bmi { grid-template-columns: repeat(2, minmax(0, 160px)) minmax(0, 1fr); align-items: end; }
.fbmi { align-self: center; margin: 0 0 4px; font-size: .92rem; color: var(--ink); }
.fbmi b { font-weight: 700; }
.fsoft { margin-top: 4px; font-size: .85rem; line-height: 1.35; color: var(--muted); }
.fsoft:empty { display: none; }
.fsoft.is-warn, .fbmi.is-warn { color: #8A5A00; }
@media (max-width: 640px) { .frow--1, .frow--bmi { grid-template-columns: minmax(0, 1fr); gap: 0; } }

/* =====================================================================
   Dla pacjentów – rozwijane sekcje (trójkąt w dół) i kalkulatory zdrowia
   ===================================================================== */
.page-hero--patients { padding-bottom: clamp(24px, 3vw, 40px); }
.acc-jump { display: flex; flex-wrap: wrap; gap: 8px 28px; margin-top: 22px; }
.acc-jump a { min-height: 40px; display: inline-flex; align-items: center; font-weight: 600; color: var(--ink); text-decoration: none; border-bottom: 1px solid var(--line-strong); }
.acc-jump a:hover { color: var(--accent); border-color: var(--accent); }
.patients { padding-top: 0; }
.acc { border-top: 1px solid var(--ink); }
.acc:last-of-type { border-bottom: 1px solid var(--line-strong); }
.acc-sum {
  display: flex; align-items: center; gap: 12px 20px; min-height: 88px; padding: 22px 0;
  list-style: none; cursor: pointer; -webkit-user-select: none; user-select: none;
}
.acc-sum::-webkit-details-marker { display: none; }
.acc-sum::marker { content: ""; }
.acc-sum:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; }
.acc-title { font-size: clamp(1.45rem, 1.1rem + 1.1vw, 2.1rem); font-weight: 600; line-height: 1.15; letter-spacing: -.025em; color: var(--ink); }
.acc-meta { margin-left: auto; font-size: .92rem; color: var(--muted); text-align: right; }
.acc-sum > .acc-icon { margin-left: auto; }
/* trójkąt (chevron) w kółku – obraca się po rozwinięciu */
.acc-icon { position: relative; flex: none; width: 40px; height: 40px; border: 1px solid var(--line-strong); border-radius: 50%; transition: transform .35s var(--ease-out), background-color .25s, border-color .25s; }
.acc-icon::before {
  content: ""; position: absolute; left: 50%; top: 45%; width: 8px; height: 8px;
  border-right: 1.5px solid var(--ink); border-bottom: 1.5px solid var(--ink); transform: translate(-50%, -50%) rotate(45deg);
}
.acc-sum:hover .acc-icon { background: var(--surface); border-color: var(--ink); }
details[open] > .acc-sum > .acc-icon { transform: rotate(180deg); }
.acc-body { padding: 4px 0 56px; }
/* płynne rozwijanie tam, gdzie przeglądarka to obsługuje */
@supports (interpolate-size: allow-keywords) {
  :root { interpolate-size: allow-keywords; }
  .acc::details-content, .calc::details-content { block-size: 0; overflow: hidden; transition: block-size .4s var(--ease-out), content-visibility .4s allow-discrete; }
  .acc[open]::details-content, .calc[open]::details-content { block-size: auto; }
}
.acc .doclist { border-top: 0; }

/* kalkulatory */
.calc-note { max-width: 78ch; margin-bottom: 18px; font-size: .92rem; line-height: 1.6; color: var(--muted); }
.calc { border-top: 1px solid var(--line); }
.calc:last-child { border-bottom: 1px solid var(--line); }
.calc-sum { min-height: 76px; padding: 18px 0; gap: 6px 20px; flex-wrap: wrap; }
.calc-name { font-size: 1.16rem; font-weight: 600; letter-spacing: -.01em; color: var(--ink); }
.calc-desc { font-size: .92rem; color: var(--muted); }
.calc-sum .acc-icon { margin-left: auto; width: 36px; height: 36px; }
.calc-body { padding: 6px 0 32px; }
.calc-lead { max-width: 70ch; margin-bottom: 20px; font-size: 1.02rem; line-height: 1.6; color: var(--text); }
.calc-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 28px 48px; align-items: start; }
.calc-grid--wide { grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); }
.calc-in { display: grid; gap: 14px; max-width: 420px; }
.calc-grid--wide .calc-in { max-width: none; }
.calc-in .field { margin: 0; }
.calc-in .fgroup { margin: 0 0 6px; }
.calc-side { position: sticky; top: calc(var(--header-h) + 20px); display: grid; gap: 16px; }
.calc-out { padding: 22px 22px 20px; background: var(--surface); border-top: 2px solid var(--ink); }
.calc-k { font-size: .76rem; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.calc-val { display: flex; align-items: baseline; gap: 8px; margin-top: 6px; }
.calc-num { font-size: clamp(2.4rem, 2rem + 1.4vw, 3.2rem); font-weight: 600; line-height: 1; letter-spacing: -.03em; color: var(--ink); font-variant-numeric: tabular-nums; }
.calc-unit { font-size: .95rem; color: var(--muted); }
.calc-cat { min-height: 2.9em; margin-top: 10px; font-size: .98rem; line-height: 1.45; color: var(--text); }
.calc-cat b { font-weight: 600; color: var(--ink); }
.calc-cat.is-warn { color: #7A4B00; }
.calc-cat.is-warn b { color: #7A4B00; }
.calc-scale { display: flex; gap: 3px; margin-top: 16px; }
.calc-scale li { flex: 1 1 0; min-width: 0; padding-top: 8px; border-top: 4px solid var(--line-strong); font-size: .7rem; line-height: 1.2; color: var(--muted); text-align: center; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.calc-scale li.is-active { border-top-color: var(--ink); color: var(--ink); font-weight: 600; }
.calc-advice { padding: 18px 20px; border: 1px solid var(--line-strong); }
.calc-advice[hidden] { display: none; }
.calc-advice p { margin-bottom: 14px; font-size: .94rem; line-height: 1.55; color: var(--text); }
.calc-advice .btn { white-space: normal; text-align: left; }
.calc-src { margin-top: 22px; max-width: 86ch; font-size: .8rem; line-height: 1.55; color: var(--muted); }
.calc-unitsel .fopt span { min-height: 40px; padding: 6px 14px; }
@media (max-width: 860px) {
  .calc-grid, .calc-grid--wide { grid-template-columns: minmax(0, 1fr); }
  .calc-side { position: static; }
  .calc-in { max-width: none; }
}
@media (max-width: 640px) {
  .acc-sum { min-height: 72px; padding: 18px 0; }
  .acc-meta { display: none; }
  .acc-sum .acc-icon { margin-left: auto; }
  .calc-desc { flex-basis: 100%; order: 3; }
}
@media (prefers-reduced-motion: reduce) { .acc-icon { transition: none; } }

/* strona główna: kafelki badań w rozwijanej zakładce */
.acc--home { margin-top: clamp(28px, 3vw, 40px); }
.acc--home .acc-sum { min-height: 72px; padding: 16px 0; }
.acc--home .acc-title { font-size: clamp(1.15rem, 1rem + .5vw, 1.4rem); }
.acc--home .acc-body { padding: 8px 0 36px; }

/* strona główna: badania naukowe i kliniczne – tekst i zdjęcie */
.studies-intro { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); gap: 32px 56px; align-items: center; }
.studies-text .studies-lead { margin-top: 18px; }
.studies-text .text-link { margin-top: 10px; }
.studies-photo { margin: 0; aspect-ratio: 3 / 2; overflow: hidden; background: var(--surface); }
.studies-photo img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: 50% 40%; }
.acc-intro { max-width: 72ch; margin-bottom: 22px; font-size: 1.02rem; line-height: 1.65; color: var(--text); }
@media (max-width: 860px) { .studies-intro { grid-template-columns: minmax(0, 1fr); } }
.studies-text .studies-cta { margin-top: 26px; }
