/* 10-academic-cv — Academic researcher profile */
:root {
  --bg: #F8FAFC;
  --white: #FFFFFF;
  --text: #1E293B;
  --muted: #64748B;
  --blue: #2563EB;
  --orange: #F97316;
  --border: #E2E8F0;
  --font-display: "EB Garamond", Georgia, serif;
  --font-body: "Crimson Text", Georgia, serif;
  --max-width: 900px;
  --transition: 0.2s ease;
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1.125rem;
  line-height: 1.7;
  color: var(--text);
  background: var(--bg);
}

a {
  color: var(--blue);
  text-decoration: none;
  transition: color var(--transition);
}

a:hover, a:focus-visible {
  color: var(--orange);
  text-decoration: underline;
}

a:focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 2px;
}

.skip-link {
  position: absolute;
  top: -100%;
  left: 1rem;
  background: var(--blue);
  color: var(--white);
  padding: 0.5rem 1rem;
  z-index: 100;
}

.skip-link:focus { top: 1rem; }

/* Header */
.site-header {
  background: var(--white);
  border-bottom: 1px solid var(--border);
  padding: 1.5rem 2rem;
}

.header-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
}

.site-title {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 600;
  margin: 0;
}

.site-title a {
  color: var(--text);
  text-decoration: none;
}

.site-title a:hover { color: var(--blue); }

.main-nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  gap: 1.5rem;
}

.main-nav a {
  font-size: 1rem;
  color: var(--muted);
  text-decoration: none;
  padding-bottom: 2px;
  border-bottom: 2px solid transparent;
  transition: all var(--transition);
}

.main-nav a:hover,
.main-nav a:focus-visible,
.main-nav a[aria-current="page"] {
  color: var(--blue);
  border-bottom-color: var(--blue);
}

/* Layout */
.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 2rem;
}

main {
  padding: 2.5rem 0 4rem;
}

/* Profile */
.profile-header {
  display: grid;
  gap: 2rem;
  margin-bottom: 2.5rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid var(--border);
}

@media (min-width: 640px) {
  .profile-header {
    grid-template-columns: 120px 1fr;
    align-items: start;
  }
}

.avatar {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--blue) 0%, #1D4ED8 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
  font-family: var(--font-display);
  font-size: 2.5rem;
  font-weight: 600;
}

.profile-info h1 {
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 4vw, 2.25rem);
  font-weight: 600;
  margin: 0 0 0.25rem;
}

.profile-info .title {
  font-size: 1.125rem;
  color: var(--muted);
  margin: 0 0 0.75rem;
}

.profile-info .affiliation {
  margin: 0;
  font-size: 1rem;
}

.profile-links {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-top: 1rem;
}

.profile-links a {
  font-size: 0.9375rem;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}

/* Sections */
.section {
  margin-bottom: 2.5rem;
}

.section h2 {
  font-family: var(--font-display);
  font-size: 1.375rem;
  font-weight: 600;
  color: var(--blue);
  margin: 0 0 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid var(--orange);
  display: inline-block;
}

.section p { margin: 0 0 1rem; }

.interest-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.interest-tags li {
  background: var(--white);
  border: 1px solid var(--border);
  padding: 0.35rem 0.85rem;
  font-size: 0.9375rem;
  border-radius: 4px;
}

/* News list */
.news-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.news-list li {
  padding: 0.75rem 0;
  border-bottom: 1px solid var(--border);
  display: grid;
  gap: 0.25rem;
}

@media (min-width: 540px) {
  .news-list li {
    grid-template-columns: 100px 1fr;
    gap: 1rem;
  }
}

.news-list li:last-child { border-bottom: none; }

.news-date {
  font-size: 0.875rem;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}

/* Publications */
.pub-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.pub-item {
  padding: 1.25rem 0;
  border-bottom: 1px solid var(--border);
}

.pub-item:last-child { border-bottom: none; }

.pub-item .pub-number {
  font-size: 0.8125rem;
  color: var(--orange);
  font-weight: 600;
  margin-bottom: 0.25rem;
}

.pub-item .pub-title {
  font-family: var(--font-display);
  font-size: 1.125rem;
  font-weight: 600;
  margin: 0 0 0.5rem;
  line-height: 1.4;
}

.pub-item .pub-authors {
  margin: 0 0 0.35rem;
  font-size: 1rem;
}

.pub-item .pub-authors strong {
  font-weight: 600;
  color: var(--text);
}

.pub-item .pub-venue {
  font-style: italic;
  color: var(--muted);
  margin: 0 0 0.5rem;
  font-size: 0.9375rem;
}

.pub-item .pub-links {
  font-size: 0.875rem;
}

.pub-item .pub-links a {
  margin-right: 1rem;
}

/* Tables */
.data-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--white);
  border: 1px solid var(--border);
  font-size: 1rem;
  margin-bottom: 2rem;
}

.data-table caption {
  font-family: var(--font-display);
  font-size: 1.125rem;
  font-weight: 600;
  text-align: left;
  padding: 0.75rem 1rem;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
}

.data-table th,
.data-table td {
  padding: 0.75rem 1rem;
  text-align: left;
  border-bottom: 1px solid var(--border);
}

.data-table th {
  font-family: var(--font-display);
  font-weight: 600;
  background: var(--bg);
  color: var(--text);
  font-size: 0.9375rem;
}

.data-table tbody tr:last-child td { border-bottom: none; }

.data-table tbody tr:hover {
  background: rgba(37, 99, 235, 0.04);
}

/* Office hours card */
.info-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-left: 4px solid var(--blue);
  padding: 1.25rem 1.5rem;
  margin-bottom: 2rem;
}

.info-card h3 {
  font-family: var(--font-display);
  font-size: 1.125rem;
  margin: 0 0 0.75rem;
  color: var(--blue);
}

.info-card p {
  margin: 0.25rem 0;
  font-size: 1rem;
}

.info-card .note {
  font-size: 0.9375rem;
  color: var(--muted);
  margin-top: 0.75rem;
}

/* Page title */
.page-title {
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 4vw, 2rem);
  font-weight: 600;
  margin: 0 0 0.5rem;
}

.page-subtitle {
  color: var(--muted);
  margin: 0 0 2rem;
}

/* Footer */
.site-footer {
  background: var(--white);
  border-top: 1px solid var(--border);
  padding: 1.5rem 2rem;
  text-align: center;
  font-size: 0.9375rem;
  color: var(--muted);
}

.site-footer p { margin: 0.25rem 0; }

.footer-nav {
  margin-bottom: 0.75rem;
}

.footer-nav a {
  color: var(--muted);
  margin: 0 0.75rem;
  text-decoration: none;
}

.footer-nav a:hover { color: var(--blue); }

@media (max-width: 640px) {
  .container { padding: 0 1rem; }
  .data-table { font-size: 0.875rem; }
  .data-table th, .data-table td { padding: 0.5rem; }
}
