:root {
  --paper: #fbfaf7;
  --panel: #ffffff;
  --ink: #1d242b;
  --muted: #61707b;
  --line: #dfe3e4;
  --accent: #245f78;
  --accent-soft: #e9f1f4;
  --warm: #9d6944;
  --max-width: 1080px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
  font-size: 16px;
  line-height: 1.62;
  text-rendering: optimizeLegibility;
}

a {
  color: var(--accent);
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

a:hover {
  color: #123f53;
}

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

.skip-link {
  position: fixed;
  top: 10px;
  left: 10px;
  z-index: 100;
  padding: 8px 12px;
  background: var(--ink);
  color: white;
  transform: translateY(-150%);
}

.skip-link:focus {
  transform: none;
}

.section-shell,
.header-inner {
  width: min(calc(100% - 40px), var(--max-width));
  margin-inline: auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: color-mix(in srgb, var(--paper) 94%, transparent);
  border-bottom: 1px solid rgba(29, 36, 43, 0.1);
  backdrop-filter: blur(12px);
}

.header-inner {
  min-height: 58px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.site-name {
  color: var(--ink);
  font-family: Georgia, "Times New Roman", serif;
  font-size: 18px;
  font-weight: 700;
  text-decoration: none;
}

nav {
  display: flex;
  gap: 24px;
}

nav a {
  color: var(--muted);
  font-size: 14px;
  text-decoration: none;
}

nav a:hover {
  color: var(--ink);
}

.intro {
  display: grid;
  grid-template-columns: 200px minmax(0, 1fr);
  gap: 50px;
  align-items: center;
  padding-block: 88px 82px;
  border-bottom: 1px solid var(--line);
}

.portrait {
  width: 200px;
  aspect-ratio: 1;
  border-radius: 50%;
  overflow: hidden;
  background: #e7e9e8;
  border: 1px solid #d3d8d9;
}

.portrait img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 30%;
}

.eyebrow {
  margin: 0 0 8px;
  color: var(--accent);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

.intro-statement {
  margin: 0;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 22px;
  font-weight: 400;
  line-height: 1.55;
  letter-spacing: -0.008em;
}

.bio {
  max-width: 700px;
  margin: 12px 0 0;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 20px;
  line-height: 1.58;
}

.availability {
  max-width: 720px;
  margin: 22px 0 0;
  padding: 15px 18px;
  border-left: 4px solid var(--accent);
  border-radius: 0 4px 4px 0;
  background: var(--accent-soft);
  color: #1d5268;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 17px;
  line-height: 1.5;
}

.availability strong {
  color: #17475b;
  font-weight: 700;
}

.availability a {
  color: #0e617f;
  font-weight: 700;
}

.profile-links,
.paper-links {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
}

.profile-links {
  margin-top: 24px;
}

.profile-links a,
.paper-link {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 5px 11px;
  border: 1px solid #c8d0d3;
  border-radius: 3px;
  background: rgba(255, 255, 255, 0.55);
  color: #35424a;
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
}

.profile-links a:hover,
.paper-link:hover {
  border-color: #8799a1;
  background: white;
  color: var(--ink);
}

.paper-link.pending {
  color: #96a0a5;
  border-style: dashed;
  cursor: default;
}

.publications {
  padding-block: 74px;
}

.section-heading {
  margin-bottom: 34px;
}

.section-heading h2 {
  max-width: 760px;
  margin: 0;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(30px, 4vw, 42px);
  font-weight: 500;
  line-height: 1.2;
  letter-spacing: -0.015em;
}

.publication {
  display: grid;
  grid-template-columns: minmax(0, 1.18fr) minmax(320px, 0.82fr);
  gap: 38px;
  align-items: center;
  padding-block: 42px;
  border-top: 1px solid var(--line);
}

.publication:first-of-type {
  border-top: 0;
}

.publication.reverse .publication-visual {
  order: 2;
}

.publication.compact {
  grid-template-columns: minmax(0, 0.9fr) minmax(360px, 1.1fr);
}

.publication-visual {
  min-width: 0;
}

.canvas-visual {
  position: relative;
  min-height: 330px;
  border: 1px solid #d3dade;
  border-radius: 5px;
  overflow: hidden;
  background: #f5f8f8;
}

.canvas-visual canvas {
  width: 100%;
  height: 330px;
}

.canvas-labels {
  position: absolute;
  top: 15px;
  left: 18px;
  right: 18px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  color: #35444c;
  font-size: 12px;
  font-weight: 700;
  text-align: center;
  pointer-events: none;
}

.visual-note {
  position: absolute;
  left: 18px;
  bottom: 12px;
  margin: 0;
  color: #52636b;
  font-size: 11px;
  letter-spacing: 0.03em;
}

.publication-copy h3 {
  margin: 4px 0 10px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(22px, 2.8vw, 29px);
  font-weight: 600;
  line-height: 1.24;
  letter-spacing: -0.01em;
}

.venue {
  margin: 0;
  color: var(--accent);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.venue-major {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 9px 11px;
}

.venue-major > a {
  display: inline-flex;
  padding: 6px 11px;
  border-radius: 3px;
  background: var(--accent);
  color: white;
  font-size: 17px;
  line-height: 1;
  letter-spacing: 0.045em;
  text-decoration: none;
}

.venue-major > a:hover {
  background: #17475b;
  color: white;
}

.venue-major small {
  color: #53636b;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.055em;
}

.authors {
  margin: 0 0 14px;
  color: #49565e;
  font-size: 14px;
}

.summary {
  margin: 0 0 20px;
  color: #46535b;
  font-size: 15px;
  line-height: 1.62;
}

.summary strong {
  color: #26343c;
  font-weight: 700;
}

.result-highlight {
  display: block;
  margin-top: 9px;
  color: #184f66;
}

.result-highlight strong {
  color: inherit;
}

.paper-figure {
  margin: 0;
  padding: 15px;
  border: 1px solid var(--line);
  border-radius: 5px;
  background: white;
}

.paper-figure img {
  width: 100%;
  height: auto;
}

.paper-figure figcaption {
  margin-top: 9px;
  color: var(--muted);
  font-size: 11px;
}

.group-visual {
  position: relative;
  min-height: 310px;
  border: 1px solid var(--line);
  border-radius: 5px;
  overflow: hidden;
  background: #f7f4ed;
}

.group-box {
  position: absolute;
  border: 1px solid #9aa5a8;
  border-radius: 50%;
  color: #354149;
  text-align: center;
}

.group-box > span {
  position: absolute;
  top: 11px;
  left: 0;
  right: 0;
  font-size: 11px;
}

.group-g {
  left: 7%;
  top: 9%;
  width: 65%;
  height: 80%;
  background: rgba(218, 228, 229, 0.45);
}

.group-s {
  left: 18%;
  top: 20%;
  width: 66%;
  height: 64%;
  background: rgba(198, 216, 219, 0.65);
}

.group-r {
  left: 24%;
  top: 26%;
  width: 52%;
  height: 47%;
  background: rgba(149, 186, 197, 0.62);
}

.hall-node {
  position: absolute;
  right: 4%;
  top: 38%;
  width: 20%;
  padding: 13px 5px;
  border: 1px solid #a98567;
  border-radius: 50%;
  background: #f3e7db;
  color: #5f4636;
  font-size: 11px;
  line-height: 1.25;
  text-align: center;
}

.permute-relation {
  position: absolute;
  right: 17%;
  bottom: 18%;
  padding: 4px 7px;
  border-radius: 3px;
  background: rgba(251, 250, 247, 0.9);
  color: #765438;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 14px;
}

.concept-label {
  position: absolute;
  right: 12px;
  bottom: 8px;
  margin: 0;
  color: #8a9295;
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.07em;
}

footer {
  border-top: 1px solid var(--line);
}

.footer-inner {
  min-height: 100px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  color: var(--muted);
  font-size: 13px;
}

.footer-inner p {
  margin: 0;
}

@media (max-width: 860px) {
  .intro {
    grid-template-columns: 160px minmax(0, 1fr);
    gap: 34px;
    padding-block: 62px;
  }

  .portrait {
    width: 160px;
  }

  .bio {
    font-size: 18px;
  }

  .publication,
  .publication.compact {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .publication.reverse .publication-visual {
    order: 0;
  }
}

@media (max-width: 600px) {
  .section-shell,
  .header-inner {
    width: min(calc(100% - 28px), var(--max-width));
  }

  .header-inner {
    min-height: 54px;
  }

  nav {
    gap: 14px;
  }

  nav a {
    font-size: 12px;
  }

  .intro {
    grid-template-columns: 1fr;
    gap: 28px;
    padding-block: 46px 52px;
  }

  .portrait {
    width: 130px;
  }

  .intro-statement {
    font-size: 20px;
  }

  .availability {
    padding: 13px 15px;
    font-size: 16px;
  }

  .publications {
    padding-block: 54px;
  }

  .publication {
    padding-block: 34px;
  }

  .canvas-visual,
  .canvas-visual canvas {
    min-height: 280px;
    height: 280px;
  }

  .canvas-labels {
    font-size: 10px;
  }

  .publication-copy h3 {
    font-size: 23px;
  }

  .footer-inner {
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    gap: 2px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}
