:root {
  --primary-color: #2563eb;
  --primary-hover: #1d4ed8;
  --secondary-color: #64748b;
  --accent-color: #0ea5e9;
  --text-primary: #1e293b;
  --text-secondary: #64748b;
  --text-light: #94a3b8;
  --background-primary: #ffffff;
  --background-secondary: #f8fafc;
  --background-accent: #f1f5f9;
  --border-color: #e2e8f0;
  --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
  --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
  --border-radius: 12px;
  --border-radius-lg: 12px;
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: "Inter", "Segoe UI", -apple-system, BlinkMacSystemFont, sans-serif;
  color: var(--text-primary);
  line-height: 1.6;
  font-size: 15px;
  background: var(--background-primary);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  font: inherit;
}

.page-shell {
  width: min(calc(100% - 32px), 1180px);
  margin: 16px auto 36px;
}

.topbar {
  position: sticky;
  top: 12px;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 10px 16px;
  margin-bottom: 18px;
  border: 1px solid rgba(226, 232, 240, 0.82);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.74);
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.08);
  backdrop-filter: blur(22px) saturate(1.25);
  -webkit-backdrop-filter: blur(22px) saturate(1.25);
}

.topbar::before {
  content: "";
  position: absolute;
  inset: -22px -28px -16px;
  z-index: -1;
  border-radius: 28px;
  background: rgba(248, 250, 252, 0.68);
  backdrop-filter: blur(24px) saturate(1.2);
  -webkit-backdrop-filter: blur(24px) saturate(1.2);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--text-primary);
  font-weight: 800;
  text-transform: lowercase;
}

.brand-logo {
  width: 28px;
  height: 28px;
  flex: 0 0 28px;
}

.topnav {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

.topnav a {
  color: var(--text-secondary);
  font-size: 0.88rem;
  font-weight: 650;
}

.topnav a:hover {
  color: var(--text-primary);
}

.hero-section,
.section-block {
  border: none;
  border-radius: var(--border-radius-lg);
  box-shadow: none;
  overflow: hidden;
}

.section-block + .section-block,
.hero-section + .section-block {
  border-top: 1px solid var(--border-color);
}

.hero-section {
  padding: 28px 24px 22px;
  background: linear-gradient(180deg, #152033 0%, #1f3045 100%);
}

.hero-copy {
  max-width: 860px;
  margin: 0 auto;
  text-align: center;
}

.eyebrow {
  margin: 0 0 8px;
  color: #cbd5e1;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.74rem;
  font-weight: 700;
}

.hero-copy h1 {
  margin: 0;
  color: #ffffff;
  font-size: clamp(2.1rem, 4.6vw, 3.5rem);
  line-height: 1.05;
  font-weight: 800;
}

.hero-wave {
  background-image: linear-gradient(120deg, rgba(125, 211, 252, 0.22), rgba(125, 211, 252, 0.22));
  background-repeat: no-repeat;
  background-size: 100% 0.38em;
  background-position: 0 92%;
  padding-bottom: 2px;
}

.hero-definition {
  max-width: 760px;
  margin: 12px auto 0;
  padding: 0;
  border: 0;
  background: transparent;
}

.hero-lead {
  max-width: 700px;
  margin: 0 auto;
  color: #cfd9e8;
  font-size: 0.97rem;
  line-height: 1.68;
}

.hero-actions {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 18px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 11px 18px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  transition: var(--transition);
}

.button.primary {
  color: #fff;
  background: rgba(255, 255, 255, 0.08);
}

.button.secondary {
  color: #fff;
  background: rgba(255, 255, 255, 0.12);
}

.button.ghost {
  color: #cbd5e1;
  background: transparent;
}

.button:hover {
  transform: translateY(-1px);
}

.hero-panel {
  margin-top: 26px;
}

.hero-example-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  max-width: 980px;
  margin: 0 auto;
}

.hero-example-link {
  position: relative;
  display: block;
  border-radius: 12px;
  outline: none;
}

.hero-example-link::after {
  content: "Source: " attr(data-source);
  position: absolute;
  left: 10px;
  bottom: 10px;
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 700;
  color: #f8fafc;
  background: rgba(15, 23, 42, 0.76);
  border: 1px solid rgba(148, 163, 184, 0.35);
  box-shadow: var(--shadow-sm);
  opacity: 0;
  transform: translateY(4px);
  transition: opacity 0.18s ease, transform 0.18s ease;
  pointer-events: none;
}

.hero-example-link:hover::after,
.hero-example-link:focus-visible::after {
  opacity: 1;
  transform: translateY(0);
}

.hero-example-grid img {
  width: 100%;
  height: 220px;
  object-fit: cover;
  border-radius: 12px;
  border: 1px solid rgba(148, 163, 184, 0.26);
  box-shadow: var(--shadow-sm);
}

.hero-action-links {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  max-width: 1040px;
  margin: 18px auto 0;
}

.hero-action-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 50px;
  padding: 0 18px;
  border-radius: 999px;
  color: #ffffff;
  background: #2f2f2f;
  font-size: 1.02rem;
  font-weight: 800;
  line-height: 1.1;
  box-shadow: 0 14px 28px rgba(15, 23, 42, 0.18);
  transition: var(--transition);
}

.hero-action-link::before {
  content: "";
  width: 24px;
  height: 24px;
  flex: 0 0 24px;
  background-repeat: no-repeat;
  background-position: center;
  background-size: contain;
}

.hero-action-paper {
  color: #7f1d1d;
  background: #ffe4e6;
}

.hero-action-paper::before {
  background-image: url("../images/icons/arxiv.png");
}

.hero-action-gallery {
  position: relative;
  padding-left: 48px;
  color: #ffffff;
  background: linear-gradient(90deg, #6672dc 0%, #7451a6 100%);
  box-shadow: 0 14px 28px rgba(102, 114, 220, 0.28);
}

.hero-action-gallery::before {
  position: absolute;
  left: 22px;
  top: 50%;
  width: 18px;
  height: 18px;
  flex: none;
  border-radius: 999px;
  background: #ffffff;
  transform: translateY(-50%);
}

.hero-action-gallery::after {
  content: "";
  position: absolute;
  left: 29px;
  top: 50%;
  width: 0;
  height: 0;
  border-top: 4px solid transparent;
  border-bottom: 4px solid transparent;
  border-left: 6px solid #6672dc;
  transform: translate(1px, -50%);
}

.hero-action-findings {
  color: #1e3a8a;
  background: #dbeafe;
  border: 1px solid rgba(96, 165, 250, 0.34);
  box-shadow: 0 14px 28px rgba(37, 99, 235, 0.14);
}

.hero-action-findings::before {
  background-image: url("../images/icons/findings.png");
}

.hero-action-contributors {
  color: #111827;
  background: #f8fafc;
  border: 1px solid rgba(15, 23, 42, 0.12);
}

.hero-action-contributors::before {
  background-image: url("../images/icons/people.png");
}

.hero-action-link:hover {
  transform: translateY(-1px);
  filter: brightness(1.05);
}

.snapshot-grid {
  display: flex;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 18px;
}

.snapshot-card {
  min-width: 170px;
  padding: 12px 16px;
  text-align: center;
  border-radius: var(--border-radius);
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.snapshot-value {
  display: block;
  font-weight: 800;
  color: #fff;
}

.snapshot-label {
  display: block;
  margin-top: 4px;
  color: #cbd5e1;
  font-size: 0.84rem;
}

.hero-carousel {
  padding: 14px 0 0;
  border-radius: 0;
  background: transparent;
  border: none;
}

.panel-head {
  display: flex;
  justify-content: center;
  margin-bottom: 12px;
}

.panel-head span {
  color: #e2e8f0;
  font-size: 0.94rem;
  font-weight: 700;
}

.hero-carousel-track {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  transition: opacity 0.45s ease, transform 0.45s ease;
  opacity: 1;
  transform: translateY(0);
}

.hero-carousel-track.is-transitioning {
  opacity: 0.35;
  transform: translateY(4px);
}

.hero-example {
  position: relative;
  min-height: 220px;
  border-radius: var(--border-radius);
  overflow: hidden;
  background-size: cover;
  background-position: center;
  box-shadow: var(--shadow-md);
}

.hero-example::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.12), rgba(15, 23, 42, 0.65));
}

.hero-example-content {
  position: absolute;
  inset: auto 0 0 0;
  padding: 16px;
  z-index: 1;
}

.hero-tag {
  display: inline-flex;
  margin-bottom: 8px;
  padding: 6px 10px;
  border-radius: 999px;
  color: #fff;
  background: rgba(15, 23, 42, 0.48);
  font-size: 0.75rem;
  font-weight: 700;
}

.hero-example h3 {
  margin: 0;
  color: #fff;
  font-size: 1rem;
}

.hero-example-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: flex-end;
  padding: 16px;
  background: rgba(15, 23, 42, 0.84);
  color: #e2e8f0;
  opacity: 0;
  transition: var(--transition);
  z-index: 2;
}

.hero-example:hover .hero-example-overlay {
  opacity: 1;
}

.hero-example-overlay p {
  margin: 0;
  font-size: 0.92rem;
  line-height: 1.65;
}

.section-block {
  margin-top: 16px;
  padding: 28px 24px;
  background: var(--background-secondary);
}

.section-emphasis {
  background: var(--background-secondary);
}

.section-heading {
  max-width: 820px;
  margin-bottom: 22px;
}

.section-heading-with-icon {
  position: relative;
  max-width: 980px;
  min-height: 58px;
  padding-left: 76px;
}

.section-icon {
  position: absolute;
  left: 0;
  top: 2px;
  width: 54px;
  height: 54px;
  object-fit: contain;
}

.section-heading .eyebrow {
  color: var(--primary-color);
}

.section-heading h2 {
  margin: 0 0 10px;
  font-size: clamp(1.55rem, 3vw, 2.25rem);
  line-height: 1.1;
  font-weight: 700;
}

.section-heading p,
.paper-meta p,
.paper-bullets li,
.compare-card p,
.gallery-content p,
.benchmark-card p,
.finding-card p,
.resource-card p {
  color: var(--text-secondary);
  font-size: 0.92rem;
}

.threads-overline {
  margin: 0 0 8px;
  color: #475569;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.concept-section .section-heading {
  max-width: 940px;
}

.problem-section {
  background: linear-gradient(180deg, #fff5f7 0%, #fffafb 100%);
}

.problem-section .section-heading h2 {
  color: #7f1d1d;
}

.concept-overline {
  margin: 0 0 8px;
  color: #b91c1c;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.paper-list {
  display: grid;
  gap: 16px;
}

.paper-card {
  position: relative;
  display: grid;
  grid-template-columns: 1fr 190px;
  gap: 20px;
  padding: 18px;
  border-radius: 10px;
  background: #fff;
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-sm);
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.45s ease, transform 0.45s ease;
}

.venue-badge-floating {
  position: absolute;
  top: 14px;
  right: 14px;
}

.paper-card.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.paper-title-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 10px;
}

.paper-title-row h3 {
  margin: 0;
  font-size: 1.12rem;
  line-height: 1.35;
}

.paper-main .topic-stack {
  margin-bottom: 12px;
}

.paper-title-highlight {
  box-decoration-break: clone;
  -webkit-box-decoration-break: clone;
  padding: 0 2px;
  border-radius: 2px;
}

.venue-badge,
.topic-pill,
.ground-truth-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 0.76rem;
  font-weight: 700;
}

.venue-badge.cvpr {
  color: #0c447c;
  background: #e6f1fb;
}

.venue-badge.cl {
  color: #3c3489;
  background: #eeedfe;
}

.paper-meta p {
  margin: 0 0 14px;
}

.paper-bullets {
  margin: 0;
  padding-left: 18px;
}

.paper-bullets li + li {
  margin-top: 8px;
}

.paper-side {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.topic-stack {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-start;
  gap: 12px;
}

.topic-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-start;
  gap: 4px;
  text-align: left;
}

.topic-row .topic-pill {
  margin: 0 2px 2px 0;
}

.topic-label {
  font-size: 0.74rem;
  font-weight: 800;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: #64748b;
}

.topic-pill {
  color: #334155;
  background: #eef2f7;
}

.paper-card.paper-wif .paper-title-highlight,
.resource-card.paper-wif .paper-title-highlight,
.benchmark-card.paper-wif .paper-title-highlight {
  background-image: linear-gradient(transparent 60%, rgba(39, 77, 120, 0.25) 0);
}

.benchmark-card.paper-wif {
  --benchmark-bg-image: url("../images/gallery/bg/worldinframe.png");
}

.paper-card.paper-ct .paper-title-highlight,
.resource-card.paper-ct .paper-title-highlight,
.benchmark-card.paper-ct .paper-title-highlight {
  background-image: linear-gradient(transparent 60%, rgba(76, 63, 120, 0.25) 0);
}

.benchmark-card.paper-ct {
  --benchmark-bg-image: url("../images/gallery/bg/confusedtourist.png");
}

.paper-card.paper-ttk .paper-title-highlight,
.resource-card.paper-ttk .paper-title-highlight,
.benchmark-card.paper-ttk .paper-title-highlight {
  background-image: linear-gradient(transparent 60%, rgba(43, 95, 98, 0.26) 0);
}

.benchmark-card.paper-ttk {
  --benchmark-bg-image: url("../images/gallery/bg/mixcube.png");
}

.paper-links {
  margin-top: auto;
  display: grid;
  gap: 10px;
}

.paper-links a,
.resource-link {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
  min-height: 40px;
  padding: 0 14px;
  border-radius: 999px;
  border: 0;
  background: var(--background-secondary);
  color: var(--text-primary);
}

.paper-links a::before {
  content: "";
  width: 20px;
  height: 20px;
  flex: 0 0 20px;
  background-repeat: no-repeat;
  background-position: center;
  background-size: contain;
}

.paper-links .paper-link-paper {
  color: #7f1d1d;
  background: #ffe4e6;
  font-weight: 800;
}

.paper-links .paper-link-paper::before {
  background-image: url("../images/icons/arxiv.png");
}

.paper-links .paper-link-dataset {
  color: #78350f;
  background: #fef3c7;
  font-weight: 800;
}

.paper-links .paper-link-dataset::before {
  background-image: url("../images/icons/hf.png");
}

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

.compare-card,
.finding-card,
.benchmark-card,
.gallery-card,
.resource-card {
  padding: 18px;
  border-radius: 10px;
  border: 1px solid var(--border-color);
  background: #fff;
  box-shadow: var(--shadow-sm);
}

.benchmark-card {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  background: #ffffff;
}

.benchmark-card::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -2;
  background-image: var(--benchmark-bg-image);
  background-size: cover;
  background-position: center;
  opacity: 0.34;
}

.benchmark-card::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: rgba(255, 255, 255, 0.7);
}

.problem-finding-card {
  display: flex;
  align-items: flex-start;
  padding: 20px 24px;
  border-radius: 12px;
  border: 0;
  background: #ffe7eb;
  box-shadow: 0 10px 24px rgba(190, 18, 60, 0.06);
}

.problem-finding-card p {
  margin: 0;
  color: #3f1d1d;
  font-size: clamp(1.06rem, 1.75vw, 1.42rem);
  line-height: 1.5;
  font-weight: 500;
}

.problem-finding-body {
  min-width: 0;
  flex: 1;
}

.problem-finding-card strong {
  color: #7f1d1d;
  font-weight: 900;
}

.finding-metric {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin: 0 8px;
  white-space: nowrap;
}

.finding-metric img {
  width: 1.12em;
  height: 1.12em;
  object-fit: contain;
  flex: 0 0 auto;
}

.problem-finding-card p .degradation {
  color: #dc2626;
  font-size: 1.08em;
  font-weight: 900;
}

.problem-finding-note {
  display: inline-block;
  margin-top: 12px;
  color: #9f1239;
  font-size: clamp(0.88rem, 1vw, 0.96rem);
  font-weight: 750;
  line-height: 1.35;
}

.finding-card h3,
.gallery-content h3,
.benchmark-card h3,
.resource-card h3 {
  margin: 0 0 10px;
  font-size: 0.98rem;
}

.findings-section {
  background: #f0fdf4;
}

.findings-section .finding-card {
  border: 0;
}

.finding-number {
  display: block;
  margin-bottom: 12px;
  color: #166534;
  font-size: 2rem;
  font-weight: 900;
  line-height: 1;
}

.findings-section .finding-card h3 {
  color: #14532d;
  font-size: 1.1rem;
  line-height: 1.28;
}

.comparison-strip {
  display: grid;
  grid-template-columns: 1fr 60px 1fr;
  gap: 12px;
  margin-top: 18px;
  align-items: center;
}

.compare-card.accent {
  background: var(--background-accent);
}

.compare-label {
  display: inline-block;
  margin-bottom: 8px;
  color: var(--primary-color);
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.compare-arrow {
  text-align: center;
  color: var(--text-light);
  font-size: 1.6rem;
}

.gallery-controls {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 18px;
}

.dataset-tabs,
.filter-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.dataset-tab,
.filter-chip {
  padding: 10px 14px;
  border-radius: 999px;
  border: 1px solid var(--border-color);
  background: #fff;
  color: var(--text-secondary);
  cursor: pointer;
  box-shadow: 0 2px 0 rgba(15, 23, 42, 0.12), 0 8px 16px rgba(15, 23, 42, 0.04);
  transform: translateY(0);
  transition: transform 0.16s ease, box-shadow 0.16s ease, border-color 0.16s ease, background-color 0.16s ease;
}

.dataset-tab:hover,
.filter-chip:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 0 rgba(15, 23, 42, 0.14), 0 12px 18px rgba(15, 23, 42, 0.08);
}

.dataset-tab:active,
.filter-chip:active {
  transform: translateY(1px);
  box-shadow: 0 1px 0 rgba(15, 23, 42, 0.16), 0 5px 10px rgba(15, 23, 42, 0.06);
}

.dataset-tab.is-active,
.filter-chip.is-active {
  color: #fff;
  background: var(--text-primary);
  border-color: var(--text-primary);
}

.dataset-tab[data-dataset-id="world-in-a-frame"] {
  color: #274d78;
  border-color: rgba(39, 77, 120, 0.3);
  background: rgba(39, 77, 120, 0.08);
}

.dataset-tab[data-dataset-id="confused-tourist"] {
  color: #4c3f78;
  border-color: rgba(76, 63, 120, 0.3);
  background: rgba(76, 63, 120, 0.08);
}

.dataset-tab[data-dataset-id="mixcube"] {
  color: #2b5f62;
  border-color: rgba(43, 95, 98, 0.32);
  background: rgba(43, 95, 98, 0.09);
}

.dataset-tab[data-dataset-id="world-in-a-frame"].is-active {
  color: #fff;
  border-color: #274d78;
  background: #274d78;
}

.dataset-tab[data-dataset-id="confused-tourist"].is-active {
  color: #fff;
  border-color: #4c3f78;
  background: #4c3f78;
}

.dataset-tab[data-dataset-id="mixcube"].is-active {
  color: #fff;
  border-color: #2b5f62;
  background: #2b5f62;
}

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

.corpus-summary-card {
  display: flex;
  align-items: center;
  gap: 18px;
  margin: 0 0 18px;
  padding: 24px 28px;
  border-radius: 12px;
  border: 0;
  background: #fff1f2;
  box-shadow: 0 12px 28px rgba(220, 38, 38, 0.08);
}

.corpus-summary-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 54px;
  height: 54px;
  flex: 0 0 54px;
  border-radius: 14px;
  color: #ffffff;
  background: #dc2626;
  font-size: 1.7rem;
  font-weight: 800;
  line-height: 1;
  box-shadow: 0 10px 22px rgba(220, 38, 38, 0.22);
}

.corpus-summary-main {
  min-width: 0;
  flex: 1;
}

.corpus-summary-kicker {
  margin: 0 0 6px;
  color: #b91c1c;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.corpus-summary-line {
  margin: 0;
  color: #1e293b;
  font-size: clamp(1.38rem, 2.65vw, 2.25rem);
  line-height: 1.24;
  font-weight: 650;
}

.corpus-summary-line strong {
  color: #dc2626;
  font-size: 1.25em;
  font-weight: 900;
}

.corpus-summary-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}

.corpus-summary-chips span {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 5px 12px;
  border-radius: 999px;
  color: #0f172a;
  background: rgba(255, 255, 255, 0.82);
  border: 0;
  font-size: 0.84rem;
  font-weight: 800;
}

.gallery-strip-wrap {
  overflow-x: auto;
  overflow-y: visible;
  scroll-snap-type: x mandatory;
  scroll-padding-inline: 4px;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior-x: contain;
  padding-bottom: 10px;
  margin-inline: -8px;
  padding-inline: 8px;
  cursor: grab;
  scrollbar-gutter: stable;
}

.gallery-strip-wrap.is-dragging {
  cursor: grabbing;
  user-select: none;
}

.gallery-grid {
  display: flex;
  flex-direction: row;
  flex-wrap: nowrap;
  gap: 16px;
  width: max-content;
  min-height: 0;
}

.gallery-card {
  flex: 0 0 min(300px, calc(100vw - 48px));
  max-width: 320px;
  scroll-snap-align: start;
  padding: 0;
  overflow: hidden;
}

.gallery-image {
  position: relative;
  min-height: 220px;
  display: flex;
  align-items: flex-start;
  padding: 16px;
  background: linear-gradient(135deg, #64748b 0%, #1e293b 100%);
  background-size: cover;
  background-position: center;
}

.gallery-image::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.05), rgba(15, 23, 42, 0.18));
}

.gallery-image-zoom {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 0;
  background: rgba(15, 23, 42, 0.14);
  color: rgba(255, 255, 255, 0.92);
  font-size: 0.95rem;
  font-weight: 700;
  cursor: pointer;
  opacity: 0;
  transition: var(--transition);
}

.gallery-image:hover .gallery-image-zoom,
.gallery-image-zoom:focus-visible {
  opacity: 1;
}

.ground-truth-pill {
  position: relative;
  z-index: 1;
}

.gallery-content {
  padding: 18px;
}

.gallery-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.gallery-head h3 {
  margin: 0;
}

.gallery-content .gallery-culture-lines {
  margin: 0 0 12px;
  font-size: 0.9rem;
  line-height: 1.55;
  color: var(--text-secondary);
}

.gallery-content .gallery-culture-lines .culture-label {
  font-weight: 700;
  color: var(--text-primary);
  margin-right: 4px;
}

.lineage-card {
  flex: 0 0 min(420px, calc(100vw - 48px));
  max-width: 440px;
}

.lineage-content {
  display: grid;
  gap: 12px;
}

.lineage-block {
  display: grid;
  gap: 8px;
}

.lineage-block strong {
  font-size: 0.82rem;
  letter-spacing: 0.02em;
}

.lineage-image-single {
  display: block;
  width: 100%;
  height: 170px;
  border-radius: 10px;
  background-size: cover;
  background-position: center;
  border: 1px solid var(--border-color);
  background-color: transparent;
  cursor: zoom-in;
}

.lineage-mini-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.lineage-mini-grid.compact {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.lineage-mini {
  display: grid;
  gap: 6px;
}

.lineage-mini-image {
  display: block;
  width: 100%;
  height: 78px;
  border-radius: 8px;
  background-size: cover;
  background-position: center;
  border: 1px solid var(--border-color);
  background-color: transparent;
  cursor: zoom-in;
}

.lineage-mini span {
  font-size: 0.72rem;
  color: var(--text-secondary);
  line-height: 1.35;
}

.mixcube-lineage-card {
  flex: 0 0 min(460px, calc(100vw - 48px));
  max-width: 480px;
}

.mixcube-lineage-content {
  display: grid;
  gap: 12px;
}

.mixcube-original-block,
.mixcube-variant-block {
  display: grid;
  gap: 8px;
}

.mixcube-original-block strong,
.mixcube-variant-block strong {
  font-size: 0.82rem;
  letter-spacing: 0.02em;
}

.mixcube-original-image,
.mixcube-variant-image {
  display: block;
  width: 100%;
  border: 1px solid var(--border-color);
  background-color: transparent;
  background-position: center;
  background-size: cover;
  cursor: zoom-in;
}

.mixcube-original-image {
  height: 220px;
  border-radius: 10px;
}

.mixcube-variant-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.mixcube-variant {
  display: grid;
  gap: 6px;
  min-width: 0;
}

.mixcube-variant-image {
  height: 76px;
  border-radius: 8px;
}

.mixcube-variant span {
  color: var(--text-secondary);
  font-size: 0.72rem;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.image-lightbox {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: none;
  place-items: center;
  background: rgba(2, 6, 23, 0.86);
  padding: 20px;
}

.image-lightbox.is-open {
  display: grid;
}

.lightbox-image {
  max-width: min(92vw, 1300px);
  max-height: 88vh;
  border-radius: 12px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.45);
}

.lightbox-caption {
  margin: 12px 0 0;
  color: #e2e8f0;
  font-size: 0.92rem;
  text-align: center;
  max-width: min(92vw, 980px);
}

.lightbox-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 999px;
  font-size: 1.6rem;
  line-height: 1;
  color: #fff;
  background: rgba(15, 23, 42, 0.75);
  cursor: pointer;
}

.gallery-content .gallery-description {
  margin: 0 0 12px;
  font-size: 0.9rem;
  line-height: 1.55;
}

.gallery-content .gallery-prompt {
  margin: 0;
  font-size: 0.88rem;
  font-style: italic;
  opacity: 0.95;
}

.gallery-card-tourist {
  flex-basis: min(360px, calc(100vw - 48px));
  max-width: 380px;
  background: #ffffff;
  border-color: #dbe4ee;
  box-shadow: 0 8px 26px rgba(15, 23, 42, 0.08);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.gallery-card-tourist:hover {
  transform: translateY(-3px);
  box-shadow: 0 14px 34px rgba(15, 23, 42, 0.12);
}

.tourist-image-button {
  display: block;
  width: 100%;
  height: 230px;
  padding: 0;
  border: 0;
  border-bottom: 1px solid #e2e8f0;
  background: #f1f5f9;
  cursor: zoom-in;
  overflow: hidden;
}

.tourist-image-button img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.2s ease;
}

.tourist-image-button:hover img,
.tourist-image-button:focus-visible img {
  transform: scale(1.03);
}

.tourist-card-content {
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-height: 342px;
  padding: 18px;
}

.tourist-prompt {
  flex: 1;
  margin: 0;
  color: #334155;
  font-size: 0.95rem;
  line-height: 1.5;
  white-space: pre-line;
}

.tourist-info-box {
  display: grid;
  gap: 7px;
  padding: 12px;
  border: 1px solid #dbe4ee;
  border-radius: 8px;
  background: #f8fafc;
}

.tourist-info-row {
  display: grid;
  grid-template-columns: max-content minmax(0, 1fr);
  gap: 6px;
  align-items: baseline;
}

.tourist-info-label {
  font-size: 0.86rem;
  font-weight: 800;
}

.tourist-name-label {
  color: #334155;
}

.tourist-origin-label {
  color: #166534;
}

.tourist-distractor-label {
  color: #991b1b;
}

.tourist-info-value {
  color: #475569;
  font-size: 0.88rem;
  line-height: 1.4;
}

.tourist-card-footer {
  display: grid;
  gap: 12px;
}

.tourist-category-pill {
  justify-self: start;
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 5px 12px;
  border-radius: 999px;
  color: #ffffff;
  background: #475569;
  font-size: 0.82rem;
  font-weight: 700;
}

.tourist-copy-buttons {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.tourist-copy-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 42px;
  padding: 8px 10px;
  border-radius: 8px;
  border: 1px solid #cbd5e1;
  background: #e2e8f0;
  color: #475569;
  font-weight: 700;
  font-size: 0.86rem;
  line-height: 1.2;
  cursor: pointer;
  transition: var(--transition);
}

.tourist-copy-image {
  border-color: #93c5fd;
  background: #dbeafe;
  color: #1e40af;
}

.tourist-copy-btn:hover {
  transform: translateY(-1px);
  filter: brightness(0.98);
}

.tourist-copy-btn.is-copied {
  border-color: #6ee7b7;
  background: #d1fae5;
  color: #065f46;
}

.tourist-copy-btn.is-copy-failed {
  border-color: #fca5a5;
  background: #fee2e2;
  color: #991b1b;
}

.tourist-copy-btn.is-copying {
  opacity: 0.72;
  cursor: progress;
}

.copy-icon,
.image-icon {
  position: relative;
  width: 16px;
  height: 16px;
  flex: 0 0 16px;
}

.copy-icon::before,
.copy-icon::after {
  content: "";
  position: absolute;
  width: 9px;
  height: 11px;
  border: 2px solid currentColor;
  border-radius: 2px;
}

.copy-icon::before {
  left: 2px;
  top: 4px;
}

.copy-icon::after {
  left: 6px;
  top: 1px;
  background: currentColor;
  opacity: 0.18;
}

.image-icon {
  border: 2px solid currentColor;
  border-radius: 3px;
}

.image-icon::before {
  content: "";
  position: absolute;
  left: 3px;
  bottom: 3px;
  width: 8px;
  height: 6px;
  background: currentColor;
  clip-path: polygon(0 100%, 36% 35%, 55% 62%, 72% 42%, 100% 100%);
}

.ground-truth-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 14px;
}

.ground-truth-pill {
  color: #085041;
  background: #e1f5ee;
}

.benchmark-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 10px;
}

.benchmark-stats {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin: 18px 0 14px;
}

.benchmark-stat {
  min-height: 108px;
  padding: 14px 14px;
  border-radius: var(--border-radius);
  background: rgba(255, 255, 255, 0.82);
  border: 1px solid rgba(203, 213, 225, 0.62);
  box-shadow: 0 10px 22px rgba(15, 23, 42, 0.04);
}

.benchmark-stat-label {
  display: block;
  margin-bottom: 4px;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-secondary);
}

.benchmark-card.paper-wif .benchmark-stat-label {
  color: #1d4ed8;
}

.benchmark-card.paper-ct .benchmark-stat-label {
  color: #6d28d9;
}

.benchmark-card.paper-ttk .benchmark-stat-label {
  color: #047857;
}

.benchmark-stat-value {
  display: block;
  font-size: 0.94rem;
  font-weight: 700;
  color: var(--text-primary);
  line-height: 1.3;
}

.benchmark-card.paper-wif .benchmark-stat-value {
  color: #1e3a8a;
}

.benchmark-card.paper-ct .benchmark-stat-value {
  color: #4c1d95;
}

.benchmark-card.paper-ttk .benchmark-stat-value {
  color: #064e3b;
}

.benchmark-paper-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 36px;
  padding: 0 14px;
  border-radius: 999px;
  color: #0f172a;
  background: rgba(255, 255, 255, 0.84);
  border: 1px solid rgba(203, 213, 225, 0.72);
  font-size: 0.86rem;
  font-weight: 800;
  transition: var(--transition);
}

.benchmark-paper-link:hover {
  transform: translateY(-1px);
  border-color: rgba(37, 99, 235, 0.36);
  box-shadow: var(--shadow-sm);
}

.resources-stack {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  align-items: stretch;
}

.resource-card {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-width: 0;
  height: 100%;
}

.resource-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 14px;
}

.citation-block {
  position: relative;
  min-width: 0;
  flex: 1;
}

.citation-copy-icon {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 28px;
  height: 28px;
  border-radius: 6px;
  border: 1px solid #334155;
  background: rgba(15, 23, 42, 0.72);
  cursor: pointer;
  transition: var(--transition);
}

.citation-copy-icon::before,
.citation-copy-icon::after {
  content: "";
  position: absolute;
  width: 10px;
  height: 10px;
  border: 1.5px solid #e2e8f0;
  border-radius: 2px;
}

.citation-copy-icon::before {
  top: 8px;
  left: 8px;
}

.citation-copy-icon::after {
  top: 5px;
  left: 11px;
  background: rgba(15, 23, 42, 0.72);
}

.citation-copy-icon:hover {
  border-color: #64748b;
  background: rgba(15, 23, 42, 0.9);
}

.citation-copy-icon.is-copied {
  border-color: #22d3ee;
}

.resource-card pre {
  margin: 0;
  padding: 14px 12px 12px;
  border-radius: var(--border-radius);
  background: #0f172a;
  color: #e2e8f0;
  overflow: auto;
  white-space: pre-wrap;
  word-break: break-word;
  font-size: 0.78rem;
  line-height: 1.45;
  max-height: 220px;
  min-height: 220px;
}

.contributors-section {
  background: var(--background-secondary);
}

.university-section {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(28px, 6vw, 72px);
  margin: 0 auto 28px;
  padding: 6px 0 12px;
}

.university-logo {
  display: block;
  width: auto;
  object-fit: contain;
}

.university-logo-kaist {
  max-width: min(34vw, 260px);
  max-height: 92px;
}

.university-logo-mbzuai {
  max-width: min(32vw, 270px);
  max-height: 68px;
}

.contributors-block + .contributors-block {
  margin-top: 26px;
}

.contributors-subheading {
  margin: 0 0 12px;
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #475569;
}

.contributors-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 14px;
}

.contributors-grid-compact {
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
}

.contributor-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 16px 12px;
  border-radius: 14px;
  border: 1px solid var(--border-color);
  background: #fff;
  box-shadow: var(--shadow-sm);
  text-align: center;
  color: var(--text-primary);
  transition: var(--transition);
}

.contributor-card.is-linked:hover {
  transform: translateY(-2px);
  border-color: rgba(37, 99, 235, 0.4);
  box-shadow: var(--shadow-md);
}

.contributor-avatar {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 64px;
  height: 64px;
  border-radius: 50%;
  overflow: hidden;
  flex: 0 0 auto;
  font-weight: 700;
  font-size: 1.05rem;
  letter-spacing: 0.02em;
  color: #fff;
  background: linear-gradient(
    135deg,
    hsl(var(--avatar-hue, 210), 55%, 48%) 0%,
    hsl(calc(var(--avatar-hue, 210) + 30), 55%, 38%) 100%
  );
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.18);
}

.contributor-avatar-photo {
  background: var(--background-accent);
  object-fit: cover;
}

img.contributor-avatar-photo {
  width: 64px;
  height: 64px;
}

.contributor-name {
  font-size: 0.92rem;
  font-weight: 600;
  line-height: 1.3;
  color: var(--text-primary);
}

.contributor-affiliation {
  font-size: 0.78rem;
  color: var(--text-secondary);
  line-height: 1.35;
}

.contributors-empty {
  margin: 0;
  padding: 16px;
  border: 1px dashed var(--border-color);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.6);
  color: var(--text-secondary);
  font-size: 0.9rem;
  text-align: center;
}

@media (max-width: 1040px) {
  .paper-card,
  .resource-card {
    grid-template-columns: 1fr;
  }

  .resources-stack {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .benchmark-grid,
  .findings-grid,
  .hero-carousel-track,
  .hero-example-grid,
  .hero-action-links {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .hero-example-grid .hero-example-link:last-child,
  .benchmark-grid .benchmark-card:last-child,
  .findings-grid .finding-card:last-child {
    grid-column: 1 / -1;
    width: min(100%, calc((100% - 12px) / 2));
    justify-self: center;
  }

  .venue-badge-floating {
    position: static;
    justify-self: end;
    margin-bottom: -4px;
  }

  .paper-title-row h3 {
    overflow-wrap: anywhere;
  }

  .corpus-summary-card {
    align-items: flex-start;
  }

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

@media (max-width: 720px) {
  .page-shell {
    width: min(calc(100% - 16px), 1180px);
  }

  .topbar {
    position: static;
    align-items: flex-start;
    border-radius: var(--border-radius-lg);
  }

  .topnav {
    gap: 10px;
  }

  .hero-section,
  .section-block {
    padding: 22px;
  }

  .section-heading-with-icon {
    min-height: 46px;
    padding-left: 56px;
  }

  .section-icon {
    width: 40px;
    height: 40px;
  }

  .hero-carousel-track,
  .hero-example-grid,
  .hero-action-links,
  .benchmark-grid,
  .findings-grid {
    grid-template-columns: 1fr;
  }

  .corpus-summary-card {
    flex-direction: column;
    padding: 18px;
  }

  .university-section {
    flex-direction: column;
    gap: 18px;
  }

  .university-logo-kaist,
  .university-logo-mbzuai {
    max-width: min(82vw, 320px);
  }

  .problem-finding-card {
    flex-direction: column;
    gap: 12px;
    padding: 16px;
  }

  .problem-finding-card p {
    font-size: clamp(0.98rem, 4.6vw, 1.22rem);
  }

  .finding-metric {
    margin: 4px 6px 0 0;
  }
  .resources-stack {
    grid-template-columns: 1fr;
  }

  .hero-copy {
    text-align: center;
  }

  .hero-actions {
    justify-content: center;
  }

  .comparison-strip {
    grid-template-columns: 1fr;
  }

  .compare-arrow {
    transform: rotate(90deg);
  }

  .paper-card {
    grid-template-columns: 1fr;
  }

  .hero-example-grid {
    justify-items: center;
  }

  .hero-example-grid .hero-example-link,
  .hero-example-grid .hero-example-link:last-child,
  .benchmark-grid .benchmark-card,
  .benchmark-grid .benchmark-card:last-child,
  .findings-grid .finding-card,
  .findings-grid .finding-card:last-child {
    grid-column: auto;
    width: min(100%, 360px);
    justify-self: center;
  }

  .paper-links {
    margin-top: 0;
  }

  .contributors-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
