:root {
  --bg: #ffffff;
  --text: #111111;
  --muted: #666666;
  --line: #e8e8e8;
  --soft: #f7f7f7;
  --max: 980px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

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

a {
  color: inherit;
  text-decoration: none;
}

.container {
  width: min(calc(100% - 48px), var(--max));
  margin: 0 auto;
}

/* Header */

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(4px);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 0;
}

.site-name {
  font-size: 1.05rem;
  font-weight: 600;
  letter-spacing: -0.01em;
}

.nav {
  display: flex;
  gap: 28px;
  font-size: 0.95rem;
}

.nav a,
.text-link,
.hero-links a {
  color: var(--muted);
}

.nav a:hover,
.text-link:hover,
.hero-links a:hover {
  color: var(--text);
}

/* Hero */

.hero {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 56px;
  align-items: center;
  padding: 72px 0 56px;
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--muted);
  font-size: 0.9rem;
}

h1 {
  margin: 0;
  font-size: clamp(2.2rem, 5vw, 3.8rem);
  line-height: 1.08;
  letter-spacing: -0.03em;
  font-weight: 600;
}

.page-title {
  font-size: clamp(2rem, 4vw, 3rem);
  margin-bottom: 1.2rem;   /* added spacing under page titles */
}

.hero-credentials {
  margin: 0.85rem 0 1rem;
  font-size: 1rem;
  line-height: 1.45;
  color: #444444;
  max-width: 44rem;
}

.lead {
  max-width: 40rem;
  margin-top: 22px;
  color: var(--muted);
  font-size: 1.06rem;
}

.hero-links {
  display: flex;
  gap: 22px;
  margin-top: 28px;
  font-size: 0.95rem;
  flex-wrap: wrap;
}

.hero-image-wrap {
  justify-self: end;
}

.hero-image {
  display: block;
  width: min(100%, 340px);
  border-radius: 14px;
}

/* Sections */

.section {
  padding: 34px 0;
  border-top: 1px solid var(--line);
}

.section:first-of-type {
  border-top: none;
}

.section-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 16px;
}

h2 {
  margin: 0 0 18px;
  font-size: 1.6rem;
  letter-spacing: -0.02em;
}

h3 {
  margin: 0 0 10px;
  font-size: 1.1rem;
  letter-spacing: -0.01em;
}

p {
  margin: 0;
  max-width: 44rem;
}

p + p {
  margin-top: 14px;
}

.narrow {
  max-width: 760px;
}

/* Tag row */

.tag-row {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 24px;
}

.tag-row a,
.tag-row span {
  display: inline-block;
  border: 1px solid var(--line);
  padding: 6px 10px;
  font-size: 0.9rem;
  color: var(--muted);
  border-radius: 999px;
  background: #ffffff;
}

.tag-row a:hover {
  color: var(--text);
  border-color: #cccccc;
  background: var(--soft);
}

/* Lists */

ul,
ol {
  margin: 0;
  padding-left: 22px;
}

li + li {
  margin-top: 8px;
}

/* Publications */

.publication-list {
  list-style: none;
  padding: 0;
  margin: 0.5rem 0 0;
}

.publication-item {
  margin-bottom: 0.45rem;
}

.pub-title {
  font-weight: 600;
  margin-bottom: 0.08rem;
  line-height: 1.25;
}

.pub-title a {
  text-decoration: none;
  color: inherit;
}

.pub-title a:hover {
  text-decoration: underline;
}

.pub-meta {
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.2;
}

/* Talks */

#talks .talk-item {
  display: flex;
  gap: 30px;
  align-items: flex-start;
  flex-wrap: wrap;
}

#talks iframe {
  max-width: 100%;
  border: 0;
  border-radius: 8px;
}

.talk-description {
  max-width: 500px;
}

.talk-description h3 {
  margin-top: 0;
  margin-bottom: 10px;
}

/* Responsive */

@media (max-width: 800px) {
  .hero {
    grid-template-columns: 1fr;
    gap: 28px;
    padding-top: 48px;
  }

  .hero-image-wrap {
    justify-self: start;
  }

  .nav {
    gap: 16px;
    font-size: 0.88rem;
    flex-wrap: wrap;
  }

  .container {
    width: min(calc(100% - 32px), var(--max));
  }

  .hero-links {
    gap: 16px;
  }
}
