:root {
  --bg: #f5f7f8;
  --surface: #ffffff;
  --surface-soft: #edf2f4;
  --text: #202b33;
  --muted: #687780;
  --muted-2: #89959c;
  --border: #dce3e6;
  --border-strong: #c8d2d7;
  --brand: #365f72;
  --brand-dark: #254856;
  --accent: #9b623d;
  --serif: Georgia, "Times New Roman", "Songti SC", serif;
  --sans: "Inter", "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --shadow-soft: 0 14px 40px rgba(27, 51, 62, 0.07);
  --header-height: 64px;
  color-scheme: light;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 15px;
  line-height: 1.5;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

body::before {
  position: fixed;
  inset: 0;
  z-index: -1;
  content: "";
  pointer-events: none;
  background: radial-gradient(circle at 12% 2%, rgba(80, 124, 143, 0.08), transparent 29rem);
}

a { color: var(--brand); text-decoration: none; transition: color 160ms ease; }
a:hover { color: var(--accent); }
a:focus-visible, button:focus-visible { outline: 3px solid rgba(54, 95, 114, 0.25); outline-offset: 3px; }
img { display: block; max-width: 100%; }
p, h1, h2, h3 { margin-top: 0; }

.skip-link {
  position: fixed;
  top: 8px;
  left: 8px;
  z-index: 100;
  padding: 8px 12px;
  border-radius: var(--radius-sm);
  background: var(--text);
  color: #fff;
  transform: translateY(-150%);
}
.skip-link:focus { transform: translateY(0); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; }
.icon-sprite { position: absolute; width: 0; height: 0; overflow: hidden; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  min-height: var(--header-height);
  border-bottom: 1px solid rgba(200, 210, 215, 0.78);
  background: rgba(245, 247, 248, 0.91);
  backdrop-filter: blur(14px);
}

.nav-shell {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: min(1220px, calc(100% - 48px));
  min-height: var(--header-height);
  margin: 0 auto;
}

.wordmark { color: var(--text); font-family: var(--serif); font-size: 22px; font-weight: 700; letter-spacing: -0.03em; }
.wordmark span { color: var(--accent); }
.site-nav { display: flex; align-items: center; gap: 30px; }
.site-nav a { position: relative; color: var(--muted); font-size: 13px; font-weight: 500; letter-spacing: 0.01em; }
.site-nav a::after { position: absolute; right: 0; bottom: -21px; left: 0; height: 2px; content: ""; background: var(--brand); transform: scaleX(0); transition: transform 160ms ease; }
.site-nav a:hover, .site-nav a.is-active { color: var(--text); }
.site-nav a.is-active::after { transform: scaleX(1); }
.menu-toggle { display: none; }

.page-shell {
  display: grid;
  grid-template-columns: 244px minmax(0, 1fr);
  gap: 64px;
  width: min(1220px, calc(100% - 48px));
  margin: 0 auto;
  padding: 52px 0 80px;
}

.profile { position: sticky; top: calc(var(--header-height) + 28px); align-self: start; }
.profile-photo {
  width: 100%;
  height: auto;
  aspect-ratio: 1 / 1;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  object-fit: cover;
  object-position: 36% 43%;
  box-shadow: var(--shadow-soft);
}
.profile-copy { padding: 22px 2px 18px; border-bottom: 1px solid var(--border); }
.profile-kicker { margin-bottom: 7px; color: var(--brand); font-size: 10px; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; }
.profile h1 { margin-bottom: 8px; font-family: var(--serif); font-size: 20px; line-height: 1.2; letter-spacing: -0.01em; }
.profile h1 span { display: block; margin-top: 5px; color: var(--muted); font-family: var(--sans); font-size: 12px; font-weight: 500; letter-spacing: 0.08em; }
.affiliation { margin-bottom: 0; color: var(--muted); font-size: 12px; line-height: 1.55; }
.profile-links { display: grid; gap: 12px; margin: 18px 0 0; padding: 0 2px; list-style: none; }
.profile-links li, .profile-links a { display: flex; align-items: center; gap: 9px; color: var(--muted); font-size: 12px; }
.profile-links a:hover { color: var(--brand-dark); }
.profile-links svg { flex: 0 0 auto; width: 16px; height: 16px; }

main { min-width: 0; }
.anchor-section { scroll-margin-top: calc(var(--header-height) + 28px); }
.hero { padding: 12px 0 0; }
.eyebrow { margin-bottom: 10px; color: var(--accent); font-size: 11px; font-weight: 700; letter-spacing: 0.15em; text-transform: uppercase; }
.hero h2 { max-width: 780px; margin-bottom: 18px; font-family: var(--serif); font-size: 30px; font-weight: 700; line-height: 1.25; letter-spacing: normal; }
.hero-lede { max-width: 880px; margin-bottom: 0; color: #34444d; font-family: var(--serif); font-size: 14px; line-height: 1.62; }
.hero-lede strong { font-weight: 700; }
.hero-lede a { border-bottom: 1px solid rgba(54, 95, 114, 0.3); }

.content-section { padding: 32px 0 0; }
.section-heading { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; }
.section-heading::after { flex: 1; height: 1px; content: ""; background: var(--border); }
.section-heading > span { color: var(--accent); font-family: var(--serif); font-size: 13px; font-weight: 700; }
.section-heading h2 { margin: 0; font-family: var(--serif); font-size: 16px; line-height: 1.5; letter-spacing: normal; }
.section-intro { max-width: 800px; margin-bottom: 8px; color: var(--muted); font-family: var(--serif); font-size: 13.8px; line-height: 1.56; }

.focus-list { display: grid; gap: 0; margin: 0; padding: 0; list-style: none; counter-reset: focus; }
.focus-list li { display: block; margin-bottom: 8px; padding: 0; counter-increment: focus; }
.focus-list li:last-child { margin-bottom: 0; }
.focus-list li > div { display: inline; }
.focus-list li::before { margin-right: 10px; content: "(" counter(focus, lower-roman) ")"; color: var(--brand); font-family: var(--serif); font-size: 13.5px; font-weight: 700; }
.focus-list h3 { display: inline; margin: 0; font-family: var(--serif); font-size: 13.8px; line-height: 1.56; }
.focus-list h3::after { content: ":"; }
.focus-list p { display: inline; margin: 0 0 0 4px; color: var(--muted); font-family: var(--serif); font-size: 13.8px; line-height: 1.56; }
.focus-list p strong { color: var(--text); font-weight: 700; }
.focus-list a { border-bottom: 1px solid rgba(54, 95, 114, 0.3); }

.experience-list { border-top: 0; }
.experience-row { display: grid; grid-template-columns: 174px minmax(0, 1fr); gap: 28px; padding: 23px 0; border-bottom: 1px solid var(--border); }
.experience-meta { display: flex; flex-direction: column; gap: 2px; }
.experience-meta time { color: var(--brand); font-size: 11px; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; }
.experience-meta span { color: var(--muted-2); font-size: 11px; }
.experience-row h3 { margin-bottom: 4px; font-family: var(--serif); font-size: 15px; line-height: 1.4; }
.experience-row p { margin-bottom: 0; color: var(--muted); font-family: var(--serif); font-size: 12.6px; line-height: 1.58; }

.project { padding: 25px 0; border-top: 1px solid var(--border); }
.section-heading + .project { padding-top: 12px; border-top: 0; }
.project:last-child { padding-bottom: 0; }
.project-meta { display: flex; flex-wrap: wrap; gap: 7px 18px; margin-bottom: 8px; color: var(--muted-2); font-size: 10px; font-weight: 700; letter-spacing: 0.07em; text-transform: uppercase; }
.project-copy h3 { margin-bottom: 8px; font-family: var(--serif); font-size: 16px; line-height: 1.35; letter-spacing: normal; }
.project-copy p { max-width: 860px; margin-bottom: 12px; color: var(--muted); font-family: var(--serif); font-size: 12.8px; line-height: 1.58; }
.project-tags, .project-links { display: flex; flex-wrap: wrap; gap: 7px; }
.project-tags span { padding: 4px 8px; border-radius: 999px; background: var(--surface-soft); color: var(--brand-dark); font-size: 10px; font-weight: 600; }
.project-links a { display: inline-flex; align-items: center; gap: 3px; padding: 5px 9px; border: 1px solid var(--border-strong); border-radius: 999px; background: rgba(255, 255, 255, 0.6); font-size: 11px; font-weight: 600; }
.project-links svg { width: 14px; height: 14px; }

.site-footer { display: flex; justify-content: space-between; gap: 32px; padding: 40px 0 0; border-top: 1px solid var(--border-strong); color: var(--muted-2); font-size: 10px; }
.site-footer p { margin: 0; }

@media (max-width: 1040px) {
  .site-nav { gap: 18px; }
  .page-shell { grid-template-columns: 216px minmax(0, 1fr); gap: 42px; }
}

@media (max-width: 820px) {
  :root { --header-height: 56px; }
  .nav-shell, .page-shell { width: min(100% - 32px, 720px); }
  .menu-toggle { display: grid; width: 38px; height: 38px; padding: 8px; border: 0; border-radius: var(--radius-sm); background: transparent; cursor: pointer; }
  .menu-toggle span:not(.sr-only) { display: block; align-self: center; height: 1.5px; background: var(--text); }
  .site-nav { position: absolute; top: calc(100% + 1px); right: 0; left: 0; display: grid; gap: 0; max-height: 0; overflow: hidden; background: rgba(245, 247, 248, 0.98); box-shadow: var(--shadow-soft); transition: max-height 180ms ease; }
  .site-nav.is-open { max-height: 320px; border-bottom: 1px solid var(--border); }
  .site-nav a { padding: 13px 24px; border-bottom: 1px solid rgba(220, 227, 230, 0.7); }
  .site-nav a::after { display: none; }
  .page-shell { grid-template-columns: 1fr; gap: 24px; padding-top: 28px; }
  .profile { position: static; display: grid; grid-template-columns: 132px minmax(0, 1fr); gap: 20px; align-items: center; }
  .profile-photo { grid-row: 1 / span 2; }
  .profile-copy { padding: 0 0 14px; }
  .profile-links { grid-column: 2; grid-template-columns: repeat(2, minmax(0, max-content)); margin-top: -8px; }
  .profile-location { display: none !important; }
  .hero { padding-top: 0; }
  .hero h2 { font-size: 28px; }
}

@media (max-width: 600px) {
  body { font-size: 14px; }
  .page-shell { gap: 24px; padding-bottom: 56px; }
  .profile { grid-template-columns: 96px minmax(0, 1fr); gap: 16px; }
  .profile h1 { font-size: 19.5px; }
  .profile h1 span { font-size: 11px; }
  .affiliation { font-size: 10px; }
  .profile-links { gap: 8px 14px; }
  .profile-links li, .profile-links a { font-size: 11px; }
  .hero { padding-bottom: 0; }
  .hero h2 { margin-bottom: 16px; font-size: 27px; line-height: 1.25; }
  .hero-lede { font-size: 14px; }
  .content-section { padding: 28px 0 0; }
  .section-heading { margin-bottom: 12px; }
  .section-heading h2 { font-size: 17px; }
  .focus-list li { grid-template-columns: 38px minmax(0, 1fr); }
  .experience-row { grid-template-columns: 1fr; gap: 8px; }
  .experience-meta { flex-direction: row; gap: 10px; align-items: baseline; }
  .project { padding: 24px 0; }
  .project-copy h3 { font-size: 16px; }
  .site-footer { flex-direction: column; gap: 10px; }
  .site-footer p { max-width: none; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: 0.01ms !important; }
}
