:root {
  color-scheme: light;
  --bg: #f7f8f3;
  --surface: #ffffff;
  --surface-soft: #fbfcf8;
  --ink: #172125;
  --muted: #657075;
  --line: #d9dfd9;
  --line-soft: rgba(217, 223, 217, 0.62);
  --link: #226f68;
  --link-strong: #174b48;
  --accent: #a45d2a;
  --accent-soft: #f2dfc8;
  --green-soft: #e9f1ed;
  --blue-soft: #eef2f6;
  --shadow: 0 18px 45px rgba(25, 38, 39, 0.08);
  --profile-shadow: 0 24px 60px rgba(25, 38, 39, 0.12);
  --content-width: 1120px;
  --anchor-offset: 76px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background:
    linear-gradient(90deg, rgba(34, 111, 104, 0.07) 0 1px, transparent 1px 100%),
    linear-gradient(180deg, rgba(34, 111, 104, 0.05) 0 1px, transparent 1px 100%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.92), rgba(247, 248, 243, 0.7) 38%, rgba(247, 248, 243, 1)),
    var(--bg);
  background-size:
    38px 38px,
    38px 38px,
    auto;
  color: var(--ink);
  font-family:
    "Inter", "Aptos", ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    "PingFang SC", "Microsoft YaHei", sans-serif;
  font-size: 16px;
  line-height: 1.74;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background:
    linear-gradient(115deg, rgba(242, 223, 200, 0.48), transparent 34%),
    linear-gradient(245deg, rgba(238, 242, 246, 0.72), transparent 42%);
}

a {
  color: var(--link);
  text-decoration: none;
  text-underline-offset: 3px;
}

a:hover,
a:focus-visible {
  color: var(--link-strong);
  text-decoration: underline;
}

.page-shell {
  display: grid;
  grid-template-columns: minmax(235px, 286px) minmax(0, 1fr);
  gap: 58px;
  width: min(calc(100% - 40px), var(--content-width));
  margin: 0 auto;
  padding: 48px 0 46px;
}

.profile-panel {
  position: sticky;
  top: 32px;
  align-self: start;
  padding: 18px 18px 20px;
  border: 1px solid rgba(217, 223, 217, 0.86);
  border-radius: 8px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(251, 252, 248, 0.82)),
    var(--surface);
  background-clip: padding-box;
  box-shadow: var(--profile-shadow);
}

.avatar {
  display: block;
  width: 100%;
  aspect-ratio: 1;
  border-radius: 50%;
  object-fit: cover;
  background:
    linear-gradient(135deg, rgba(34, 111, 104, 0.08), rgba(164, 93, 42, 0.08)),
    var(--surface);
  border: 1px solid var(--line);
  box-shadow: 0 12px 28px rgba(25, 38, 39, 0.09);
}

.profile-panel h1 {
  margin: 20px 0 0;
  font-family: "Palatino Linotype", "Songti SC", "Noto Serif SC", Georgia, serif;
  font-size: 31px;
  line-height: 1.14;
  font-weight: 700;
  letter-spacing: 0;
}

.name-cn {
  margin: 5px 0 18px;
  color: #566369;
  font-family: "Noto Serif SC", "Songti SC", "STSong", "SimSun", serif;
  font-size: 20px;
  font-weight: 600;
  line-height: 1.35;
}

.affiliation,
.location {
  margin: 0;
  color: var(--ink);
  line-height: 1.5;
}

.affiliation {
  margin-top: 0;
  color: var(--muted);
  font-size: 18px;
  font-weight: 720;
}

.location {
  margin-top: 2px;
  color: #7a8489;
  font-size: 15px;
  font-weight: 560;
}

.social-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 20px;
  padding-top: 18px;
  border-top: 1px solid var(--line-soft);
}

.tag {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 5px 10px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.76);
  color: var(--link-strong);
  font-size: 14px;
  line-height: 1.3;
}

.social-icon {
  position: relative;
  display: inline-grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.82);
  color: var(--link-strong);
  box-shadow: 0 8px 20px rgba(25, 38, 39, 0.06);
  transition:
    background 160ms ease,
    border-color 160ms ease,
    color 160ms ease,
    transform 160ms ease;
}

.social-icon:hover,
.social-icon:focus-visible {
  transform: translateY(-2px);
  border-color: rgba(34, 111, 104, 0.38);
  background: var(--link-strong);
  color: #ffffff;
  text-decoration: none;
}

.social-icon svg {
  width: 21px;
  height: 21px;
  fill: currentColor;
}

.social-icon[title]::after {
  content: attr(title);
  position: absolute;
  left: 50%;
  bottom: calc(100% + 8px);
  z-index: 2;
  transform: translateX(-50%) translateY(4px);
  width: max-content;
  max-width: 150px;
  padding: 4px 7px;
  border-radius: 5px;
  background: var(--ink);
  color: #ffffff;
  font-size: 12px;
  line-height: 1.25;
  opacity: 0;
  pointer-events: none;
  transition:
    opacity 160ms ease,
    transform 160ms ease;
}

.social-icon:hover::after,
.social-icon:focus-visible::after {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

.social-label {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.content {
  min-width: 0;
}

.content-nav {
  position: sticky;
  top: 0;
  z-index: 4;
  display: flex;
  flex-wrap: wrap;
  gap: 8px 18px;
  align-items: center;
  margin: -14px 0 18px;
  padding: 13px 0 11px;
  border-bottom: 1px solid var(--line-soft);
  background: rgba(247, 248, 243, 0.82);
  backdrop-filter: blur(18px);
}

.content-nav a {
  position: relative;
  color: #3d4b50;
  font-size: 14px;
  font-weight: 720;
  line-height: 1.35;
}

.content-nav a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -5px;
  height: 2px;
  border-radius: 99px;
  background: var(--accent);
  opacity: 0;
  transform: translateY(3px);
  transition:
    opacity 160ms ease,
    transform 160ms ease;
}

.content-nav a:hover,
.content-nav a:focus-visible {
  color: var(--link-strong);
  text-decoration: none;
}

.content-nav a:hover::after,
.content-nav a:focus-visible::after {
  opacity: 1;
  transform: translateY(0);
}

.section {
  position: relative;
  scroll-margin-top: var(--anchor-offset);
  padding: 28px 0 32px;
  border-bottom: 1px solid var(--line-soft);
}

.section:first-child {
  padding-top: 18px;
  padding-bottom: 36px;
}

.section h2 {
  margin: 0 0 14px;
  font-family: "Palatino Linotype", "Songti SC", "Noto Serif SC", Georgia, serif;
  font-size: 28px;
  line-height: 1.25;
  font-weight: 700;
  letter-spacing: 0;
}

.section:not(:first-child) h2 {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 25px;
}

.section:not(:first-child) h2::after {
  content: "";
  flex: 1 1 auto;
  height: 1px;
  background: linear-gradient(90deg, var(--line), transparent);
}

.section p {
  margin: 0 0 13px;
}

.section p:last-child {
  margin-bottom: 0;
}

#about-content a {
  color: var(--link-strong);
  font-weight: 720;
  text-decoration: underline;
  text-decoration-color: rgba(23, 75, 72, 0.34);
}

#about-content a:hover,
#about-content a:focus-visible {
  color: #0f3432;
  text-decoration-color: currentColor;
}

.interest-list,
.timeline {
  margin: 0;
  padding-left: 22px;
}

.interest-list li,
.timeline li {
  padding-left: 4px;
  margin: 8px 0;
}

.interest-list li::marker {
  color: var(--link);
}

.timeline li::marker {
  color: var(--accent);
}

.timeline time {
  color: var(--accent);
  font-weight: 720;
}

.education-list {
  position: relative;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 42px;
}

.education-list::before {
  content: "";
  position: absolute;
  top: 12px;
  bottom: 12px;
  left: 50%;
  width: 1px;
  background: var(--line-soft);
}

.education-item {
  display: grid;
  grid-template-columns: 68px minmax(0, 1fr);
  gap: 30px;
  align-items: center;
  padding: 12px 0;
}

.education-item + .education-item {
  padding-left: 0;
  border-left: 0;
}

.education-logo {
  display: grid;
  place-items: center;
  width: 68px;
  height: 68px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.86);
  box-shadow: 0 8px 20px rgba(25, 38, 39, 0.06);
}

.education-logo img {
  display: block;
  width: 78%;
  height: 78%;
  object-fit: contain;
}

.education-body {
  min-width: 0;
}

.education-body h3 {
  margin: 0;
  color: var(--ink);
  font-size: 18px;
  line-height: 1.35;
  font-weight: 760;
}

.education-meta {
  display: flex;
  flex-wrap: nowrap;
  gap: 4px 10px;
  align-items: center;
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.45;
  white-space: nowrap;
}

.education-years {
  color: var(--accent);
  font-weight: 760;
}

.education-meta span {
  color: var(--muted);
}

.education-meta span::before {
  content: "";
  display: inline-block;
  width: 4px;
  height: 4px;
  margin: 0 10px 3px 0;
  border-radius: 50%;
  background: var(--line);
}

.publication-list {
  display: grid;
  gap: 16px;
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: publications;
}

.publication {
  position: relative;
  display: grid;
  grid-template-columns: 176px minmax(0, 1fr);
  gap: 20px;
  align-items: center;
  padding: 16px;
  border: 1px solid rgba(217, 223, 217, 0.82);
  border-radius: 8px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.92), rgba(251, 252, 248, 0.76)),
    var(--surface-soft);
  box-shadow: 0 10px 28px rgba(25, 38, 39, 0.045);
  counter-increment: publications;
}

.publication::before {
  content: counter(publications) ".";
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

.publication-thumb {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 6px;
  border: 1px solid var(--line);
  background: #ffffff;
  box-shadow: 0 10px 24px rgba(25, 38, 39, 0.07);
}

video.publication-thumb {
  cursor: pointer;
}

.publication-thumb-empty {
  min-height: 88px;
  background:
    linear-gradient(135deg, rgba(225, 232, 224, 0.72), rgba(226, 236, 241, 0.8));
}

.publication-body {
  min-width: 0;
}

.publication-title {
  display: inline;
  color: var(--link-strong);
  font-size: 18px;
  font-weight: 760;
  line-height: 1.36;
}

.authors {
  margin-top: 5px;
  color: var(--muted);
  line-height: 1.5;
}

.authors strong {
  color: var(--ink);
  font-weight: 780;
}

.publication-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin-top: 10px;
}

.publication-venue,
.publication-links a {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 3px 9px;
  border-radius: 5px;
  font-size: 14px;
  font-weight: 680;
}

.publication-venue {
  border: 1px solid currentColor;
  background: #ffffff;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.72);
}

.venue-eccv {
  color: #1f6f68;
  background: rgba(233, 241, 237, 0.72);
}

.venue-ral {
  color: #8b4d1f;
  background: rgba(242, 223, 200, 0.68);
}

.venue-icra {
  color: #355f8c;
  background: rgba(238, 242, 246, 0.9);
}

.venue-default {
  color: #5e6670;
  background: rgba(247, 248, 243, 0.95);
}

.publication-links a {
  border: 1px solid transparent;
  background: var(--green-soft);
  color: var(--link-strong);
}

.publication-links a:hover,
.publication-links a:focus-visible {
  border-color: var(--link-strong);
  background: var(--link-strong);
  color: #ffffff;
  text-decoration: none;
}

.footer {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 18px;
  padding: 24px 0 0;
  color: var(--muted);
  font-size: 14px;
}

@media (max-width: 820px) {
  :root {
    --anchor-offset: 66px;
  }

  .page-shell {
    grid-template-columns: 1fr;
    gap: 20px;
    width: min(calc(100% - 30px), 640px);
    padding-top: 26px;
  }

  .profile-panel {
    position: static;
    display: grid;
    grid-template-columns: 108px minmax(0, 1fr);
    column-gap: 18px;
    align-items: start;
    padding: 14px;
  }

  .content-nav {
    gap: 8px;
    margin-top: 0;
    overflow-x: auto;
    flex-wrap: nowrap;
    padding-top: 10px;
    padding-bottom: 10px;
  }

  .content-nav a {
    flex: 0 0 auto;
    font-size: 12px;
  }

  .avatar {
    grid-row: span 4;
    width: 108px;
  }

  .profile-panel h1 {
    margin-top: 0;
    font-size: 27px;
  }

  .name-cn {
    margin-bottom: 12px;
  }

  .social-links {
    grid-column: 1 / -1;
    margin-top: 14px;
  }

  .publication {
    grid-template-columns: 132px minmax(0, 1fr);
    gap: 14px;
  }

  .education-list {
    grid-template-columns: 1fr;
    gap: 0;
  }

  .education-list::before {
    display: none;
  }

  .education-item + .education-item {
    padding-left: 0;
    border-left: 0;
    border-top: 1px solid var(--line-soft);
  }

  .education-meta {
    flex-wrap: wrap;
    white-space: normal;
  }

}

@media (max-width: 560px) {
  body {
    font-size: 15px;
  }

  .profile-panel {
    grid-template-columns: 92px minmax(0, 1fr);
  }

  .avatar {
    width: 92px;
  }

  .profile-panel h1 {
    font-size: 24px;
  }

  .section h2 {
    font-size: 24px;
  }

  .section:not(:first-child) h2 {
    font-size: 22px;
  }

  .education-item {
    grid-template-columns: 56px minmax(0, 1fr);
    gap: 18px;
    padding: 9px 0 12px;
  }

  .education-logo {
    width: 56px;
    height: 56px;
  }

  .publication {
    grid-template-columns: 1fr;
    gap: 12px;
    padding: 14px;
  }

  .publication-thumb {
    width: min(100%, 280px);
    max-width: 280px;
  }
}
