:root {
  --paper: #fafafa;
  --ink: #222222;
  --secondary: #666666;
  --link: #333333;
  --accent: #a46222;
  --rule: #e3e3e3;
  --wash: #f0f0f0;
  --body: Georgia, "Iowan Old Style", "Songti SC", "STSong", "SimSun", serif;
  --name: "Iowan Old Style", Georgia, "Songti SC", "STSong", "SimSun", serif;
  --ui: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  --utility: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --paper: #111111; --ink: #eeeeee; --secondary: #aaaaaa;
    --link: #dddddd; --accent: #e4b66b; --rule: #2c2c2c; --wash: #1e1e1e;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --paper: #111111; --ink: #eeeeee; --secondary: #aaaaaa;
  --link: #dddddd; --accent: #e4b66b; --rule: #2c2c2c; --wash: #1e1e1e;
  color-scheme: dark;
}
* { box-sizing: border-box; }
html { scroll-padding-top: 32px; }
body { margin: 0; color: var(--ink); background: var(--paper); font: 0.9375rem/1.75 var(--body); -webkit-font-smoothing: antialiased; }
p, h1, h2, h3, h4 { margin: 0; overflow-wrap: anywhere; }
button { font: inherit; }
.site-header, .site-footer, .resume-actions, .position, .other-name, .photo-caption, .choice-label, .view-link { font-family: var(--ui); }
a[href]:not([aria-disabled="true"]), button:enabled:not([aria-disabled="true"]) { cursor: pointer; }
button:disabled, [aria-disabled="true"] { cursor: default; }
a { color: var(--link); text-decoration-thickness: 1px; text-underline-offset: .22em; }
a, button { -webkit-tap-highlight-color: transparent; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; }
::selection { background: var(--wash); color: var(--ink); }
[hidden] { display: none !important; }
:root[data-enhanced] .thread-instrument[hidden] { display: block !important; visibility: hidden; }
:root[data-enhanced] .preferences[hidden] { display: flex !important; visibility: hidden; }
:root[data-enhanced] .email-compose[hidden] { display: grid !important; visibility: hidden; }
:root[data-enhanced] .language-fallback, :root[data-enhanced] .index-fallback { display: none; }
.site-header, .page, .site-footer { width: min(1080px, calc(100% - 96px)); margin-inline: auto; }
.site-header { display: flex; flex-wrap: wrap; align-items: center; gap: 36px; min-height: 106px; border-bottom: 1px solid var(--rule); }
.wordmark { color: var(--ink); font-weight: 600; text-decoration: none; display: inline-flex; align-items: center; gap: 12px; min-height: 44px; margin-right: auto; white-space: nowrap; }
.primary-nav { display: flex; gap: 28px; align-items: center; }
.primary-nav a { min-height: 44px; display: inline-flex; align-items: center; color: var(--secondary); text-decoration: none; font-size: 0.8125rem; }
.primary-nav a[aria-current="page"] { color: var(--ink); }
.primary-nav a[aria-current="page"] { text-decoration: underline; text-underline-offset: 8px; }
.preferences { display: flex; align-items: center; gap: 4px; }
.language-fallback { font-size: 0.8125rem; }
.page { padding-top: 68px; }
.home-hero, .home-section { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 80px; }
.home-hero { align-items: center; padding-bottom: 72px; }
.home-identity .portrait { width: 190px; height: 190px; object-fit: cover; border-radius: 8px; display: block; margin-bottom: 26px; }
h1 { font: 500 2.875rem/1.18 var(--name); letter-spacing: -.025em; }
.other-name { color: var(--secondary); font-size: 0.75rem; margin-top: 10px; }
.eyebrow { color: var(--secondary); font-size: 0.75rem; font-weight: 500; letter-spacing: .035em; }
.lead { font-size: 1.625rem; line-height: 1.6; letter-spacing: -.02em; margin-top: 18px; max-width: 660px; text-wrap: balance; white-space: pre-line; }
:lang(zh-Hans) .lead { font-size: 1.5625rem; line-height: 1.8; }
.bio-detail { color: var(--secondary); font-size: 1rem; line-height: 1.85; margin-top: 20px; max-width: 610px; }
.hero-actions { display: flex; align-items: center; gap: 28px; margin-top: 30px; }
.primary-action { display: inline-flex; justify-content: space-between; align-items: center; gap: 28px; padding: 11px 19px; min-height: 46px; border-radius: 5px; background: var(--ink); color: var(--paper); text-decoration: none; font-size: 0.8125rem; }
.contact-action { display: inline-flex; gap: 12px; align-items: center; min-height: 44px; font-size: 0.8125rem; }
.home-section { padding-block: 40px; border-top: 1px solid var(--rule); scroll-margin-top: 24px; }
.section-label h2 { font-size: 1rem; font-weight: 600; }
.section-label p { font-size: 0.75rem; color: var(--secondary); margin-top: 8px; max-width: 200px; }
.work-entry + .work-entry { margin-top: 28px; }
.work-entry h3 { font-size: 1.125rem; font-weight: 500; line-height: 1.5; }
.work-entry h3 a, .research-list a { color: var(--ink); text-decoration: none; }
.work-entry h3 span, .research-list h3 span { font-size: 0.8125rem; color: var(--secondary); white-space: nowrap; margin-left: 10px; }
.work-entry p { color: var(--secondary); font-size: 0.875rem; margin-top: 8px; max-width: 610px; }
.research-intro { font-size: 0.9375rem; margin-bottom: 24px; }
.research-list { list-style: none; margin: 0; padding: 0; }
.research-list li { display: grid; grid-template-columns: 44px minmax(0, 1fr); gap: 16px; }
.research-list li + li { margin-top: 22px; }
.research-list h3 { font-size: 0.9375rem; font-weight: 500; line-height: 1.6; }
.research-list p { font-size: 0.75rem; color: var(--secondary); margin-top: 3px; }
.text-action { font-size: 0.8125rem; display: inline-block; margin-top: 25px; }
.site-footer { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 24px; border-top: 1px solid var(--rule); margin-top: 28px; padding-block: 24px 38px; }
.motto { font: 1.125rem/1.5 "Songti SC", var(--name); letter-spacing: .15em; color: var(--secondary); }
.site-footer nav { display: flex; gap: 28px; flex-wrap: wrap; }
.site-footer a { font-size: 0.75rem; min-height: 44px; display: inline-flex; align-items: center; }
.resume-page { display: grid; grid-template-columns: 240px minmax(0, 1fr); column-gap: 80px; row-gap: 38px; }
.introduction { grid-column: 1 / -1; display: grid; grid-template-columns: 240px minmax(0,1fr); column-gap: 80px; padding-bottom: 38px; border-bottom: 1px solid var(--rule); }
.identity { display: flex; flex-wrap: wrap; flex-direction: column; gap: 24px; }
.identity .portrait { order: -1; width: 88px; height: 88px; object-fit: cover; border-radius: 6px; }
.identity h1 { font-size: 2.375rem; }
.position { color: var(--secondary); font-size: 0.8125rem; }
.identity .position { margin-top: 6px; }
.resume-bio > p { font-size: 0.9375rem; }
.resume-actions { display: flex; justify-content: space-between; align-items: center; gap: 20px; margin-top: 16px; }
.print-button { border: 0; background: none; color: var(--link); font-size: 0.75rem; padding: 8px 0; min-height: 44px; }
.print-contact { display: none; }
.section { grid-column: 1 / -1; position: relative; display: grid; grid-template-columns: 240px minmax(0,1fr); column-gap: 80px; }
.section > h2 { grid-column: 1; grid-row: 1 / 20; font-size: 1rem; font-weight: 600; }
.section > :not(h2):not(.anchor-alias) { grid-column: 2; }
.employment + .employment { margin-top: 28px; }
.employment-heading { display: flex; justify-content: space-between; align-items: baseline; gap: 20px; }
h3 { font-size: 1rem; font-weight: 600; }
h4 { font-size: 0.875rem; font-weight: 500; margin-top: 14px; }
.date { font: 0.6875rem/1.8 var(--utility); color: var(--secondary); white-space: nowrap; font-variant-numeric: tabular-nums; }
.employment .position { margin: 2px 0 9px; }
.employment > p:not(.position) { font-size: 0.875rem; }
.product ul { padding-left: 18px; margin: 6px 0 0; font-size: 0.875rem; }
.product li + li { margin-top: 4px; }
.additional { margin-top: 14px; color: var(--secondary); }
.additional + .additional { margin-top: 5px; }
.education article + article { margin-top: 20px; }
.education article > p { font-size: 0.875rem; color: var(--secondary); }
.publications { list-style: none; margin: 0; padding: 0; }
.publications li + li { margin-top: 24px; }
.paper-title { font-size: 0.875rem; line-height: 1.65; }
.authors, .venue { color: var(--secondary); font-size: 0.75rem; line-height: 1.7; }
.authors { margin-top: 5px; }
.patents article + article { margin-top: 16px; }
.patent-detail { font-size: 0.75rem; line-height: 1.6; color: var(--secondary); margin-top: 4px; }
.community p { font-size: 0.875rem; }
.anchor-alias { position: absolute; top: 0; }
.skip { position: absolute; top: -100px; left: 20px; background: var(--paper); padding: 10px 15px; z-index: 20; }
.skip:focus { top: 10px; }
@media (max-width: 900px) {
  .site-header, .page, .site-footer { width: calc(100% - 64px); }
  .site-header { gap: 20px; min-height: 90px; }
  .primary-nav { gap: 18px; }
  .home-hero, .home-section, .introduction, .section, .resume-page { grid-template-columns: 190px minmax(0,1fr); column-gap: 40px; }
  .home-identity .portrait { width: 164px; height: 164px; }
  .lead, :lang(zh-Hans) .lead { font-size: 1.375rem; }
  .page { padding-top: 48px; }
}
@media (max-width: 650px) {
  .site-header, .page, .site-footer { width: calc(100% - 40px); }
  .site-header { display: grid; grid-template-columns: minmax(0,1fr) auto; gap: 0 8px; padding-block: 14px 8px; min-height: 100px; }
  .wordmark { grid-column: 1; grid-row: 1; width: auto; gap: 8px; }
  .preferences, .language-fallback { grid-column: 2; grid-row: 1; margin-left: 0; }
  .primary-nav { grid-column: 1 / -1; grid-row: 2; width: 100%; gap: 26px; }
  .preference-trigger { padding-inline: 9px; }
  .home-hero, .home-section, .introduction, .section, .resume-page { display: block; }
  .page { padding-top: 36px; }
  .home-identity { display: grid; grid-template-columns: minmax(0,1fr) 92px; column-gap: 16px; align-items: center; }
  .home-identity .portrait { grid-column: 2; grid-row: 1 / 3; width: 92px; height: 92px; margin: 0; }
  .home-identity h1 { grid-column: 1; grid-row: 1; font-size: 2.375rem; align-self: end; }
  .home-identity .other-name { grid-column: 1; grid-row: 2; font-size: 0.625rem; margin-top: 8px; align-self: start; }
  .home-bio { margin-top: 28px; }
  .lead, :lang(zh-Hans) .lead { font-size: 1.375rem; margin-top: 12px; }
  .bio-detail { font-size: 0.875rem; margin-top: 16px; }
  .hero-actions { gap: 22px; margin-top: 24px; }
  .home-hero { padding-bottom: 36px; }
  .home-section { padding-block: 30px; }
  .section-label { margin-bottom: 24px; }
  .section-label p { max-width: none; margin-top: 3px; }
  .work-entry h3 { font-size: 1.0625rem; }
  .work-entry + .work-entry { margin-top: 25px; }
  .site-footer { align-items: flex-start; gap: 16px; padding-block: 20px; }
  .site-footer nav { gap: 0 18px; justify-content: flex-end; max-width: 250px; }
  .site-footer .motto { flex: none; padding-top: 8px; }
  .identity { flex-direction: row; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 26px; }
  .identity .portrait { order: 0; width: 80px; height: 80px; }
  .identity h1 { font-size: 2.125rem; }
  .identity .other-name { font-size: 0.625rem; }
  .introduction { padding-bottom: 24px; }
  .resume-bio > p { font-size: 0.875rem; }
  .section { margin-top: 30px; }
  .section > h2 { margin-bottom: 18px; }
  .employment-heading { flex-wrap: wrap; gap: 3px 12px; }
  .date { font-size: 0.625rem; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}
.site-header { border: 0; min-height: 88px; }
.wordmark { gap: 0; font-size: 0.875rem; letter-spacing: -.02em; }
.domain { color: var(--secondary); font-weight: 400; }
.index-page { max-width: 960px; padding-top: 32px; }
.index-page .home-hero { grid-template-columns: 248px minmax(0,1fr); gap: 88px; align-items: start; padding-bottom: 0; }
.index-identity h1 { margin-top: 26px; font-size: 2.625rem; }
.index-identity .other-name { margin-top: 8px; }
.photo-caption { font-size: 0.6875rem; color: var(--secondary); margin-top: 20px; }
.index-stage { min-height: 330px; }
.index-ready { position: relative; padding-bottom: 64px; }
.index-ready .index-stage { min-height: 266px; }
.index-ready .view-link { position: absolute; bottom: 0; left: 0; margin-top: 0; }
.site-footer a { gap: 8px; }
.index-view { outline-offset: 10px; }
.compact-bio { font-size: 1.25rem; line-height: 1.9; letter-spacing: -.014em; text-wrap: pretty; }
:lang(en) .compact-bio { font-size: 1.1875rem; line-height: 1.8; }
.view-caption { font-size: 0.75rem; color: var(--secondary); margin-bottom: 22px; max-width: 480px; text-wrap: pretty; }
.view-link { display: inline-flex; align-items: center; min-height: 44px; gap: 24px; font-size: 0.8125rem; text-decoration: none; margin-top: 24px; }
.index-work + .index-work { margin-top: 20px; }
.index-work h2, .index-papers h2 { font-size: 0.9375rem; line-height: 1.5; font-weight: 550; }
.index-work p { font-size: 0.8125rem; color: var(--secondary); margin-top: 6px; line-height: 1.75; text-wrap: pretty; }
.index-papers { list-style: none; padding: 0; margin: 0; }
.index-papers li { display: grid; grid-template-columns: 38px minmax(0,1fr); gap: 16px; }
.index-papers li + li { margin-top: 24px; }
.index-papers a { color: var(--ink); text-decoration: none; }
.index-papers p { font-size: 0.6875rem; color: var(--secondary); margin-top: 5px; }
.index-fallback { display: flex; gap: 24px; }
.legacy-links { display: flex; gap: 24px; padding-block: 24px; }
body[data-page="home"] .site-footer { border: 0; max-width: 960px; margin-top: 32px; }
@media (hover: hover) and (pointer: fine) {
  a:hover { text-decoration: underline; }
  .primary-nav a:hover { color: var(--ink); }
  .index-papers a:hover { color: var(--link); }
  .action-arrow { display: inline-block; transition: transform 160ms cubic-bezier(.23,1,.32,1); }
  a:hover > .action-arrow, button:hover > .action-arrow { transform: translateX(3px); }
}
@media (prefers-reduced-motion: reduce) {
  .action-arrow { transition: none; }
}
@media (max-width: 900px) {
  .index-page .home-hero { grid-template-columns: 190px minmax(0,1fr); gap: 48px; }
  .index-identity h1 { font-size: 2.25rem; }
  .compact-bio, :lang(en) .compact-bio { font-size: 1.0625rem; }
  .index-stage { min-height: 370px; }
  .index-ready .index-stage { min-height: 306px; }
}
@media (max-width: 650px) {
  .site-header { display: flex; min-height: 76px; padding-block: 12px; gap: 4px; }
  .wordmark { font-size: 0.75rem; }
  .index-page { padding-top: 24px; }
  .index-page .home-hero { display: block; }
  .index-identity { display: block; }
  .index-identity h1 { font-size: 2rem; margin: 0; align-self: end; }
  .index-identity .other-name { font-size: 0.6875rem; margin-top: 4px; }
  .photo-caption { margin-top: 10px; font-size: 0.625rem; }
  .index-content { margin-top: 34px; }
  .index-stage { min-height: 356px; }
  .index-ready .index-stage { min-height: 280px; }
  .compact-bio, :lang(en) .compact-bio { font-size: 1.125rem; line-height: 1.9; }
  body[data-page="home"] .site-footer { margin-top: 24px; }
  .resume-actions { gap: 10px; flex-wrap: wrap; }
  .resume-actions .primary-nav { width: auto; gap: 18px; }
}
.thread-page .index-identity h1 { margin-top: 38px; }
.thread-instrument { margin-bottom: 28px; }
.thread-track { position: relative; height: 80px; }
.thread-track svg { display: block; width: 100%; height: 80px; overflow: visible; touch-action: pan-y; }
.thread-line { stroke: var(--rule); stroke-width: 1.5; fill: none; vector-effect: non-scaling-stroke; pointer-events: none; }
.thread-track circle { fill: var(--secondary); pointer-events: none; }
.thread-instrument button.thread-knob { position: absolute; top: 40px; left: 50%; width: 48px; height: 48px; padding: 0; border: 0; background: none; border-radius: 50%; transform: translate(-50%,-50%); touch-action: none; cursor: grab; display: grid; place-items: center; }
.knob-dot { width: 15px; height: 15px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 6px var(--paper), 0 0 0 7px var(--rule); pointer-events: none; }
.thread-instrument.is-dragging button.thread-knob { cursor: grabbing; }
.is-dragging .knob-dot { transform: scale(1.15); background: var(--ink); }
.thread-choices { display: flex; justify-content: space-between; }
.thread-choices button { display: block; min-width: 64px; min-height: 64px; padding: 0 4px 8px; background: none; border: 0; color: var(--secondary); border-radius: 4px; }
.choice-glyph { display: block; font: 1.875rem/1.2 "Songti SC", var(--name); }
.choice-label { display: block; font-size: 0.6875rem; line-height: 1.5; margin-top: 6px; }
.thread-choices [aria-pressed="true"] { color: var(--ink); }
.thread-choices [aria-pressed="true"] .choice-label { text-decoration: underline; text-underline-offset: 5px; text-decoration-color: var(--accent); }
.thread-page .index-ready .index-stage { min-height: 200px; }
.thread-page .compact-bio { font-size: 1.0625rem; line-height: 1.9; }
body[data-page="home"] .site-footer nav { margin-left: auto; }
body[data-page="home"] .site-footer { margin-top: 16px; }
@media (hover: hover) and (pointer: fine) {
  .thread-choices button:hover { color: var(--ink); background: var(--wash); }
  .thread-knob:hover .knob-dot { box-shadow: 0 0 0 6px var(--paper), 0 0 0 8px var(--rule); }
}
@media (max-width: 900px) {
  .thread-page .index-ready .index-stage { min-height: 260px; }
}
@media (max-width: 650px) {
  .thread-page .index-identity h1 { margin-top: 0; }
  .thread-page .index-content { margin-top: 18px; }
  .thread-page .index-ready .index-stage { min-height: 240px; }
  .thread-page .compact-bio { font-size: 1rem; line-height: 1.9; }
  .thread-instrument { margin-bottom: 24px; }
}
@page { size: A4; margin: 12mm 15mm; }
/* Home uses available viewport space; the resume keeps its document layout. */
.icon { width: 19px; height: 19px; flex: none; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
.preferences { gap: 6px; }
.preferences button { min-width: 40px; height: 44px; border: 0; border-radius: 5px; background: none; color: var(--secondary); display: inline-flex; align-items: center; justify-content: center; padding: 0 8px; font-size: 0.75rem; }
.language-link { min-height: 44px; display: inline-flex; align-items: center; color: var(--secondary); font-size: 0.75rem; text-decoration: none; padding: 0 8px; }
#theme-toggle .icon-moon, #theme-toggle[data-dark="true"] .icon-sun { display: none; }
#theme-toggle[data-dark="true"] .icon-moon { display: block; }
.social-icons { display: flex; gap: 12px; }
.social-icons a, .social-icons button { display: grid; place-items: center; width: 44px; height: 44px; border: 0; padding: 0; background: transparent; border-radius: 6px; color: var(--secondary); }
.site-credit { font-size: 0.6875rem; white-space: nowrap; display: flex; align-items: center; gap: 16px; }
.site-credit a { font-size: 0.6875rem; }
.email-nojs { font-size: 0.6875rem; line-height: 1.5; }
.privacy-page { max-width: 680px; padding-bottom: 24px; }
.privacy-page h1 { font-size: 2.25rem; }
.privacy-date { color: var(--secondary); font: 0.75rem/1.6 var(--ui); margin-top: 12px; }
.privacy-page section { margin-top: 28px; }
.privacy-page h2 { font-size: 1.1875rem; font-weight: 500; margin-bottom: 8px; }
.privacy-page p { line-height: 1.8; }
.privacy-sources { font: 0.75rem/1.7 var(--ui); margin-top: 24px; }
.donate-page { max-width: 980px; padding-block: 72px 48px; }
.donate-intro { max-width: 580px; }
.donate-intro .eyebrow { letter-spacing: .08em; }
.donate-intro h1 { margin-top: 14px; font-size: 2.625rem; line-height: 1.25; }
.donate-intro > p:not(.eyebrow) { margin-top: 18px; max-width: 520px; color: var(--secondary); line-height: 1.85; }
.donate-paypal { display: inline-flex; gap: 28px; align-items: center; min-height: 48px; margin-top: 26px; padding: 0 2px 0 0; border-bottom: 1px solid var(--accent); color: var(--ink); text-decoration: none; font: 0.875rem/1.5 var(--ui); }
.donate-methods { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: clamp(32px,8vw,96px); margin-top: 60px; padding-top: 22px; border-top: 1px solid var(--rule); }
.donate-method { min-width: 0; margin: 0; }
.donate-method figcaption { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.donate-method h2 { font: 500 1.25rem/1.5 var(--body); }
.donate-method figcaption > span { color: var(--secondary); font: 0.75rem/1.5 var(--ui); }
.donate-qr { display: block; width: min(100%,310px); margin-top: 14px; background: #fff; line-height: 0; }
.donate-qr img { display: block; width: 100%; height: auto; }
.donate-phone-note { max-width: 660px; margin-top: 34px; color: var(--secondary); font: 0.8125rem/1.7 var(--ui); }
.donate-phone-note summary { width: fit-content; min-height: 44px; display: flex; align-items: center; color: var(--link); cursor: pointer; text-decoration: underline; text-underline-offset: .22em; }
.donate-phone-note p { max-width: 600px; margin-top: 6px; }
@media (hover:hover) and (pointer:fine) {
  .preferences button:hover, .social-icons a:hover, .social-icons button:hover { background: var(--wash); color: var(--ink); }
}
.preferences button:active, .social-icons a:active, .social-icons button:active { background: var(--rule); }
@media screen {
  body[data-page="home"]:has(.index-fallback:not([hidden])) { height: auto; min-height: 100dvh; }
  body[data-page="home"] { height: 100dvh; display: grid; grid-template-rows: 64px minmax(0,1fr) 64px; padding-top: env(safe-area-inset-top); padding-bottom: env(safe-area-inset-bottom); }
  body[data-page="home"] .site-header { min-height: 0; height: 100%; padding: 0; }
  body[data-page="home"] .page { padding-top: 0; min-height: 0; display: flex; align-items: center; }
  body[data-page="home"] .home-hero { width: 100%; max-height: 100%; min-height: 0; }
  body[data-page="home"] .index-content { margin: 0; min-height: 0; }
  body[data-page="home"] .index-ready { padding-bottom: 48px; }
  body[data-page="home"] .index-ready .index-stage { min-height: 0; }
  body[data-page="home"] .index-view { min-height: 190px; }
  body[data-page="home"] .index-identity h1 { margin-top: 26px; }
  body[data-page="home"] .thread-instrument { margin-bottom: 18px; }
  body[data-page="home"] .site-footer { width: min(960px,calc(100% - 96px)); height: 100%; margin: 0 auto; padding: 0; align-items: center; justify-content: space-between; }
  body[data-page="home"] .site-footer nav { max-width: none; gap: 8px; }
  body[data-page="home"] .view-caption { margin-bottom: 12px; }
  body[data-page="home"] .index-work + .index-work { margin-top: 12px; }
  body[data-page="home"] .index-papers li + li { margin-top: 14px; }
  @media (max-width:900px) {
    body[data-page="home"] .site-footer { width: calc(100% - 64px); }
    body[data-page="home"] .home-hero { grid-template-columns: 170px minmax(0,1fr); gap: 32px; }
  }
  @media (max-width:650px) {
    body[data-page="home"] .site-footer { flex-direction: column; align-items: stretch; justify-content: center; gap: 0; }
    body[data-page="home"] .site-credit { height: 28px; }
    body[data-page="home"] .site-credit a { min-height: 28px; }
    body[data-page="home"] .site-footer nav { margin-left: auto; }
    body[data-page="home"] { grid-template-rows: 56px minmax(0,1fr) 72px; }
    body[data-page="home"] .site-footer { width: calc(100% - 40px); }
    body[data-page="home"] .home-hero { display: grid; grid-template-rows: auto minmax(0,1fr); grid-template-columns: 1fr; gap: 16px; }
    body[data-page="home"] .index-identity h1 { margin: 0; font-size: 1.875rem; }
    body[data-page="home"] .photo-caption { margin-top: 4px; }
    body[data-page="home"] .other-name { margin-top: 4px; }
    body[data-page="home"] .thread-track, body[data-page="home"] .thread-track svg { height: 56px; }
    body[data-page="home"] .thread-knob { top: 28px; }
    body[data-page="home"] .thread-instrument { margin-bottom: 12px; }
    body[data-page="home"] .thread-choices button { min-height: 54px; }
    body[data-page="home"] .choice-glyph { font-size: 1.625rem; }
    body[data-page="home"] .compact-bio { font-size: 0.9375rem; line-height: 1.65; }
    body[data-page="home"] .index-view { min-height: 150px; }
  }
  @media (max-height:650px) {
    body[data-page="home"] .index-view { min-height: 108px; }
    body[data-page="home"] .index-work + .index-work, body[data-page="home"] .index-papers li + li { margin-top: 10px; }
    body[data-page="home"] .index-papers h2, body[data-page="home"] .index-work h2 { font-size: 0.8125rem; line-height: 1.4; }
    body[data-page="home"] .compact-bio { font-size: 0.875rem; line-height: 1.5; }
  }
  @media (max-height:440px) {
    body[data-page="home"] { grid-template-rows: 44px minmax(0,1fr) 72px; }
    body[data-page="home"] .home-hero { gap: 6px; }
    body[data-page="home"] .other-name, body[data-page="home"] .photo-caption { display: none; }
    body[data-page="home"] .index-identity h1 { font-size: 1.5rem; }
    body[data-page="home"] .thread-track, body[data-page="home"] .thread-track svg { height: 40px; }
    body[data-page="home"] .thread-knob { top: 20px; }
    body[data-page="home"] .thread-choices button { min-height: 44px; padding-bottom: 0; }
    body[data-page="home"] .choice-glyph { font-size: 1.125rem; }
    body[data-page="home"] .choice-label { margin-top: 2px; font-size: 0.625rem; }
    body[data-page="home"] .thread-instrument { margin-bottom: 6px; }
    body[data-page="home"] .index-view { min-height: 92px; }
    body[data-page="home"] .index-work + .index-work, body[data-page="home"] .index-papers li + li { margin-top: 4px; }
    body[data-page="home"] .index-papers h2 { font-size: 0.75rem; }
    body[data-page="home"] .compact-bio { font-size: 0.8125rem; line-height: 1.45; }
  }
}
@media screen and (max-width:650px) {
  .donate-page { padding-block: 46px 32px; }
  .donate-intro h1 { font-size: 2rem; }
  .donate-methods { grid-template-columns: minmax(0,1fr); gap: 30px; margin-top: 38px; }
  .donate-qr { width: min(100%,300px); }
}
@media screen {
  body[data-page="home"] .page { align-items: center; padding-block: clamp(8px,4dvh,36px) 8px; }
  body[data-page="home"] .home-hero { height: min(100%,560px); max-height: none; grid-template-rows: minmax(0,1fr); }
  body[data-page="home"] .index-content { height: 100%; display: grid; grid-template-rows: 168px minmax(0,1fr); padding-bottom: 48px; position: relative; }
  body[data-page="home"] .index-stage { position: relative; min-height: 0; padding-top: 12px; }
  body[data-page="home"] .index-view { min-height: 0; }
  body[data-page="home"] .index-ready .view-link { bottom: -48px; width: 200px; max-width: 100%; }
  body[data-page="home"] .index-identity h1 { font-size: 2rem; font-weight: 500; letter-spacing: -.025em; margin-top: 24px; }
  body[data-page="home"] .thread-instrument { margin: 0; }
  body[data-page="home"] .choice-glyph { font-family: var(--name); font-size: 1.4375rem; font-weight: 500; }
  body[data-page="home"] .choice-label { font-size: 0.6875rem; }
  body[data-page="home"] .thread-choices button { min-height: 56px; }
  body[data-page="home"] .compact-bio { font-size: 0.9375rem; line-height: 1.7; }
  body[data-page="home"] .research-group + .research-group { margin-top: 18px; }
  body[data-page="home"] .research-group-title { font-size: 0.9375rem; font-weight: 500; line-height: 1.5; margin-bottom: 6px; }
  .research-group-title a { color: var(--ink); text-decoration: none; display: inline-flex; align-items: baseline; gap: 12px; }
  .research-count { font: 0.6875rem/1.5 var(--ui); color: var(--secondary); }
  body[data-page="home"] .index-papers, .index-patents { list-style: none; margin: 0; padding: 0; font-size: 0.8125rem; line-height: 1.6; }
  body[data-page="home"] .index-papers li { display: block; }
  body[data-page="home"] .index-papers li + li, .index-patents li + li { margin-top: 4px; }
  .index-patents a { color: var(--ink); text-decoration: none; }
  .thread-line { stroke-width: 1; }
  .knob-dot { width: 12px; height: 12px; box-shadow: 0 0 0 5px var(--paper),0 0 0 6px var(--rule); }
  .site-header { border-bottom: 1px solid var(--rule); }
  @media (max-width:650px) {
    body[data-page="home"] .home-hero { height: min(100%,620px); grid-template-rows: 100px minmax(0,1fr); gap: 8px; }
    body[data-page="home"] .index-content { grid-template-rows: 132px minmax(0,1fr); }
    body[data-page="home"] .index-identity h1 { margin-top: 0; font-size: 1.6875rem; }
  }
  @media (max-height:650px) {
    body[data-page="home"] .page { padding-block: 6px; }
    body[data-page="home"] .index-content { grid-template-rows: 114px minmax(0,1fr); }
    body[data-page="home"] .home-hero { grid-template-rows: minmax(0,1fr); }
    body[data-page="home"] .research-group + .research-group { margin-top: 10px; }
    @media (max-width:650px) {
      body[data-page="home"] .home-hero { grid-template-rows: 76px minmax(0,1fr); }
    }
  }
  @media (max-height:440px) {
    body[data-page="home"] .home-hero { grid-template-rows: 28px minmax(0,1fr); gap: 0; }
    body[data-page="home"] .index-content { grid-template-rows: 84px minmax(0,1fr); }
    body[data-page="home"] .index-stage { padding-top: 0; }
    body[data-page="home"] .index-identity h1 { font-size: 1.375rem; margin: 0; }
    body[data-page="home"] .choice-glyph { font-size: 1.125rem; }
    body[data-page="home"] .thread-choices button { min-height: 44px; }
    body[data-page="home"] .compact-bio { font-size: 0.8125rem; line-height: 1.45; }
    body[data-page="home"] .research-group + .research-group { margin-top: 6px; }
  }
}
@media screen and (max-height:320px), screen and (max-width:280px) {
  body[data-page="home"] { height: auto; min-height: 100dvh; display: block; }
  body[data-page="home"] .site-header { height: auto; min-height: 44px; }
  body[data-page="home"] .page { display: block; }
  body[data-page="home"] .home-hero { height: auto; max-height: none; display: block; }
  body[data-page="home"] .index-content { height: auto; display: block; padding: 0; }
  body[data-page="home"] .thread-instrument { margin-top: 20px; }
  body[data-page="home"] .index-stage { padding-top: 20px; }
  body[data-page="home"] .index-ready .view-link { position: static; margin-top: 12px; }
  body[data-page="home"] .site-footer { height: auto; padding-block: 12px; }
}
@media screen {
  body[data-page="home"].home-reflow { height: auto; min-height: 100dvh; display: block; }
  body[data-page="home"].home-reflow .site-header { height: auto; min-height: 56px; }
  body[data-page="home"].home-reflow .page { display: block; padding-block: 24px; }
  body[data-page="home"].home-reflow .home-hero { height: auto; max-height: none; display: block; }
  body[data-page="home"].home-reflow .index-content { height: auto; display: block; padding: 0; }
  body[data-page="home"].home-reflow .thread-instrument { margin-top: 28px; }
  body[data-page="home"].home-reflow .index-stage { padding-top: 20px; }
  body[data-page="home"].home-reflow .index-identity { display: block; }
  body[data-page="home"].home-reflow .thread-choices button { height: auto; min-height: 76px; }
  body[data-page="home"].home-reflow .index-ready .view-link { position: static; margin-top: 16px; }
  body[data-page="home"].home-reflow .site-footer { height: auto; padding-block: 12px; }
  body[data-page="home"].home-reflow .site-credit { height: auto; }
  .site-credit { flex-wrap: wrap; white-space: normal; }
}
@media print {
  html:root, html:root:not([data-theme="light"]), html:root[data-theme] { --paper: #fff; --ink: #111; --secondary: #555; --link: #111; --rule: #ddd; --name: "Iowan Old Style", "Palatino Linotype", Palatino, "Songti SC", serif; color-scheme: light; background: #fff; }
  body { font-size: 8.5pt; line-height: 1.3; color: #111; background: #fff; }
  .page { display: block; width: 100%; padding: 0; margin: 0; }
  a { color: inherit; text-decoration: none; }
  .site-header, .site-footer, .preferences, .skip, .resume-actions { display: none; }
  .introduction { display: block; border: 0; padding: 0; margin-bottom: 8pt; }
  .identity { display: flex; flex-direction: row; justify-content: space-between; gap: 10pt; margin-bottom: 8pt; }
  .identity h1 { font-size: 23pt; }
  .identity .portrait { order: 0; width: 46pt; height: 46pt; }
  .identity .other-name { font-size: 7pt; margin-top: 3pt; }
  .identity .position { font-size: 8pt; }
  .resume-bio > p { font-size: 8pt; }
  .print-contact { display: block; font-size: 7pt !important; margin-top: 4pt; }
  .section { display: block; margin-top: 9pt; }
  .section > h2 { font-size: 11pt; margin-bottom: 5pt; }
  h3 { font-size: 9pt; }
  h4 { font-size: 8.5pt; margin-top: 7pt; }
  .employment .position, .date { font-size: 7pt; }
  .employment > p:not(.position), .product ul, .education article > p, .community p { font-size: 8pt; }
  .employment .position { margin: 2pt 0 4pt; }
  .product ul { margin-top: 4pt; }
  .product li + li { margin-top: 2pt; }
  .employment + .employment { margin-top: 8pt; }
  .additional { margin-top: 6pt; }
  .additional + .additional { margin-top: 3pt; }
  .education article + article { margin-top: 6pt; }
  .paper-title { font-size: 8pt; line-height: 1.4; }
  .authors, .venue { font-size: 7pt; line-height: 1.4; }
  .authors { margin-top: 2pt; }
  .publications li + li { margin-top: 7pt; }
  .patents h3 { font-size: 8pt; line-height: 1.3; }
  .patents article + article { margin-top: 4pt; }
  .patent-detail { font-size: 6.5pt; line-height: 1.3; margin-top: 2pt; }
  .employment-heading { flex-wrap: nowrap; }
  .employment, .publications li, .education article { break-inside: avoid; }
  h2, h3, h4 { break-after: avoid; }
  .home-hero, .home-section { display: block; padding-block: 10pt; }
  .home-identity .portrait { width: 60pt; height: 60pt; }
  .lead, :lang(zh-Hans) .lead { font-size: 14pt; }
  .hero-actions { display: none; }
}
