:root {
  --bg: #ffffff;
  --surface: #f6f7f9;
  --text: #1d2228;
  --muted: #5b6570;
  --accent: #1f5fa8;
  --border: #e3e6ea;
  --maxw: 1080px;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #14171b;
    --surface: #1c2026;
    --text: #e6e9ed;
    --muted: #9aa4af;
    --accent: #7fb2ef;
    --border: #2c323a;
  }
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 16px/1.65 "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

/* Top bar */
.topbar { border-bottom: 1px solid var(--border); }
.topbar-inner {
  max-width: var(--maxw); margin: 0 auto; padding: 14px 20px;
  display: flex; justify-content: space-between; align-items: center; gap: 16px;
}
.brand { font-weight: 600; color: var(--text); }
.topbar nav a { margin-left: 20px; color: var(--muted); font-size: 15px; }
.topbar nav a[aria-current="page"] { color: var(--text); font-weight: 600; }

/* Layout */
.layout {
  max-width: var(--maxw); margin: 0 auto; padding: 36px 20px 64px;
  display: grid; grid-template-columns: 250px 1fr; gap: 48px;
}
.profile { position: sticky; top: 24px; align-self: start; text-align: center; }
.profile img {
  width: 170px; height: 170px; border-radius: 50%; object-fit: cover;
  border: 1px solid var(--border);
}
.profile h1 { font-size: 22px; margin: 14px 0 2px; }
.profile .role { color: var(--muted); font-size: 14.5px; margin: 0 0 14px; line-height: 1.45; }
.profile .links { list-style: none; padding: 0; margin: 0; font-size: 14.5px; }
.profile .links li { margin: 4px 0; }

main h2 {
  font-size: 20px; margin: 40px 0 16px; padding-bottom: 6px;
  border-bottom: 1px solid var(--border);
}
main h2:first-child { margin-top: 0; }
main p { margin: 0 0 14px; }

.callout {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 10px; padding: 16px 18px; margin: 18px 0;
}
.callout p { margin: 0 0 6px; }
.callout p:last-child { margin-bottom: 0; }
.small { font-size: 14.5px; color: var(--muted); }

/* Experience / research cards */
.item { display: grid; grid-template-columns: 56px 1fr; gap: 16px; margin-bottom: 22px; }
.item img { width: 56px; height: 56px; object-fit: contain; border-radius: 8px; background: #fff; padding: 4px; }
.item h3 { font-size: 16.5px; margin: 0 0 2px; }
.item .meta { color: var(--muted); font-size: 14.5px; margin: 0 0 6px; }
.item p { margin: 0; font-size: 15.5px; }

/* Acknowledgments reading column */
.prose p { margin-bottom: 16px; }

footer {
  border-top: 1px solid var(--border); color: var(--muted); font-size: 13.5px;
  text-align: center; padding: 20px;
}

@media (max-width: 760px) {
  .layout { grid-template-columns: 1fr; gap: 28px; padding: 24px 16px 48px; }
  .profile { position: static; }
  .profile img { width: 130px; height: 130px; }
  .topbar-inner { padding: 12px 16px; flex-wrap: wrap; }
  .topbar nav a { margin-left: 0; margin-right: 14px; }
}
main, .profile { min-width: 0; overflow-wrap: anywhere; }
