:root {
  color-scheme: light;
  --background: #fff;
  --text: #303030;
  --heading: #222;
  --muted: #747474;
  --link: #994449;
  --line: #e9e7e5;
  --tile: #f6f4f2;
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --background: #191a1c;
  --text: #dededb;
  --heading: #f4f2ed;
  --muted: #a5a6a4;
  --link: #e49c9f;
  --line: #343537;
  --tile: #252629;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--background);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
  font-size: 15px;
  line-height: 1.8;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--link); text-decoration: none; text-underline-offset: .2em; }
a:hover { text-decoration: underline; }
a:focus-visible, button:focus-visible { outline: 2px solid var(--link); outline-offset: 5px; border-radius: 2px; }
[hidden] { display: none !important; }
strong { font-weight: 600; }
p { margin: 0 0 12px; }
h1, h2, h3 { color: var(--heading); font-weight: 400; }
h1, h2, .paper-copy h3 { font-family: Georgia, "Times New Roman", serif; }
h1 { margin: 0; font-size: 38px; line-height: 1.25; letter-spacing: -.5px; }
h2 { margin: 0 0 18px; font-size: 23px; line-height: 1.35; }
h3 { margin: 0; font-size: 15px; line-height: 1.5; }
.page { max-width: 1023px; margin: 0 auto; padding: 48px 28px 26px; }
.profile { display: flex; align-items: center; gap: 42px; margin-bottom: 44px; }
.profile-copy { min-width: 0; flex: 1; }
.portrait { display: block; width: 180px; height: 180px; object-fit: cover; border-radius: 6px; flex: 0 0 auto; }
.name-line { display: flex; flex-wrap: wrap; align-items: center; gap: 14px; margin-bottom: 14px; }
.affiliation { color: var(--muted); line-height: 1.7; margin-bottom: 4px; }
.email { font-size: 14px; color: var(--muted); }
.social-links { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 18px; margin-top: 14px; font-size: 14px; line-height: 20px; }
.social-links a { display: inline-flex; align-items: center; gap: 6px; min-height: 20px; white-space: nowrap; }
.social-label { display: block; line-height: 20px; }
.social-logo { display: block; width: 16px; height: 16px; object-fit: contain; flex: 0 0 16px; }
:root[data-theme="dark"] .social-logo.github-logo { filter: invert(1); }
.theme-toggle { border: 0; padding: 7px; background: transparent; color: var(--heading); cursor: pointer; line-height: 0; flex: 0 0 auto; }
.theme-toggle svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.moon-icon { display: none; }
:root[data-theme="dark"] .sun-icon { display: none; }
:root[data-theme="dark"] .moon-icon { display: inline; }
section { margin-bottom: 44px; scroll-margin-top: 24px; }
#about p { line-height: 1.9; }
.publications { display: grid; gap: 29px; }
.publication { display: grid; grid-template-columns: 281px minmax(0, 1fr); gap: 28px; align-items: center; }
.paper-figure, .paper-wordmark { position: relative; width: 100%; aspect-ratio: 16 / 9; min-width: 0; border-radius: 3px; }
.paper-figure { display: flex; align-items: center; justify-content: center; background: #fff; }
.paper-figure img, .paper-figure video, .paper-wordmark img, .paper-wordmark video { position: absolute; inset: 0; display: block; width: 100%; height: 100%; object-fit: contain; border-radius: inherit; }
.paper-media { overflow: hidden; box-shadow: inset 0 0 0 1px var(--line); }
.media-open { position: absolute; inset: 0; width: 100%; border: 0; background: transparent; padding: 0; cursor: zoom-in; color: #444; }
.media-expand, .media-toggle { position: absolute; bottom: 6px; display: grid; place-items: center; width: 25px; height: 25px; background: rgb(255 255 255 / 92%); box-shadow: 0 1px 5px rgb(0 0 0 / 13%); border-radius: 4px; font: 18px/1 Arial, sans-serif; color: #444; }
.media-expand { right: 6px; }
.media-toggle { left: 6px; border: 0; cursor: pointer; font-size: 12px; padding: 0; }
.media-open:focus-visible { outline-offset: -3px; }
.media-toggle:focus-visible { outline-offset: 2px; }
.media-dialog { width: min(1080px, calc(100vw - 32px)); max-height: calc(100dvh - 32px); padding: 18px; border: 1px solid var(--line); border-radius: 8px; background: var(--background); color: var(--text); }
.media-dialog::backdrop { background: rgb(0 0 0 / 68%); }
.media-dialog-header { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 12px; }
.media-dialog-header h2 { margin: 0; font-size: 20px; }
.media-close { width: 32px; height: 32px; border: 0; background: var(--tile); color: var(--text); border-radius: 4px; font: 25px/1 Arial, sans-serif; cursor: pointer; }
.media-dialog-content img, .media-dialog-content video { display: block; width: 100%; max-height: calc(100dvh - 118px); object-fit: contain; background: #fff; }
body.media-is-open { overflow: hidden; }
.paper-copy h3 { font-size: 18px; line-height: 1.45; margin-bottom: 5px; }
.paper-copy h3 a { color: var(--heading); }
.authors { font-size: 13px; line-height: 1.65; color: var(--muted); margin-bottom: 3px; }
.authors strong { color: var(--text); }
.venue { font-size: 13px; font-style: italic; margin-bottom: 5px; }
.paper-status { color: var(--link); margin: 0; }
.paper-links { display: flex; flex-wrap: wrap; gap: 8px; font-size: 13px; line-height: 1.7; }
.paper-wordmark { display: flex; flex-direction: column; justify-content: center; align-items: center; background: var(--tile); }
.paper-wordmark span { font-family: Georgia, serif; font-size: 25px; color: var(--heading); }
.paper-wordmark small { margin-top: 4px; color: var(--muted); font-size: 10px; letter-spacing: .4px; }
.publication-note { color: var(--muted); font-size: 12px; line-height: 1.7; margin: 15px 0 0; }
sup { font-size: .75em; line-height: 0; }
.experience-list { margin-top: 26px; padding-left: 36px; }
.experience { position: relative; padding-bottom: 30px; }
.experience:last-child { padding-bottom: 0; }
.experience::before { content: ""; position: absolute; left: -36px; top: 6px; width: 10px; height: 10px; border-radius: 50%; background: var(--link); z-index: 1; }
.experience:not(:last-child)::after { content: ""; position: absolute; left: -32px; top: 11px; bottom: -11px; width: 2px; background: var(--line); }
.experience-body { display: grid; grid-template-columns: 116px minmax(0, 1fr); align-items: center; gap: 24px; margin-top: 9px; }
.experience-logo { display: flex; align-items: center; justify-content: center; width: 116px; height: 88px; overflow: hidden; background: #fff; border: 1px solid var(--line); border-radius: 5px; }
.experience-logo img { display: block; flex: 0 0 auto; max-width: 100%; max-height: 100%; object-fit: contain; }
.logo-firered img { width: 88px; height: 64px; }
.logo-midea img { width: 108px; height: 81px; }
.logo-westlake img { width: 56px; height: 56px; }
.experience-position { min-width: 0; }
.experience h3 { font-size: 16px; font-weight: 600; line-height: 1.6; }
.team { font-weight: 400; }
.experience .date { font-size: 13px; line-height: 1.6; color: var(--muted); margin: 0; white-space: nowrap; }
.experience .role { font-size: 14px; line-height: 1.8; color: var(--muted); margin: 5px 0 0; }
.experience .role a { white-space: nowrap; }
.role-divider { margin: 0 5px; }
footer { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 5px 20px; border-top: 1px solid var(--line); padding-top: 17px; color: var(--muted); font-size: 11px; }
footer a { color: var(--muted); }
.skip-link { position: fixed; top: 8px; left: 8px; padding: 6px 12px; background: var(--background); transform: translateY(-150%); z-index: 1; }
.skip-link:focus { transform: translateY(0); }
@media (max-width: 680px) {
  .page { padding: 30px 22px 22px; }
  .profile { gap: 23px; margin-bottom: 35px; }
  .portrait { width: 124px; height: 124px; }
  h1 { font-size: 30px; }
  .name-line { gap: 8px; margin-bottom: 8px; }
  .affiliation { font-size: 13px; }
  .email { font-size: 12px; overflow-wrap: anywhere; }
  .social-links { gap: 8px; margin-top: 9px; font-size: 12px; }
  .publication { grid-template-columns: minmax(0, 1fr); gap: 13px; }
  .paper-figure, .paper-wordmark { width: min(100%, 360px); }
  .paper-copy h3 { font-size: 17px; }
  .experience-list { padding-left: 30px; }
  .experience::before { left: -30px; }
  .experience:not(:last-child)::after { left: -26px; }
  .experience-body { grid-template-columns: 96px minmax(0, 1fr); gap: 17px; }
  .experience-logo { width: 96px; height: 76px; }
  .logo-firered img { width: 72px; height: 54px; }
  .logo-midea img { width: 96px; height: 72px; }
  .logo-westlake img { width: 48px; height: 48px; }
  .experience .date { font-size: 12px; }
  .experience h3 { font-size: 15px; }
  .experience .role { font-size: 13px; }
  section { margin-bottom: 36px; }
}
@media (max-width: 460px) {
  .profile { align-items: flex-start; gap: 18px; }
  .portrait { width: 92px; height: 92px; }
  h1 { font-size: 27px; }
  .name-line { gap: 2px; }
  .theme-toggle { padding: 5px; }
  .affiliation { line-height: 1.5; }
  .social-links { gap: 7px; }
  .publication { grid-template-columns: 1fr; gap: 13px; }
  .paper-figure, .paper-wordmark { width: 100%; }
  .publications { gap: 28px; }
  h2 { font-size: 22px; }
}
@media (max-width: 360px) {
  .profile { gap: 14px; }
  .portrait { width: 80px; height: 80px; }
  h1 { font-size: 24px; }
  .experience-body { grid-template-columns: 80px minmax(0, 1fr); gap: 13px; }
  .experience-logo { width: 80px; height: 68px; }
  .logo-firered img { width: 60px; height: 48px; }
  .logo-midea img { width: 80px; height: 60px; }
  .logo-westlake img { width: 44px; height: 44px; }
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
@media print {
  :root { --background: #fff; --text: #222; --heading: #111; --muted: #555; --link: #333; }
  .page { max-width: none; padding: 0; }
  .theme-toggle, .skip-link, footer { display: none !important; }
  .publication, .experience { break-inside: avoid; }
  section { margin-bottom: 24px; }
}
