@import url("https://fonts.googleapis.com/css2?family=JetBrains+Mono:wght@400;500&family=Poppins:wght@400;500;600&family=Source+Serif+4:opsz,wght@8..60,400;8..60,500;8..60,600&display=swap");

:root {
  --bg: #f7f7f2;
  --grid: rgba(52, 62, 72, 0.11);
  --paper: rgba(255, 255, 255, 0.64);
  --text: #1a1c1f;
  --muted: #636a73;
  --light: #8b929b;
  --line: #d6d8d3;
  --tag: #eef3ef;
  --tag-line: #ccd9d1;
  --accent: #2563eb;
  --accent-2: #1d4ed8;
  --thu-purple: #660874;
  --thu-purple-hover: #4f065c;
  --award: #a4511d;
  --shadow: 0 16px 40px rgba(41, 52, 61, 0.07);
  --max-width: 940px;
  --font-serif: "Source Serif 4", Georgia, serif;
  --font-sans: "Poppins", "Segoe UI", sans-serif;
  --font-mono: "JetBrains Mono", "Courier New", monospace;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 72px;
}

body {
  margin: 0;
  color: var(--text);
  font-family: var(--font-serif);
  font-size: 16px;
  line-height: 1.72;
  background-color: var(--bg);
  background-image:
    radial-gradient(circle, var(--grid) 1px, transparent 1px),
    linear-gradient(180deg, rgba(255, 255, 255, 0.55) 0%, rgba(255, 255, 255, 0) 320px);
  background-position: 0 0, 0 0;
  background-size: 24px 24px, 100% 100%;
  min-height: 100vh;
}

a {
  color: var(--accent);
  text-decoration: none;
  text-underline-offset: 3px;
  transition: color 0.15s ease, text-decoration-color 0.15s ease;
}

a:hover {
  color: var(--accent-2);
  text-decoration: underline;
}

a.thu-link {
  color: var(--thu-purple);
  font-weight: 600;
}

a.thu-link:hover {
  color: var(--thu-purple-hover);
}

img {
  max-width: 100%;
}

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 54px 32px 72px;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.site-header {
  margin-bottom: 16px;
}

.site-header h1 {
  margin: 0 0 8px;
  font-family: var(--font-sans);
  font-size: 3.65rem;
  font-weight: 500;
  line-height: 1.05;
  letter-spacing: 0;
}

.tagline {
  margin: 0;
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: 0.78rem;
  line-height: 1.85;
}

.tagline span {
  color: var(--light);
  margin: 0 7px;
}

.site-nav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 8px;
  margin: 0 0 34px;
  padding: 8px 11px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: rgba(247, 247, 242, 0.91);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.site-nav a {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 4px 8px;
  border-radius: 4px;
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: 0.69rem;
  line-height: 1.2;
}

.site-nav a:hover {
  color: var(--accent);
  background: rgba(255, 255, 255, 0.72);
  text-decoration: none;
}

section {
  margin: 0 0 38px;
}

.section-title {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 8px 14px;
  margin: 0 0 12px;
  font-family: var(--font-sans);
  font-size: 1.85rem;
  font-weight: 500;
  line-height: 1.2;
  letter-spacing: 0;
}

.section-link {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 400;
}

.bio-section {
  display: grid;
  grid-template-columns: 172px 1fr;
  gap: 28px;
  align-items: start;
}

.bio-avatar {
  width: 172px;
}

.bio-avatar img {
  display: block;
  width: 166px;
  height: 166px;
  object-fit: cover;
  border: 2px solid var(--line);
  border-radius: 50%;
  background: #fff;
  box-shadow: var(--shadow);
}

.bio-text p {
  margin: 0 0 12px;
  font-size: 0.97rem;
}

.bio-text p:last-of-type {
  margin-bottom: 0;
}

.bio-more {
  display: none;
  margin-top: 10px;
  color: var(--muted);
  font-size: 0.93rem;
  line-height: 1.68;
}

.bio-more.is-expanded {
  display: block;
}

.bio-more p {
  margin: 0;
}

.bio-toggle {
  display: inline-flex;
  align-items: center;
  margin-top: 10px;
  min-height: 26px;
  padding: 3px 8px;
  border: 1px solid var(--tag-line);
  border-radius: 4px;
  background: var(--tag);
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: 0.68rem;
  line-height: 1.25;
  cursor: pointer;
}

.bio-toggle:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.badge-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}

.badge,
.date-tag {
  display: inline-flex;
  align-items: center;
  min-height: 22px;
  padding: 3px 8px;
  border: 1px solid var(--tag-line);
  border-radius: 4px;
  background: var(--tag);
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: 0.66rem;
  line-height: 1.25;
  white-space: nowrap;
}

.social-links {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin: 4px 0 38px;
}

.social-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: 34px;
  padding: 6px 13px;
  border: 1.5px solid var(--line);
  border-radius: 5px;
  background: rgba(255, 255, 255, 0.6);
  color: var(--text);
  font-family: var(--font-mono);
  font-size: 0.74rem;
  line-height: 1.25;
}

.social-btn:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: rgba(255, 255, 255, 0.86);
  text-decoration: none;
}

.social-btn img {
  width: 15px;
  height: 15px;
  object-fit: contain;
  flex: 0 0 auto;
}

.social-btn .icon-round {
  border-radius: 50%;
}

.content-panel {
  border: 1px solid var(--line);
  border-radius: 7px;
  background: var(--paper);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.6) inset;
}

.news-panel {
  padding: 7px 10px 8px;
}

.news-list {
  display: flex;
  flex-direction: column;
  gap: 1px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.news-item {
  display: flex;
  align-items: baseline;
  gap: 10px;
  padding: 5px 6px;
  border-radius: 4px;
  font-size: 0.88rem;
  line-height: 1.46;
  transition: background 0.12s ease;
}

.news-item:hover {
  background: rgba(28, 45, 55, 0.045);
}

.news-hidden {
  display: none;
}

.news-list.is-expanded .news-hidden {
  display: flex;
}

.toggle-btn {
  width: 100%;
  margin-top: 8px;
  padding: 8px 0 2px;
  border: 0;
  border-top: 1px dashed var(--line);
  background: transparent;
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: 0.7rem;
  line-height: 1.4;
  cursor: pointer;
}

.toggle-btn:hover {
  color: var(--accent);
}

.pub-list {
  display: flex;
  flex-direction: column;
  gap: 0;
  margin: 0;
  padding: 0;
  list-style: none;
}

.pub-item {
  display: grid;
  grid-template-columns: 204px 1fr;
  gap: 18px;
  align-items: start;
  padding: 16px 0;
  border-top: 1px solid var(--line);
}

.pub-item:first-child {
  border-top: 0;
  padding-top: 2px;
}

.pub-thumb {
  display: block;
  width: 204px;
  border-radius: 6px;
  color: inherit;
}

.pub-thumb img {
  display: block;
  width: 204px;
  max-height: 142px;
  object-fit: contain;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  transition: transform 0.22s ease, border-color 0.22s ease, box-shadow 0.22s ease;
}

.pub-thumb:hover img {
  transform: translateY(-2px);
  border-color: rgba(23, 107, 135, 0.45);
  box-shadow: var(--shadow);
}

.pub-body {
  min-width: 0;
}

.pub-body h3 {
  margin: 0 0 5px;
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.42;
}

.pub-body h3 a {
  color: var(--text);
}

.pub-body h3 a:hover {
  color: var(--accent);
  text-decoration: none;
}

.pub-venue,
.pub-authors {
  margin: 0 0 4px;
  color: var(--muted);
  font-size: 0.86rem;
  line-height: 1.5;
}

.pub-venue {
  font-style: italic;
}

.pub-venue span {
  color: var(--award);
  font-style: normal;
  font-weight: 600;
}

.pub-authors strong {
  color: var(--text);
  font-weight: 600;
  text-decoration: underline;
  text-decoration-style: dotted;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

.pub-links {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 8px;
}

.pub-links a {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 3px 9px;
  border: 1px solid var(--tag-line);
  border-radius: 4px;
  background: var(--tag);
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: 0.7rem;
  line-height: 1.25;
}

.pub-links a:hover {
  border-color: var(--accent);
  color: var(--accent);
  text-decoration: none;
}

.timeline-list {
  margin: 0;
  padding: 5px 10px;
  list-style: none;
}

.timeline-item {
  display: grid;
  grid-template-columns: 120px 92px 1fr;
  gap: 12px;
  align-items: center;
  padding: 12px 4px;
  border-top: 1px solid var(--line);
}

.timeline-item:first-child {
  border-top: 0;
}

.timeline-logo {
  display: block;
  justify-self: center;
  width: 72px;
  max-height: 72px;
  object-fit: contain;
  border-radius: 4px;
}

.date-col {
  color: var(--light);
  font-family: var(--font-mono);
  font-size: 0.66rem;
  line-height: 1.45;
}

.timeline-item h3 {
  margin: 0 0 2px;
  font-size: 0.98rem;
  font-weight: 600;
  line-height: 1.35;
}

.timeline-item p {
  margin: 0;
  color: var(--muted);
  font-size: 0.86rem;
  line-height: 1.55;
}

.timeline-item .muted {
  margin-top: 4px;
  color: var(--light);
}

.activity-panel {
  padding: 13px 16px;
}

.activity-panel p {
  margin: 0;
  color: var(--muted);
  font-size: 0.94rem;
}

.site-footer {
  margin-top: 48px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
  color: var(--light);
  font-family: var(--font-mono);
  font-size: 0.72rem;
  line-height: 1.6;
  text-align: center;
}

.site-footer p {
  margin: 0 0 4px;
}

@media (max-width: 760px) {
  .container {
    padding: 34px 18px 58px;
  }

  .site-nav {
    margin-bottom: 28px;
    padding: 7px 8px;
  }

  .site-nav a {
    min-height: 26px;
    padding: 3px 6px;
    font-size: 0.66rem;
  }

  .site-header h1 {
    font-size: 2.65rem;
  }

  .bio-section {
    grid-template-columns: 1fr;
    justify-items: center;
    gap: 18px;
    text-align: center;
  }

  .bio-avatar {
    width: 132px;
    position: static;
  }

  .badge-row,
  .social-links {
    justify-content: center;
  }

  .section-title {
    font-size: 1.58rem;
  }

  .news-item {
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
  }

  .news-list.is-expanded .news-hidden {
    display: flex;
  }

  .pub-item {
    grid-template-columns: 1fr;
    gap: 10px;
    padding: 17px 0;
  }

  .pub-thumb,
  .pub-thumb img {
    width: 100%;
  }

  .pub-thumb img {
    max-height: none;
  }

  .timeline-item {
    grid-template-columns: 112px 1fr;
  }

  .timeline-logo {
    display: none;
  }
}

@media (max-width: 460px) {
  .tagline span {
    margin: 0 4px;
  }

  .timeline-item {
    grid-template-columns: 1fr;
    gap: 4px;
  }

  .date-col {
    color: var(--muted);
  }

  .social-btn {
    flex: 1 1 calc(50% - 8px);
  }
}
