:root {
  color-scheme: light;
  --ink: #202124;
  --muted: #5f6368;
  --line: #e2e5e8;
  --paper: #ffffff;
  --surface: #ffffff;
  --accent: #1f6f78;
  --accent-strong: #15535a;
  --warm: #8a4a2f;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background: var(--paper);
  line-height: 1.6;
}

a {
  color: var(--accent-strong);
  text-decoration-color: color-mix(in srgb, var(--accent-strong), transparent 58%);
  text-underline-offset: 0.18em;
}

a:hover {
  color: var(--warm);
  text-decoration-color: currentColor;
}

.site-shell {
  display: grid;
  grid-template-columns: 210px minmax(0, 610px);
  gap: 54px;
  width: min(930px, calc(100% - 48px));
  margin: 0 auto;
  padding: 42px 0 52px;
  position: relative;
}

.profile-sidebar {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.topbar {
  display: flex;
  gap: 24px;
  align-items: center;
  justify-content: space-between;
  min-height: 42px;
  margin-bottom: 30px;
  font-size: 0.9rem;
}

.wordmark {
  color: var(--ink);
  font-weight: 650;
  text-decoration: none;
}

.nav-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 18px;
  justify-content: flex-end;
}

.topbar-actions {
  display: flex;
  gap: 18px;
  align-items: center;
}

.topbar .language-switch {
  flex: 0 0 auto;
  margin-top: 0;
}

.nav-links a {
  color: var(--muted);
  text-decoration: none;
}

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

.content-column {
  min-width: 0;
}

.section-kicker {
  display: none;
}

h1,
h2,
p {
  margin-top: 0;
}

h1 {
  max-width: none;
  margin-bottom: 12px;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 1.86rem;
  font-weight: 650;
  line-height: 1.1;
  letter-spacing: 0;
}

.affiliation {
  margin: 12px 0 10px;
  color: var(--muted);
  font-size: 0.92rem;
  font-weight: 400;
  line-height: 1.45;
}

.links {
  display: flex;
  flex-wrap: wrap;
  gap: 9px 13px;
  align-items: center;
  font-size: 0.95rem;
}

.links a {
  color: var(--ink);
  min-height: 24px;
  font-weight: 600;
  text-decoration: none;
}

.links a:hover {
  color: var(--accent);
  text-decoration: underline;
}

.language-switch {
  display: inline-flex;
  margin-top: 16px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 4px;
}

.site-language-switch {
  position: absolute;
  top: 42px;
  right: 0;
  margin-top: 0;
}

.language-button {
  min-width: 36px;
  min-height: 28px;
  padding: 3px 8px;
  border: 0;
  border-right: 1px solid var(--line);
  background: var(--paper);
  color: var(--muted);
  font: inherit;
  font-size: 0.78rem;
  font-weight: 650;
  line-height: 1;
  cursor: pointer;
}

.language-button:last-child {
  border-right: 0;
}

.language-button[aria-pressed="true"] {
  background: var(--ink);
  color: var(--paper);
}

.language-button:hover:not([aria-pressed="true"]) {
  background: #f3f5f6;
  color: var(--ink);
}

.language-button:focus-visible {
  position: relative;
  outline: 2px solid var(--accent);
  outline-offset: -2px;
}

.portrait-wrap {
  margin: 0;
  width: 190px;
  aspect-ratio: 1;
  overflow: hidden;
  border: 0;
  background: var(--surface);
}

.portrait {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.section {
  display: block;
  padding: 0;
  border-bottom: 0;
}

.section + .section {
  margin-top: 14px;
}

.section-body {
  max-width: none;
}

.section h2 {
  margin-bottom: 10px;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 1.82rem;
  font-weight: 650;
  line-height: 1.12;
  letter-spacing: 0;
}

.section p {
  color: var(--muted);
  font-size: 1rem;
  line-height: 1.48;
}

.section p + p {
  margin-top: 10px;
}

.section p:last-child {
  margin-bottom: 0;
}

.project-entry h3 {
  margin: 0 0 3px;
  font-size: 1rem;
  font-weight: 650;
  line-height: 1.4;
}

.project-entry h3 a {
  color: var(--accent);
  text-decoration: none;
}

.project-entry h3 a:hover {
  color: var(--warm);
  text-decoration: underline;
}

.project-entry .project-entry-link {
  display: inline-block;
  margin-top: 5px;
  font-size: 0.92rem;
}

.project-entry + .project-entry {
  margin-top: 15px;
}

.publication-list {
  display: grid;
  gap: 0;
  margin: 2px 0 0;
  padding: 0;
  list-style: none;
}

.publication-item {
  display: grid;
  grid-template-columns: 58px minmax(0, 1fr);
  gap: 16px;
  padding: 10px 0;
  border-bottom: 0;
}

.publication-item:first-child {
  padding-top: 4px;
}

.publication-item:last-child {
  border-bottom: 0;
}

.publication-year {
  color: var(--muted);
  font-size: 0.92rem;
  font-weight: 650;
  line-height: 1.45;
}

.publication-item h3 {
  display: inline;
  margin: 0;
  font-size: 1rem;
  font-weight: 400;
  line-height: 1.4;
  letter-spacing: 0;
}

.publication-item h3 a {
  color: var(--accent);
  text-decoration: none;
}

.publication-item h3 a:hover {
  color: var(--warm);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
}

.publication-authors,
.publication-meta,
.publication-note {
  margin: 0;
  color: var(--muted);
  font-size: 1rem;
  line-height: 1.4;
}

.publication-authors strong {
  color: var(--ink);
  font-weight: 650;
}

.publication-note {
  margin-top: 12px;
}

.contact {
  display: block;
  margin-top: 26px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.92rem;
}

.contact p {
  margin-bottom: 8px;
}

.publication-page {
  display: block;
  width: min(880px, calc(100% - 44px));
}

.paper-detail {
  padding: 44px 0 68px;
  border-top: 1px solid var(--line);
}

.paper-detail .eyebrow {
  margin-bottom: 8px;
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 650;
}

.paper-detail h1 {
  max-width: 900px;
  margin-bottom: 18px;
  font-size: clamp(1.8rem, 4.2vw, 2.55rem);
  line-height: 1.08;
}

.paper-authors {
  color: var(--muted);
  font-size: 1.08rem;
}

.paper-authors strong {
  color: var(--ink);
}

.paper-abstract {
  margin-top: 38px;
  padding-top: 28px;
  border-top: 1px solid var(--line);
}

.paper-abstract h2 {
  margin-bottom: 14px;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: clamp(1.35rem, 2.4vw, 1.7rem);
  font-weight: 650;
  line-height: 1.2;
}

.paper-abstract p,
.paper-links {
  color: var(--muted);
  font-size: 1.02rem;
}

.paper-links {
  margin-top: 28px;
}

@media (max-width: 760px) {
  .site-shell {
    grid-template-columns: 1fr;
    gap: 24px;
    width: min(100% - 46px, 940px);
    padding-top: 26px;
  }

  .site-language-switch {
    top: 26px;
  }

  .profile-sidebar {
    padding-bottom: 14px;
    border-bottom: 1px solid var(--line);
  }

  .portrait-wrap {
    width: min(100%, 182px);
  }

  .links {
    font-size: 0.95rem;
  }

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

  .topbar-actions {
    width: 100%;
    align-items: flex-start;
    flex-direction: column;
    gap: 12px;
  }

  .nav-links {
    justify-content: flex-start;
  }

  .section + .section {
    margin-top: 14px;
  }

  .section h2 {
    font-size: 1.72rem;
  }

  .publication-item {
    grid-template-columns: 58px minmax(0, 1fr);
    gap: 14px;
    padding: 11px 0;
  }

  .paper-detail {
    padding-top: 32px;
  }

  .paper-detail h1 {
    font-size: clamp(1.9rem, 10vw, 2.7rem);
  }
}
