/* Academic homepage — clean, readable, mobile-friendly */
:root {
  --bg: #fafbfc;
  --surface: #ffffff;
  --text: #1a1d21;
  --muted: #5c6570;
  --border: #e6e9ee;
  --accent: #1a5f7a;
  --accent-soft: #e8f2f6;
  --radius: 12px;
  --shadow: 0 1px 3px rgba(26, 29, 33, 0.06), 0 4px 16px rgba(26, 29, 33, 0.04);
  --max: 720px;
  --font: "Noto Sans SC", "PingFang SC", "Microsoft YaHei", system-ui, -apple-system, sans-serif;
  --font-mono: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.7;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

a {
  color: var(--accent);
  text-decoration: none;
}
a:hover {
  text-decoration: underline;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--accent);
  color: #fff;
  padding: 0.5rem 1rem;
  z-index: 100;
}
.skip-link:focus {
  left: 0;
}

/* Nav */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(250, 251, 252, 0.92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}

.nav-inner {
  max-width: calc(var(--max) + 4rem);
  margin: 0 auto;
  padding: 0.75rem 1.25rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.nav-brand {
  font-weight: 600;
  color: var(--text);
  text-decoration: none;
  white-space: nowrap;
}
.nav-brand:hover {
  text-decoration: none;
  color: var(--accent);
}

.nav-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 1rem;
  list-style: none;
  margin: 0;
  padding: 0;
  font-size: 0.9rem;
}
.nav-links a {
  color: var(--muted);
  text-decoration: none;
}
.nav-links a:hover,
.nav-links a[aria-current="page"] {
  color: var(--accent);
}
.nav-links a[aria-current="page"] {
  font-weight: 600;
}

/* Layout */
main {
  max-width: calc(var(--max) + 4rem);
  margin: 0 auto;
  padding: 2rem 1.25rem 4rem;
}

section {
  margin-bottom: 3rem;
  scroll-margin-top: 4rem;
}

.section-title {
  font-size: 1.15rem;
  font-weight: 650;
  letter-spacing: 0.02em;
  margin: 0 0 1.25rem;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid var(--accent-soft);
  color: var(--text);
}
.section-title span.en {
  display: block;
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--muted);
  letter-spacing: 0.04em;
  margin-top: 0.15rem;
  text-transform: uppercase;
}

/* Hero */
.hero {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 1.5rem 1.75rem;
  align-items: start;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.75rem;
  box-shadow: var(--shadow);
  margin-bottom: 3rem;
}

.avatar-wrap {
  width: 112px;
  height: 112px;
  border-radius: 50%;
  overflow: hidden;
  background: var(--accent-soft);
  border: 3px solid var(--border);
  flex-shrink: 0;
}
.avatar-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-text h1 {
  margin: 0 0 0.25rem;
  font-size: 1.65rem;
  font-weight: 700;
  line-height: 1.3;
}
.hero-text .name-en {
  font-size: 1rem;
  font-weight: 500;
  color: var(--muted);
  margin: 0 0 0.5rem;
}
.hero-text .title {
  margin: 0 0 0.35rem;
  color: var(--text);
  font-size: 0.95rem;
}
.hero-text .title-en {
  margin: 0 0 0.75rem;
  color: var(--muted);
  font-size: 0.82rem;
  line-height: 1.5;
}
.tagline {
  display: inline-block;
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 0.82rem;
  padding: 0.25rem 0.65rem;
  border-radius: 999px;
  margin-bottom: 1rem;
}
.bio {
  margin: 0;
  color: var(--muted);
  font-size: 0.95rem;
}
.bio + .bio-en {
  margin-top: 0.65rem;
  font-size: 0.85rem;
  color: var(--muted);
  font-style: italic;
}

.placeholder-hint {
  font-size: 0.75rem;
  color: #a05a00;
  background: #fff8e6;
  border: 1px dashed #e6c35c;
  padding: 0.35rem 0.6rem;
  border-radius: 6px;
  margin-top: 0.75rem;
}

/* Research cards */
.interest-grid {
  display: grid;
  gap: 0.85rem;
}

.interest-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.1rem 1.25rem;
  box-shadow: var(--shadow);
}
.interest-card h3 {
  margin: 0 0 0.15rem;
  font-size: 1rem;
  font-weight: 600;
}
.interest-card .en-label {
  font-size: 0.78rem;
  color: var(--accent);
  margin-bottom: 0.45rem;
}
.interest-card p {
  margin: 0;
  font-size: 0.9rem;
  color: var(--muted);
}

/* Publications */
.pub-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.pub-item {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.1rem 1.25rem;
  margin-bottom: 0.75rem;
  box-shadow: var(--shadow);
}
.pub-item .year {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--accent);
  font-weight: 600;
  margin-bottom: 0.25rem;
}
.pub-item .pub-title {
  font-weight: 600;
  margin: 0 0 0.35rem;
  font-size: 0.95rem;
  line-height: 1.45;
}
.pub-item .authors,
.pub-item .venue {
  margin: 0;
  font-size: 0.85rem;
  color: var(--muted);
}
.pub-item .venue {
  font-style: italic;
}
.pub-links {
  margin-top: 0.5rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 0.85rem;
  font-size: 0.82rem;
}
.pub-note {
  margin-top: 0.5rem;
  font-size: 0.75rem;
  color: #a05a00;
}
.is-pending {
  color: #a05a00;
}

/* Conferences & talks */
.talk-list {
  display: grid;
  gap: 0.85rem;
}

.talk-card {
  display: grid;
  grid-template-columns: 11.5rem minmax(0, 1fr);
  gap: 1rem 1.15rem;
  align-items: start;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.1rem 1.25rem;
  box-shadow: var(--shadow);
}
.talk-card--no-photo {
  grid-template-columns: minmax(0, 1fr);
}

.talk-photo {
  margin: 0;
  border-radius: 8px;
  overflow: hidden;
  background: var(--accent-soft);
  border: 1px solid var(--border);
}
.talk-photo[hidden] {
  display: none;
}
.talk-photo img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  background: var(--accent-soft);
}
.talk-photo figcaption {
  margin: 0;
  padding: 0.35rem 0.55rem 0.45rem;
  font-size: 0.75rem;
  line-height: 1.45;
  color: var(--muted);
}

.talk-type {
  display: inline-block;
  margin: 0 0 0.45rem;
  padding: 0.12rem 0.55rem;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 0.75rem;
  font-weight: 600;
  line-height: 1.5;
}
.talk-name {
  margin: 0;
  font-size: 0.95rem;
  font-weight: 600;
  line-height: 1.45;
}
.talk-name-en {
  margin: 0.1rem 0 0.55rem;
  font-size: 0.78rem;
  color: var(--accent);
  line-height: 1.45;
}
.talk-title {
  margin: 0;
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.45;
}
.talk-title-en {
  margin: 0.15rem 0 0;
  font-size: 0.82rem;
  font-style: italic;
  color: var(--muted);
  line-height: 1.45;
}
.talk-summary {
  margin: 0.55rem 0 0;
  font-size: 0.9rem;
  color: var(--muted);
}
.talk-facts {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 1.15rem;
  margin: 0.7rem 0 0;
}
.talk-facts div {
  display: flex;
  gap: 0.4rem;
  font-size: 0.82rem;
}
.talk-facts dt {
  margin: 0;
  color: var(--muted);
  font-weight: 600;
}
.talk-facts dd {
  margin: 0;
}
.talk-related {
  display: flex;
  flex-wrap: wrap;
  gap: 0.2rem 0.55rem;
  margin: 0.75rem 0 0;
  padding-top: 0.65rem;
  border-top: 1px solid var(--border);
  font-size: 0.82rem;
  color: var(--muted);
  line-height: 1.5;
}
.talk-related-label {
  font-weight: 600;
  color: var(--text);
}
.talk-related a {
  color: var(--accent);
}

/* Education */
.edu-list {
  list-style: none;
  margin: 0;
  padding: 0;
}
.edu-item {
  display: grid;
  grid-template-columns: 5.5rem 1fr;
  gap: 0.5rem 1rem;
  padding: 0.85rem 0;
  border-bottom: 1px solid var(--border);
}
.edu-item:last-child {
  border-bottom: none;
}
.edu-period {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--accent);
  font-weight: 600;
}
.edu-degree {
  margin: 0;
  font-weight: 600;
  font-size: 0.95rem;
}
.edu-school {
  margin: 0.15rem 0 0;
  font-size: 0.85rem;
  color: var(--muted);
}

/* Contact */
.contact-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.35rem 1.5rem;
  box-shadow: var(--shadow);
}
.contact-list {
  list-style: none;
  margin: 0;
  padding: 0;
}
.contact-list li {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 0.75rem;
  padding: 0.45rem 0;
  font-size: 0.95rem;
  border-bottom: 1px solid var(--border);
}
.contact-list li:last-child {
  border-bottom: none;
}
.contact-label {
  min-width: 4.5rem;
  color: var(--muted);
  font-size: 0.85rem;
}
.contact-actions {
  margin-top: 1.1rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
}
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.5rem 1rem;
  border-radius: 8px;
  font-size: 0.9rem;
  font-weight: 550;
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--text);
  text-decoration: none;
  cursor: pointer;
}
.btn:hover {
  text-decoration: none;
  border-color: var(--accent);
  color: var(--accent);
}
.btn-primary {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}
.btn-primary:hover {
  background: #154d63;
  color: #fff;
}
.btn[aria-disabled="true"],
.btn.is-disabled {
  opacity: 0.45;
  pointer-events: none;
}

/* Research tools */
.tool-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 17.5rem), 1fr));
  gap: 0.85rem;
  align-items: stretch;
}

.tool-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.75rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.15rem 1.25rem 1.25rem;
  box-shadow: var(--shadow);
}

.tool-card-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem 0.6rem;
}

.tool-card h3 {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 650;
  line-height: 1.4;
}

.tool-badge {
  display: inline-block;
  padding: 0.12rem 0.55rem;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 0.75rem;
  font-weight: 600;
  line-height: 1.5;
}

.tool-desc {
  margin: 0;
  flex: 1;
  font-size: 0.9rem;
  color: var(--muted);
}

.tool-card .btn {
  margin-top: 0.15rem;
}

.tools-note {
  margin: 1rem 0 0;
  font-size: 0.82rem;
  color: var(--muted);
}

/* Footer */
.site-footer {
  max-width: calc(var(--max) + 4rem);
  margin: 0 auto;
  padding: 1.5rem 1.25rem 2.5rem;
  border-top: 1px solid var(--border);
  color: var(--muted);
  font-size: 0.8rem;
  text-align: center;
}

/* Responsive */
@media (max-width: 560px) {
  .hero {
    grid-template-columns: 1fr;
    justify-items: center;
    text-align: center;
  }
  .hero-text .tagline {
    margin-left: auto;
    margin-right: auto;
  }
  .nav-links {
    font-size: 0.8rem;
    gap: 0.2rem 0.65rem;
    justify-content: flex-end;
  }
  .edu-item {
    grid-template-columns: 1fr;
  }
  .talk-card {
    grid-template-columns: minmax(0, 1fr);
  }
}
