/* Site-specific styling layered on top of the Academic theme. */
:root {
  --ink: #1b2233;
  --muted: #5d6678;
  --accent: #2f5bea;
  --line: #e4e7ee;
  --soft: #f3f5fa;
}

body { color: var(--ink); }
a { color: var(--accent); }

/* One calm background instead of alternating grey bands. */
.home-section,
.home-section:nth-of-type(even) { background-color: #fff; padding: 46px 0 6px 0; }
.home-section:first-of-type { padding-top: 64px; padding-bottom: 10px; }
.home-section:last-of-type { padding-bottom: 40px; }

/* ---------- Intro ---------- */
#about .portrait-title h1 {
  font-size: 2.7rem;
  font-weight: 700;
  letter-spacing: -0.015em;
  margin: 0 0 0.3rem 0;
  color: var(--ink);
}
.hero-role {
  color: var(--muted);
  font-size: 1.12rem;
  margin: 0 0 1.2rem 0;
}
#about p { font-size: 1.04rem; line-height: 1.72; }

#profile { padding-top: 14px; padding-bottom: 0; }
#profile .portrait {
  width: 270px;
  height: 270px;
  object-position: 50% 46%;
  border: 6px solid #fff;
  box-shadow: 0 0 0 1px var(--line), 0 16px 36px rgba(24, 34, 68, 0.18);
}
#profile .network-icon { display: none; }

.link-pills { margin: 1.3rem 0 0.4rem 0; }
.link-pills a {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin: 0 0.5rem 0.6rem 0;
  padding: 0.42rem 1rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--ink);
  font-size: 0.95rem;
  font-weight: 500;
  background: #fff;
  transition: border-color 0.15s, color 0.15s, box-shadow 0.15s;
}
.link-pills a:hover {
  border-color: var(--accent);
  color: var(--accent);
  text-decoration: none;
  box-shadow: 0 4px 14px rgba(47, 91, 234, 0.15);
}
.link-pills i { color: var(--accent); }

.affiliation-logos {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 18px 36px;
  margin: 1.8rem 0 0 0;
  padding: 1.5rem 0.5rem 0 0.5rem;
  border-top: 1px solid var(--line);
}
.affiliation-logos img { width: auto; margin: 0; display: block; }
.affiliation-logos .logo-cmu { height: 74px; }
.affiliation-logos .logo-mld { height: 50px; }
.affiliation-logos .logo-ntu { height: 58px; }
.affiliation-logos a { opacity: 0.95; transition: opacity 0.15s; }
@media (max-width: 991px) {
  .affiliation-logos { justify-content: flex-start; }
  .affiliation-logos .logo-cmu { height: 54px; }
  .affiliation-logos .logo-mld { height: 36px; }
  .affiliation-logos .logo-ntu { height: 42px; }
}
.affiliation-logos a:hover { opacity: 1; }

/* ---------- Section headings ---------- */
.section-heading h1 {
  position: relative;
  font-size: 1.85rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--ink);
  margin: 0 0 1.6rem 0;
  padding-bottom: 0.55rem;
}
.section-heading h1::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 46px;
  height: 4px;
  border-radius: 2px;
  background: var(--accent);
}

/* ---------- Research cards ---------- */
.pub-row {
  align-items: center;
  margin: 0 0 18px 0;
  padding: 18px 8px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #fff;
  transition: box-shadow 0.2s, transform 0.2s, border-color 0.2s;
}
.pub-row:hover {
  border-color: #cfd6e6;
  box-shadow: 0 14px 34px rgba(24, 34, 68, 0.10);
  transform: translateY(-2px);
}
img.paper-teaser,
video.paper-teaser,
.paper-teaser-empty {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  padding-top: 0;
  border-radius: 10px;
  background: var(--soft);
}
.paper-teaser-empty {
  display: flex;
  align-items: center;
  justify-content: center;
  color: #b3bcd0;
  font-size: 2.6rem;
}
.pub-row .stream-item { margin-bottom: 0; }
.pub-row .article-title { font-size: 1.2rem; line-height: 1.35; font-weight: 700; }
.pub-row .article-title a { color: var(--ink); }
.pub-row .article-title a:hover { color: var(--accent); text-decoration: none; }
.pub-row .stream-meta { margin-top: 0.4rem; font-size: 0.95rem; color: var(--muted); }
.pub-row .stream-meta b, .pub-row .stream-meta strong { color: var(--ink); }
.pub-venue-line { margin: 0.55rem 0 0.35rem 0; }
.pub-venue {
  display: inline-block;
  padding: 0.14rem 0.7rem;
  border-radius: 999px;
  background: var(--soft);
  color: #33405c;
  font-size: 0.82rem;
  font-weight: 600;
}
.pub-note { margin-left: 0.5rem; font-size: 0.82rem; color: var(--muted); }
.pub-row .btn-links .btn {
  border-radius: 999px;
  border-color: #cdd6ee;
  color: var(--accent);
  font-size: 0.82rem;
  line-height: 1.5;
  padding: 0.2rem 0.9rem;
  margin-right: 0.35rem !important;
}
.pub-row .btn-links .btn:hover { background: var(--accent); border-color: var(--accent); color: #fff; }
.pub-tldr { margin-top: 0.5rem; font-size: 0.97rem; line-height: 1.6; color: #39435a; }

@media (max-width: 991px) {
  .pub-thumb { margin-bottom: 14px; }
  #profile .portrait { width: 210px; height: 210px; }
  #about .portrait-title h1 { font-size: 2.1rem; }
}

/* ---------- Teaching / service / awards lists ---------- */
.cv-list { list-style: none; margin: 0; padding: 0; }
.cv-list li {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 1.5rem;
  padding: 0.8rem 0;
  border-bottom: 1px solid var(--line);
}
.cv-list li:first-child { padding-top: 0.2rem; }
.cv-list li:last-child { border-bottom: 0; }
.cv-list .where { display: block; color: var(--muted); font-size: 0.92rem; margin-top: 0.1rem; }
.cv-list .when { color: var(--muted); font-size: 0.92rem; white-space: nowrap; font-variant-numeric: tabular-nums; }

/* ---------- Research statement ---------- */
.research-statement {
  margin: -0.4rem 0 1.8rem 0;
  padding-left: 1.1rem;
  border-left: 3px solid var(--accent);
}
.research-statement p { margin: 0; font-size: 1.06rem; line-height: 1.7; color: #2a3348; }
.research-statement strong { color: var(--ink); }
