:root {
  --ink: #18201f;
  --muted: #66716d;
  --paper: #f6f1e7;
  --paper-soft: #fffaf1;
  --night: #0d1414;
  --teal: #2f928b;
  --teal-dark: #17635f;
  --gold: #d99b39;
  --red: #b64b3f;
  --line: rgba(24, 32, 31, 0.14);
  --shadow: 0 22px 55px rgba(18, 27, 25, 0.14);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background:
    linear-gradient(90deg, rgba(47, 146, 139, 0.08) 1px, transparent 1px),
    linear-gradient(180deg, rgba(217, 155, 57, 0.08) 1px, transparent 1px),
    var(--paper);
  background-size: 80px 80px;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
  line-height: 1.65;
}

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

a {
  color: var(--teal-dark);
  text-decoration-color: rgba(47, 146, 139, 0.35);
  text-decoration-thickness: 0.08em;
  text-underline-offset: 0.2em;
}

a:hover {
  color: #0b4d4a;
}

.site-shell {
  min-height: 100vh;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  color: #fffaf1;
  background: rgba(13, 20, 20, 0.9);
  border-bottom: 1px solid rgba(255, 250, 241, 0.12);
  backdrop-filter: blur(16px);
}

.nav {
  width: min(1180px, calc(100% - 40px));
  margin: 0 auto;
  min-height: 70px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand {
  color: #fffaf1;
  text-decoration: none;
  display: inline-grid;
  gap: 2px;
  line-height: 1;
}

.brand strong {
  font-size: 1rem;
  letter-spacing: 0;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.nav-links a {
  color: rgba(255, 250, 241, 0.78);
  text-decoration: none;
  font-size: 0.93rem;
  padding: 8px 12px;
  border-radius: 999px;
}

.nav-links a:hover,
.nav-links a[aria-current="page"] {
  color: #fffaf1;
  background: rgba(255, 250, 241, 0.12);
}

.hero {
  position: relative;
  min-height: 600px;
  color: #fffaf1;
  background: linear-gradient(135deg, #101817 0%, #16231f 58%, #283d33 100%);
  display: grid;
  align-items: center;
  overflow: hidden;
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(90deg, rgba(255, 250, 241, 0.05) 1px, transparent 1px),
    linear-gradient(180deg, rgba(255, 250, 241, 0.04) 1px, transparent 1px);
  background-size: 88px 88px;
  opacity: 0.42;
}

.hero-inner {
  position: relative;
  z-index: 1;
  width: min(1180px, calc(100% - 40px));
  margin: 0 auto;
  padding: 86px 0;
}

.eyebrow {
  margin: 0 0 18px;
  color: #f0c877;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

h1,
h2,
h3 {
  line-height: 1.04;
  letter-spacing: 0;
}

.hero h1 {
  max-width: none;
  margin: 0;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(4rem, 7.2vw, 6.45rem);
  font-weight: 700;
  white-space: nowrap;
}

.hero-copy {
  max-width: 720px;
  margin: 26px 0 0;
  color: rgba(255, 250, 241, 0.88);
  font-size: clamp(1.08rem, 2vw, 1.35rem);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 34px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 12px 18px;
  border: 1px solid transparent;
  border-radius: 999px;
  text-decoration: none;
  font-weight: 800;
}

.button.primary {
  color: #0d1414;
  background: #f0c877;
}

.button.primary:hover {
  color: #0d1414;
  background: #ffd98a;
}

.button.secondary {
  color: #fffaf1;
  border-color: rgba(255, 250, 241, 0.35);
  background: rgba(255, 250, 241, 0.08);
}

.button.secondary:hover {
  color: #fffaf1;
  background: rgba(255, 250, 241, 0.16);
}

.hero-stats {
  width: min(1180px, calc(100% - 40px));
  margin: 34px auto 0;
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}

.stat-card {
  min-height: 126px;
  padding: 22px;
  color: #fffaf1;
  background: rgba(13, 20, 20, 0.92);
  border: 1px solid rgba(255, 250, 241, 0.14);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.stat-card strong {
  display: block;
  color: #f0c877;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.95rem;
  line-height: 1;
}

.stat-card span {
  display: block;
  margin-top: 10px;
  color: rgba(255, 250, 241, 0.72);
  font-size: 0.94rem;
}

.stat-card a {
  color: #fffaf1;
  text-decoration-color: rgba(255, 250, 241, 0.35);
}

.social-strip {
  width: min(1180px, calc(100% - 40px));
  margin: 34px auto 0;
  padding: 20px 22px;
  display: flex;
  align-items: center;
  gap: 18px;
  flex-wrap: wrap;
  background: #fffaf1;
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 16px 40px rgba(24, 32, 31, 0.08);
}

.social-title {
  margin: 0;
  color: #111;
  font-size: clamp(1.35rem, 3vw, 1.85rem);
  font-weight: 800;
}

.social-icons {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.social-icon {
  width: 42px;
  height: 42px;
  display: inline-grid;
  place-items: center;
  color: #fff;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 900;
  line-height: 1;
  box-shadow: 0 10px 22px rgba(24, 32, 31, 0.12);
}

.social-icon:hover {
  color: #fff;
  transform: translateY(-1px);
}

.social-icon.orcid {
  color: #fff;
  background: #a6ce39;
  border-radius: 50%;
  font-size: 1.25rem;
  font-family: Arial, sans-serif;
}

.social-icon.scholar {
  background: #4f7fe8;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.9rem;
}

.social-icon.arxiv {
  width: 76px;
  background: #b31b1b;
  font-size: 0.95rem;
}

.social-icon.linkedin {
  background: #0a77a8;
  font-size: 1.45rem;
}

.social-icon.bluesky {
  background: #1385fe;
  border-radius: 50% 50% 42% 42%;
  font-size: 0.9rem;
  letter-spacing: 0;
}

.section {
  width: min(1180px, calc(100% - 40px));
  margin: 0 auto;
  padding: 88px 0;
}

.section.tight {
  padding-top: 58px;
}

.section-header {
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(260px, 0.55fr);
  gap: 46px;
  align-items: end;
  margin-bottom: 36px;
}

.section-header.compact {
  grid-template-columns: 1fr;
}

.section-header h2,
.page-title h1 {
  margin: 0;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(2.4rem, 5vw, 4.8rem);
}

.section-header p,
.page-title p {
  margin: 0;
  color: var(--muted);
  font-size: 1.05rem;
}

.page-title .authorship-note {
  margin-top: 10px;
  font-size: 0.95rem;
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.feature-card,
.publication,
.course,
.talk-item,
.contact-panel {
  background: rgba(255, 250, 241, 0.82);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 16px 40px rgba(24, 32, 31, 0.08);
}

.feature-card {
  min-height: 250px;
  padding: 24px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.feature-card .number {
  color: var(--red);
  font-family: Georgia, "Times New Roman", serif;
  font-size: 3.2rem;
  line-height: 1;
}

.feature-card h3,
.publication h2,
.course h2 {
  margin: 18px 0 10px;
  font-size: 1.35rem;
}

.feature-card p,
.publication p,
.course p,
.talk-item p {
  margin: 0;
  color: var(--muted);
}

.split-band {
  background: var(--night);
  color: #fffaf1;
  margin: 20px 0;
}

.split-band .section {
  display: grid;
  grid-template-columns: 0.8fr 1fr;
  gap: 54px;
  align-items: center;
}

.split-band h2 {
  margin: 0;
  color: #fffaf1;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(2.2rem, 4vw, 4rem);
}

.split-band p {
  margin: 18px 0 0;
  color: rgba(255, 250, 241, 0.72);
}

.split-band a {
  color: #fffaf1;
}

.research-banner {
  padding: 34px;
  color: #fffaf1;
  background: var(--night);
  border: 1px solid rgba(255, 250, 241, 0.12);
  border-radius: 8px;
  box-shadow: var(--shadow);
  display: grid;
  grid-template-columns: 0.8fr 1fr;
  gap: 44px;
  align-items: center;
}

.research-banner-compact {
  grid-template-columns: 1fr;
}

.research-banner h2 {
  margin: 0;
  color: #fffaf1;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(2.2rem, 4vw, 4rem);
}

.research-banner p {
  margin: 12px 0 0;
  color: rgba(255, 250, 241, 0.72);
}

.research-banner a {
  color: #fffaf1;
}

.research-list {
  display: grid;
  gap: 14px;
}

.research-stack {
  display: grid;
  gap: 48px;
}

.research-group {
  display: grid;
  gap: 18px;
}

.research-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
}

.research-heading h2 {
  margin: 0;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(2rem, 4vw, 3.4rem);
}

.research-heading p {
  max-width: 520px;
  margin: 0;
  color: var(--muted);
}

.publication {
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr);
  gap: 20px;
  padding: 22px;
}

.publication.research-paper {
  gap: 18px;
  padding: 18px 20px;
  align-items: start;
}

.publication.research-paper h2 {
  margin-bottom: 8px;
}

.publication.research-paper .pub-meta {
  margin-top: 7px;
}

.pub-index {
  width: 56px;
  height: 56px;
  display: grid;
  place-items: center;
  color: #fffaf1;
  background: var(--teal-dark);
  border-radius: 50%;
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 700;
}

.research-paper .pub-index {
  width: 50px;
  height: 50px;
  font-size: 0.96rem;
}

.pub-index.term-index {
  width: 86px;
  padding: 0 10px;
  border-radius: 999px;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
  font-size: 0.78rem;
  font-weight: 800;
  line-height: 1.15;
  text-align: center;
}

.publication h2 {
  margin-top: 0;
}

.pub-meta {
  margin-top: 10px;
  color: var(--muted);
  font-size: 0.95rem;
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}

.tag {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 4px 10px;
  color: #5a3d12;
  background: rgba(217, 155, 57, 0.18);
  border: 1px solid rgba(217, 155, 57, 0.38);
  border-radius: 999px;
  font-size: 0.82rem;
  font-weight: 800;
}

.view-more {
  justify-self: end;
  min-height: 44px;
  padding: 10px 18px;
  color: #fffaf1;
  background: var(--night);
  border: 0;
  border-radius: 999px;
  font: inherit;
  font-weight: 800;
  cursor: pointer;
}

.view-more:hover {
  background: #263432;
}

.view-more[hidden],
.is-hidden {
  display: none;
}

.page-hero {
  color: #fffaf1;
  background: linear-gradient(135deg, #101817 0%, #172521 62%, #304235 100%);
}

.page-title {
  width: min(1180px, calc(100% - 40px));
  margin: 0 auto;
  padding: 104px 0 84px;
}

.page-title p {
  max-width: 760px;
  color: rgba(255, 250, 241, 0.76);
  margin-top: 20px;
}

.two-column {
  display: grid;
  grid-template-columns: 0.74fr 1fr;
  gap: 32px;
  align-items: start;
}

.sidebar-panel {
  position: sticky;
  top: 104px;
  padding: 26px;
  color: #fffaf1;
  background: var(--night);
  border-radius: 8px;
}

.sidebar-panel h2 {
  margin: 0;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 2rem;
}

.sidebar-panel p {
  margin: 18px 0 0;
  color: rgba(255, 250, 241, 0.7);
}

.sidebar-panel a {
  color: #fffaf1;
}

.course-list,
.talk-list {
  display: grid;
  gap: 14px;
}

.course,
.talk-item {
  padding: 22px;
}

.course h2,
.talk-item h2 {
  margin: 0 0 10px;
  font-size: 1.25rem;
}

.talk-item {
  border-left: 5px solid var(--teal);
}

.contact-panel {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 24px;
  align-items: center;
  padding: 28px;
  background: #fffaf1;
}

.contact-panel h2 {
  margin: 0;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 2rem;
}

.contact-panel p {
  margin: 8px 0 0;
  color: var(--muted);
}

.footer {
  color: rgba(255, 250, 241, 0.72);
  background: var(--night);
}

.footer-inner {
  width: min(1180px, calc(100% - 40px));
  margin: 0 auto;
  padding: 28px 0;
  display: flex;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
  font-size: 0.9rem;
}

.footer a {
  color: #fffaf1;
}

@media (max-width: 880px) {
  .nav {
    align-items: flex-start;
    flex-direction: column;
    padding: 14px 0;
  }

  .nav-links {
    justify-content: flex-start;
  }

  .hero {
    min-height: 560px;
  }

  .hero-inner,
  .page-title {
    padding-top: 74px;
  }

  .hero-stats,
  .social-strip,
  .feature-grid,
  .section-header,
  .split-band .section,
  .research-banner,
  .two-column,
  .contact-panel {
    grid-template-columns: 1fr;
  }

  .hero-stats {
    margin-top: 24px;
  }

  .social-strip {
    align-items: flex-start;
    flex-direction: column;
  }

  .section {
    padding: 62px 0;
  }

  .sidebar-panel {
    position: static;
  }
}

@media (max-width: 560px) {
  .nav,
  .hero-inner,
  .hero-stats,
  .section,
  .page-title,
  .footer-inner {
    width: min(100% - 28px, 1180px);
  }

  .nav-links a {
    padding: 7px 9px;
  }

  .hero h1 {
    font-size: clamp(3rem, 15vw, 4.2rem);
  }

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

  .pub-index {
    width: 48px;
    height: 48px;
  }

  .pub-index.term-index {
    width: fit-content;
    min-width: 72px;
    height: 40px;
  }

  .contact-panel {
    padding: 22px;
  }
}
