:root {
  --ink: #101828;
  --text: #344054;
  --muted: #667085;
  --paper: #f6f4ef;
  --surface: #ffffff;
  --line: #dedbd2;
  --midnight: #17152f;
  --violet: #5d3fd3;
  --aqua: #0e9384;
  --coral: #e35d4f;
  --sun: #efb331;
  --shadow: 0 28px 80px rgba(16, 24, 40, 0.14);
  --max: 1180px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background:
    linear-gradient(180deg, rgba(23, 21, 47, 0.05), transparent 520px),
    var(--paper);
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.6;
}

img {
  display: block;
  max-width: 100%;
}

a {
  color: var(--violet);
  text-decoration-thickness: 0.08em;
  text-underline-offset: 0.22em;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  max-width: 840px;
  margin-bottom: 1.2rem;
  font-size: clamp(1.55rem, 3.5vw, 3.4rem);
  line-height: 1.05;
  letter-spacing: 0;
}

h2 {
  margin-bottom: 1rem;
  font-size: clamp(2rem, 4vw, 4.4rem);
  line-height: 0.98;
  letter-spacing: 0;
}

h3 {
  margin-bottom: 0.6rem;
  line-height: 1.18;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.8rem max(1.1rem, calc((100vw - var(--max)) / 2));
  background: rgba(246, 244, 239, 0.88);
  border-bottom: 1px solid rgba(222, 219, 210, 0.82);
  backdrop-filter: blur(18px);
}

.identity {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  color: var(--ink);
  font-weight: 900;
  text-decoration: none;
}

.identity span {
  display: grid;
  place-items: center;
  width: 2.55rem;
  height: 2.55rem;
  color: white;
  background: var(--midnight);
  border-radius: 0.55rem;
}

nav {
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

nav a {
  color: var(--ink);
  padding: 0.58rem 0.75rem;
  border-radius: 0.45rem;
  font-size: 0.95rem;
  font-weight: 800;
  text-decoration: none;
}

nav a:hover,
nav a:focus-visible {
  background: white;
}

.menu-button {
  display: none;
  width: 2.7rem;
  height: 2.7rem;
  border: 1px solid var(--line);
  border-radius: 0.45rem;
  background: white;
}

.menu-button span:not(.sr-only) {
  display: block;
  width: 1.1rem;
  height: 2px;
  margin: 4px auto;
  background: var(--ink);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
}

.hero {
  display: grid;
  grid-template-columns: minmax(260px, 0.72fr) minmax(0, 1.28fr);
  align-items: end;
  gap: clamp(2rem, 6vw, 5.5rem);
  max-width: var(--max);
  min-height: calc(100vh - 72px);
  margin: 0 auto;
  padding: 4rem 1.1rem 5.5rem;
}

.hero-media {
  position: relative;
  isolation: isolate;
}

.hero-media::after {
  content: "";
  position: absolute;
  inset: auto -1rem -1rem 1.4rem;
  height: 45%;
  z-index: -1;
  background: var(--coral);
  border-radius: 0.8rem;
}

.hero-media img {
  width: min(100%, 430px);
  aspect-ratio: 4 / 5;
  object-fit: cover;
  border-radius: 0.8rem;
  box-shadow: var(--shadow);
}

.kicker {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  margin-bottom: 1rem;
  color: var(--aqua);
  font-size: 0.78rem;
  font-weight: 950;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.kicker::before {
  content: "";
  width: 2rem;
  height: 3px;
  background: var(--sun);
}

.hero-content > p:not(.kicker) {
  max-width: 760px;
  color: var(--text);
  font-size: clamp(1.1rem, 2vw, 1.35rem);
}

.hero-actions,
.contact-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin: 2rem 0 1rem;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 3rem;
  padding: 0.78rem 1rem;
  border: 1px solid transparent;
  border-radius: 0.42rem;
  font-weight: 900;
  text-decoration: none;
}

.button.primary {
  color: white;
  background: var(--violet);
}

.button.ghost {
  color: var(--ink);
  background: rgba(255, 255, 255, 0.62);
  border-color: var(--line);
}

.social-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  margin-top: 1.1rem;
}

.social-strip a {
  display: inline-flex;
  min-height: 2.35rem;
  align-items: center;
  padding: 0.48rem 0.75rem;
  color: var(--midnight);
  background: white;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-size: 0.9rem;
  font-weight: 850;
  text-decoration: none;
}

.social-strip.dark a {
  color: white;
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.25);
}

.section {
  max-width: var(--max);
  margin: 0 auto;
  padding: 5.8rem 1.1rem;
}

.intro {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
  gap: 1.5rem;
  align-items: end;
  border-top: 1px solid var(--line);
}

.intro p {
  color: var(--text);
}

.stat-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.8rem;
}

.stat-grid article {
  min-height: 150px;
  padding: 1.1rem;
  background: white;
  border: 1px solid var(--line);
  border-radius: 0.7rem;
}

.stat-grid span {
  display: block;
  margin-bottom: 0.4rem;
  color: var(--violet);
  font-size: 2.25rem;
  font-weight: 950;
  line-height: 1;
}

.stat-grid p {
  margin-bottom: 0;
  color: var(--muted);
  font-weight: 800;
}

.section-heading {
  max-width: 850px;
  margin-bottom: 2rem;
}

.section-heading p:last-child {
  max-width: 680px;
  color: var(--text);
  font-size: 1.08rem;
}

.research-section {
  max-width: none;
  background: var(--midnight);
  color: white;
}

.research-section > * {
  max-width: var(--max);
  margin-left: auto;
  margin-right: auto;
}

.research-section .section-heading p:last-child {
  color: rgba(255, 255, 255, 0.72);
}

.research-tools {
  display: grid;
  grid-template-columns: minmax(260px, 0.9fr) minmax(0, 1.1fr);
  gap: 1rem;
  margin-bottom: 1.2rem;
}

.research-tools label {
  display: grid;
  gap: 0.45rem;
  color: rgba(255, 255, 255, 0.78);
  font-weight: 850;
}

.research-tools input {
  width: 100%;
  min-height: 3.1rem;
  padding: 0.8rem 1rem;
  color: white;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.24);
  border-radius: 0.55rem;
  font: inherit;
}

.research-tools input::placeholder {
  color: rgba(255, 255, 255, 0.5);
}

.filter-buttons {
  display: flex;
  flex-wrap: wrap;
  align-content: end;
  gap: 0.5rem;
}

.filter-buttons button {
  min-height: 2.7rem;
  padding: 0.55rem 0.8rem;
  color: white;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 999px;
  cursor: pointer;
  font: inherit;
  font-weight: 850;
}

.filter-buttons button.active {
  color: var(--midnight);
  background: var(--sun);
  border-color: var(--sun);
}

.research-layout {
  display: grid;
  grid-template-columns: 310px minmax(0, 1fr);
  gap: 1rem;
  align-items: start;
}

.research-aside {
  position: sticky;
  top: 5.5rem;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 0.8rem;
}

.research-aside img {
  min-height: 190px;
  object-fit: cover;
}

.research-aside div {
  padding: 1rem;
}

.research-aside ul {
  padding-left: 1.1rem;
  margin: 0;
  color: rgba(255, 255, 255, 0.75);
}

.publication-list {
  display: grid;
  gap: 0.8rem;
}

.publication {
  padding: 1rem;
  background: white;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 0.75rem;
  color: var(--ink);
  box-shadow: 0 16px 34px rgba(0, 0, 0, 0.13);
}

.publication.is-hidden {
  display: none;
}

.pub-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-bottom: 0.7rem;
}

.pub-meta span {
  display: inline-flex;
  align-items: center;
  min-height: 1.85rem;
  padding: 0.25rem 0.55rem;
  color: var(--aqua);
  background: #eaf6f4;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 900;
}

.publication h3 {
  margin-bottom: 0.45rem;
  font-size: 1.1rem;
}

.publication p {
  margin-bottom: 0.45rem;
  color: var(--text);
}

.teaching-cards {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

.teaching-cards article,
.timeline article,
.award-list p {
  background: white;
  border: 1px solid var(--line);
  border-radius: 0.7rem;
}

.teaching-cards article {
  padding: 1.3rem;
}

.teaching-cards p {
  color: var(--text);
  margin-bottom: 0;
}

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

.timeline {
  display: grid;
  gap: 0.8rem;
}

.timeline article {
  display: grid;
  grid-template-columns: 140px 240px minmax(0, 1fr);
  gap: 1rem;
  align-items: start;
  padding: 1rem;
}

.timeline span {
  color: var(--aqua);
  font-weight: 950;
}

.timeline h3,
.timeline p {
  margin-bottom: 0;
}

.timeline p {
  color: var(--text);
}

.awards-section {
  padding-top: 2rem;
}

.award-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.8rem;
}

.award-list p {
  margin: 0;
  padding: 1rem;
  font-weight: 800;
}

.contact-section {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 170px;
  gap: 2rem;
  align-items: center;
  max-width: var(--max);
  margin: 4rem auto;
  padding: 3rem 1.1rem;
  color: white;
  background: linear-gradient(135deg, var(--midnight), #27356e);
  border-radius: 1rem;
}

.contact-section p {
  color: rgba(255, 255, 255, 0.78);
}

.contact-section .button.ghost {
  color: white;
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.28);
}

.contact-section img {
  width: 160px;
  padding: 0.6rem;
  background: white;
  border-radius: 0.7rem;
}

footer {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  max-width: var(--max);
  margin: 0 auto;
  padding: 2rem 1.1rem 3rem;
  color: var(--muted);
  border-top: 1px solid var(--line);
}

footer p {
  margin: 0;
}

@media (max-width: 980px) {
  .hero,
  .intro,
  .research-tools,
  .research-layout,
  .teaching-cards,
  .contact-section {
    grid-template-columns: 1fr;
  }

  .hero {
    align-items: start;
    min-height: auto;
  }

  .research-aside {
    position: static;
  }

  .timeline article {
    grid-template-columns: 120px minmax(0, 1fr);
  }

  .timeline p {
    grid-column: 2;
  }
}

@media (max-width: 720px) {
  .topbar {
    align-items: flex-start;
  }

  .menu-button {
    display: block;
  }

  nav {
    position: absolute;
    inset: 4.35rem 1rem auto 1rem;
    display: none;
    flex-direction: column;
    align-items: stretch;
    padding: 0.75rem;
    background: white;
    border: 1px solid var(--line);
    border-radius: 0.7rem;
    box-shadow: var(--shadow);
  }

  nav.open {
    display: flex;
  }

  .hero,
  .section {
    padding-top: 4rem;
    padding-bottom: 4rem;
  }

  .stat-grid,
  .award-list {
    grid-template-columns: 1fr;
  }

  .timeline article {
    grid-template-columns: 1fr;
  }

  .timeline p {
    grid-column: auto;
  }

  .contact-section {
    margin: 2rem 1rem;
  }
}
