/* Shared colors and typography across the static lab website. */
:root {
  --site-text: #f5f8ff;
  --site-muted: #c4cfde;
  --site-accent: #9ed6ff;
  --site-line: rgba(176, 218, 255, .24);
  --site-background: linear-gradient(
    180deg,
    #020409 0%,
    #050b16 12%,
    #081a33 25%,
    #10294c 39%,
    #122e51 47%,
    #0d2445 55%,
    #071329 68%,
    #061e30 79%,
    #07383f 93%,
    #062e39 100%
  );
}
html { background: #020409; }
body {
  min-height: 100svh;
  background: var(--site-background);
  background-repeat: no-repeat;
  background-attachment: scroll;
  color: var(--site-text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
.footer { background: transparent; color: #c1d6ed; }
.interior-page main h1 {
  font-size: clamp(2rem, 3.2vw, 2.8rem);
  line-height: 1.08;
  letter-spacing: -.045em;
  font-weight: 500;
  color: var(--site-text);
}
.interior-page main :is(.research-group-title, .intro h2, .student-section > h2) {
  font-size: clamp(1.8rem, 3.2vw, 2.8rem);
  line-height: 1.1;
  letter-spacing: -.045em;
  font-weight: 500;
}
.interior-page .eyebrow {
  color: var(--site-accent);
  font-size: 11px;
  letter-spacing: .18em;
  font-weight: 800;
}
.interior-page main {
  max-width: 1360px;
  padding: 40px clamp(24px, 6vw, 80px) 100px;
}
.publications-page main > p:not(.eyebrow) {
  margin: 24px 0 48px;
  color: var(--site-muted);
  font-size: 16px;
  line-height: 1.65;
}
.publications-page .footer {
  max-width: 1360px;
  padding: 28px clamp(24px, 6vw, 80px);
  border-top: 1px solid var(--site-line);
}
.nav .links a[aria-current="page"] { color: var(--site-accent); }
@media (max-width: 760px) {
  .nav { flex-wrap: wrap; gap: 24px; }
  .nav .links { display: flex; width: 100%; flex-wrap: wrap; gap: 14px 20px; font-size: 13px; }
  .nav .links a:not(.button) { display: inline; }
  .nav .links .button { font-size: 13px; padding: 8px 13px; }
  .interior-page main { padding-top: 28px; }
}

/* One viewport of stars at the top of every page, beneath its content. */
body { position: relative; }
#stars {
  position: absolute;
  inset: 0 0 auto;
  display: block;
  width: 100%;
  height: 100svh;
  pointer-events: none;
}
.interior-page #stars {
  mask-image: linear-gradient(to bottom, #000 0%, #000 65%, transparent 100%);
}
.interior-page main,
.interior-page .footer {
  position: relative;
  z-index: 1;
}

/* Consistent page titles and a compact gap before the first content block. */
.interior-page .page-heading { margin: 0 0 24px; }
.interior-page .page-heading h1 { margin: 0; }
.research-page .research-note { margin-inline: 0; }
.people-page .director { padding-top: 0; }
.people-page .director h2 {
  margin: 0 0 30px;
  font-size: clamp(2rem, 3.2vw, 2.8rem);
  line-height: 1.08;
  letter-spacing: -.045em;
  font-weight: 500;
}

.recruitment-announcement {
  text-decoration: underline;
  text-underline-offset: .18em;
}

/* Mobile navigation expands in the document flow, keeping content below it. */
.nav-toggle { display: none; }
@media (max-width: 760px) {
  .nav {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 16px;
  }
  .nav.nav-ready .nav-toggle {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 5px;
    width: 44px;
    height: 44px;
    padding: 10px;
    flex-shrink: 0;
    border: 1px solid var(--site-line);
    border-radius: 10px;
    background: rgba(148,205,255,.08);
    color: var(--site-text);
    cursor: pointer;
  }
  .nav-toggle span {
    display: block;
    width: 22px;
    height: 2px;
    background: currentColor;
    border-radius: 2px;
  }
  .nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
  .nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
  .nav-toggle:focus-visible { outline: 2px solid var(--site-accent); outline-offset: 4px; }
  .nav .links {
    flex-basis: 100%;
    flex-direction: column;
    align-items: stretch;
    gap: 4px;
    padding-top: 12px;
    border-top: 1px solid var(--site-line);
  }
  .nav.nav-ready .links { display: none; }
  .nav.nav-ready.menu-open .links { display: flex; }
  .nav .links a:not(.button),
  .nav .links .button {
    display: flex;
    align-items: center;
    min-height: 44px;
    padding: 12px 14px;
    font-size: 14px;
  }
  .nav .links .button { justify-content: center; margin-top: 6px; }
  .hero { height: auto; min-height: 100svh; }
  .hero .hero-copy { flex: 1 0 auto; min-height: auto; }
}
