/* Reset and Base */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --primary: #2563eb;
  --primary-dark: #1d4ed8;
  --text: #1f2937;
  --text-light: #6b7280;
  --bg: #ffffff;
  --bg-alt: #f9fafb;
  --border: #e5e7eb;
  --max-width: 800px;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
}

a {
  color: var(--primary);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* Navbar */
.navbar {
  border-bottom: 1px solid var(--border);
  background: var(--bg);
  position: sticky;
  top: 0;
  z-index: 100;
}

.nav-container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 60px;
}

.nav-brand {
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--text);
}

.nav-brand:hover {
  text-decoration: none;
}

.nav-links {
  display: flex;
  gap: 1.5rem;
}

.nav-links a {
  color: var(--text-light);
  font-size: 0.9rem;
  padding: 0.25rem 0;
}

.nav-links a.active,
.nav-links a:hover {
  color: var(--text);
  text-decoration: none;
  border-bottom: 2px solid var(--primary);
}

/* Hero */
.hero {
  padding: 3rem 0 2rem;
  text-align: center;
}

.hero h1 {
  font-size: 2rem;
  margin-bottom: 0.5rem;
}

.hero .subtitle {
  color: var(--text-light);
  font-size: 1rem;
}

/* Sections */
section {
  padding: 2rem 0;
  border-bottom: 1px solid var(--border);
}

section:last-child {
  border-bottom: none;
}

section h2 {
  font-size: 1.3rem;
  margin-bottom: 1rem;
  color: var(--text);
}

/* Contact Links */
.contact-links {
  display: flex;
  gap: 1rem;
  margin-top: 1rem;
  flex-wrap: wrap;
}

.contact-links a {
  padding: 0.4rem 0.8rem;
  border: 1px solid var(--border);
  border-radius: 6px;
  font-size: 0.85rem;
  color: var(--text);
}

.contact-links a:hover {
  background: var(--bg-alt);
  text-decoration: none;
}

/* News */
.news-list {
  list-style: none;
}

.news-list li {
  padding: 0.5rem 0;
  color: var(--text-light);
  font-size: 0.95rem;
}

/* Interests Grid */
.interests-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 0.75rem;
}

.interest-item {
  padding: 0.6rem 1rem;
  background: var(--bg-alt);
  border-radius: 6px;
  font-size: 0.9rem;
  text-align: center;
  border: 1px solid var(--border);
}

/* Publications */
.pub-item {
  padding: 1.2rem 0;
}

.pub-item h3 {
  font-size: 1.1rem;
  margin-bottom: 0.3rem;
}

.pub-authors {
  color: var(--text-light);
  font-size: 0.9rem;
}

.pub-venue {
  color: var(--primary);
  font-size: 0.9rem;
  font-style: italic;
}

.pub-description {
  margin-top: 0.5rem;
  font-size: 0.9rem;
  color: var(--text-light);
}

/* Teaching */
.teaching-grid {
  display: grid;
  gap: 1.5rem;
}

.teaching-item {
  padding: 1rem;
  background: var(--bg-alt);
  border-radius: 8px;
  border: 1px solid var(--border);
}

.teaching-item h3 {
  font-size: 1rem;
  margin-bottom: 0.3rem;
}

.teaching-item p {
  font-size: 0.9rem;
  color: var(--text-light);
}

.teaching-item ul {
  margin-top: 0.5rem;
  margin-left: 1.2rem;
  font-size: 0.9rem;
}

.teaching-item li {
  margin-bottom: 0.3rem;
}

/* Awards */
section.awards ul {
  list-style: disc;
  margin-left: 1.5rem;
}

section.awards li {
  padding: 0.3rem 0;
  font-size: 0.95rem;
}

/* CV Section */
.cv-section {
  margin-bottom: 2rem;
}

.cv-section h3 {
  font-size: 1.1rem;
  margin-bottom: 0.3rem;
}

.cv-section ul {
  margin-left: 1.5rem;
}

.cv-section li {
  margin-bottom: 0.4rem;
  font-size: 0.95rem;
}

/* Notes */
.notes-list {
  display: grid;
  gap: 1.5rem;
}

.note-card {
  padding: 1.2rem;
  background: var(--bg-alt);
  border-radius: 8px;
  border: 1px solid var(--border);
}

.note-card h2 {
  font-size: 1.1rem;
  margin-bottom: 0.3rem;
}

.note-date {
  font-size: 0.85rem;
  color: var(--text-light);
  margin-bottom: 0.5rem;
}

.note-tags {
  display: flex;
  gap: 0.5rem;
  margin-top: 0.75rem;
}

.tag {
  padding: 0.2rem 0.5rem;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 4px;
  font-size: 0.8rem;
  color: var(--text-light);
}

/* Footer */
.footer {
  padding: 2rem 0;
  text-align: center;
  color: var(--text-light);
  font-size: 0.85rem;
  border-top: 1px solid var(--border);
}

/* Responsive */
@media (max-width: 600px) {
  .nav-container {
    flex-direction: column;
    height: auto;
    padding: 0.75rem 1.5rem;
    gap: 0.5rem;
  }

  .nav-links {
    gap: 1rem;
  }

  .hero h1 {
    font-size: 1.5rem;
  }

  .interests-grid {
    grid-template-columns: 1fr 1fr;
  }
}
