:root {
  --ink: #17201c;
  --muted: #5f6964;
  --paper: #f8f8f4;
  --surface: #ffffff;
  --line: #dfe3dd;
  --accent: #0f6651;
  --accent-soft: #e7f1ed;
  --award: #7a4d12;
  --award-soft: #f6ead5;
  --serif: "Newsreader", Georgia, serif;
  --sans: "DM Sans", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background:
    radial-gradient(circle at 10% 0%, rgba(15, 102, 81, 0.07), transparent 25rem),
    var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.68;
  -webkit-font-smoothing: antialiased;
}

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

a:hover {
  color: #094b3c;
}

.skip-link {
  position: absolute;
  left: -9999px;
}

.skip-link:focus {
  left: 1rem;
  top: 1rem;
  z-index: 10;
  padding: 0.6rem 0.9rem;
  border-radius: 0.25rem;
  background: var(--ink);
  color: white;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 5;
  border-bottom: 1px solid rgba(223, 227, 221, 0.85);
  background: rgba(248, 248, 244, 0.9);
  backdrop-filter: blur(14px);
}

.header-inner,
.footer-inner,
.page-shell {
  width: min(920px, calc(100% - 3rem));
  margin: 0 auto;
}

.header-inner {
  min-height: 68px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.wordmark {
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  border-radius: 50%;
  background: var(--ink);
  color: white;
  font-family: var(--serif);
  font-size: 1.05rem;
  font-weight: 600;
  text-decoration: none;
}

nav {
  display: flex;
  gap: 1.5rem;
}

nav a {
  color: var(--muted);
  font-size: 0.83rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  text-decoration: none;
}

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

.page-shell {
  padding: 6.5rem 0 7rem;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 210px;
  gap: 4.75rem;
  align-items: center;
  padding-bottom: 6.5rem;
}

.hero-copy {
  grid-column: 1;
  grid-row: 1;
}

.portrait {
  grid-column: 2;
  grid-row: 1;
  width: 210px;
  height: 210px;
  border: 1px solid var(--line);
  border-radius: 50%;
  object-fit: cover;
  filter: saturate(0.82);
  box-shadow: 0 20px 45px rgba(23, 32, 28, 0.12);
}

.eyebrow,
.section-kicker {
  margin: 0 0 1rem;
  color: var(--accent);
  font-size: 0.74rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.eyebrow p,
.hero-name p,
.hero-lede p,
.hero-detail p,
.section-kicker p,
.section-heading p,
.publication-title p,
.venue p,
.award p {
  margin: 0;
}

.hero-name {
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(3.7rem, 8vw, 5.8rem);
  font-weight: 500;
  letter-spacing: -0.055em;
  line-height: 0.92;
}

.hero-lede {
  max-width: 660px;
  margin: 1.7rem 0 0;
  font-family: var(--serif);
  font-size: clamp(1.45rem, 3vw, 1.9rem);
  line-height: 1.28;
}

.hero-detail {
  max-width: 640px;
  margin: 1.2rem 0 0;
  color: var(--muted);
}

.profile-links,
.paper-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  margin-top: 1.5rem;
}

.profile-links p,
.paper-links p {
  margin: 0;
}

.profile-links a,
.paper-links a {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0.35rem 0.72rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  color: var(--ink);
  font-size: 0.78rem;
  font-weight: 600;
  text-decoration: none;
}

.profile-links a:hover,
.paper-links a:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.profile-links a {
  width: 44px;
  height: 44px;
  min-height: 44px;
  padding: 0;
  justify-content: center;
  overflow: hidden;
  border-radius: 50%;
  background-position: center;
  background-repeat: no-repeat;
  background-size: 21px 21px;
  text-indent: -9999px;
  white-space: nowrap;
  transition:
    border-color 160ms ease,
    box-shadow 160ms ease,
    transform 160ms ease;
}

.profile-links a[href*="github.com"] {
  background-image: url("/static/github.svg");
  background-size: 22px 22px;
}

.profile-links a[href*="linkedin.com"] {
  background-image: url("/static/linkedin.svg");
}

.profile-links a:hover {
  box-shadow: 0 8px 18px rgba(23, 32, 28, 0.1);
  transform: translateY(-1px);
}

.profile-links a:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

.section-block {
  display: grid;
  grid-template-columns: 76px minmax(0, 1fr);
  padding: 4.75rem 0;
  border-top: 1px solid var(--line);
  scroll-margin-top: 78px;
}

.section-block > :not(.section-kicker) {
  grid-column: 2;
}

.section-kicker {
  grid-column: 1;
  grid-row: 1 / span 20;
  padding-top: 0.5rem;
}

.section-heading {
  margin: 0 0 1.8rem;
  font-family: var(--serif);
  font-size: clamp(2.5rem, 5vw, 3.5rem);
  font-weight: 500;
  letter-spacing: -0.035em;
  line-height: 1;
}

.section-block > p {
  max-width: 720px;
  margin: 0 0 1rem;
  color: #38413d;
}

.publication {
  margin: 0;
  padding: 2.2rem 0;
  border-top: 1px solid var(--line);
}

.publication.featured {
  position: relative;
  margin: 0 0 2.25rem;
  padding: 2.2rem 2.35rem 2.35rem;
  overflow: hidden;
  border: 1px solid #bdd4cb;
  border-radius: 0.5rem;
  background: linear-gradient(135deg, #f2f7f4 0%, #ffffff 72%);
  box-shadow: 0 18px 44px rgba(15, 102, 81, 0.08);
}

.publication.featured::before {
  position: absolute;
  inset: 0 auto 0 0;
  width: 4px;
  background: var(--accent);
  content: "";
}

.publication-topline {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.7rem;
}

.venue,
.award {
  display: inline-block;
  width: fit-content;
  margin-bottom: 0.9rem;
  padding: 0.28rem 0.58rem;
  border-radius: 0.2rem;
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 0.69rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.award {
  background: var(--award-soft);
  color: var(--award);
}

.publication-title {
  max-width: 750px;
  margin: 0 0 0.7rem;
  font-family: var(--serif);
  font-size: clamp(1.45rem, 3vw, 1.85rem);
  font-weight: 600;
  line-height: 1.18;
}

.publication p {
  margin: 0.42rem 0;
  color: var(--muted);
}

.publication.featured p {
  color: #3e4944;
}

.paper-links {
  margin-top: 1.1rem;
}

.timeline {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.1rem;
}

.timeline-item {
  min-height: 130px;
  padding: 1.45rem 1.55rem;
  border: 1px solid var(--line);
  border-radius: 0.35rem;
  background: rgba(255, 255, 255, 0.65);
}

.timeline-item p {
  margin: 0.25rem 0;
  color: var(--muted);
}

.timeline-item p:first-child {
  color: var(--ink);
  font-family: var(--serif);
  font-size: 1.3rem;
}

footer {
  border-top: 1px solid var(--line);
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  gap: 2rem;
  padding: 2rem 0 2.5rem;
  color: var(--muted);
  font-size: 0.77rem;
}

@media (max-width: 760px) {
  .header-inner,
  .footer-inner,
  .page-shell {
    width: min(100% - 2rem, 920px);
  }

  .header-inner {
    min-height: 60px;
  }

  nav {
    gap: 0.85rem;
  }

  nav a {
    font-size: 0.73rem;
  }

  .page-shell {
    padding: 3.5rem 0 4rem;
  }

  .hero {
    grid-template-columns: 1fr;
    gap: 2rem;
    padding-bottom: 4.5rem;
  }

  .portrait {
    grid-column: 1;
    grid-row: 1;
    width: 120px;
    height: 120px;
  }

  .hero-copy {
    grid-row: 2;
  }

  .hero-name {
    font-size: clamp(3.3rem, 17vw, 4.8rem);
  }

  .section-block {
    grid-template-columns: 1fr;
    padding: 3.5rem 0;
  }

  .section-kicker,
  .section-block > :not(.section-kicker) {
    grid-column: 1;
  }

  .section-kicker {
    grid-row: auto;
    margin-bottom: 0.65rem;
  }

  .publication.featured {
    padding: 1.6rem 1.35rem 1.7rem;
  }

  .timeline {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  nav a:first-child {
    display: none;
  }

  .hero-name {
    font-size: 3.45rem;
  }

  .hero-lede {
    font-size: 1.35rem;
  }

  .footer-inner {
    flex-direction: column;
    gap: 0.25rem;
  }
}

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