:root {
  --navy: #123262;
  --navy-deep: #0e274c;
  --ink: #202630;
  --muted: #5e6773;
  --link: #216bb0;
  --border: #dee5ec;
  --soft: #f3f7fb;
  --content-width: 1110px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background: #fff;
  font-family: "Lato", "Helvetica Neue", Arial, sans-serif;
  font-size: 16.5px;
  line-height: 1.55;
}

a {
  color: var(--link);
  text-decoration: none;
}

a:hover,
a:focus-visible {
  color: var(--navy);
  text-decoration: underline;
}

p {
  margin: 0 0 1rem;
}

h1,
h2,
h3 {
  margin: 0;
  color: #151a20;
  font-weight: 600;
  line-height: 1.25;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: var(--navy);
}

.nav-shell {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: min(var(--content-width), calc(100% - 3rem));
  min-height: 58px;
  margin: 0 auto;
}

.brand,
.brand:hover,
.brand:focus-visible {
  color: #fff;
  font-size: 1.18rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  text-decoration: none;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 1.05rem;
}

.nav-links a {
  color: rgba(255, 255, 255, 0.75);
}

.nav-links a:hover,
.nav-links a:focus-visible {
  color: #fff;
  text-decoration: none;
}

.nav-links a[aria-current="page"] {
  color: #fff;
  font-weight: 600;
}

.menu-toggle {
  display: none;
  color: #fff;
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.42);
  border-radius: 4px;
  padding: 0.34rem 0.65rem;
  font: inherit;
}

.page {
  width: min(var(--content-width), calc(100% - 3rem));
  margin: 0 auto;
}

.hero,
.section {
  scroll-margin-top: 76px;
}

.anchor-target {
  display: block;
  height: 0;
  scroll-margin-top: 76px;
}

.hero {
  padding: 2.15rem 0 0;
}

.hero-grid {
  display: grid;
  grid-template-columns: 220px minmax(270px, 1fr) 260px;
  gap: 2.45rem;
  align-items: start;
}

.portrait {
  margin: 0;
}

.portrait img {
  display: block;
  width: 200px;
  height: 215px;
  object-fit: cover;
  object-position: center 25%;
}

.identity {
  padding-top: 0.15rem;
}

.identity h1 {
  margin-bottom: 1.45rem;
  font-size: clamp(1.75rem, 3vw, 2rem);
}

.affiliation {
  margin-bottom: 0.15rem;
}

.email {
  margin-bottom: 0.25rem;
}

.social-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.58rem;
  font-weight: 500;
}

.social-links span {
  color: #7b8590;
}

.interests {
  padding-top: 1.35rem;
}

.interests h2 {
  margin-bottom: 1.55rem;
  font-size: 1.08rem;
  font-weight: 700;
}

.interests ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.bio {
  margin-top: 1.15rem;
  text-align: justify;
}

.bio p + p {
  margin-top: 0.4rem;
}

.section {
  margin-top: 2.35rem;
}

.section > h2,
.section-heading h1,
.section-heading h2 {
  margin-bottom: 1rem;
  font-size: 1.55rem;
  font-weight: 500;
}

.notice {
  padding: 0.95rem 1.15rem 0.9rem;
  background: var(--soft);
  border-left: 4px solid var(--navy);
}

.notice p {
  margin: 0;
}

.section-heading {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  border-bottom: 1px solid var(--border);
  margin-bottom: 0.2rem;
}

.publications-page,
.content-page {
  padding-bottom: 3rem;
}

.publications-page .section,
.content-page .section {
  margin-top: 2.15rem;
}

.page-intro {
  max-width: 760px;
  margin: 0.65rem 0 1.6rem;
  color: var(--muted);
}

.content-block {
  max-width: 860px;
  margin-right: auto;
  margin-left: auto;
}

.content-list {
  margin: 0;
  padding-left: 1.35rem;
}

.content-list li {
  margin-bottom: 0.35rem;
}

.compact-list {
  margin-top: 0.35rem;
}

.members-block {
  max-width: var(--content-width);
}

.members-block h3 {
  margin-top: 1.45rem;
  margin-bottom: 0.82rem;
  font-size: 1.08rem;
  font-weight: 700;
}

.people-grid {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: center;
  gap: 1.7rem 1.2rem;
  margin-top: 1rem;
}

.person-card {
  flex: 0 1 230px;
  width: 100%;
  max-width: 230px;
  text-align: center;
}

.person-card img,
.person-placeholder {
  display: block;
  width: 150px;
  height: 150px;
  margin: 0 auto 0.72rem;
  border-radius: 50%;
}

.person-card img {
  object-fit: cover;
  object-position: center;
}

.person-placeholder {
  display: grid;
  place-items: center;
  color: #fff;
  background: var(--navy);
  font-size: 2rem;
  font-weight: 700;
  letter-spacing: 0.04em;
}

.person-card h4 {
  margin: 0 0 0.2rem;
  font-size: 1rem;
  font-weight: 700;
}

.person-card p {
  margin: 0;
  color: var(--muted);
  font-size: 0.95rem;
}

.lab-gallery {
  max-width: var(--content-width);
}

.lab-carousel {
  position: relative;
  width: min(760px, 100%);
  margin: 1.15rem auto 0;
  padding-bottom: 2rem;
}

.lab-carousel-viewport {
  position: relative;
  overflow: hidden;
  aspect-ratio: 4 / 3;
  background: var(--soft);
  border: 1px solid var(--border);
  border-radius: 8px;
}

.lab-slide {
  position: absolute;
  inset: 0;
  margin: 0;
  opacity: 0;
  pointer-events: none;
  transition: opacity 180ms ease;
}

.lab-slide.is-active {
  opacity: 1;
  pointer-events: auto;
}

.lab-slide img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.lab-carousel-button {
  position: absolute;
  top: calc(50% - 1rem);
  z-index: 2;
  display: grid;
  place-items: center;
  width: 2.35rem;
  height: 2.35rem;
  color: #fff;
  background: rgba(18, 50, 98, 0.88);
  border: 0;
  border-radius: 50%;
  cursor: pointer;
  font: 700 1.8rem/1 Georgia, serif;
}

.lab-carousel-button:hover,
.lab-carousel-button:focus-visible {
  background: var(--navy-deep);
}

.lab-carousel-prev {
  left: 0.75rem;
}

.lab-carousel-next {
  right: 0.75rem;
}

.lab-carousel-dots {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  display: flex;
  justify-content: center;
  gap: 0.45rem;
}

.lab-carousel-dot {
  width: 0.62rem;
  height: 0.62rem;
  padding: 0;
  background: #aeb8c4;
  border: 0;
  border-radius: 50%;
  cursor: pointer;
}

.lab-carousel-dot.is-active,
.lab-carousel-dot:hover,
.lab-carousel-dot:focus-visible {
  background: var(--navy);
}

.publication-year {
  margin: 2rem 0 0.25rem;
  padding-bottom: 0.35rem;
  border-bottom: 1px solid var(--border);
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--navy);
}

.heading-link,
.heading-links {
  white-space: nowrap;
  font-size: 0.96rem;
}

.heading-links {
  display: flex;
  align-items: center;
  gap: 0.36rem;
}

.heading-links span {
  color: var(--muted);
}

#publications .section-heading {
  display: block;
  padding-bottom: 0.85rem;
}

#publications .heading-links {
  margin-top: -0.55rem;
}

.news-list {
  margin: 0;
  padding-left: 2.25rem;
}

.news-list li {
  margin-bottom: 0.28rem;
}

.publication {
  display: grid;
  grid-template-columns: 205px 1fr;
  gap: 1.35rem;
  padding: 1.3rem 0;
  border-bottom: 1px solid var(--border);
}

.publication-media {
  position: relative;
  width: 205px;
  height: 124px;
}

.publication-media img {
  display: block;
  width: 100%;
  height: 124px;
  object-fit: contain;
  object-position: left center;
}

.conference-badge {
  position: absolute;
  top: -0.45rem;
  left: -0.38rem;
  z-index: 1;
  padding: 0.24rem 0.58rem;
  color: #fff;
  background: #00369f;
  border-radius: 6px;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  line-height: 1.2;
}

.publication h3 {
  margin-bottom: 0.34rem;
  font-size: 1.04rem;
  font-weight: 700;
}

.authors,
.venue {
  margin-bottom: 0.22rem;
  font-size: 0.96rem;
}

.authors {
  color: #303743;
}

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

.highlight-note {
  display: inline-block;
  margin: 0.08rem 0 0.3rem;
  font-size: 0.9rem;
  font-weight: 700;
}

.highlight-note a {
  color: #9b3b00;
  text-decoration: underline;
}

.paper-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
  margin: 0.4rem 0 0;
  font-size: 0.95rem;
}

.paper-links a::before {
  content: "[";
}

.paper-links a::after {
  content: "]";
}

.background-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3.25rem;
}

.background-grid h3 {
  margin-bottom: 0.85rem;
  font-size: 1.1rem;
}

.contact {
  margin-bottom: 3rem;
}

.site-footer {
  padding: 1.1rem 1.5rem;
  color: var(--muted);
  border-top: 1px solid var(--border);
  text-align: center;
  font-size: 0.92rem;
}

.site-footer p {
  margin: 0;
}

@media (max-width: 860px) {
  .hero-grid {
    grid-template-columns: 205px 1fr;
    gap: 1.9rem;
  }

  .interests {
    grid-column: 2;
    padding-top: 0.55rem;
  }

  .interests h2 {
    margin-bottom: 0.55rem;
  }
}

@media (max-width: 680px) {
  body {
    font-size: 16px;
  }

  .nav-shell,
  .page {
    width: min(var(--content-width), calc(100% - 2rem));
  }

  .nav-shell {
    position: relative;
    min-height: 56px;
  }

  .menu-toggle {
    display: block;
  }

  .nav-links {
    display: none;
    position: absolute;
    top: 56px;
    left: -1rem;
    right: -1rem;
    flex-direction: column;
    align-items: flex-start;
    gap: 0;
    padding: 0.45rem 1rem 0.7rem;
    background: var(--navy-deep);
  }

  .nav-links.is-open {
    display: flex;
  }

  .nav-links a {
    width: 100%;
    padding: 0.48rem 0;
  }

  .hero {
    padding-top: 1.45rem;
  }

  .hero-grid {
    grid-template-columns: 1fr;
    gap: 1.3rem;
  }

  .portrait img {
    width: min(210px, 100%);
    height: 220px;
  }

  .identity h1 {
    margin-bottom: 0.85rem;
  }

  .interests {
    grid-column: auto;
  }

  .bio {
    margin-top: 1.55rem;
    text-align: left;
  }

  .section-heading {
    display: block;
    padding-bottom: 0.85rem;
  }

  .heading-links {
    margin-top: -0.4rem;
  }

  .publication {
    grid-template-columns: 1fr;
    gap: 0.7rem;
  }

  .publication-media {
    width: min(250px, 100%);
    height: 132px;
  }

  .publication-media img {
    height: 132px;
  }

  .background-grid {
    grid-template-columns: 1fr;
    gap: 1.25rem;
  }

  .people-grid {
    flex-direction: column;
    align-items: center;
    gap: 1.35rem;
  }

  .lab-carousel {
    padding-bottom: 1.8rem;
  }

  .lab-carousel-button {
    width: 2rem;
    height: 2rem;
    font-size: 1.45rem;
  }

  .lab-carousel-prev {
    left: 0.5rem;
  }

  .lab-carousel-next {
    right: 0.5rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .lab-slide {
    transition: none;
  }
}
