:root {
  color-scheme: light;
  --text: #202124;
  --muted: #5f6368;
  --line: #d9dee7;
  --soft: #f7f8fa;
  --paper: #ffffff;
  --accent: #2f5fa7;
  --accent-2: #24746b;
  --max: 1080px;
}

* { box-sizing: border-box; }

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

.page {
  width: min(var(--max), calc(100% - 32px));
  margin: 0 auto;
  padding: 44px 0 68px;
}

.hero {
  text-align: center;
  border-bottom: 1px solid var(--line);
  padding-bottom: 28px;
  margin-bottom: 28px;
}

.header-copy {
  width: 100%;
  max-width: 980px;
  margin: 0 auto;
  text-align: center;
}

h1 {
  margin: 0 auto 16px;
  max-width: 980px;
  font-size: clamp(30px, 5vw, 48px);
  line-height: 1.12;
  font-weight: 700;
  letter-spacing: 0;
}

.authors {
  margin: 0 auto 8px;
  width: 100%;
  max-width: 960px;
  color: #3f4652;
  font-size: 21px;
  line-height: 1.45;
  text-align: center;
}

.authors sup,
.affiliations sup {
  font-size: 0.72em;
  line-height: 0;
}

.affiliations {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px 22px;
  margin: 0 auto 10px;
  width: 100%;
  max-width: 900px;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.4;
  text-align: center;
}


.venue {
  margin: 0 auto 18px;
  color: var(--muted);
  font-size: 16px;
  text-align: center;
}

.links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 14px;
}

.links .btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: #fff;
  text-decoration: none;
  padding: 13px 21px;
  border-radius: 4px;
  font-size: 19px;
  font-weight: 700;
  line-height: 1.2;
}

.links .btn i {
  font-size: 21px;
  line-height: 1;
}

.links .btn--primary { background: #2f5fa7; }
.links .btn--inverse { background: #3f4652; }
.links .btn--danger { background: #c94f4f; }
.links .btn--model { background: #ffcc4d; }
.links .model-icon { color: #fff; }
.links .btn:hover { filter: brightness(0.92); }

section { margin: 48px 0; }



main.page section h2 {
  text-align: left;
}

h2 {
  margin: 0 0 14px;
  font-size: 28px;
  line-height: 1.2;
  font-weight: 650;
  text-align: left;
}

h4 {
  margin: 0 0 12px;
  font-size: 18px;
  line-height: 1.25;
  font-weight: 650;
}

.text-section p,
.section-copy {
  max-width: 880px;
  margin: 0 auto 18px;
  color: #333842;
  font-size: 17px;
}

.method-content {
  width: 100%;
  max-width: 100%;
  margin: 24px auto 0;
}

.method-figure {
  margin: 0 0 18px;
}

.method-figure img {
  width: 100%;
  background: #fff;
  border: 1px solid var(--line);
}

.text-section .intro-copy,
.text-section .method-copy {
  display: block;
  width: 100%;
  max-width: none;
  margin: 0;
  font-size: 19px;
  line-height: 1.55;
  text-align: left;
}




.showcase-pair-grid {
  display: flex;
  justify-content: center;
  align-items: flex-start;
  gap: 18px;
  margin-top: 24px;
  flex-wrap: nowrap;
}

.more-pair-grid,
.human-pair-grid,
.dancingbox-pair-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 26px;
  margin-top: 24px;
}

.pair-result-figure img {
  width: 100%;
}

.showcase-case .pair-result-figure img {
  width: auto;
  max-width: none;
  height: auto;
}



.control-edit-list {
  display: grid;
  grid-template-columns: 1fr;
  gap: 26px;
  margin-top: 24px;
}

.control-edit-card {
  width: 100%;
}

.card-stack {
  display: grid;
  gap: 26px;
  margin-top: 24px;
}

.result-card {
  border-top: 1px solid var(--line);
  padding-top: 18px;
}

.media-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  align-items: start;
}

.media-count-1 { grid-template-columns: minmax(0, 1fr); }
.media-count-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.media-count-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }

figure { margin: 0; }

figure img {
  display: block;
  width: 100%;
  height: auto;
  object-fit: contain;
  background: #f0f1f3;
  border: 1px solid var(--line);
}

figcaption {
  color: var(--muted);
  text-align: center;
  font-size: 14px;
  margin-top: 7px;
}

#bibtex {
  width: 100%;
  max-width: none;
}

pre,
.citation-box {
  display: block;
  max-width: none;
  width: 100%;
  overflow-x: auto;
  margin: 18px 0 0;
  padding: 16px;
  background: #f3f5f7;
  border: 1px solid var(--line);
  border-radius: 4px;
  font-size: 14px;
  line-height: 1.45;
}

@media (max-width: 900px) {
  .media-count-3,
  .media-count-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 640px) {
  .page { width: min(100% - 22px, var(--max)); padding-top: 30px; }
  .media-grid,
  .media-count-3,
  .media-count-4 { grid-template-columns: 1fr; }
  h1 { font-size: 30px; }
}

@media (max-width: 480px) {
  .links a { width: calc(50% - 6px); }
}
