:root {
  --background: #f8f9fa;
  --surface: #ffffff;
  --text: #17191c;
  --muted: #5b6470;
  --faint: #8a929b;
  --rule: #dfe3e8;
  --accent: #086b74;
  --accent-dark: #064d53;
  --measure: 1060px;
}

@font-face {
  font-family: "KaiName";
  src: url("assets/fonts/kai-name.woff") format("woff");
  font-display: swap;
  unicode-range: U+5F35, U+51F1, U+7232;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--background);
  color: var(--text);
  font-family: "SFMono-Regular", "Cascadia Code", "Roboto Mono", "Liberation Mono", Menlo, Consolas, monospace;
  font-size: 15px;
  line-height: 1.62;
}

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

a:hover,
a:focus {
  color: var(--accent-dark);
}

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

h1 {
  max-width: 740px;
  margin-bottom: 0.4rem;
  font-size: 2.55rem;
  line-height: 1.08;
  letter-spacing: 0;
}

h1 span {
  display: inline-block;
  color: var(--muted);
  font-family: "KaiName", "Kaiti TC", "STKaiti", "KaiTi", "DFKai-SB", "BiauKai", serif;
  font-size: 1em;
  font-weight: 500;
  vertical-align: 0;
}

h2 {
  margin-bottom: 0;
  font-size: 0.92rem;
  line-height: 1.3;
  letter-spacing: 0;
  text-transform: uppercase;
  color: var(--accent-dark);
}

h3 {
  margin-bottom: 0.55rem;
  font-size: 0.98rem;
  line-height: 1.35;
}

p {
  margin-bottom: 1rem;
}

strong {
  font-weight: 700;
}

.site-header,
main,
.site-footer {
  width: min(var(--measure), calc(100% - 36px));
  margin-inline: auto;
}

.site-header {
  padding: 58px 0 22px;
}

.header-inner {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 260px;
  gap: 46px;
  align-items: start;
  padding-bottom: 30px;
  border-bottom: 1px solid var(--rule);
}

.eyebrow {
  margin-bottom: 0.6rem;
  color: var(--muted);
  font-size: 0.88rem;
  font-weight: 600;
}

.lead {
  max-width: 760px;
  margin-bottom: 1.25rem;
  color: #30363d;
  font-size: 1rem;
  line-height: 1.62;
}

.contact-links,
.page-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem 1rem;
}

.contact-links a,
.contact-links span,
.page-links a {
  font-size: 0.9rem;
  font-weight: 600;
}

.contact-links span {
  color: var(--muted);
}

.portrait {
  margin: 0;
  justify-self: end;
  width: min(260px, 100%);
}

.portrait img {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  height: auto;
  object-fit: cover;
  border: 1px solid var(--rule);
  border-radius: 8px;
}

.page-links {
  padding-top: 18px;
}

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

.two-column {
  display: block;
}

.section-body {
  max-width: none;
  margin-top: 0.95rem;
}

.section-body > :last-child,
.feature > :last-child {
  margin-bottom: 0;
}

.side-note {
  margin-top: 0.55rem;
  color: var(--muted);
  font-size: 0.86rem;
  line-height: 1.5;
}

.compact-list {
  display: grid;
  gap: 0.35rem;
  margin: 1.15rem 0 0;
}

.compact-list div {
  display: grid;
  grid-template-columns: 96px minmax(0, 1fr);
  gap: 18px;
}

.compact-list strong {
  color: var(--muted);
  font-weight: 700;
}

.news-list,
.publication-list,
.plain-list {
  margin: 0;
  padding-left: 1.25rem;
}

.news-list {
  list-style: disc;
  padding-left: 1.25rem;
}

.news-list li {
  margin-bottom: 0.42rem;
}

.plain-list li {
  margin-bottom: 0.45rem;
}

.publication-list {
  padding-left: 1.35rem;
}

.publication-list li {
  margin-bottom: 1.05rem;
  padding-left: 0.18rem;
}

.pub-title,
.pub-authors,
.pub-venue {
  display: block;
}

.pub-title {
  font-weight: 700;
  line-height: 1.45;
}

.pub-authors {
  color: #323941;
  font-size: 0.9rem;
  line-height: 1.5;
}

.pub-venue {
  color: var(--muted);
  font-size: 0.88rem;
  font-style: italic;
}

.compact-publications li {
  margin-bottom: 0.8rem;
}

.legend {
  color: var(--muted);
  font-size: 0.86rem;
}

.feature-list {
  display: grid;
  gap: 22px;
}

.feature {
  padding-left: 0;
}

.feature h3 {
  margin-bottom: 0.35rem;
}

.press-intro {
  display: grid;
  gap: 1.05rem;
}

.press-links {
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.55;
}

.press-links span {
  color: var(--faint);
}

.site-footer {
  padding: 30px 0 48px;
  color: var(--muted);
  font-size: 0.88rem;
}

.site-footer p {
  margin-bottom: 0.35rem;
}

@media (max-width: 820px) {
  .site-header {
    padding-top: 34px;
  }

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

  .header-inner {
    gap: 24px;
  }

  .portrait {
    justify-self: start;
    width: min(320px, 100%);
  }

  h2 {
    margin-bottom: 0.1rem;
  }

  .compact-list div {
    grid-template-columns: 1fr;
    gap: 0;
  }
}

@media (max-width: 520px) {
  .site-header,
  main,
  .site-footer {
    width: min(100% - 26px, var(--measure));
  }

  h1 {
    font-size: 1.9rem;
  }

  h1 span {
    display: block;
    margin-top: 0.35rem;
    font-size: 1em;
  }

  .lead {
    font-size: 0.98rem;
  }

  .section {
    padding: 28px 0;
  }
}

@media print {
  body {
    background: #ffffff;
    color: #000000;
  }

  .page-links,
  .portrait {
    display: none;
  }

  .site-header,
  main,
  .site-footer {
    width: 100%;
  }
}
