:root {
  --bg: #f8f9fd;
  --surface: rgba(255, 255, 255, 0.94);
  --text: #20213a;
  --muted: #62667e;
  --accent: #5757e9;
  --accent-2: #7d67f3;
  --pink: #ef5da8;
  --border: rgba(87, 87, 233, 0.12);
  --accent-soft: rgba(87, 87, 233, 0.07);
  --shadow: 0 18px 50px rgba(45, 48, 90, 0.10), 0 3px 12px rgba(45, 48, 90, 0.04);
  --shadow-soft: 0 6px 24px rgba(45, 48, 90, 0.06);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

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

.background {
  position: fixed;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
  z-index: -1;
}

.glow {
  position: absolute;
  border-radius: 999px;
  filter: blur(90px);
  opacity: 0.42;
}

.glow-a {
  width: 520px;
  height: 520px;
  right: -150px;
  top: -140px;
  background: #d9e0ff;
}

.glow-b {
  width: 420px;
  height: 420px;
  left: -160px;
  top: 52%;
  background: #ffe1ef;
}

.glow-c {
  width: 360px;
  height: 360px;
  right: 8%;
  bottom: -160px;
  background: #e8dcff;
}

.page {
  width: min(920px, calc(100% - 40px));
  margin: 0 auto;
  padding: 54px 0 64px;
}

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-soft);
  backdrop-filter: blur(12px);
}

.hero {
  position: relative;
  display: flex;
  align-items: center;
  gap: 42px;
  padding: 42px 46px;
  border-radius: 28px;
  overflow: hidden;
  box-shadow: var(--shadow);
}

.hero-accent {
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  height: 3px;
  background: linear-gradient(90deg, #5a5ff3 0%, #ef5da8 55%, #8f7df5 100%);
}

.avatar-wrap {
  flex: 0 0 auto;
  width: 166px;
  height: 166px;
  border-radius: 50%;
  padding: 4px;
  background: linear-gradient(135deg, #666bf1, #9a84ff);
  box-shadow: 0 10px 28px rgba(87, 87, 233, 0.16);
}

.avatar,
.avatar-fallback {
  width: 100%;
  height: 100%;
  border-radius: 50%;
}

.avatar {
  display: block;
  object-fit: cover;
  border: 4px solid #fff;
}

.avatar-fallback {
  display: none;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 46px;
  font-weight: 700;
  background: linear-gradient(135deg, #4f55db, #a06fec);
  border: 4px solid #fff;
}

.hero-copy {
  min-width: 0;
  flex: 1;
}

.hero h1 {
  margin: 0 0 6px;
  font-size: clamp(32px, 5vw, 44px);
  line-height: 1.15;
  letter-spacing: -1.2px;
  background: linear-gradient(120deg, #23243e, #4f55db);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.tagline {
  margin: 0 0 20px;
  color: var(--muted);
  font-size: 15px;
}

.links {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 8px 15px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--accent-soft);
  color: var(--accent);
  text-decoration: none;
  font-size: 13px;
  font-weight: 600;
  transition: 0.2s ease;
}

.pill svg {
  width: 15px;
  height: 15px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.pill:nth-child(3) svg {
  fill: currentColor;
  stroke: none;
}

.pill:hover {
  transform: translateY(-2px);
  color: #fff;
  background: var(--accent);
  border-color: var(--accent);
  box-shadow: 0 8px 18px rgba(87, 87, 233, 0.22);
}

.about {
  margin-top: 36px;
  padding: 31px 39px;
  border-radius: 20px;
}

.about p {
  margin: 0 0 14px;
  color: var(--muted);
  font-size: 14.5px;
}

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

.about strong {
  color: var(--text);
  font-weight: 700;
}

.about a {
  text-decoration: none;
  font-weight: 500;
}

.about a:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}

.publications {
  margin-top: 37px;
}

.section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 22px;
  padding: 0 8px;
}

.section-head > div {
  display: flex;
  align-items: baseline;
  gap: 13px;
  flex-wrap: wrap;
}

.section-head h2 {
  margin: 0;
  font-size: 27px;
  letter-spacing: -0.5px;
}

.section-note {
  padding: 4px 11px;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--muted);
  font-size: 12px;
}

.all-pubs {
  display: inline-flex;
  align-items: center;
  padding: 8px 17px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--accent-soft);
  text-decoration: none;
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
}

.all-pubs:hover {
  background: var(--accent);
  color: #fff;
}

.paper {
  display: flex;
  gap: 24px;
  padding: 27px;
  border-radius: 20px;
  transition: 0.2s ease;
}

.paper:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow);
}

.paper-thumb {
  flex: 0 0 235px;
  height: 150px;
  border-radius: 11px;
  overflow: hidden;
  background: linear-gradient(135deg, #eef0ff, #f8ebf5);
  border: 1px solid rgba(87, 87, 233, 0.08);
}

.paper-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}


.paper-fallback {
  display: none;
  width: 100%;
  height: 100%;
  padding: 20px;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  text-align: center;
  background:
    radial-gradient(circle at 25% 30%, rgba(98, 104, 255, 0.26), transparent 38%),
    radial-gradient(circle at 78% 72%, rgba(236, 92, 168, 0.20), transparent 35%),
    linear-gradient(135deg, #f5f6ff, #fff7fb);
}

.paper-fallback span {
  color: var(--accent);
  font-size: 27px;
  font-weight: 700;
}

.paper-fallback small {
  margin-top: 4px;
  color: var(--muted);
}

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

.paper h3 {
  margin: 0 0 8px;
  font-size: 17px;
  line-height: 1.42;
  letter-spacing: -0.2px;
}

.authors {
  margin: 0 0 8px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}

.authors strong {
  color: var(--accent);
}

.venue-row {
  margin-bottom: 10px;
}

.venue {
  display: inline-flex;
  padding: 3px 11px;
  border-radius: 999px;
  color: var(--accent);
  background: var(--accent-soft);
  border: 1px solid var(--border);
  font-size: 11.5px;
  font-weight: 700;
}

.paper-desc {
  margin: 0 0 12px;
  color: var(--muted);
  font-size: 13px;
}

.paper-links {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.paper-link {
  display: inline-flex;
  padding: 4px 11px;
  border-radius: 999px;
  background: var(--accent-soft);
  border: 1px solid var(--border);
  color: var(--accent);
  font-size: 11.5px;
  font-weight: 600;
}

.paper-link.muted {
  color: #777b91;
}

footer {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  margin-top: 38px;
  padding: 0 8px;
  color: #8a8da2;
  font-size: 12px;
}

@media (max-width: 760px) {
  .page {
    width: min(100% - 24px, 920px);
    padding-top: 24px;
  }

  .hero {
    flex-direction: column;
    text-align: center;
    gap: 24px;
    padding: 36px 24px;
  }

  .avatar-wrap {
    width: 142px;
    height: 142px;
  }

  .links {
    justify-content: center;
  }

  .about {
    padding: 26px 24px;
  }

  .section-head {
    align-items: flex-start;
  }

  .paper {
    flex-direction: column;
  }

  .paper-thumb {
    width: 100%;
    flex-basis: auto;
    height: auto;
    aspect-ratio: 16 / 9;
  }

  footer {
    flex-direction: column;
    text-align: center;
  }
}

@media (max-width: 520px) {
  .section-head {
    flex-direction: column;
  }

  .hero h1 {
    font-size: 34px;
  }

  .pill {
    padding: 8px 13px;
  }
}
