@font-face {
  font-family: Spectral;
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('assets/fonts/spectral-regular.ttf') format('truetype');
}
@font-face {
  font-family: Spectral;
  font-style: italic;
  font-weight: 400;
  font-display: swap;
  src: url('assets/fonts/spectral-italic.ttf') format('truetype');
}
@font-face {
  font-family: 'Source Han Serif';
  font-style: normal;
  font-weight: 200 900;
  font-display: swap;
  src: url('assets/fonts/source-han-serif-name.woff2') format('woff2');
}
:root {
  --paper: #f7f6f2;
  --ink: #292c28;
  --muted: #696c63;
  --line: #d9dbd1;
  --accent: #555f44;
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --paper: #000;
  --ink: #fff;
  --muted: #fff;
  --line: #333;
  --accent: #fff;
}
* { box-sizing: border-box; }
html { scroll-padding-top: 28px; }
body { margin: 0; background: var(--paper); color: var(--ink); font-family: Spectral, Georgia, serif; font-size: 18px; line-height: 1.6; -webkit-font-smoothing: antialiased; }
::selection { background: var(--line); }
a { color: inherit; text-decoration: none; }
a:hover { color: var(--accent); }
a:focus-visible, button:focus-visible { outline: 2px solid var(--accent); outline-offset: 5px; }
h1, h2, h3, p { margin: 0; }
h1, h2, h3 { font-weight: 400; }
p { text-wrap: pretty; }
.page { max-width: 948px; margin-inline: auto; padding-inline: 48px; }
.skip-link { position: absolute; left: 16px; top: -100px; padding: 10px; background: var(--paper); }
.skip-link:focus { top: 12px; z-index: 1; }
header { display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 22px 0; border-bottom: 1px solid var(--line); }
.wordmark { font-size: 20px; letter-spacing: -.5px; }
nav { display: flex; align-items: center; gap: 28px; font-size: 15px; }
nav a { padding-block: 10px; }
.theme-toggle { color: var(--ink); background: transparent; border: 1px solid var(--line); border-radius: 50%; padding: 0; cursor: pointer; width: 44px; height: 44px; flex-shrink: 0; }
.theme-toggle:not([hidden]) { display: grid; place-items: center; }
.theme-toggle svg { width: 20px; height: 20px; }
.theme-toggle .sun-icon, :root[data-theme="dark"] .theme-toggle .moon-icon { display: none; }
:root[data-theme="dark"] .theme-toggle .sun-icon { display: block; }
.theme-toggle:hover { border-color: var(--ink); }
nav a:hover { text-decoration: underline; text-underline-offset: 5px; }
.intro { display: grid; grid-template-columns: 210px minmax(0, 1fr); gap: 60px; align-items: center; padding: 62px 0 58px; }
.profile { display: grid; justify-items: center; gap: 16px; }
.contact-links { width: 100%; text-align: center; font-size: 14px; line-height: 1.6; }
.contact-links > a { display: block; padding-block: 4px; overflow-wrap: anywhere; }
.contact-links a { color: var(--accent); }
.contact-links a:hover { text-decoration: underline; text-underline-offset: 4px; }
.profile-links { display: flex; justify-content: center; flex-wrap: wrap; gap: 18px; margin-top: 3px; }
.profile-links a { padding-block: 5px; }
.portrait { display: block; width: 210px; height: 210px; object-fit: cover; object-position: left center; border-radius: 50%; justify-self: center; }
h1 { display: flex; align-items: baseline; flex-wrap: wrap; gap: 8px 20px; font-size: 39px; line-height: 1.3; letter-spacing: -1px; margin-bottom: 18px; }
.chinese-name { font-family: 'Source Han Serif', serif; font-size: 29px; font-weight: 400; letter-spacing: 2px; white-space: nowrap; }
.intro-copy p + p { margin-top: 12px; }
.welcome { font-size: 21px; }
.intro-copy a { color: var(--accent); text-decoration: underline; text-decoration-color: var(--line); text-underline-offset: 4px; }
.intro-copy a:hover { text-decoration-color: var(--accent); }
.intro-copy em { font-style: normal; color: var(--accent); }
h2 { font-size: 27px; line-height: 1.4; letter-spacing: -.6px; }
.education { display: grid; grid-template-columns: 210px minmax(0, 1fr); gap: 60px; border-top: 1px solid var(--line); padding: 30px 0 32px; }
.education-detail { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; }
.education-detail h3 { font-size: 22px; }
.education-detail p { color: var(--muted); font-size: 16px; }
.education-detail .year { white-space: nowrap; }
.publications { border-top: 1px solid var(--line); padding-top: 26px; }
.section-heading { display: flex; align-items: center; justify-content: space-between; gap: 24px; margin-bottom: 10px; }
.publication-year { color: var(--muted); font-size: 32px; line-height: 1; font-style: italic; }
.paper { display: grid; grid-template-columns: 210px minmax(0, 1fr); gap: 60px; align-items: center; padding: 28px 0 34px; }
.paper + .paper { border-top: 1px solid var(--line); }
.paper-image { display: block; border: 1px solid var(--line); border-radius: 5px; background: #fff; padding: 8px; box-shadow: 0 3px 10px #292c2809; }
.paper-image:hover { border-color: var(--muted); }
.paper-image img { display: block; width: 100%; height: auto; }
.paper-detail h3 { font-size: 23px; line-height: 1.4; letter-spacing: -.3px; }
.paper-detail h3 a:hover { text-decoration: underline; text-underline-offset: 4px; }
.venue { font-size: 18px; margin-top: 9px; }
.authors { color: var(--muted); font-size: 16px; line-height: 1.65; margin-top: 8px; }
.authors strong { color: var(--ink); font-weight: 400; text-decoration: underline; text-underline-offset: 3px; }
.paper-links { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 20px; margin-top: 10px; font-size: 15px; }
.paper-links a { color: var(--accent); padding: 5px 0; text-decoration: underline; text-underline-offset: 4px; text-decoration-color: var(--line); }
.paper-links a:hover { text-decoration-color: var(--accent); }
footer { display: flex; justify-content: space-between; border-top: 1px solid var(--line); padding: 20px 0 26px; color: var(--muted); font-size: 14px; }
@media (max-width: 900px) {
  .page { padding-inline: 32px; }
  .intro, .education, .paper { grid-template-columns: 210px minmax(0, 1fr); gap: 36px; }
  .portrait { width: 200px; height: 200px; }
  h1 { font-size: 34px; gap: 6px 16px; }
  .chinese-name { font-size: 26px; }
  .education-detail { flex-wrap: wrap; gap: 6px 16px; }
}
@media (max-width: 600px) {
  .page { padding-inline: 24px; }
  header { flex-wrap: wrap; gap: 8px 20px; padding-block: 16px 12px; }
  .wordmark { font-size: 19px; }
  nav { gap: 20px; font-size: 14px; }
  .intro { grid-template-columns: 1fr; gap: 28px; padding: 32px 0; }
  .portrait { width: 180px; height: 180px; }
  h1 { font-size: 32px; margin-bottom: 20px; }
  .chinese-name { font-size: 25px; }
  .intro-copy { font-size: 17px; }
  .welcome { font-size: 20px; }
  .education { grid-template-columns: 1fr; gap: 16px; padding-block: 24px; }
  h2 { font-size: 25px; }
  .education-detail h3 { font-size: 21px; }
  .education-detail p { font-size: 15px; }
  .publications { padding-top: 24px; }
  .publication-year { font-size: 26px; }
  .section-heading { gap: 14px; }
  .paper { grid-template-columns: 1fr; gap: 22px; padding: 24px 0 30px; }
  .paper-image { width: 100%; max-width: 360px; justify-self: center; }
  .paper-detail h3 { font-size: 22px; }
  .authors { font-size: 16px; }
}
