:root {
  --background: #ffffff;
  --surface: #f5f6f7;
  --text: #20242a;
  --muted: #646b73;
  --rule: #d9dde1;
  --navy: #17324d;
  --link: #1f557f;
  color: var(--text);
  background: var(--background);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans", Arial, sans-serif;
  font-synthesis: none;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 88px; }
body { min-width: 320px; margin: 0; background: var(--background); }
a { color: var(--link); text-underline-offset: 3px; }
a:hover { color: var(--navy); }

.skip-link {
  position: fixed;
  z-index: 50;
  top: 8px;
  left: 8px;
  padding: 9px 12px;
  color: #fff;
  background: var(--navy);
  transform: translateY(-150%);
}
.skip-link:focus { transform: translateY(0); }

.site-header {
  position: sticky;
  z-index: 20;
  top: 0;
  border-bottom: 1px solid var(--rule);
  background: rgba(255, 255, 255, 0.97);
}
.header-inner {
  width: min(1180px, calc(100% - 48px));
  min-height: 70px;
  display: grid;
  grid-template-columns: 1fr auto auto;
  align-items: center;
  gap: 34px;
  margin: 0 auto;
}
.site-title {
  color: var(--navy);
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.25rem;
  font-weight: 700;
  text-decoration: none;
}
.primary-nav { display: flex; gap: 26px; }
.primary-nav a {
  color: var(--text);
  font-size: 0.82rem;
  font-weight: 600;
  text-decoration: none;
}
.primary-nav a:hover { color: var(--link); }
.language-switcher { display: flex; border-left: 1px solid var(--rule); padding-left: 20px; }
.language-button {
  border: 0;
  border-bottom: 2px solid transparent;
  padding: 8px 7px 6px;
  color: var(--muted);
  background: transparent;
  font: inherit;
  font-size: 0.68rem;
  font-weight: 700;
  cursor: pointer;
}
.language-button.active { border-bottom-color: var(--navy); color: var(--navy); }
.language-button:focus-visible, a:focus-visible { outline: 2px solid var(--link); outline-offset: 3px; }

.page-shell {
  width: min(1180px, calc(100% - 48px));
  display: grid;
  grid-template-columns: 250px minmax(0, 1fr);
  gap: clamp(60px, 9vw, 120px);
  margin: 0 auto;
  padding: 76px 0 110px;
}
.profile-sidebar { align-self: start; position: sticky; top: 112px; }
.portrait {
  width: 100%;
  max-width: 220px;
  aspect-ratio: 4 / 5;
  margin-bottom: 28px;
  overflow: hidden;
  background: var(--surface);
}
.portrait img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  object-position: 50% 42%;
}
.profile-sidebar h1 {
  margin: 0;
  color: var(--navy);
  font-family: Georgia, "Times New Roman", serif;
  font-size: 2rem;
  font-weight: 500;
  line-height: 1.12;
}
.position { margin: 13px 0 4px; font-weight: 650; }
.affiliation { margin: 0; color: var(--muted); font-size: 0.9rem; line-height: 1.55; }
.profile-details { margin: 34px 0; padding: 0; border-top: 1px solid var(--rule); }
.profile-details div { padding: 17px 0; border-bottom: 1px solid var(--rule); }
.profile-details dt {
  margin-bottom: 6px;
  color: var(--muted);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.profile-details dd { margin: 0; font-size: 0.86rem; line-height: 1.5; }
.section-nav { display: flex; align-items: flex-start; flex-direction: column; gap: 8px; }
.section-nav a { color: var(--muted); font-size: 0.78rem; text-decoration: none; }
.section-nav a:hover { color: var(--link); }

.main-column { min-width: 0; }
.lead-section { padding: 8px 0 92px; border-bottom: 1px solid var(--rule); }
.section-kicker {
  margin: 0 0 20px;
  color: var(--link);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.lead-section h2 {
  max-width: 790px;
  margin: 0;
  color: var(--navy);
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(2.45rem, 5.2vw, 4.5rem);
  font-weight: 400;
  letter-spacing: -0.025em;
  line-height: 1.08;
}
.lead {
  max-width: 760px;
  margin: 36px 0 0;
  color: #3f464d;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.18rem;
  line-height: 1.75;
}

.content-section { padding: 78px 0; border-bottom: 1px solid var(--rule); }
.section-heading {
  display: grid;
  grid-template-columns: 48px 1fr;
  align-items: start;
  gap: 20px;
  margin-bottom: 42px;
}
.section-heading p {
  margin: 6px 0 0;
  color: var(--muted);
  font-family: Georgia, "Times New Roman", serif;
  font-size: 0.8rem;
}
.section-heading h2 {
  margin: 0;
  color: var(--navy);
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(1.75rem, 3vw, 2.45rem);
  font-weight: 500;
  line-height: 1.2;
}
.cv-list { border-top: 1px solid var(--text); }
.cv-entry {
  display: grid;
  grid-template-columns: 175px 1fr;
  gap: 28px;
  padding: 24px 0;
  border-bottom: 1px solid var(--rule);
}
.cv-entry time { color: var(--muted); font-size: 0.78rem; font-variant-numeric: tabular-nums; }
.cv-entry h3, .cv-entry p { margin: 0; }
.cv-entry h3 { font-family: Georgia, "Times New Roman", serif; font-size: 1.18rem; font-weight: 600; }
.cv-entry p { margin-top: 7px; color: var(--muted); font-size: 0.9rem; line-height: 1.5; }

.interest-list {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0 44px;
  margin: 0;
  padding: 0;
  border-top: 1px solid var(--text);
  list-style: none;
}
.interest-list li { position: relative; padding: 18px 0 18px 22px; border-bottom: 1px solid var(--rule); line-height: 1.45; }
.interest-list li::before { content: ""; position: absolute; top: 25px; left: 0; width: 5px; height: 5px; border-radius: 50%; background: var(--navy); }

.publication-note { margin: -18px 0 30px 68px; color: var(--muted); font-size: 0.86rem; }
.bibliography { margin: 0 0 0 68px; padding: 0; counter-reset: publications; list-style: none; }
.bibliography li {
  position: relative;
  padding: 25px 0 27px;
  border-top: 1px solid var(--rule);
  counter-increment: publications;
}
.bibliography li:last-child { border-bottom: 1px solid var(--rule); }
.bibliography li::before {
  content: counter(publications) ".";
  position: absolute;
  right: calc(100% + 22px);
  top: 27px;
  color: var(--muted);
  font-family: Georgia, "Times New Roman", serif;
}
.bibliography p { margin: 0; font-family: Georgia, "Times New Roman", serif; font-size: 1rem; line-height: 1.7; }
.bibliography a { display: inline-block; margin-top: 11px; font-size: 0.78rem; }
.bibliography cite { font-style: italic; }

.course-list, .project-list { border-top: 1px solid var(--text); }
.course-list article {
  display: grid;
  grid-template-columns: 105px 1fr;
  gap: 28px;
  padding: 25px 0;
  border-bottom: 1px solid var(--rule);
}
.course-code { color: var(--link); font-size: 0.78rem; font-weight: 700; letter-spacing: 0.06em; }
.course-list p, .course-list h3 { margin: 0; }
.course-list h3 { font-family: Georgia, "Times New Roman", serif; font-size: 1.16rem; }
.course-list div p { margin-top: 8px; color: var(--muted); font-size: 0.9rem; line-height: 1.55; }
.project-list article {
  display: grid;
  grid-template-columns: minmax(230px, 0.8fr) 1fr;
  gap: 44px;
  padding: 25px 0;
  border-bottom: 1px solid var(--rule);
}
.project-list h3, .project-list p { margin: 0; }
.project-list h3 { font-family: Georgia, "Times New Roman", serif; font-size: 1.18rem; }
.project-list div p { margin-top: 7px; color: var(--muted); font-size: 0.78rem; }
.project-list div .project-subtitle { font-family: Georgia, "Times New Roman", serif; font-size: 0.88rem; }
.project-subtitle cite { font-style: italic; }
html[lang="zh-Hans"] .project-subtitle cite { font-style: normal; }
.project-list > article > p { color: #444b52; font-size: 0.92rem; line-height: 1.6; }

.site-footer {
  width: min(1180px, calc(100% - 48px));
  display: flex;
  justify-content: space-between;
  gap: 30px;
  margin: 0 auto;
  padding: 30px 0 42px;
  border-top: 1px solid var(--text);
  color: var(--muted);
  font-size: 0.76rem;
}
.site-footer div { display: flex; gap: 16px; }
.site-footer span:first-child { color: var(--navy); font-weight: 700; }
.site-footer p { margin: 0; }

@media (max-width: 900px) {
  .primary-nav { display: none; }
  .header-inner { grid-template-columns: 1fr auto; }
  .page-shell { grid-template-columns: 200px minmax(0, 1fr); gap: 55px; }
  .interest-list { grid-template-columns: 1fr; }
  .project-list article { grid-template-columns: 1fr; gap: 16px; }
}

@media (max-width: 680px) {
  html { scroll-padding-top: 72px; }
  .header-inner, .page-shell, .site-footer { width: min(100% - 36px, 1180px); }
  .header-inner { min-height: 62px; gap: 12px; }
  .site-title { font-size: 1rem; }
  .language-switcher { padding-left: 8px; }
  .language-button { padding-inline: 5px; }
  .page-shell { grid-template-columns: 1fr; gap: 62px; padding: 50px 0 80px; }
  .profile-sidebar { position: static; }
  .portrait { max-width: 180px; }
  .profile-details { display: grid; grid-template-columns: 1fr 1fr; }
  .profile-details div { padding-right: 18px; }
  .profile-details div:nth-child(3) { display: none; }
  .section-nav { display: none; }
  .lead-section { padding-bottom: 68px; }
  .lead-section h2 { font-size: clamp(2.35rem, 12vw, 3.3rem); }
  .content-section { padding: 62px 0; }
  .section-heading { grid-template-columns: 32px 1fr; gap: 12px; }
  .cv-entry, .course-list article { grid-template-columns: 1fr; gap: 10px; }
  .publication-note, .bibliography { margin-left: 44px; }
  .site-footer, .site-footer div { flex-direction: column; gap: 8px; }
}

@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
