/* ===== Design tokens ===== */
:root {
  --max-width: 720px;
  --ink: #1a1a1a;
  --ink-soft: #595959;
  --ink-faint: #8a8a8a;
  --line: #e7e7e4;
  --bg: #fbfbf9;
  --accent: #1a1a1a;
  --serif: "Newsreader", Georgia, "Times New Roman", serif;
  --sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

/* ===== Reset ===== */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img { max-width: 100%; display: block; }
a {
  color: var(--ink);
  text-decoration: none;
  border-bottom: 1px solid var(--line);
  transition: border-color .15s ease, color .15s ease;
}
a:hover { border-color: var(--ink); }

/* ===== Layout ===== */
.page {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 88px 28px 96px;
}

/* ===== Intro ===== */
.intro {
  display: flex;
  align-items: center;
  gap: 30px;
  margin-bottom: 52px;
}
.avatar {
  width: 128px;
  height: 128px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
  filter: grayscale(8%);
}
.name {
  font-family: var(--serif);
  font-weight: 500;
  font-size: 2.1rem;
  line-height: 1.1;
  letter-spacing: -0.01em;
  margin: 0 0 6px;
}
.tagline {
  font-size: 1.02rem;
  color: var(--ink);
  margin: 0 0 2px;
}
.affil {
  color: var(--ink-soft);
  font-size: 0.95rem;
  margin: 0 0 14px;
}
.links {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  padding: 0;
  margin: 0;
}
.links a {
  font-size: 0.9rem;
  color: var(--ink-soft);
  border-bottom: none;
  position: relative;
}
.links a::after {
  content: "";
  position: absolute;
  left: 0; bottom: -2px;
  width: 0; height: 1px;
  background: var(--ink);
  transition: width .2s ease;
}
.links a:hover { color: var(--ink); }
.links a:hover::after { width: 100%; }

/* ===== Sections ===== */
.section {
  padding-top: 36px;
  margin-top: 36px;
  border-top: 1px solid var(--line);
}
.section:first-of-type { border-top: none; margin-top: 0; padding-top: 0; }
.section p { margin: 0 0 16px; }
.section p:last-child { margin-bottom: 0; }
.section__title {
  font-family: var(--serif);
  font-weight: 500;
  font-size: 1.35rem;
  letter-spacing: -0.01em;
  margin: 0 0 22px;
}
.section__note {
  font-size: 0.85rem;
  color: var(--ink-faint);
  margin-top: -10px !important;
  margin-bottom: 22px !important;
}
.section__foot {
  font-size: 0.92rem;
  color: var(--ink-soft);
  margin-top: 16px;
}
.eq { color: var(--ink-faint); }

/* ===== About ===== */
#about p { color: #2a2a2a; }

/* ===== Publications ===== */
.pub-list { list-style: none; padding: 0; margin: 0; }
.pub {
  display: flex;
  gap: 22px;
  padding: 22px 0;
  border-top: 1px solid var(--line);
}
.pub:first-child { border-top: none; padding-top: 0; }
.pub--no-thumb .pub__body { padding-left: 0; }
.pub__thumb {
  flex-shrink: 0;
  width: 168px;
  border-bottom: none;
  border-radius: 6px;
  overflow: hidden;
  align-self: flex-start;
}
.pub__thumb img {
  width: 168px;
  height: 100px;
  object-fit: cover;
  border-radius: 6px;
  transition: transform .3s ease;
}
.pub__thumb:hover img { transform: scale(1.03); }
.pub__body { flex: 1; min-width: 0; }
.pub__title {
  font-weight: 500;
  font-size: 1rem;
  line-height: 1.4;
  margin: 0 0 4px !important;
}
.pub__authors {
  color: var(--ink-soft);
  font-size: 0.9rem;
  margin: 0 0 3px !important;
}
.pub__venue {
  font-size: 0.88rem;
  color: var(--ink-faint);
  margin: 0 0 8px !important;
}
.badge {
  display: inline-block;
  font-size: 0.72rem;
  letter-spacing: 0.02em;
  color: var(--ink-soft);
  background: #efeeea;
  border-radius: 4px;
  padding: 1px 7px;
  margin-left: 4px;
  vertical-align: middle;
}
.pub__links { display: flex; gap: 14px; margin: 0 !important; }
.pub__links a {
  font-size: 0.85rem;
  color: var(--ink-soft);
  border-bottom: none;
  padding: 1px 0;
}
.pub__links a::before { content: "→ "; color: var(--ink-faint); }
.pub__links a:hover { color: var(--ink); }

/* ===== Projects ===== */
.project-list { list-style: none; padding: 0; margin: 0; }
.project {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 20px;
  padding: 14px 0;
  border-top: 1px solid var(--line);
}
.project:first-child { border-top: none; padding-top: 0; }
.project__main { min-width: 0; }
.project__title {
  font-weight: 500;
  font-size: 0.98rem;
  line-height: 1.4;
  margin: 0 0 2px !important;
  color: var(--ink);
}
.project__org {
  font-size: 0.86rem;
  color: var(--ink-soft);
  margin: 0 !important;
}
.project__org .role {
  display: inline-block;
  font-size: 0.72rem;
  letter-spacing: 0.02em;
  color: var(--ink-soft);
  background: #efeeea;
  border-radius: 4px;
  padding: 1px 7px;
  margin-left: 6px;
  vertical-align: middle;
}
.project__year {
  flex-shrink: 0;
  font-size: 0.85rem;
  color: var(--ink-faint);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

/* ===== Timeline (honors / projects) ===== */
.timeline { list-style: none; padding: 0; margin: 0; }
.timeline li {
  display: flex;
  gap: 20px;
  padding: 9px 0;
  align-items: baseline;
}
.timeline .year {
  flex-shrink: 0;
  width: 72px;
  font-size: 0.85rem;
  color: var(--ink-faint);
  font-variant-numeric: tabular-nums;
}
.timeline .desc {
  font-size: 0.95rem;
  color: #2a2a2a;
}

/* ===== Footer ===== */
.footer {
  margin-top: 56px;
  padding-top: 24px;
  border-top: 1px solid var(--line);
  color: var(--ink-faint);
  font-size: 0.82rem;
}
.footer p { margin: 0; }

/* ===== Responsive ===== */
@media (max-width: 620px) {
  .page { padding: 52px 22px 64px; }
  .intro {
    flex-direction: column;
    align-items: flex-start;
    gap: 20px;
    margin-bottom: 40px;
  }
  .avatar { width: 96px; height: 96px; }
  .name { font-size: 1.8rem; }
  .pub { flex-direction: column; gap: 12px; }
  .pub__thumb, .pub__thumb img { width: 100%; }
  .pub__thumb img { height: 168px; }
  .timeline li { flex-direction: column; gap: 2px; }
  .timeline .year { width: auto; }
}
