:root {
  --bg: #ffffff;
  --bg-alt: #f8fafc;
  --navy: #173c5a;
  --blue: #2563eb;
  --ink: #0f172a;
  --muted: #64748b;
  --line: #e2e8f0;
  --radius: 18px;
  --ice: #d9eef7;
}

* { box-sizing: border-box; }

html { 
  scroll-behavior: smooth; 
  scroll-padding-top: 80px; 
}

@view-transition {
  navigation: auto;
}

::view-transition-old(root),
::view-transition-new(root) {
  animation-duration: 140ms;
}

body { 
  margin: 0; 
  font-family: "Manrope", sans-serif; 
  color: var(--ink); 
  background: var(--bg); 
  line-height: 1.5; 
  -webkit-font-smoothing: antialiased; 
}

.container { 
  width: min(1120px, calc(100% - 40px)); 
  margin: 0 auto; 
}

.muted {
  color: var(--muted);
}

.tiny {
  font-size: 12px;
}

/* --- Header & Navigation --- */
.header { 
  position: sticky; 
  top: 0; 
  z-index: 100; 
  background: rgba(255, 255, 255, 0.9); 
  border-bottom: 1px solid var(--line); 
  backdrop-filter: blur(10px); 
}

.header__inner { 
  display: flex; 
  align-items: center; 
  justify-content: space-between; 
  padding: 14px 0; 
}

.brand { 
  display: flex; 
  align-items: center; 
  gap: 12px; 
  text-decoration: none; 
  color: var(--navy); 
  font-weight: 700; 
  font-family: "Sora"; 
  font-size: 18px; 
}

.brand__logo {
  width: 38px;
  height: 38px;
  object-fit: contain;
}
.brand__text {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.brand__name {
  line-height: 1;
}

.brand__motto {
  font-family: "Manrope", sans-serif;
  font-size: 11px;
  font-weight: 800;
  line-height: 1.2;
  color: var(--muted);
}

.digit {
  color: #70be40;
}

.nav { display: flex; gap: 18px; }

.nav a { 
  position: relative;
  display: inline-flex;
  align-items: center;
  padding: 2px 0;
  text-decoration: none; 
  color: var(--muted); 
  font-size: 13px; 
  font-weight: 800; 
}

.nav a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -7px;
  height: 2px;
  border-radius: 999px;
  background: var(--blue);
  transform: scaleX(0);
  transform-origin: center;
  transition: transform 180ms ease;
}

.nav a:hover { color: var(--blue); }

.nav a.is-active {
  color: var(--navy);
  font-weight: 900;
}

.nav a.is-active::after {
  transform: scaleX(1);
}

/* --- Buttons --- */
.btn { 
  padding: 10px 18px; 
  border-radius: 999px; 
  font-weight: 900; 
  text-decoration: none; 
  font-size: 14px; 
  line-height: 1.2;
  display: inline-flex; 
  align-items: center; 
  justify-content: center;
  text-align: center;
  transition: 0.2s; 
  border: 1px solid var(--line); 
  cursor: pointer; 
  background: white; 
}

.btn--primary { 
  background: var(--navy); 
  color: white; 
  border: none; 
}

.btn--secondary { 
  background: var(--bg-alt); 
  color: var(--navy); 
}

.btn:hover { 
  transform: translateY(-1px); 
  opacity: 0.9; 
}

/* --- Hero Section --- */
.hero-block { 
  padding: 20px 0; 
  border-bottom: 1px solid var(--line); 
}

.hero__grid { 
  display: grid; 
  grid-template-columns: 1.15fr 0.85fr; 
  gap: 40px; 
  align-items: stretch; 
  margin-bottom: 30px; 
}

h1 { 
  font-family: "Sora"; 
  font-size: 56px;
  line-height: 1.05; 
  margin: 0 0 16px; 
  letter-spacing: 0;
  color: var(--navy); 
}

.eyebrow { 
  color: var(--muted); 
  font-weight: 900; 
  font-size: 13px; 
  letter-spacing: 0.04em; 
  margin-bottom: 10px; 
  text-transform: uppercase; 
}

.lead { 
  font-size: 17px; 
  color: var(--muted); 
  margin-bottom: 24px; 
  max-width: 60ch; 
}

.hero__actions { display: flex; gap: 12px; }

.impact-card { 
  background: var(--bg-alt); 
  border: 1px solid var(--line); 
  border-radius: 26px; 
  padding: 24px; 
}

.impact-header { 
  font-size: 11px; 
  text-transform: uppercase; 
  font-weight: 800; 
  color: var(--muted); 
  margin-bottom: 16px; 
}

.stat { 
  display: flex; 
  justify-content: space-between; 
  align-items: baseline; 
  gap: 16px;
  margin-bottom: 8px; 
}

.stat-label { 
  font-size: 12px; 
  color: var(--muted); 
  font-weight: 600; 
}

.stat-value {
  font-family: "Sora";
  font-size: 20px;
  font-weight: 700;
  color: var(--navy);
  text-align: right;
}

.progress-container { 
  background: #e2e8f0; 
  height: 6px; 
  border-radius: 10px; 
  margin: 8px 0; 
}

.progress-bar { 
  background: var(--blue); 
  height: 100%; 
  border-radius: 10px; 
}

.progress-bar--current {
  width: 56%;
}

/* --- Section Layouts --- */
.section { padding: 60px 0; } 
.section--alt { 
  background: var(--bg-alt); 
  border-top: 1px solid var(--line); 
  border-bottom: 1px solid var(--line); 
}

.section-title { 
  font-family: "Sora"; 
  font-size: 26px; 
  margin-bottom: 12px; 
  color: var(--navy); 
}

.section__titleRow {
  margin-bottom: 20px;
}

.subpage-titleRow {
  max-width: 760px;
  margin-bottom: 22px;
}

.subpage-titleRow h1.section-title {
  margin: 0 0 8px;
  font-size: 34px;
  line-height: 1.12;
}

.subpage-titleRow .muted {
  margin: 0;
  max-width: 64ch;
  font-size: 15px;
  line-height: 1.6;
}

/* --- Bottom Page CTA --- */
.page-cta {
  padding: 34px 0;
  background: var(--navy);
  border-top: 1px solid rgba(255, 255, 255, 0.12);
}

.page-cta__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
}

.page-cta h2 {
  margin: 0 0 6px;
  color: white;
  font-family: "Sora";
  font-size: 24px;
  line-height: 1.2;
}

.page-cta p {
  margin: 0;
  max-width: 68ch;
  color: rgba(255, 255, 255, 0.78);
  font-size: 15px;
}

.page-cta__button {
  flex: 0 0 auto;
  background: white;
  color: var(--navy);
  border-color: white;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.16);
}

.page-cta__button:hover {
  opacity: 1;
  background: #f8fafc;
}

/* --- Motion System --- */
.reveal-ready .reveal-on-scroll {
  opacity: 0;
  transform: translate3d(0, 16px, 0);
  transition:
    opacity 520ms ease,
    transform 620ms cubic-bezier(0.22, 1, 0.36, 1);
  will-change: opacity, transform;
}

.reveal-ready .reveal-on-scroll.is-visible {
  opacity: 1;
  transform: translate3d(0, 0, 0);
}

.reveal-delay-0 { transition-delay: 0ms; }
.reveal-delay-1 { transition-delay: 45ms; }
.reveal-delay-2 { transition-delay: 90ms; }
.reveal-delay-3 { transition-delay: 135ms; }
.reveal-delay-4 { transition-delay: 180ms; }
.reveal-delay-5 { transition-delay: 225ms; }

/* --- Donate Section --- */
.action-grid { 
  display: grid; 
  grid-template-columns: 0.6fr 1.4fr; 
  gap: 60px; 
  align-items: center; 
}

.graphic-box { 
  background: white; 
  border: 1px solid var(--line); 
  aspect-ratio: 1; 
  border-radius: 24px; 
  display: flex; 
  align-items: center; 
  justify-content: center; 
  box-shadow: 0 10px 26px rgba(0,0,0,0.04); 
}

.hardware-icon {
  width: min(128px, 58%);
  height: auto;
  fill: none;
  stroke: var(--navy);
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 6;
}

.action-content h2 { 
  font-family: "Sora"; 
  font-size: 32px; 
  margin: 0 0 16px; 
  color: var(--navy); 
}

.action-content p { 
  color: var(--muted); 
  font-size: 17px; 
  margin-bottom: 24px; 
}

.check-list { list-style: none; padding: 0; margin-bottom: 32px; }

.check-list li { 
  font-size: 15px; 
  margin-bottom: 12px; 
  padding-left: 28px; 
  position: relative; 
}

.check-list li::before { 
  content: "→"; 
  position: absolute; 
  left: 0; 
  color: var(--blue); 
  font-weight: 800; 
}

.card__actions { display: flex; gap: 12px; margin-top: 14px; }
.goal-box {
  margin-top: 16px;
}

.disclaimer { 
  font-size: 11px; 
  margin-top: 20px; 
  font-style: italic; 
  color: var(--muted); 
  font-variant-ligatures: none;
}

.no-ligature { font-variant-ligatures: none; }

/* --- Research Section --- */
.projects-section {
  padding-top: 48px;
}

.filters { 
  display: flex; 
  flex-wrap: wrap; 
  gap: 10px; 
  margin: 20px 0; 
}

.pill { 
  padding: 8px 16px; 
  border-radius: 999px; 
  border: 1px solid var(--line); 
  background: white; 
  font-weight: 800; 
  color: var(--muted); 
  cursor: pointer; 
  font-size: 13px; 
  transition: 0.2s;
}

.pill.is-active { 
  color: white; 
  background: var(--navy); 
  border-color: var(--navy); 
}

.projects {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 20px;
  margin-top: 24px;
}

.project-card {
  position: relative;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 12px;
  box-shadow: 0 16px 38px rgba(15, 23, 42, 0.035);
  overflow: hidden;
  padding: 24px;
  display: flex;
  flex-direction: column;
}

.project-card::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 3px;
  background: linear-gradient(90deg, rgba(37, 99, 235, 0.28), rgba(112, 190, 64, 0.26), transparent 70%);
  opacity: 0.7;
  pointer-events: none;
}

.project-card__title {
  font-family: "Sora", sans-serif;
  font-size: 20px; 
  font-weight: 700;
  margin: 0;
  color: var(--navy);
  padding-right: 85px; 
  line-height: 1.2;
}

.project-card__id {
  font-size: 11px;
  font-weight: 800;
  color: var(--muted);
  text-transform: uppercase;
  margin-bottom: 10px;
  letter-spacing: 0.05em;
}

.badge {
  position: absolute;
  top: 20px;
  right: 20px;
  font-size: 10px;
  font-weight: 800;
  text-transform: uppercase;
  padding: 5px 12px;
  border-radius: 20px;
  background: var(--ice);
  color: var(--navy);
  border: 1px solid rgba(23, 60, 90, 0.1);
  white-space: nowrap;
}

.badge--alzheimers { background: #e0dbff; color: #4433ff; }
.badge--cancer { background: #ffe0e0; color: #ff3333; }
.badge--influenza { background: #e0f7ff; color: #0077aa; }
.badge--parkinsons { background: #e7f8d8; color: #44751f; }

.project-card__meta {
  font-size: 15px; 
  font-weight: 800;
  color: var(--blue);
  margin-bottom: 12px;
  letter-spacing: 0;
}

.project-card__summary {
  font-size: 14px;
  color: var(--muted);
  line-height: 1.6;
  margin: 0;
}

.project-card__details {
  margin-top: 18px;
  border-top: 1px solid var(--line);
  padding-top: 12px;
  display: flex;
  flex: 1;
  flex-direction: column;
}

.project-card__details-title {
  margin: 0;
  font-size: 13px;
  font-weight: 800;
  color: var(--navy);
}

.project-card__content {
  font-size: 13px;
  padding-top: 12px;
  color: var(--muted);
  line-height: 1.6;
  display: flex;
  flex: 1;
  flex-direction: column;
}

.project-card__content p {
  margin: 0;
}

.project-card__links {
  display: flex;
  gap: 8px;
  margin-top: auto;
  padding-top: 16px;
}

.project-card__official-link {
  border-color: rgba(37, 99, 235, 0.28);
  color: var(--navy);
  gap: 6px;
  white-space: nowrap;
}

.project-card__official-link:hover {
  background: var(--navy);
  border-color: var(--navy);
  color: white;
  opacity: 1;
}

/* --- Footer --- */
.footer { 
  padding: 28px 0;
  border-top: 1px solid var(--line); 
  font-size: 12px; 
  color: var(--muted); 
  line-height: 1.5;
}

.footer__inner {
  display: grid;
  grid-template-columns: 1.2fr 1fr 1.2fr;
  gap: 24px;
  align-items: center;
}

.footer__group {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.footer__group--center {
  text-align: center;
  align-items: center;
}

.footer__group--right {
  text-align: right;
  align-items: flex-end;
}

.footer__brand,
.footer__credit {
  color: var(--navy);
  font-weight: 800;
}

.footer__credit {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  text-decoration: none;
  white-space: nowrap;
}

.footer__credit-line {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.footer__credit:hover {
  color: var(--blue);
}

.footer__credit-logo {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  flex: 0 0 auto;
}

.footer__email {
  color: var(--navy);
  font-weight: 800;
  text-decoration: none;
}

.footer__email:hover {
  color: var(--blue);
}

/* --- Process Page Classes --- */
.process-hero {
  padding: 30px 0 26px;
  border-bottom: 1px solid var(--line);
}

.process-hero__grid {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(260px, 0.75fr);
  gap: 28px;
  align-items: start;
}

.process-hero h1 {
  max-width: 760px;
  margin-bottom: 10px;
  font-size: 34px;
  line-height: 1.12;
}

.process-summary {
  background: var(--bg-alt);
  color: var(--ink);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 18px;
}

.process-summary__label {
  display: block;
  margin-bottom: 10px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.process-summary__list {
  display: grid;
  gap: 6px;
  margin: 0;
  padding-left: 18px;
  color: var(--navy);
  font-size: 15px;
  font-weight: 800;
  line-height: 1.5;
}

.process-section {
  padding: 48px 0;
  background: var(--bg-alt);
  border-bottom: 1px solid var(--line);
}

.process-flow {
  display: grid;
  gap: 16px;
}

.process-step {
  display: grid;
  grid-template-columns: 92px minmax(0, 1fr);
  gap: 22px;
  align-items: center;
  background: white;
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 18px;
}

.process-icon {
  width: 76px;
  height: 76px;
  border-radius: 16px;
  background: var(--bg-alt);
  border: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: center;
}

.process-icon svg {
  width: 50px;
  height: 50px;
}

.process-step__number {
  display: inline-block;
  margin-bottom: 6px;
  color: var(--blue);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.08em;
}

.process-step h2,
.process-note h2 {
  margin: 0 0 8px;
  color: var(--navy);
  font-family: "Sora";
  font-size: 20px;
}

.process-step p,
.process-note p {
  margin: 0;
  color: var(--muted);
  font-size: 15px;
}

.process-note {
  padding: 36px 0;
}

.process-note__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.process-note__inner p {
  max-width: 78ch;
}

/* --- Science Page Classes --- */
.science-hero { padding: 30px 0 26px; border-bottom: 1px solid var(--line); }
.science-kicker { font-size: 11px; font-weight: 900; color: var(--muted); text-transform: uppercase; letter-spacing: 0.06em; margin-bottom: 10px; }
.science-grid { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(260px, 0.75fr); gap: 28px; align-items: start; }
.science-hero h1 { max-width: 760px; margin-bottom: 10px; font-size: 34px; line-height: 1.12; }
.science-lead { font-size: 15px; color: var(--muted); line-height: 1.65; margin: 0 0 12px; max-width: 64ch; }
.science-lead--tight { margin: 0 0 16px; }
.science-card { background: var(--bg-alt); border: 1px solid var(--line); border-radius: 14px; padding: 18px; }
.science-card h3 { margin: 0 0 8px; font-family: "Sora"; color: var(--navy); font-size: 15px; }
.science-list { margin: 0; padding-left: 18px; color: var(--muted); font-size: 14px; line-height: 1.55; }
.science-list li { margin: 6px 0; }
.science-section { padding: 48px 0; }
.science-section--alt { background: var(--bg-alt); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.science-rows { display: grid; gap: 18px; }
.science-row { display: grid; grid-template-columns: 0.9fr 1.1fr; gap: 18px; align-items: center; background: white; border: 1px solid var(--line); border-radius: 18px; padding: 18px; }
.science-row h3 { font-family: "Sora"; margin: 0 0 8px; color: var(--navy); font-size: 18px; }
.science-row p { margin: 0; color: var(--muted); font-size: 15px; }
.science-visual { background: var(--bg-alt); border: 1px solid var(--line); border-radius: 16px; padding: 14px; display: flex; align-items: center; justify-content: center; min-height: 180px; overflow: hidden; }
.science-visual svg { max-width: 100%; height: auto; }

.floaty { animation: floaty 4.5s ease-in-out infinite; transform-origin: center; }
@keyframes floaty { 0%, 100% { transform: translateY(0px); } 50% { transform: translateY(-6px); } }
.stroke-draw { stroke-dasharray: 900; stroke-dashoffset: 900; animation: draw 2.6s ease forwards; }
@keyframes draw { to { stroke-dashoffset: 0; } }
.pulse { animation: pulse 2.2s ease-in-out infinite; }
@keyframes pulse { 0%, 100% { transform: scale(1); opacity: 0.95; } 50% { transform: scale(1.03); opacity: 1; } }

.science-faq { display: grid; gap: 12px; }
.science-faq details { background: white; border: 1px solid var(--line); border-radius: 14px; padding: 14px 16px; }
.science-faq summary { cursor: pointer; font-weight: 900; color: var(--navy); list-style: none; }
.science-faq summary::-webkit-details-marker { display: none; }
.science-faq p { margin: 10px 0 0; color: var(--muted); font-size: 14px; line-height: 1.7; }
.science-faq details[open] p { animation: answerFade 180ms ease; }
@keyframes answerFade { from { opacity: 0; transform: translateY(-3px); } to { opacity: 1; transform: translateY(0); } }

/* --- RESPONSIVE UPDATES --- */
@media (max-width: 860px) {
  .header__inner {
    flex-direction: column;
    gap: 12px;
    padding: 16px 0;
  }

  h1 {
    font-size: 42px;
  }
  
  .nav {
    flex-wrap: wrap;
    justify-content: center;
    gap: 12px 18px;
  }

  .hero__grid, 
  .action-grid { 
    grid-template-columns: 1fr; 
    gap: 30px;
  }
  
  .graphic-box {
    aspect-ratio: auto;
    padding: 30px;
    max-height: 240px;
  }

  .hardware-icon {
    width: 100px;
  }

  .projects { grid-template-columns: 1fr; }
  
  .badge { 
    position: static; 
    display: inline-block; 
    margin-top: 10px; 
    margin-bottom: 5px;
  }
  
  .project-card__title { padding-right: 0; }

  .science-grid { grid-template-columns: 1fr; }
  .science-row { grid-template-columns: 1fr; }

  .process-hero__grid,
  .process-step {
    grid-template-columns: 1fr;
  }

  .process-icon {
    width: 68px;
    height: 68px;
  }

  .process-note__inner {
    align-items: flex-start;
    flex-direction: column;
  }

  .page-cta__inner {
    align-items: flex-start;
    flex-direction: column;
  }

  .footer__inner {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 14px;
  }

  .footer__group,
  .footer__group--center,
  .footer__group--right {
    align-items: center;
    text-align: center;
  }

  .footer__credit-line {
    justify-content: center;
  }
}

@media (max-width: 520px) {
  html {
    scroll-padding-top: 132px;
  }

  .container {
    width: min(100% - 28px, 1120px);
  }

  .header__inner {
    align-items: stretch;
  }

  .brand {
    justify-content: center;
  }

  .brand__logo {
    width: 34px;
    height: 34px;
  }

  .brand__name {
    font-size: 16px;
  }

  .brand__motto {
    font-size: 10px;
  }

  .nav {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px 10px;
    width: 100%;
  }

  .nav a {
    justify-content: center;
    font-size: 12px;
    line-height: 1.2;
    text-align: center;
  }

  h1 {
    font-size: 34px;
  }

  .hero-block,
  .science-hero,
  .process-hero {
    padding-top: 24px;
  }

  .science-hero h1,
  .process-hero h1,
  .subpage-titleRow h1.section-title {
    font-size: 30px;
  }

  .section,
  .science-section,
  .process-section {
    padding: 40px 0;
  }

  .hero__actions,
  .card__actions {
    flex-direction: column;
    align-items: stretch;
  }

  .impact-card,
  .science-card,
  .process-summary,
  .project-card {
    border-radius: 14px;
    padding: 18px;
  }

  .stat {
    align-items: flex-start;
    flex-direction: column;
    gap: 2px;
  }

  .stat-value {
    text-align: left;
  }

  .project-card__official-link {
    width: 100%;
  }

  .page-cta__button {
    width: 100%;
  }

  .process-summary__list {
    font-size: 15px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  ::view-transition-old(root),
  ::view-transition-new(root),
  .floaty,
  .stroke-draw,
  .pulse,
  .science-faq details[open] p {
    animation: none;
  }

  .reveal-ready .reveal-on-scroll {
    opacity: 1;
    transform: none;
    transition: none;
  }

  .stroke-draw {
    stroke-dashoffset: 0;
  }
}
