* {
  box-sizing: border-box;
}

:root {
  --background: #fafafa;
  --text: #24272b;
  --muted: #616873;
  --border: #e1e4e8;
  --accent: #2563b8;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--background);
  color: var(--text);
  font-family: ui-sans-serif, -apple-system, BlinkMacSystemFont,
    "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 1rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

a {
  color: var(--accent);
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

a:hover {
  text-decoration-thickness: 2px;
}

a:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 4px;
  border-radius: 2px;
}

.skip-link {
  position: absolute;
  z-index: 1;
  top: 0.75rem;
  left: 1rem;
  padding: 0.5rem 0.75rem;
  background: var(--background);
  transform: translateY(-200%);
}

.skip-link:focus {
  transform: translateY(0);
}

.site-header {
  border-top: 4px solid var(--text);
  border-bottom: 1px solid var(--border);
}

.site-nav,
.page-content,
.site-footer {
  max-width: 860px;
  margin-right: auto;
  margin-left: auto;
  padding-right: 1.5rem;
  padding-left: 1.5rem;
}

.site-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  padding-top: 0.85rem;
  padding-bottom: 0.85rem;
}

.nav-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.5rem;
  font-size: 0.95rem;
}

.site-nav a {
  color: var(--muted);
  text-decoration: none;
  transition: color 0.2s ease;
}

.site-nav .home-link {
  color: var(--text);
  font-size: 1.25rem;
  font-weight: 500;
}

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

.page-content {
  padding-top: 2.75rem;
}

h1,
h2,
h3,
h4 {
  color: var(--text);
  letter-spacing: -0.02em;
}

h1 {
  margin: 0;
  font-size: clamp(2rem, 5vw, 2.5rem);
  line-height: 1.2;
  font-weight: 600;
  overflow-wrap: break-word;
}

h2 {
  margin: 0 0 1.25rem;
  font-size: 1.4rem;
  line-height: 1.35;
  font-weight: 550;
}

p {
  margin: 0 0 1rem;
}

.subtitle {
  margin: 0.65rem 0 1.75rem;
  color: var(--muted);
  font-size: 1.05rem;
}

.about-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 18rem;
  gap: 3rem;
  align-items: start;
}

.about-copy,
.contact-details {
  min-width: 0;
}

#research {
  margin-top: 2rem;
}

.research-interests {
  margin: 0.5rem 0 0;
  padding-left: 1.25rem;
}

.research-interests li {
  margin: 0.3rem 0;
}

#research h2,
.contact-details h2 {
  margin-bottom: 0.75rem;
  font-size: 1.1rem;
  font-weight: 600;
}

.contact-details {
  font-size: 0.9rem;
  line-height: 1.65;
}

.contact-email {
  margin-bottom: 1.25rem;
  overflow-wrap: anywhere;
}

address {
  font-style: normal;
}

address p {
  margin-bottom: 1.25rem;
}

address p:last-child {
  margin-bottom: 0;
}

address strong {
  display: block;
  margin-bottom: 0.25rem;
  font-weight: 600;
}

section[id],
aside[id] {
  scroll-margin-top: 1.5rem;
}

.content-section {
  margin-top: 3rem;
  padding-top: 2rem;
  border-top: 1px solid var(--border);
}

.publication-group-title {
  margin: 1.5rem 0 0.5rem;
  font-size: 1.05rem;
  font-weight: 600;
}

.publication {
  padding: 0.9rem 0 1.1rem;
}

.publication + .publication {
  border-top: 1px solid var(--border);
}

.publication-title {
  margin: 0 0 0.3rem;
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.5;
  letter-spacing: -0.01em;
}

.authors {
  margin-bottom: 0.65rem;
  color: var(--muted);
  font-size: 0.93rem;
}

.publication-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.publication-links a {
  display: inline-flex;
  align-items: center;
  padding: 0.15rem 0.65rem;
  border: 1px solid var(--border);
  border-radius: 999px;
  font-size: 0.82rem;
  font-weight: 500;
  text-decoration: none;
  transition: border-color 0.2s ease, background-color 0.2s ease;
}

.publication-links a:hover {
  border-color: var(--accent);
  background: #eff6ff;
}

.profile-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.5rem;
}

.site-footer {
  margin-top: 3.5rem;
  padding-top: 1.5rem;
  padding-bottom: 2.5rem;
  color: var(--muted);
  font-size: 0.85rem;
}

.site-footer p {
  margin: 0;
}

@media (max-width: 700px) {
  .about-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 2rem;
  }
}

@media (max-width: 480px) {
  .site-nav,
  .page-content,
  .site-footer {
    padding-right: 1.25rem;
    padding-left: 1.25rem;
  }

  .site-nav {
    flex-wrap: wrap;
    gap: 0.5rem;
  }

  .home-link {
    flex-basis: 100%;
  }

  .nav-links {
    gap: 0.5rem 1.25rem;
  }

  .page-content {
    padding-top: 2rem;
  }

  .content-section {
    margin-top: 2.5rem;
    padding-top: 1.5rem;
  }
}

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

  a {
    transition: none;
  }
}
