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

/* ── Base ───────────────────────────────────────────── */
body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
  font-size: 16px;
  line-height: 1.65;
  color: #1a1a1a;
  background: #fff;
}

a {
  color: #4a6fa5;
  text-decoration: underline;
}

a:hover {
  color: #2c4f82;
}

/* ── Nav ────────────────────────────────────────────── */
nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: 880px;
  margin: 0 auto;
  padding: 1.4rem 2rem;
}

.site-name {
  font-size: 1rem;
  font-weight: 700;
  color: #1a1a1a;
}

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

.nav-links a {
  color: #1a1a1a;
  text-decoration: none;
  font-size: 1rem;
}

.nav-links a:hover {
  text-decoration: underline;
}

/* ── Main container ─────────────────────────────────── */
main {
  max-width: 880px;
  margin: 0 auto;
  padding: 1.5rem 2rem 5rem;
}

/* ── Hero ───────────────────────────────────────────── */
.hero {
  display: flex;
  align-items: flex-start;
  gap: 3.5rem;
  margin-bottom: 3.5rem;
}

.bio {
  flex: 1;
  min-width: 0;
}

.bio h1 {
  font-size: 2.1rem;
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 1rem;
}

.bio p {
  margin-bottom: 0.85rem;
}

.contact-links {
  margin-top: 1.3rem;
  font-size: 0.95rem;
  line-height: 2;
}

.photo {
  flex-shrink: 0;
}

.photo img {
  width: 175px;
  height: 175px;
  border-radius: 50%;
  object-fit: cover;
  display: block;
}

/* ── Content sections ───────────────────────────────── */
.content-section {
  margin-bottom: 2.8rem;
}

.content-section h2 {
  font-size: 0.78rem;
  font-variant: small-caps;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-weight: 700;
  color: #444;
  margin-bottom: 0.45rem;
}

.content-section hr {
  border: none;
  border-top: 1px solid #d0d0d0;
  margin-bottom: 1.2rem;
}

.content-section > p {
  margin-bottom: 0.85rem;
}

/* ── Publication cards ──────────────────────────────── */
.pub-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.2rem;
}

.pub-card {
  border: 1px solid #e0e0e0;
  border-radius: 4px;
  overflow: hidden;
}

.pub-card.expanded {
  grid-column: 1 / -1;
}

.pub-card summary {
  list-style: none;
  cursor: pointer;
}

.pub-card summary::-webkit-details-marker {
  display: none;
}

.pub-card summary img {
  width: 100%;
  height: 180px;
  object-fit: cover;
  display: block;
}

.pub-card-info {
  padding: 0.75rem;
}

.pub-card-title {
  font-weight: 700;
  font-size: 0.9rem;
  margin-bottom: 0.2rem;
}

.pub-card-authors {
  font-size: 0.82rem;
  margin-bottom: 0.15rem;
}

.pub-card-authors .me {
  text-decoration: underline;
}

.pub-card-venue {
  font-size: 0.82rem;
  font-style: italic;
  color: #555;
}

.pub-card-body {
  padding: 0.75rem;
  border-top: 1px solid #e0e0e0;
  font-size: 0.9rem;
  color: #333;
}

.pub-card-body p {
  margin-bottom: 0.5rem;
}

.pub-abstract-label {
  font-size: 0.75rem;
  font-variant: small-caps;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #888;
  margin-bottom: 0.4rem;
}

/* ── Blog index ─────────────────────────────────────── */
.page-title {
  font-size: 2.1rem;
  font-weight: 700;
  margin-bottom: 1.5rem;
}

.blog-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.2rem;
}

.blog-card {
  display: block;
  border: 1px solid #e0e0e0;
  border-radius: 4px;
  padding: 1.2rem;
  text-decoration: none;
  color: inherit;
}

.blog-card:hover {
  border-color: #aaa;
}

.blog-date {
  font-size: 0.82rem;
  color: #888;
  margin-bottom: 0.4rem;
  letter-spacing: 0.03em;
}

.blog-title {
  font-weight: 700;
  font-size: 0.95rem;
  margin-bottom: 0.4rem;
  color: #1a1a1a;
}

.blog-excerpt {
  font-size: 0.87rem;
  color: #444;
  line-height: 1.5;
  margin-bottom: 0.75rem;
}

.blog-read {
  font-size: 0.87rem;
  color: #4a6fa5;
  text-decoration: underline;
}

/* ── Blog post ──────────────────────────────────────── */
.back-link {
  display: inline-block;
  font-size: 0.9rem;
  color: #4a6fa5;
  text-decoration: underline;
  margin-bottom: 1.5rem;
}

.post h1 {
  font-size: 2.1rem;
  font-weight: 700;
  margin-bottom: 1rem;
  line-height: 1.2;
}

.post-body p {
  margin-bottom: 0.9rem;
  line-height: 1.65;
}

/* ── Mobile ─────────────────────────────────────────── */
@media (max-width: 600px) {
  .hero {
    flex-direction: column-reverse;
    gap: 1.5rem;
  }
  .photo img {
    width: 130px;
    height: 130px;
  }
  .pub-grid { grid-template-columns: 1fr; }
  .blog-grid { grid-template-columns: 1fr; }
}
