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

:root {
  --bg:        #f5efe0;
  --text:      #1a1a1a;
  --link:      #266dc3;
  --secondary: #69603e;
  --rule:      #d6cdb8;
  --section-bg-alt: #ede6d3;
  --max-width: 860px;
}

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: Georgia, 'Times New Roman', Times, serif;
  font-size: 18px;
  line-height: 1.7;
}

a { color: var(--link); text-decoration: none; }
a:hover { text-decoration: underline; }

/* ── Header / Nav ───────────────────────────────────────────────── */
header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--bg);
  border-bottom: 1px solid var(--rule);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 2rem;
  gap: 1rem;
}

.site-title {
  display: flex;
  align-items: baseline;
  gap: 0.6rem;
  flex-shrink: 0;
}

.site-title .name {
  font-size: 1.2rem;
  font-weight: bold;
  letter-spacing: 0.01em;
}

.site-title .tagline {
  font-size: 0.9rem;
  color: var(--secondary);
  font-style: italic;
}

nav {
  display: flex;
  gap: 1.4rem;
  flex-wrap: wrap;
}

nav a {
  font-size: 0.92rem;
  color: var(--text);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-family: 'Helvetica Neue', Arial, sans-serif;
}

nav a:hover { color: var(--link); text-decoration: none; }

.nav-toggle {
  display: none;
  background: none;
  border: none;
  font-size: 1.4rem;
  cursor: pointer;
  color: var(--text);
}

/* ── Sections ───────────────────────────────────────────────────── */
section {
  border-bottom: 1px solid var(--rule);
}

section:nth-child(even) {
  background: var(--section-bg-alt);
}

.section-inner,
.about-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 3.5rem 2rem;
}

/* ── About ──────────────────────────────────────────────────────── */
.about-inner {
  display: flex;
  gap: 3rem;
  align-items: flex-start;
}

.photo-col {
  flex-shrink: 0;
}

.profile-photo {
  width: 200px;
  height: 200px;
  object-fit: cover;
  border-radius: 4px;
  border: 1px solid var(--rule);
  display: block;
}

/* Placeholder if photo missing */
.profile-photo[src="assets/photo.jpg"]:not([complete]) {
  background: var(--rule);
}

.bio-col h1 {
  font-size: 2rem;
  margin-bottom: 1rem;
  font-weight: normal;
}

.bio-col p + p {
  margin-top: 0.9rem;
}

.contact-links {
  margin-top: 1.4rem;
  font-size: 0.95rem;
  font-family: 'Helvetica Neue', Arial, sans-serif;
}

.contact-links a { color: var(--link); }
.contact-links .sep { margin: 0 0.4rem; color: var(--secondary); }

/* ── Research / Teaching ────────────────────────────────────────── */
.section-inner h2 {
  font-size: 1.6rem;
  font-weight: normal;
  margin-bottom: 1.2rem;
  color: var(--secondary);
  border-bottom: 1px solid var(--rule);
  padding-bottom: 0.4rem;
}

.section-inner p + p { margin-top: 0.9rem; }

/* ── Footer ─────────────────────────────────────────────────────── */
footer {
  text-align: center;
  padding: 2rem;
  font-size: 0.85rem;
  color: var(--secondary);
  font-family: 'Helvetica Neue', Arial, sans-serif;
}

footer a { color: var(--secondary); }
footer a:hover { color: var(--link); }
footer p + p { margin-top: 0.4rem; }
.copy { font-size: 0.8rem; }

/* ── Mobile ─────────────────────────────────────────────────────── */
@media (max-width: 640px) {
  header { flex-wrap: wrap; padding: 0.75rem 1.2rem; }

  nav {
    display: none;
    width: 100%;
    flex-direction: column;
    gap: 0.8rem;
    padding: 0.8rem 0;
  }

  nav.open { display: flex; }

  .nav-toggle { display: block; }

  .about-inner {
    flex-direction: column;
    gap: 1.5rem;
    padding: 2rem 1.2rem;
  }

  .profile-photo { width: 140px; height: 140px; }

  .section-inner { padding: 2rem 1.2rem; }
}
