@font-face {
  font-family: "WoooLAB Project Cursive";
  src: url("assets/fonts/cascadia-cursive-semibold.01d3f8eb3253.woff2") format("woff2");
  font-style: italic;
  font-weight: 600;
  font-display: block;
  unicode-range: U+0020-007E;
}
:root {
  color-scheme: light dark;
  --paper: #f8f5f1;
  --panel: #f0eae3;
  --ink: #2b2724;
  --muted: #70665e;
  --soft: #8c8076;
  --line: #ded5cb;
  --hairline: #e9e1d8;
  --accent: #ad6b44;
  --accent-wash: #f0e2d7;
  --logo-filter: none;
  --header-logo-filter: brightness(1.18);
  --brand-intro-duration: 1s;
  --back-to-top-size: 44px;
  --back-to-top-desktop-top: calc(75svh - var(--back-to-top-size) / 2);
  --brand-glow: rgb(194 124 78 / .4);
  --brand-halo: rgb(194 124 78 / .22);
  --brand-aura-core: rgb(239 178 126 / .36);
  --brand-aura-mid: rgb(239 178 126 / .21);
  --brand-aura-edge: rgb(239 178 126 / .075);
  --shadow: 0 12px 40px #34231924;
  --cursor-dot: rgb(128 128 128 / .4);
  --cursor-surface: rgb(128 128 128 / .12);
  --cursor-media: rgb(128 128 128 / .06);
  --cjk: "WoooLAB PingFang SC";
  --serif: var(--cjk), "WoooLAB Serif", "WoooLAB Symbols", serif;
  --sans: var(--cjk), "WoooLAB Sans", "WoooLAB Symbols", sans-serif;
  --mono: var(--cjk), "WoooLAB Mono", "WoooLAB Symbols", monospace;
  --mixed-mono: var(--mono);
  --project-title: var(--cjk), "WoooLAB Project Cursive", "WoooLAB Mono", "WoooLAB Symbols", monospace;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --paper: #292522;
    --panel: #342d28;
    --ink: #f0e8e1;
    --muted: #bdb0a5;
    --soft: #a39588;
    --line: #4b3d33;
    --hairline: #3e342c;
    --accent: #e8b48e;
    --accent-wash: #3a2a21;
    --logo-filter: invert(1) brightness(.94);
    --header-logo-filter: invert(1) brightness(1.11);
    --brand-glow: rgb(244 221 203 / .35);
    --brand-halo: rgb(232 180 142 / .18);
    --brand-aura-core: rgb(255 218 183 / .3);
    --brand-aura-mid: rgb(225 176 141 / .18);
    --brand-aura-edge: rgb(190 136 99 / .065);
    --shadow: 0 12px 40px #0008;
    --cursor-dot: rgb(180 180 180 / .4);
    --cursor-surface: rgb(180 180 180 / .16);
    --cursor-media: rgb(180 180 180 / .06);
  }
}
:root[data-theme="light"] { color-scheme: light; }
:root[data-theme="dark"] {
  color-scheme: dark;
  --paper: #292522;
  --panel: #342d28;
  --ink: #f0e8e1;
  --muted: #bdb0a5;
  --soft: #a39588;
  --line: #4b3d33;
  --hairline: #3e342c;
  --accent: #e8b48e;
  --accent-wash: #3a2a21;
  --logo-filter: invert(1) brightness(.94);
  --header-logo-filter: invert(1) brightness(1.11);
  --brand-glow: rgb(244 221 203 / .35);
  --brand-halo: rgb(232 180 142 / .18);
  --brand-aura-core: rgb(255 218 183 / .3);
  --brand-aura-mid: rgb(225 176 141 / .18);
  --brand-aura-edge: rgb(190 136 99 / .065);
  --shadow: 0 12px 40px #0008;
  --cursor-dot: rgb(180 180 180 / .4);
  --cursor-surface: rgb(180 180 180 / .16);
  --cursor-media: rgb(180 180 180 / .06);
}
::view-transition { pointer-events: none; }
::view-transition-group(root), ::view-transition-old(root), ::view-transition-new(root) { animation-duration: .36s; animation-timing-function: cubic-bezier(.3,0,.2,1); }
.theme-changing body, .theme-changing :is(a, button, p, h1, h2, h3, span, dt, dd, time, li, header, footer, section, dialog, .project-entry, .experience-entry, .mini-cv) {
  transition: color .36s cubic-bezier(.3,0,.2,1), background-color .36s cubic-bezier(.3,0,.2,1), border-color .36s cubic-bezier(.3,0,.2,1), text-decoration-color .36s cubic-bezier(.3,0,.2,1);
}
.theme-changing .brand img { transition: filter .36s cubic-bezier(.3,0,.2,1); }
* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--banner-height, 77px) + 20px); scrollbar-gutter: stable; }
/* Keep the logo's decorative halo below all foreground content. */
body { margin: 0; isolation: isolate; color: var(--ink); background: var(--paper); font: 15px/1.8 var(--serif); -webkit-font-smoothing: antialiased; }
a { color: inherit; text-decoration: none; text-underline-offset: 4px; }
a, button { transition: color .15s ease, text-decoration-color .15s ease; }
:where(html:not(.has-adaptive-cursor)) a:hover, a[data-cursor-within] { color: var(--accent); }
:where(a, button, summary) { -webkit-tap-highlight-color: transparent; }
:where(a, button, summary):focus { outline: none; }
:where(html:not([data-input-mode="pointer"])) :is(a, button, summary):focus-visible { outline: 1px solid var(--accent); outline-offset: 5px; }
button, input { font: inherit; }
button { cursor: pointer; }
html.has-adaptive-cursor, html.has-adaptive-cursor * { cursor: none !important; }
.adaptive-cursor { position: fixed; z-index: 1000; left: 0; top: 0; width: 20px; height: 20px; border-radius: 50%; transform: translate3d(-100px, -100px, 0); pointer-events: none; visibility: visible; opacity: 0; transition: opacity .12s ease; }
.adaptive-cursor.is-visible { opacity: 1; }
.adaptive-cursor::before { content: ""; position: absolute; inset: 0; border: 0; border-radius: inherit; background: var(--cursor-dot); box-shadow: none; transform-origin: 50% 50%; transition: background .16s ease, transform .1s ease; }
.adaptive-cursor[data-mode="target"]::before { background: var(--cursor-surface); }
.adaptive-cursor[data-mode="media"]::before { background: var(--cursor-media); }
.adaptive-cursor.is-pressed::before { transform: scale(.95); }
@media (forced-colors: active), print {
  .adaptive-cursor { display: none !important; }
  html.has-adaptive-cursor, html.has-adaptive-cursor * { cursor: revert !important; }
}
img { display: block; max-width: 100%; height: auto; }
h1, h2, h3, p, figure, ul, dl, dd { margin: 0; }
::selection { background: var(--accent-wash); color: var(--ink); }
.shell { width: min(100% - 88px, 1180px); margin-inline: auto; }
.content-section { width: min(100% - 88px, 736px); margin: 48px auto 0; }
#main { position: relative; z-index: 0; }
.skip-link { position: fixed; top: -100px; left: 12px; z-index: 20; padding: 6px 18px; background: var(--ink); color: var(--paper); }
:where(html:not([data-input-mode="pointer"])) .skip-link:focus-visible { top: 10px; }
.site-banner { position: sticky; top: 0; z-index: 0; }
.site-banner[data-pinned] { z-index: 12; }
.site-banner::before {
  content: "";
  position: absolute;
  z-index: -1;
  inset: 0;
  pointer-events: none;
  opacity: 0;
  visibility: hidden;
  background: var(--paper);
  box-shadow: inset 0 -1px var(--line), 0 5px 18px rgb(16 12 8 / .09);
  transition: opacity .36s ease, visibility 0s .36s;
}
.site-banner[data-pinned]::before { opacity: 1; visibility: visible; transition-delay: 0s; }
@supports ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .site-banner::before {
    background: linear-gradient(to bottom, color-mix(in srgb, var(--paper) 77%, white 6%), color-mix(in srgb, var(--paper) 63%, transparent));
    -webkit-backdrop-filter: blur(18px) saturate(1.45);
    backdrop-filter: blur(18px) saturate(1.45);
    box-shadow: inset 0 1px rgb(255 255 255 / .07), inset 0 -1px color-mix(in srgb, var(--line) 65%, transparent), 0 5px 18px rgb(16 12 8 / .09);
  }
}
.site-header { display: flex; gap: 28px; align-items: center; padding: 24px 0 20px; border-bottom: 1px solid var(--line); }
.brand { display: inline-flex; flex-shrink: 0; }
.brand img { filter: var(--logo-filter); }
.site-header .brand { position: relative; --brand-aura-radii: 260px 250px; --brand-logo-shadows: drop-shadow(0 0 3px var(--brand-glow)) drop-shadow(0 0 12px var(--brand-halo)); }
.site-header .brand::before, .brand-aura-canvas { z-index: -1; pointer-events: none; width: 600px; height: 560px; }
.site-header .brand::before { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -38%); }
.site-header .brand::before { content: ""; opacity: 1; transform-origin: 50% 38%; animation: brand-aura-in var(--brand-intro-duration) cubic-bezier(.65, 0, .6, 1) both; }
.site-header .brand::before { background: radial-gradient(ellipse var(--brand-aura-radii) at 50% 38%, var(--brand-aura-core) 0%, var(--brand-aura-mid) 36%, var(--brand-aura-edge) 63%, transparent 100%); filter: blur(16px); }
.brand-aura-canvas { position: fixed; visibility: hidden; }
.site-header .brand[data-glow-renderer]::before { visibility: hidden; }
.brand-aura-canvas[data-ready] { visibility: visible; }
.site-header .brand[data-glow-renderer] { --brand-logo-shadows: ; }
.site-header .brand img { filter: var(--header-logo-filter) var(--brand-logo-shadows); animation: brand-glow-in var(--brand-intro-duration) cubic-bezier(.65, 0, .6, 1) both; }
.site-banner[data-pinned] .brand::before { opacity: 0; transform: var(--brand-aura-transform, translate(-50%, -38%)); animation: brand-aura-out .38s ease; }
.site-banner[data-pinned] .brand img { filter: var(--logo-filter); animation: brand-glow-out .38s ease; }
html[data-fonts-loading] .site-header .brand::before,
html[data-fonts-loading] .site-header .brand img { animation-play-state: paused; }
@keyframes brand-glow-in {
  from { filter: var(--logo-filter); }
  to { filter: var(--header-logo-filter) var(--brand-logo-shadows); }
}
@keyframes brand-aura-in {
  from { opacity: 0; transform: translate(-50%, -38%) scale(0); }
  to { opacity: 1; transform: translate(-50%, -38%) scale(1); }
}
@keyframes brand-glow-out { from { filter: var(--brand-glow-from, var(--logo-filter)); } }
@keyframes brand-aura-out { from { opacity: var(--brand-aura-opacity, 0); } }
@media (pointer: coarse) {
  .site-banner::before { z-index: 0; clip-path: inset(0); }
  .site-header { position: relative; z-index: 1; }
  .site-header .brand,
  .site-header .brand[data-glow-renderer] { --brand-logo-shadows: drop-shadow(0 0 3px var(--brand-glow)); }
  .site-header .brand img { clip-path: inset(-10px); }
}
.site-header nav { display: flex; gap: 27px; margin-left: auto; font-size: 13px; letter-spacing: .025em; }
:where(html:not(.has-adaptive-cursor)) .site-header nav a:hover, .site-header nav a[data-cursor-within] { text-decoration: underline; }
.header-controls { display: flex; align-items: center; gap: 12px; margin-left: 12px; }
.language-switch { display: flex; align-items: center; gap: 9px; font-size: 11px; color: var(--soft); }
.language-switch button { padding: 3px 0; border: none; background: transparent; color: var(--muted); }
.language-switch button[aria-pressed=true] { color: var(--ink); text-decoration: underline; text-underline-offset: 4px; }
.theme-toggle { position: relative; flex: 0 0 auto; width: 32px; height: 32px; padding: 0; border: 0; border-radius: 50%; color: var(--muted); background: transparent; }
.theme-toggle[hidden] { display: none; }
:where(html:not(.has-adaptive-cursor)) .theme-toggle:hover, .theme-toggle[data-cursor-within] { color: var(--accent); background: var(--accent-wash); }
.theme-icon { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); pointer-events: none; }
.theme-icon--sun, :root[data-theme="dark"] .theme-icon--moon { opacity: 0; }
:root[data-theme="dark"] .theme-icon--sun { opacity: 1; }
.profile { display: grid; grid-template-columns: 260px minmax(0, 1fr) 260px; column-gap: 38px; align-items: stretch; padding-top: 36px; }
.portfolio-sections { grid-column: 1 / -1; min-width: 0; margin-top: 22px; }
.portfolio-sections > .content-section { width: min(100%, 736px); }
.identity-column {
  --pcb-stage-width: min(244px, 100%);
  --pcb-cabinet-scale: .8;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  min-width: 0;
}
.identity-column > :is(.avatar, h1) { flex-shrink: 0; }
@media (pointer: coarse) {
  .identity-column, .identity-column * { -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; -webkit-tap-highlight-color: transparent; }
  .identity-column .social-link { -webkit-touch-callout: default; }
}
.avatar { width: 112px; height: 112px; object-fit: cover; border-radius: 7px; border: 1px solid var(--line); margin-bottom: 18px; }
h1 { font: 600 32px/1.12 var(--mono); letter-spacing: -.035em; }
#profile-name { font-family: var(--serif); }
.identity-column > .oled-playground { margin-top: 18px; }
/* Empty pseudo-elements keep the real font layout without showing fallback text. */
html[data-fonts-loading] :where(.site-header nav a, .language-switch, .theme-toggle, h1, h2, h3, .social-link, .affiliation-copy, .profile-description, .mini-cv > div, .profile-honors p, .social-stat, .refresh-count, .project-meta, .entry-description, .entry-links a, .entry-tags, .entry-heading > .entry-date, .minor-heading, .honor-list li, .affiliations p, .education-details summary, .school-list li, .section-footnote, .site-footer p, .site-footer > a:last-child, .error-page p, .error-page > a:last-child) { position: relative; }
html[data-fonts-loading] :where(.site-header nav a, .language-switch, .theme-toggle, h1, h2, h3, .social-link, .affiliation-copy, .profile-description, .mini-cv > div, .profile-honors p, .social-stat, .refresh-count, .project-meta, .entry-description, .entry-links a, .entry-tags, .entry-heading > .entry-date, .minor-heading, .honor-list li, .affiliations p, .education-details summary, .school-list li, .section-footnote, .site-footer p, .site-footer > a:last-child, .error-page p, .error-page > a:last-child)::after {
  content: ""; visibility: visible; position: absolute; pointer-events: none; left: 0; top: .3em;
  width: min(100%, var(--skeleton-width, 100%)); height: calc(100% - .6em); min-height: .5em; border-radius: 3px;
  background: repeating-linear-gradient(to bottom, var(--line) 0 .65em, transparent .65em var(--skeleton-row, 1.8em));
  opacity: .55; animation: skeleton-pulse 1.6s ease-in-out infinite alternate;
}
html[data-fonts-loading] h1 { --skeleton-width: 180px; }
html[data-fonts-loading] :where(.entry-description, .profile-description) { --skeleton-row: 1.9em; }
html[data-fonts-loading] .entry-tags { --skeleton-width: 180px; }
html[data-fonts-loading] :where(.social-link, .theme-toggle)::after { left: 50%; top: 50%; transform: translate(-50%, -50%); width: 22px; height: 22px; border-radius: 50%; background: var(--line); }
html[data-fonts-loading] .theme-toggle[hidden] { display: block; }
html[data-fonts-loading] .photo-wall { pointer-events: none; }
html[data-fonts-loading] .photo-track { animation-play-state: paused !important; }
html[data-media-placeholders] :is(.avatar, .photo-float-image, .project-preview img, .photo-viewer-image):not([data-media-ready]),
html[data-media-placeholders] .photo-link:has(> img:not([data-media-ready])) {
  color: transparent; background: linear-gradient(105deg, transparent 25%, rgb(255 255 255 / .12) 50%, transparent 75%) var(--panel);
  background-size: 220% 100%;
}
html[data-media-placeholders] .photo-link > img:not([data-media-ready]) { visibility: hidden; }
html[data-media-placeholders] .site-header .brand img:not([data-media-ready]) { color: transparent; }
html[data-media-placeholders] .site-header .brand:has(img:not([data-media-ready]))::after { content: ""; position: absolute; inset: 0; visibility: visible; pointer-events: none; border-radius: 2px; background: var(--line); opacity: .55; }
@keyframes skeleton-pulse { from { opacity: .35; } to { opacity: .65; } }
.social-links { display: flex; align-items: center; gap: 12px; }
.social-link { display: inline-flex; align-items: center; justify-content: center; flex: 0 0 auto; width: var(--social-hit-size, 32px); height: var(--social-hit-size, 32px); color: var(--ink); border-radius: 3px; }
:where(html:not(.has-adaptive-cursor)) .social-link:hover, .social-link[data-cursor-within] { color: var(--accent); }
.social-icon { display: block; width: var(--social-icon-size, 22px); height: var(--social-icon-size, 22px); background-color: currentColor; -webkit-mask: var(--social-icon-source) center / contain no-repeat; mask: var(--social-icon-source) center / contain no-repeat; }
.social-icon--github { --social-icon-source: url("assets/icons/github.svg"); }
.social-icon--bilibili { --social-icon-source: url("assets/icons/bilibili.svg"); }
.social-icon--xiaohongshu { --social-icon-source: url("assets/icons/xiaohongshu.svg"); width: 32px; height: 22px; }
.social-icon--email { --social-icon-source: url("assets/icons/email.svg"); }
.profile-social.social-links {
  --social-edge-inset: calc((var(--social-icon-size, 22px) - var(--social-hit-size, 32px)) / 2);
  width: calc(var(--pcb-stage-width) * var(--pcb-cabinet-scale));
  justify-content: space-between;
  gap: 0;
  padding-top: 12px;
}
.profile-social-label { display: none; }
.profile-social > .social-link:first-of-type { margin-inline-start: var(--social-edge-inset); }
.profile-social > .social-link:last-child { margin-inline-end: var(--social-edge-inset); }
.entry-links a { display: inline-flex; align-items: baseline; gap: 5px; text-decoration: underline; text-decoration-thickness: 1px; text-decoration-color: var(--line); }
:where(html:not(.has-adaptive-cursor)) .entry-links a:hover, .entry-links a[data-cursor-within] { text-decoration-color: var(--accent); }
.link-arrow { font-family: var(--sans); font-size: .9em; color: var(--soft); }
:where(html:not(.has-adaptive-cursor)) a:hover .link-arrow, a[data-cursor-within] .link-arrow { color: var(--accent); }
.profile-details { min-width: 0; }
.profile-affiliations { display: grid; gap: 10px; margin-bottom: 16px; }
.affiliation-row { display: flex; align-items: center; gap: 10px; }
.affiliation-icon { --mark-size: 23px; display: block; width: var(--mark-size); height: var(--mark-size); flex-shrink: 0; background-color: var(--ink); }
.affiliation-icon--hkust { mask: url('assets/affiliations/hkust-emblem.svg') center / contain no-repeat; }
/* Crop the official transparent wordmark to its symbol using its alpha channel. */
.affiliation-icon--brainco { mask-image: url('assets/affiliations/brainco-source.png'); mask-repeat: no-repeat; mask-size: 444.155844% 150.649351%; mask-position: 12.075472% center; }
.affiliation-copy { display: flex; align-items: baseline; flex-wrap: wrap; gap: 1px 12px; min-width: 0; }
.affiliation-name { font-size: 17px; font-weight: 700; line-height: 1.6; }
.affiliation-role { font-size: 12px; color: var(--muted); line-height: 1.7; }
.profile-stats { display: flex; align-items: flex-start; flex-wrap: wrap; gap: 12px 26px; margin-top: 20px; }
.stat-value { display: inline-flex; align-items: center; gap: 8px; font-size: 12px; }
.stat-value strong { display: inline-block; text-align: right; font: 600 22px/1.2 var(--mono); letter-spacing: 0; font-variant-numeric: tabular-nums; }
.stat-value strong.rolling-counter { display: inline-flex; vertical-align: baseline; height: 1.2em; }
.counter-reel { display: block; height: 1.2em; width: 1ch; overflow: hidden; }
.counter-track { display: block; will-change: transform; }
.counter-digit { display: block; height: 1.2em; line-height: 1.2em; text-align: center; }
.counter-separator { display: block; width: 1ch; line-height: 1.2em; }
.stats-status { display: block; color: var(--soft); font: 10px/1.6 var(--sans); margin-top: 2px; }
.profile-stats .refresh-count { margin-top: 5px; }
.profile-description { color: var(--muted); font-size: 14px; line-height: 1.95; }
.mini-cv { display: grid; gap: 7px; padding-top: 16px; margin-top: 17px; border-top: 1px solid var(--line); }
.mini-cv > div { display: grid; grid-template-columns: 108px 1fr; gap: 16px; align-items: baseline; }
.mini-cv dt { font-size: 12px; color: var(--muted); font-variant-numeric: tabular-nums; }
.mini-cv dd { font-size: 13px; line-height: 1.7; }
.profile-honors { margin-top: 17px; font-size: 12px; line-height: 1.8; }
.profile-honors p:first-child { font-size: 13px; margin-bottom: 3px; }
.profile-honors p:last-child { color: var(--muted); }
.refresh-count { border: 0; background: none; color: var(--muted); font: 11px/1.5 var(--serif); padding: 3px 0; text-decoration: underline; text-decoration-color: var(--line); }
.refresh-count:disabled { opacity: .5; cursor: progress; }
.section-heading { display: flex; align-items: baseline; gap: 14px; }
h2 { font-size: 22px; font-weight: 600; line-height: 1.4; letter-spacing: -.02em; }
#work-title, #experience-title, #recognition-title { font-weight: 700; -webkit-text-stroke: .15px currentColor; }
.section-rule { height: 1px; flex: 1; background: var(--hairline); margin-left: 8px; align-self: center; }
.project-entry { position: relative; padding: 24px 0; border-bottom: 1px solid var(--hairline); }
.entry-heading { display: flex; align-items: baseline; justify-content: space-between; gap: 18px; }
.project-entry .entry-heading { display: grid; grid-template-columns: minmax(0, 1fr) auto; }
.project-meta { display: flex; flex-direction: column; align-items: flex-end; gap: 3px; }
.project-stars { display: inline-flex; align-items: baseline; gap: 6px; color: var(--ink); font-family: inherit; white-space: nowrap; }
.project-stars strong { font-size: 18px; font-weight: 600; letter-spacing: -.04em; }
.project-stars > span { font-size: 11px; color: var(--muted); }
:where(html:not(.has-adaptive-cursor)) .project-stars:hover strong, .project-stars[data-cursor-within] strong { text-decoration: underline; text-underline-offset: 4px; }
h3 { font-weight: 400; font-size: 22px; letter-spacing: -.02em; line-height: 1.4; }
.project-title { position: relative; width: fit-content; max-width: 100%; }
.preview-trigger { text-decoration: underline; text-decoration-color: transparent; transition: text-decoration-color .15s; }
:where(html:not(.has-adaptive-cursor)) .preview-trigger:hover, .preview-trigger[data-cursor-within] { text-decoration-color: var(--accent); }
.entry-date { flex-shrink: 0; font-size: 10px; color: var(--muted); font-variant-numeric: tabular-nums; }
.entry-description { margin-top: 10px; font-size: 13px; line-height: 1.9; color: var(--muted); max-width: 660px; }
.entry-links { display: flex; align-items: center; flex-wrap: wrap; gap: 18px; margin-top: 10px; font-size: 11px; }
.entry-tags { color: var(--soft); font-size: 10px; margin-top: 7px; }
.project-preview { display: none; position: absolute; z-index: 4; left: calc(100% + 22px); top: -66px; width: 255px; background: var(--paper); border: 1px solid var(--line); border-radius: 3px; padding: 4px; box-shadow: var(--shadow); pointer-events: none; }
.project-preview img { width: 100%; height: 150px; object-fit: cover; }
.project-preview > span { display: block; padding: 5px 3px 1px; color: var(--muted); font: 10px/1.4 var(--mixed-mono); letter-spacing: .02em; }
@media (hover: hover) and (pointer: fine) {
  :where(html:not(.has-adaptive-cursor)) .preview-trigger:hover + .project-preview,
  .preview-trigger[data-cursor-within] + .project-preview { display: block; }
}
:where(html:not([data-input-mode="pointer"])) .preview-trigger:focus-visible + .project-preview { display: block; }
.project-title.preview-dismissed .project-preview { display: none; }
.section-footnote { display: flex; justify-content: space-between; gap: 20px; font-size: 10px; color: var(--muted); margin-top: 15px; }
.experience-list { margin-top: 13px; }
#work, #experience, #recognition { font-family: var(--mixed-mono); }
.experience-entry { border-bottom: 1px solid var(--hairline); padding: 22px 0; }
.experience-entry h3, .project-entry h3 { font-size: 17px; font-weight: 600; line-height: 1.65; }
#work .project-entry h3 { font-family: var(--project-title); font-size: 19px; font-style: italic; font-feature-settings: "ss01" 1; font-synthesis: none; }
.company-detail { color: var(--soft); font-size: 10px; margin-top: 3px; }
.job-role { font-size: 12px; font-weight: 600; color: var(--ink); margin-top: 6px; }
.experience-entry .entry-description { margin-top: 7px; }
summary { cursor: pointer; list-style: none; }
summary::-webkit-details-marker { display: none; }
summary:before { content: "+"; color: var(--accent); font: 16px/1 var(--serif); width: 18px; display: inline-block; }
details[open] > summary:before { content: "−"; }
.education-details { border-bottom: 1px solid var(--line); padding: 20px 0; }
.education-details summary { font-size: 14px; display: flex; align-items: baseline; gap: 10px; }
.education-details summary:before { flex-shrink: 0; width: 8px; }
.education-details summary .entry-date { margin-left: auto; }
.details-content { margin-top: 15px; padding-left: 18px; }
.details-content > p { font-size: 12px; color: var(--muted); }
.school-list { list-style: none; padding: 0; margin-top: 14px; }
.school-list li { display: flex; justify-content: space-between; gap: 20px; font-size: 11px; padding: 5px 0; }
.minor-heading { font-size: 15px; font-weight: 600; color: var(--ink); margin-top: 24px; margin-bottom: 13px; }
.honor-list { padding: 0; list-style: none; }
.honor-list li { display: grid; grid-template-columns: 68px 1fr; gap: 18px; font-size: 14px; line-height: 1.9; padding: 8px 0; }
.honor-list time { font-size: 11px; color: var(--muted); padding-top: 2px; font-variant-numeric: tabular-nums; }
.more-awards { margin-top: 10px; }
.more-awards summary { font-size: 12px; color: var(--muted); }
.more-awards summary > span:last-child { margin-left: 10px; font-size: 11px; color: var(--soft); }
.more-awards .honor-list { margin-top: 10px; }
.certificates-heading { border-top: 1px solid var(--line); padding-top: 21px; margin-top: 25px; }
.affiliations { border-top: 1px solid var(--line); margin-top: 23px; }
.affiliations p { font-size: 14px; line-height: 1.9; color: var(--muted); }
.profile-gallery { position: relative; min-width: 0; min-height: 350px; }
.photo-wall { --photo-columns: 2; position: absolute; inset: 0; display: grid; grid-template-columns: repeat(var(--photo-columns), minmax(0, 1fr)); align-items: start; gap: 8px; overflow-y: auto; scrollbar-width: none; mask-image: linear-gradient(to bottom, transparent, #000 36px, #000 calc(100% - 36px), transparent); -webkit-mask-image: linear-gradient(to bottom, transparent, #000 36px, #000 calc(100% - 36px), transparent); }
.photo-wall[data-photo-columns="3"] { --photo-columns: 3; }
@media (pointer: coarse) {
  .photo-wall:not([data-photo-columns]) { --photo-columns: 3; }
  .photo-wall:not([data-photo-columns]) :is(.photo-column, .photo-track, .photo-group) { display: contents; }
}
.photo-wall::-webkit-scrollbar { display: none; }
.photo-wall.is-ready { overflow: hidden; }
.photo-column { min-width: 0; }
.photo-track, .photo-group { display: flex; flex-direction: column; gap: 8px; }
.photo-wall.is-ready .photo-track { animation: photo-scroll var(--photo-duration, 120s) linear infinite; will-change: transform; }
.photo-wall.is-ready .photo-column:nth-child(even) .photo-track { animation-direction: reverse; }
.photo-wall.is-paused .photo-track { animation-play-state: paused; will-change: auto; }
.photo-link { position: relative; display: block; flex: 0 0 auto; width: 100%; overflow: hidden; contain: paint; aspect-ratio: var(--photo-ratio, 1.3333); border-radius: 3px; background: var(--panel); cursor: zoom-in; }
.photo-link img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: var(--photo-focus, center); }
.photo-link.is-lifted { opacity: 0; }
.photo-float { position: fixed; z-index: 10; max-width: none; outline: 2px solid var(--paper); border-radius: 3px; box-shadow: 0 12px 32px #0006; transform-origin: center; translate: 0px 0px; transition: translate .18s cubic-bezier(.2,.75,.25,1); pointer-events: none; }
.photo-float[data-shadow-ready] { box-shadow: none; }
.photo-float-image { width: 100%; height: 100%; border-radius: inherit; object-fit: cover; }
.photo-float-shadow { position: absolute; z-index: -1; max-width: none; pointer-events: none; opacity: 1; transition: opacity .18s cubic-bezier(.3,0,.3,1); }
.photo-float.is-returning .photo-float-shadow { opacity: 0; }
.gallery-open { position: absolute; z-index: 2; bottom: 12px; right: 8px; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; padding: 0; border: 0; color: var(--ink); background: var(--paper); font: 11px/1.6 var(--mixed-mono); }
:where(html:not([data-input-mode="pointer"])) .gallery-open:focus-visible { width: auto; height: auto; clip-path: none; padding: 6px 10px; }
@keyframes photo-scroll { to { transform: translateY(calc(-50% - 4px)); } }
.photo-viewer-open { overflow: hidden; scrollbar-gutter: auto; padding-inline-end: var(--viewer-scrollbar-gap, 0px); }
/* The animated border extends past the dialog's padding; it must not create a scrollport. */
.photo-viewer { width: min(1040px, calc(100% - 40px)); max-width: none; max-height: calc(100dvh - 40px); padding: 12px 16px 14px; border: 1px solid transparent; border-radius: 5px; color: var(--ink); background: transparent; overflow: visible; }
.photo-viewer:not([open]) { display: none; }
.photo-viewer::before { content: ""; position: absolute; inset: -1px; z-index: -1; pointer-events: none; border: 1px solid var(--line); border-radius: inherit; background: var(--paper); }
.photo-viewer.is-animating::before, .photo-viewer.is-animating :is(.photo-viewer-bar, .photo-viewer-footer) { animation: viewer-panel-in .3s cubic-bezier(.2,.75,.25,1) both; }
.photo-viewer.is-animating.is-closing::before, .photo-viewer.is-animating.is-closing :is(.photo-viewer-bar, .photo-viewer-footer) { animation: viewer-panel-out .22s cubic-bezier(.2,.75,.25,1) both; }
@keyframes viewer-panel-in { from { opacity: 0; transform: var(--viewer-panel-start, scale(.94)); } to { opacity: 1; transform: none; } }
@keyframes viewer-panel-out { from { opacity: var(--viewer-panel-opacity, 1); transform: var(--viewer-panel-current, none); } to { opacity: 0; transform: var(--viewer-panel-end, scale(.94)); } }
.photo-viewer::backdrop { background: #100d0be6; animation: viewer-backdrop-in .3s cubic-bezier(.2,.75,.25,1) both; }
.photo-viewer.is-closing::backdrop { animation: viewer-backdrop-out .22s cubic-bezier(.2,.75,.25,1) both; }
@keyframes viewer-backdrop-in { from { background: #100d0b00; } to { background: #100d0be6; } }
@keyframes viewer-backdrop-out { from { background: var(--viewer-backdrop-from, #100d0be6); } to { background: #100d0b00; } }
.photo-viewer-bar { display: flex; justify-content: flex-end; margin-bottom: 10px; }
.photo-viewer button { border: 0; background: transparent; color: var(--muted); font: 12px/1.6 var(--mixed-mono); padding: 3px 6px; min-height: 32px; }
:where(html:not(.has-adaptive-cursor)) .photo-viewer button:hover, .photo-viewer button[data-cursor-within] { color: var(--ink); }
.photo-viewer-image { width: auto; height: auto; max-width: 100%; max-height: calc(100dvh - 170px); object-fit: contain; margin-inline: auto; }
.photo-viewer-footer { display: flex; align-items: center; flex-wrap: wrap; gap: 10px 22px; margin-top: 13px; }
.photo-viewer-controls { display: flex; align-items: center; gap: 12px; margin-inline: auto; }
.photo-viewer-count { color: var(--soft); font: 11px/1.5 var(--mono); white-space: nowrap; }
.contact-section { margin-bottom: 54px; }
.contact-links { --social-hit-size: 40px; --social-icon-size: 26px; gap: 16px; margin-top: 16px; }
.site-footer { display: flex; align-items: center; gap: 26px; border-top: 1px solid var(--line); padding: 23px 0; font-size: 10px; color: var(--muted); }
.site-footer p { margin-left: auto; }
.back-to-top {
  position: fixed;
  z-index: 11;
  right: max(16px, env(safe-area-inset-right));
  bottom: max(16px, env(safe-area-inset-bottom));
  width: var(--back-to-top-size);
  height: var(--back-to-top-size);
  display: grid;
  place-items: center;
  border: 1px solid color-mix(in srgb, var(--accent) 45%, var(--line));
  border-radius: 50%;
  background: var(--panel);
  color: var(--ink);
  box-shadow: 0 3px 16px rgb(20 13 9 / .16);
  transition: opacity .24s ease, visibility 0s, color .15s ease;
}
.back-to-top[inert] { opacity: 0; visibility: hidden; pointer-events: none; transition-delay: 0s, .24s, 0s; }
@media (min-width: 761px) and (hover: hover) and (pointer: fine) {
  .back-to-top {
    right: clamp(28px, 4vw, 64px);
    top: var(--back-to-top-desktop-top);
    bottom: auto;
    background: color-mix(in srgb, var(--accent) 32%, var(--panel));
    border-color: color-mix(in srgb, var(--accent) 72%, var(--line));
    box-shadow: inset 0 1px rgb(255 255 255 / .15), 0 3px 16px rgb(20 13 9 / .16);
  }
}
html[lang=en] body { font-size: 16px; }
html[lang=en] .profile-description { font-size: 16px; line-height: 1.7; }
html[lang=en] .entry-description { font-size: 15px; line-height: 1.7; }
html[lang=en] .mini-cv dd, html[lang=en] .profile-honors p { font-size: 14px; }
html[lang=en] .honor-list li, html[lang=en] #recognition .affiliations p { font-size: 14px; line-height: 1.85; }
html[lang=en] .job-role { font-size: 14px; }
html[lang=en] :is(.experience-entry, .project-entry) h3 { font-family: var(--mixed-mono); font-size: 18px; line-height: 1.65; letter-spacing: -.035em; }
html[lang=en] :is(#experience, #work) .entry-description { font-size: 13px; line-height: 1.85; }
html[lang=en] #experience .job-role { font-size: 12px; }
.error-page { width: min(100% - 48px,760px); margin: 70px auto; }
.error-page h1 { font-size: clamp(36px,7vw,64px); margin: 45px 0 20px; }
.error-page p { color: var(--muted); }
.error-page > a:last-child { display: inline-block; margin-top: 24px; text-decoration: underline; }
@media (max-width: 1040px) {
  .profile { grid-template-columns: 244px minmax(0, 1fr); column-gap: 32px; }
}
@media (max-width: 1040px), (pointer: coarse) {
  .profile-gallery { grid-column: 1 / -1; width: min(100%, 460px); height: 340px; min-height: 0; margin: 28px auto 0; }
}
@media (max-width: 800px) {
  .shell { width: calc(100% - 56px); }
  .content-section { width: calc(100% - 80px); }
  .profile { grid-template-columns: 218px minmax(0, 1fr); gap: 32px; }
  .mini-cv > div { grid-template-columns: 94px 1fr; gap: 12px; }
  .mini-cv dt { font-size: 11px; }
  h1 { font-size: 32px; }
  .profile-description { font-size: 13px; }
  .site-header nav { gap: 20px; }
  .project-preview { width: 215px; left: calc(100% + 14px); }
  .project-preview img { height: 125px; }
}
@media (max-width: 760px) {
  :root { --banner-height: 124px; }
  .site-header { flex-wrap: wrap; gap: 18px; }
  .header-controls { margin-left: auto; }
  .theme-toggle { width: 44px; height: 44px; }
  .site-header nav { order: 3; margin: 0; width: 100%; justify-content: space-between; gap: 15px; font-size: 12px; }
}
@media (max-width: 600px) {
  .shell, .content-section { width: calc(100% - 40px); }
  .site-header { padding-top: 22px; padding-bottom: 16px; flex-wrap: wrap; gap: 18px; }
  .brand img { width: 112px; }
  .site-header .brand { --brand-aura-radii: 190px 250px; }
  .site-header .brand::before, .brand-aura-canvas { width: 400px; }
  .site-header nav { order: 3; margin: 0; width: 100%; justify-content: space-between; gap: 15px; font-size: 12px; }
  .profile { display: block; padding-top: 28px; }
  .portfolio-sections { margin-top: 28px; }
  .identity-column { display: grid; grid-template-columns: 94px minmax(0,1fr); gap: 0 22px; align-items: start; }
  .avatar { width: 94px; height: 94px; border-radius: 6px; margin: 0; }
  .identity-column > .avatar { grid-column: 1; grid-row: 1; }
  .identity-column > h1 { grid-column: 2; grid-row: 1; align-self: center; }
  h1 { font-size: clamp(23px, 6.3vw, 29px); }
  .identity-column > .oled-playground { grid-column: 1 / -1; grid-row: 2; margin-top: 20px; }
  .social-links { --social-hit-size: 44px; gap: 8px; }
  .profile-social.social-links { grid-column: 1 / -1; grid-row: 3; margin-top: 7px; padding-top: 0; }
  .profile-details { padding-top: 28px; }
  .affiliation-row { align-items: flex-start; gap: 10px; }
  .affiliation-icon { --mark-size: 21px; margin-top: 2px; }
  .affiliation-name { font-size: 16px; }
  .affiliation-role { font-size: 12px; }
  .profile-stats { gap: 10px 18px; }
  .stat-value strong { font-size: 20px; }
  .stat-value { font-size: 11px; gap: 6px; }
  .stats-status { font-size: 10px; }
  .profile-description { font-size: 13px; line-height: 1.85; }
  .mini-cv { gap: 9px; margin-top: 15px; padding-top: 14px; }
  .mini-cv > div { grid-template-columns: 94px 1fr; gap: 12px; }
  .mini-cv dd { font-size: 12px; }
  .profile-honors { margin-top: 17px; }
  .content-section { margin-top: 40px; }
  h2 { font-size: 21px; }
  .section-heading { gap: 10px; }
  .project-entry { padding: 23px 0 21px; }
  .project-stars strong { font-size: 16px; }
  .project-stars > span { font-size: 10px; }
  h3 { font-size: 21px; }
  .entry-date { font-size: 9px; }
  .entry-heading { flex-wrap: wrap; row-gap: 3px; column-gap: 12px; }
  .entry-description { font-size: 12px; margin-top: 8px; }
  .entry-links { gap: 15px; font-size: 11px; }
  .entry-tags { font-size: 9px; }
  .project-preview { left: 0; top: calc(100% + 8px); width: 230px; }
  .section-footnote { font-size: 9px; gap: 12px; }
  .experience-entry h3, .project-entry h3 { font-size: 16px; }
  #work .project-entry h3 { font-size: 18px; }
  .experience-entry { padding: 21px 0; }
  .experience-entry .entry-heading { display: block; }
  .experience-entry .entry-date { display: block; margin-top: 4px; }
  .job-role { font-size: 11px; }
  .education-details summary { font-size: 12px; gap: 8px; }
  .education-details summary .entry-date { font-size: 8px; }
  .details-content { padding-left: 0; }
  .school-list li { display: block; font-size: 11px; padding: 7px 0; }
  .school-list .entry-date { display: block; }
  .honor-list li { grid-template-columns: 55px 1fr; gap: 12px; font-size: 13px; padding: 8px 0; }
  .honor-list time { font-size: 10px; }
  .minor-heading { font-size: 14px; margin-top: 20px; margin-bottom: 10px; }
  .affiliations p { font-size: 13px; }
  .profile-gallery { height: clamp(270px, 82vw, 360px); }
  .photo-viewer { width: calc(100% - 20px); max-height: calc(100dvh - 20px); padding: 10px; }
  .photo-viewer button { min-height: 44px; padding-inline: 8px; }
  .photo-viewer-image { max-height: calc(100dvh - 180px); }
  .photo-viewer-controls { gap: 6px; }
  .contact-section { margin-bottom: 36px; }
  .site-footer { gap: 15px; flex-wrap: wrap; font-size: 9px; padding: 20px 0; }
  .site-footer .brand img { width: 94px; }
  .site-footer > a:last-child { margin-left: auto; }
  html[lang=en] .profile-description { font-size: 15px; }
  html[lang=en] .entry-description { font-size: 14px; }
  html[lang=en] .mini-cv dd, html[lang=en] .profile-honors p { font-size: 13px; }
  html[lang=en] .honor-list li, html[lang=en] #recognition .affiliations p { font-size: 13px; }
  html[lang=en] .job-role { font-size: 13px; }
  html[lang=en] :is(.experience-entry, .project-entry) h3 { font-size: 17px; }
  html[lang=en] :is(#experience, #work) .entry-description { font-size: 12px; }
}
@media (pointer: coarse) {
  .identity-column {
    --pcb-panel-width: clamp(94px, 28%, 126px);
    --pcb-panel-gap: 8px;
    --pcb-stage-width: min(288px, calc(100% - var(--pcb-panel-width) - var(--pcb-panel-gap)));
    --pcb-cabinet-scale: .9;
  }
  .profile-social.social-links {
    --social-hit-size: 44px;
    width: calc(var(--pcb-stage-width) + var(--pcb-panel-gap) + var(--pcb-panel-width));
  }
  .profile-social-label { display: block; color: var(--muted); font: 11px/1.5 var(--sans); white-space: nowrap; }
  .profile-social > .social-link:first-of-type { margin-inline-start: 0; }
}
@media (pointer: coarse) and (max-width: 760px) {
  .profile { grid-template-columns: minmax(0, 1fr); }
  .profile-details { padding-top: 28px; }
}
@media (pointer: coarse) and (min-width: 761px) {
  .profile { grid-template-columns: minmax(0, 46%) minmax(0, 1fr); column-gap: 28px; }
}
@media screen and (min-width: 1041px) and (hover: hover) and (pointer: fine) {
  :root {
    --portfolio-aside-width: clamp(256px, 20.5vw, 300px);
    --portfolio-gap: 28px;
    --portfolio-side-space: calc(2 * (var(--portfolio-aside-width) + var(--portfolio-gap)));
    --portfolio-width: min(100% - 48px, 736px + var(--portfolio-side-space));
    --portfolio-aside-top: calc(var(--banner-height, 77px) + 20px);
    --portfolio-gallery-height: clamp(0px, calc(var(--back-to-top-desktop-top) - var(--portfolio-aside-top) - 14px), 540px);
  }
  .profile {
    width: var(--portfolio-width);
    grid-template-columns: var(--portfolio-aside-width) minmax(0, 1fr) var(--portfolio-aside-width);
    grid-template-rows: auto 1fr;
    column-gap: var(--portfolio-gap);
    align-items: start;
  }
  .profile > :is(.identity-column, .profile-gallery) {
    position: sticky;
    top: var(--portfolio-aside-top);
    grid-row: 1 / -1;
    align-self: start;
  }
  .profile > .identity-column {
    --pcb-stage-width: min(280px, 100%);
    grid-column: 1;
  }
  .identity-column > .avatar { width: 128px; height: 128px; }
  .profile-details { grid-column: 2; grid-row: 1; }
  .profile-gallery { grid-column: 3; height: var(--portfolio-gallery-height); min-height: 0; }
  .back-to-top { right: calc((100% - var(--portfolio-width) + var(--portfolio-aside-width) - var(--back-to-top-size)) / 2); }
  .portfolio-sections { grid-column: 2; grid-row: 2; }
  .site-footer { width: min(736px, calc(100% - 48px - var(--portfolio-side-space))); }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *:before, *:after { transition: none !important; animation: none !important; }
  .photo-wall.is-ready { overflow-y: auto; mask-image: none; -webkit-mask-image: none; }
  .photo-track { transform: none; }
  [data-photo-clone] { display: none; }
  .photo-viewer::backdrop { animation: none !important; }
}
@media print {
  .site-banner { position: static; }
  .site-header .brand img { filter: none; animation: none; }
  .site-banner::before, .site-header .brand::before, .brand-aura-canvas, .back-to-top { display: none; }
  .site-header nav, .header-controls, .refresh-count, .project-preview, .profile-gallery, .photo-viewer, .photo-float { display: none !important; }
  .profile { grid-template-columns: 218px minmax(0, 1fr); }
  :root, :root[data-theme] { color-scheme: light; --paper: white; --ink: #111; --muted: #444; --soft: #666; --line: #ddd; --hairline: #e5e5e5; --accent: #333; --logo-filter: none; }
  .shell, .content-section { width: 100%; }
  .content-section { margin-top: 28px; }
  .project-entry, .experience-entry, .honor-list li { break-inside: avoid; }
}
