:root {
  --ink: #222222;
  --muted: #646464;
  --blue: #1659a7;
  --blue-dark: #0c3e79;
  --rule: #dedede;
  --soft: #f5f8fb;
  --white: #ffffff;
}

* { box-sizing: border-box; }

/* Homepage: compact, image-led academic layout. */
.home { font-family: "Lato", Verdana, Helvetica, sans-serif; font-size: 14px; line-height: 1.42; }
.home a { color: #1772d0; text-decoration: none; }
.home a:hover { color: #f09228; }
.home-page { width: min(800px, calc(100% - 28px)); margin: 0 auto; }
.home-intro { display: grid; grid-template-columns: 63fr 37fr; align-items: center; padding-top: 16px; }
.home-intro-copy, .home-portrait-wrap { padding: 2.5%; }
.home-intro h1 { margin: 15px 0 22px; text-align: center; font-size: 32px; font-weight: 400; line-height: 1.1; letter-spacing: 0; }
.section-links { display: flex; flex-wrap: wrap; justify-content: center; margin: -10px 0 20px; font-size: 15px; text-align: center; }
.section-links a { font-weight: 700; }
.section-links span { margin: 0 8px; color: #777; }
.home-intro p { margin: 14px 0; max-width: none; }
.research-hook { color: #333; }
.profile-links { display: flex; flex-wrap: wrap; justify-content: center; margin: 17px 0 7px; text-align: center; }
.profile-links span { margin: 0 5px; color: #555; }
.home-portrait-wrap { margin: 0; text-align: center; }
.home-portrait { display: block; width: 100%; aspect-ratio: 1; object-fit: cover; object-position: 72% 28%; border-radius: 50%; }
.home-portrait-wrap figcaption { margin-top: 5px; color: #777; font-size: 10px; }
.home-section { padding: 16px; border: 0; }
.home-section[id] { scroll-margin-top: 18px; }
.home-section h2 { margin: 0 0 14px; font-size: 22px; line-height: 1.25; font-weight: 400; }
.home-section p { max-width: none; }
.research > p { margin: 0 0 13px; }
.research .recruiting { margin-bottom: 0; }
.papers { padding-top: 14px; }
.papers h2 { margin-bottom: 8px; }
.paper-row { display: grid; grid-template-columns: 20% minmax(0, 80%); align-items: center; margin: 0; padding: 12px 0; border: 0; border-bottom: 1px solid #d8d8d8; }
.paper-row.featured { background: #ffffd0; }
.paper-visual { position: relative; z-index: 1; display: block; width: 160px; max-width: 100%; padding: 8px; cursor: zoom-in; }
.paper-visual img { display: block; width: 100%; aspect-ratio: 1; object-fit: contain; background: #fff; transition: transform 160ms ease-out, box-shadow 160ms ease-out; transform-origin: left center; }

@media (hover: hover) and (pointer: fine) {
  .paper-visual:hover,
  .paper-visual:focus-visible { z-index: 5; }
  .paper-visual:hover img,
  .paper-visual:focus-visible img {
    transform: scale(2.8);
    box-shadow: 0 5px 18px rgba(0, 0, 0, .24);
  }
}
.paper-copy { min-width: 0; padding: 8px; overflow-wrap: anywhere; }
.paper-copy p { margin: 2px 0; }
.paper-title { font-weight: 700; }
.paper-actions { margin: 3px 0 5px !important; }
.paper-row.text-only { display: block; min-height: 0; }
.paper-year { padding: 10px 16px; color: #777; text-align: center; font-size: 16px; }
.home-timeline { padding-top: 24px; }
.home-timeline h3 { margin: 15px 0 5px; font-size: 15px; font-weight: 700; }
.publication-subheading { margin: 18px 0 5px; font-size: 15px; }
.home-bibliography { list-style: none; margin: 4px 0 0; padding: 0; }
.home-bibliography li { display: grid; grid-template-columns: 72px minmax(0, 1fr); gap: 10px; padding: 8px 0; border-top: 1px solid #e5e5e5; }
.home-bibliography li > span { color: #777; font-variant-numeric: tabular-nums; }
.home-footer { padding: 26px 16px 48px; color: #777; font-size: 12px; text-align: center; }
.home-footer p { margin: 3px 0; max-width: none; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  color: var(--ink);
  background: var(--white);
  font: 16px/1.62 "Segoe UI", Arial, Helvetica, sans-serif;
}

a { color: var(--blue); text-underline-offset: 0.16em; }
a:hover { color: var(--blue-dark); }
a:focus-visible { outline: 3px solid #85b7ee; outline-offset: 3px; }

.skip-link { position: absolute; left: -9999px; top: 8px; }
.skip-link:focus { left: 8px; z-index: 10; padding: 8px 12px; background: white; }

.page { width: min(920px, calc(100% - 40px)); margin: 0 auto; }

.intro {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 210px;
  gap: 52px;
  align-items: start;
  padding: 72px 0 44px;
  border-bottom: 1px solid var(--rule);
}

h1 { margin: 0 0 8px; font-size: 40px; line-height: 1.15; letter-spacing: -0.025em; }
h2 { margin: 0 0 18px; font-size: 23px; line-height: 1.3; }
h3 { margin: 0 0 7px; font-size: 18px; line-height: 1.38; }
p { max-width: 72ch; }

.position { margin: 0 0 20px; color: var(--muted); }
.intro nav { display: flex; flex-wrap: wrap; gap: 5px 17px; margin-top: 22px; }
.portrait-wrap { margin: 0; }
.portrait { width: 210px; height: 210px; object-fit: cover; object-position: 50% 30%; border-radius: 4px; }
.portrait-wrap figcaption { margin-top: 5px; color: var(--muted); font-size: 11px; text-align: right; }

section, .opening { padding: 38px 0; border-bottom: 1px solid var(--rule); }
.opening { margin: 0; background: var(--soft); padding-left: 24px; padding-right: 24px; }
.opening p { margin-bottom: 9px; }
.section-heading { display: flex; align-items: baseline; justify-content: space-between; gap: 20px; }

.publication {
  display: grid;
  grid-template-columns: 145px minmax(0, 1fr);
  gap: 25px;
  padding: 25px 0;
  border-top: 1px solid var(--rule);
}
.publication:first-of-type { margin-top: 5px; }
.publication p { margin: 5px 0; }
.paper-thumb { display: block; height: 150px; overflow: hidden; border: 1px solid #cfcfcf; background: #eee; }
.paper-thumb img { width: 100%; height: 100%; object-fit: cover; object-position: top; transition: transform 120ms ease-out; }
.paper-thumb:hover img { transform: translateY(-2px); }
.authors, .venue { color: var(--muted); }
.venue { font-style: italic; }
.paper-links { word-spacing: 9px; }

.compact-publications { list-style: none; margin: 8px 0 0; padding: 0; }
.compact-publications li { display: grid; grid-template-columns: 56px 1fr; gap: 12px; padding: 13px 0; border-top: 1px solid var(--rule); }
.compact-publications span { color: var(--muted); }

footer { padding: 34px 0 60px; color: var(--muted); font-size: 14px; }
footer p { margin: 4px 0; }

.subpage-header { padding: 54px 0 26px; border-bottom: 1px solid var(--rule); }
.subpage-header nav { margin-bottom: 20px; }
.note { max-width: 760px; padding: 34px 0 70px; }
.note h2 { margin-top: 38px; }
.note blockquote { margin: 24px 0; padding: 4px 0 4px 20px; border-left: 3px solid var(--blue); color: #3b3b3b; font: 18px/1.65 Georgia, "Times New Roman", serif; }
.note .provenance { padding: 14px 16px; background: var(--soft); color: var(--muted); font-size: 14px; }
.bibliography { list-style: none; padding: 0; }
.bibliography li { padding: 18px 0; border-top: 1px solid var(--rule); }
.talk-list li { display: grid; grid-template-columns: 58px minmax(0, 1fr); gap: 8px; }
.talk-year { color: var(--muted); font-variant-numeric: tabular-nums; }
.course-list { list-style: none; padding: 0; }
.course-list li { display: grid; grid-template-columns: 105px minmax(0, 1fr); gap: 12px; }
.course-term, .section-note { color: var(--muted); }
.section-note { margin-top: -10px; }

@media (max-width: 680px) {
  .page { width: min(100% - 28px, 920px); }
  .intro { grid-template-columns: 1fr; gap: 24px; padding-top: 38px; }
  .portrait { grid-row: 1; width: 132px; height: 132px; }
  h1 { font-size: 34px; }
  .publication { grid-template-columns: 92px 1fr; gap: 16px; }
  .paper-thumb { height: 115px; }
  .section-heading { display: block; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .paper-thumb img { transition: none; }
  .paper-visual img { transition: none; }
}

@media (max-width: 600px) {
  .home-page { width: min(100% - 20px, 800px); }
  .home-intro { grid-template-columns: 1fr; padding-top: 22px; }
  .home-intro-copy { order: 2; padding: 3%; }
  .home-portrait-wrap { order: 1; width: 190px; margin: 0 auto; padding: 0; }
  .home-intro h1 { margin: 12px 0 18px; }
  .home-section { padding: 16px 8px; }
  .paper-row { grid-template-columns: 31% minmax(0, 69%); align-items: start; }
  .paper-visual { width: 100%; padding: 8px 8px 8px 0; }
  .paper-copy { padding: 7px 0 7px 8px; }
  .paper-row.text-only { grid-template-columns: 48px 1fr; }
  .paper-year { padding: 9px 4px 0 0; font-size: 13px; text-align: left; }
  .profile-links span { margin: 0 2px; }
  .home-bibliography li { grid-template-columns: 64px minmax(0, 1fr); gap: 7px; }
}
