:root {
  color-scheme: light;
  font-family: Inter, "Noto Sans SC", "PingFang SC", "Microsoft YaHei", sans-serif;
  color: #25352b;
  background: #fafbf8;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; scrollbar-width: none; }
html::-webkit-scrollbar { display: none; }
body {
  margin: 0;
  min-height: 100vh;
  min-height: 100dvh;
  position: relative;
  isolation: isolate;
  overflow-x: clip;
}
.site-header {
  position: relative;
  z-index: 2;
  width: 100%;
  padding: clamp(12px, 2.4vh, 30px) clamp(16px, 3.4vw, 48px);
}
.identity { margin: 0; text-shadow: 0 1px 14px #fafbf8; }
.name-en {
  display: block;
  font-size: clamp(26px, 2.4vw, 36px);
  font-weight: 600;
  letter-spacing: -.7px;
  line-height: 1.15;
}
.name-zh {
  display: block;
  margin-top: 7px;
  font-size: clamp(16px, 1.4vw, 20px);
  font-weight: 400;
  letter-spacing: .12em;
  line-height: 1.5;
}
main { position: relative; isolation: isolate; }
.scene-background { display: none; }
.hero {
  position: relative;
  height: 100vh;
  height: 100dvh;
  isolation: isolate;
  overflow: hidden;
}
.second-page { min-height: 100vh; min-height: 100dvh; background: #fafbf8; }
.second-page:focus { outline: none; }
html.has-hero-scene { height: 100%; overflow: hidden; overscroll-behavior: none; }
.has-hero-scene body { height: 100vh; height: 100dvh; min-height: 0; overflow: hidden; overscroll-behavior: none; }
.has-hero-scene main { position: fixed; inset: 0; height: 100vh; height: 100dvh; overflow: clip; }
.has-hero-scene .scene-background { display: block; position: absolute; inset: 0; z-index: -1; opacity: var(--background-reveal, 0); pointer-events: none; }
.scene-background img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: center; }
.scene-background::after { content: ""; position: absolute; inset: 0; background: #fafbf8cc; }
.has-hero-scene .hero { position: absolute; inset: 0; height: 100%; overflow: visible; }
.has-hero-scene .portrait { position: absolute; pointer-events: none; }
.photo-depth { position: absolute; inset: 0; container-type: size; will-change: transform; }
.has-hero-scene .site-header { transform: translate3d(0, var(--hero-copy-y, 0px), 0); }
.has-hero-scene .second-page { position: absolute; inset: 0; min-height: 0; z-index: 1; background: transparent; pointer-events: none; }
.has-hero-scene .profile-shell { transform: translate3d(0, var(--profile-y, 100vh), 0); pointer-events: auto; will-change: transform; }
.living-ink-mask { -webkit-mask-image: none !important; mask-image: none !important; opacity: 0; pointer-events: none; }
.profile-shell {
  max-width: 960px;
  margin-inline: auto;
  padding: clamp(64px, 6.5vw, 96px) 32px 88px;
}
.profile-content { min-width: 0; }
.biography, .profile-section { scroll-margin-top: 56px; }
.biography p {
  margin: 0 0 22px;
  color: #566059;
  font-size: 16px;
  line-height: 1.9;
  text-wrap: pretty;
}
.biography .bio-lead { margin-bottom: 22px; }
.biography strong { color: #354c3d; font-weight: 600; }
.profile-reference { color: #354c3d; font-weight: 600; text-decoration-color: #a3b4a3; text-decoration-thickness: 1px; text-underline-offset: .2em; }
.profile-reference:hover, .profile-reference:focus-visible { color: #1f3828; text-decoration-color: currentColor; }
.link-favicon { display: inline-block; width: 1em; height: 1em; margin-right: .35em; object-fit: contain; vertical-align: -.12em; border-radius: 2px; }
.research-topic { color: #354c3d; box-shadow: inset 0 -.4em #e6ece1; }
.profile-sections { margin-top: 42px; }
.profile-section { border-top: 1px solid #25352b26; padding-block: 24px; }
.profile-section-empty { min-height: 90px; }
.profile-section h2 {
  margin: 0;
  color: #25352b;
  font-family: "TM Garamond", Georgia, serif;
  font-size: 32px;
  line-height: 1.25;
  font-weight: 700;
  letter-spacing: -.015em;
}
.publication { display: grid; grid-template-columns: minmax(0, 1fr) var(--publication-size, 180px); align-items: start; gap: 28px; margin-top: 24px; }
.research-experience-entry { display: grid; grid-template-columns: 80px minmax(0, 1fr); align-items: center; gap: 24px; margin-top: 24px; }
.experience-icon { display: grid; place-items: center; aspect-ratio: 1; border-radius: 8px; background: #e6ece1; color: #354c3d; font-family: "TM Garamond", Georgia, serif; font-size: 50px; line-height: 1; }
.experience-icon-brand { background: #fff; }
.experience-brand-logo { display: block; width: 80%; height: auto; }
.experience-details { min-width: 0; }
.research-experience-entry h3 { margin: 0 0 3px; font-size: 19px; font-weight: 600; line-height: 1.4; }
.research-experience-entry h3 a { color: #354c3d; text-decoration: none; }
.research-experience-entry h3 a:hover, .research-experience-entry h3 a:focus-visible { text-decoration: underline; text-decoration-color: #a3b4a3; text-underline-offset: .2em; }
.experience-institution { margin: 0 0 3px; color: #78847b; font-size: 14px; line-height: 1.5; }
.experience-meta { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 6px 16px; }
.experience-role { margin: 0; color: #566059; font-size: 14px; line-height: 1.5; }
.experience-date { margin-left: auto; white-space: nowrap; color: #78847b; font-size: 13.5px; font-variant-numeric: tabular-nums; }
.publication-preview { position: relative; display: block; aspect-ratio: 1; overflow: hidden; border-radius: 8px; background: #e6ece1; }
/* Based on UI Layouts Realistic, with stronger depth: https://tools.ui-layouts.com/shadows */
.publication-preview {
  box-shadow: 0 2px 5px -1px rgba(0, 0, 0, .12),
              0 6px 12px -2px rgba(0, 0, 0, .18),
              0 14px 24px -5px rgba(0, 0, 0, .22);
}
.experience-icon-avatar { overflow: hidden; background: #f8f8f8; }
.experience-icon-avatar img { display: block; width: 100%; height: 100%; object-fit: contain; }
.publication-preview-image { background: #fff; }
.publication-preview-image img { display: block; flex: 0 0 auto; width: auto; max-width: none; height: 100%; aspect-ratio: 1504 / 728; }
.publication-filmstrip { position: absolute; top: 0; left: 0; display: flex; width: max-content; height: 100%; animation: publication-pan 32s linear infinite; }
.publication-preview video { display: block; flex: 0 0 auto; width: auto; max-width: none; height: 100%; aspect-ratio: 1828 / 390; }
.publication-video-label { position: absolute; left: 8px; padding: 2px 6px; border-radius: 3px; background: #15251dd9; color: #fff; font-size: 10px; font-weight: 500; line-height: 1.5; pointer-events: none; }
.publication-video-label-human { top: 8px; }
.publication-video-label-robot { top: calc(50% + 8px); }
.publication-preview:hover .publication-filmstrip, .publication-preview:focus-visible .publication-filmstrip { animation-play-state: paused; }
.publication-preview:focus-visible { outline: 2px solid #354c3d; outline-offset: 4px; }
.publication-details { min-width: 0; grid-column: 1; grid-row: 1; }
.publication > .publication-preview { grid-column: 2; grid-row: 1; }
.publication h3 { margin: 0 0 10px; font-size: 19px; font-weight: 600; line-height: 1.5; text-wrap: pretty; }
@keyframes publication-pan {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}
.publication h3 a { color: #354c3d; text-decoration: none; }
.publication h3 a:hover, .publication h3 a:focus-visible { text-decoration: underline; text-decoration-color: #a3b4a3; text-underline-offset: .2em; }
.publication-authors, .publication-summary { margin: 0 0 10px; color: #566059; font-size: 14px; line-height: 1.8; }
.publication-authors strong { color: #354c3d; font-weight: 600; }
.publication-meta { display: flex; justify-content: space-between; align-items: baseline; gap: 20px; margin-top: 16px; font-size: 13px; }
.publication-links { display: flex; flex-wrap: wrap; gap: 8px 16px; }
.publication-links a { white-space: nowrap; }
.publication-meta time { color: #78847b; font-variant-numeric: tabular-nums; }
.honors-list { display: grid; gap: 0; margin: 20px 0 0; padding: 0; list-style: none; }
.honors-list li { position: relative; display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: baseline; column-gap: 20px; padding: 10px 0 10px 20px; color: #566059; font-size: 15px; line-height: 1.6; }
.honors-list li::before { content: ""; position: absolute; left: 1px; top: 20px; width: 4px; height: 4px; border-radius: 50%; background: #81947c; }
.honor-title { min-width: 0; }
.honor-date { justify-self: end; white-space: nowrap; color: #78847b; font-size: .9em; font-variant-numeric: tabular-nums; }
@media (max-width: 760px) {
  .profile-shell { padding: 48px 24px 64px; }
  .biography p { font-size: 15px; line-height: 1.85; }
  .profile-sections { margin-top: 34px; }
  .profile-section h2 { font-size: 30px; }
  .profile-section-empty { min-height: 84px; }
  .publication { display: flow-root; }
  .publication > .publication-preview { float: right; width: 160px; margin: 0 0 12px 22px; }
  .publication-meta { clear: both; }
  .research-experience-entry { gap: 20px; }
  .publication h3 { font-size: 17px; }
  .honors-list li { font-size: 14px; }
}
@media (max-width: 600px) {
  .hero .social-links {
    top: auto;
    bottom: max(106px, calc(env(safe-area-inset-bottom, 0px) + 100px));
    left: 50%;
    transform: translateX(-50%);
    width: calc(100% - 32px);
    max-width: none;
    align-items: center;
    --link-gap: 8px;
    font-size: 13px;
  }
  .hero .social-row { justify-content: center; }
  .hero .social-arrow { display: none; }
}
@media (max-width: 520px) {
  .publication > .publication-preview { width: 104px; margin-left: 16px; }
  .research-experience-entry { grid-template-columns: 64px minmax(0, 1fr); align-items: start; gap: 16px; }
  .experience-icon { font-size: 40px; }
  .research-experience-entry h3 { font-size: 17px; }
  .publication h3 { font-size: 16px; }
  .publication-authors, .publication-summary { font-size: 13px; line-height: 1.7; }
}
.scroll-cue {
  position: absolute;
  z-index: 3;
  left: 50%;
  bottom: max(42px, calc(env(safe-area-inset-bottom, 0px) + 36px));
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border: 1px solid #ffffffb3;
  border-radius: 50%;
  background: #fafbf8dc;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: 0 4px 20px #25352b14, inset 0 0 0 1px #25352b0a;
  color: #25352b;
  transform: translateX(-50%);
  text-decoration: none;
  transition: background .25s, box-shadow .25s;
}
.scroll-cue svg { animation: scroll-float 2.8s ease-in-out infinite; }
.scroll-cue:hover { background: #fff; box-shadow: 0 6px 24px #25352b26; }
.scroll-cue:hover svg { animation-play-state: paused; }
.scroll-cue:focus-visible { outline: 2px solid #25352b; outline-offset: 5px; }
@keyframes scroll-float {
  0%, 100% { transform: translateY(-3px); }
  50% { transform: translateY(3px); }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .publication-filmstrip { animation: none; }
  .scroll-cue { transition: none; }
  .scroll-cue svg { animation: none; }
}
.portrait {
  position: absolute;
  inset: 0;
  margin: 0;
  overflow: hidden;
  container-type: size;
}
.splash-photo {
  --photo-width: 2528;
  --photo-height: 1673;
  --crop-width: 2373;
  --crop-height: 1545;
  --crop-center-x: 1250.5;
  --crop-right: 2437;
  --crop-bottom-padding: 64;
  --portrait-focus-x: calc(var(--photo-width) * .7);
  position: absolute;
  display: block;
  left: 50%;
  bottom: min(
    calc(-100cqw * var(--crop-bottom-padding) / var(--crop-width)),
    calc(-100cqh * var(--crop-bottom-padding) / var(--crop-height))
  );
  width: max(
    calc(100cqw * var(--photo-width) / var(--crop-width)),
    calc(100cqh * var(--photo-width) / var(--crop-height))
  );
  height: auto;
  aspect-ratio: 2528 / 1673;
  transform: translateX(calc(-100% * var(--crop-center-x) / var(--photo-width)));
  -webkit-mask-image: url("assets/contour-splash-mask.svg");
  mask-image: url("assets/contour-splash-mask.svg");
  -webkit-mask-size: 100% 100%;
  mask-size: 100% 100%;
  -webkit-mask-repeat: no-repeat;
  mask-repeat: no-repeat;
  mask-mode: alpha;
}
@media (max-height: 520px) {
  .site-header { padding-top: 10px; padding-bottom: 10px; }
}

@media (max-aspect-ratio: 1/1) {
  .splash-photo {
    left: max(
      50%,
      calc(100cqw - 100cqh * (var(--crop-right) - var(--portrait-focus-x)) / var(--crop-height))
    );
    transform: translateX(calc(-100% * var(--portrait-focus-x) / var(--photo-width)));
  }
}
