*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
:root {
  --black: #111;
  --gray: #555;
  --light: #999;
  --border: #e4e4e4;
  --bg: #f8f8f7;
  --red: #dc2626;
  --content-width: 900px;
  --dataset-width: 1200px;
}
html { scroll-behavior: smooth; }
body { 
  font-family: 'DM Sans', sans-serif; 
  background: #fff; 
  color: var(--black); 
  font-size: 16px; 
  line-height: 1.7;
  position: relative;
}

/* NAV */
nav {
  position: sticky; top: 0; z-index: 200;
  background: rgba(255,255,255,0.93); backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
  height: 52px; padding: 0 2.5rem;
  display: flex; align-items: center; justify-content: space-between;
}
.nav-logo { font-family: 'DM Sans', serif; font-size: 1.15rem; font-weight: 600; color: var(--black); text-decoration: none; }
.nav-links { display: flex; gap: 1.6rem; list-style: none; }
.nav-links a { font-size: 0.8rem; color: var(--gray); text-decoration: none; letter-spacing: 0.04em; transition: color .2s; }
.nav-links a:hover { color: var(--black); }

/* HERO */
.hero { max-width: var(--content-width); margin: 0 auto; padding: 76px 2rem 48px; text-align: center; }
.hero h1 {
  font-family: 'Inter', 'DM Sans', sans-serif;
  font-size: clamp(1.85rem, 4.5vw, 2.95rem);
  font-weight: 600; line-height: 1.18; letter-spacing: -0.015em; margin-bottom: 30px;
  color: #111;
}
.authors { font-size: 0.92rem; color: var(--gray); margin-bottom: 6px; line-height: 2.1; }
.authors a { color: var(--black); text-decoration: none; font-weight: 500; }
.authors a:hover { text-decoration: underline; }
.authors sup { font-size: 0.6rem; color: var(--light); }
.affiliations { font-size: 0.79rem; color: var(--light); margin-bottom: 34px; line-height: 1.8; }
.btn-group { display: flex; gap: 9px; justify-content: center; flex-wrap: wrap; }
.btn {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 0.82rem; font-weight: 500; padding: 8px 17px; border-radius: 50px;
  text-decoration: none; transition: all .2s; border: 1.5px solid transparent; white-space: nowrap;
}
.btn-primary { background: var(--black); color: #fff; }
.btn-primary:hover { background: #2a2a2a; }
.btn-outline { background: #fff; color: var(--black); border-color: var(--border); }
.btn-outline:hover { border-color: #aaa; background: var(--bg); }
.btn svg { width: 14px; height: 14px; flex-shrink: 0; }

/* SECTIONS — all use same consistent width except dataset */
.sec { max-width: var(--content-width); margin: 0 auto; padding: 0 2rem 72px; }
.sec-content { max-width: var(--content-width); margin: 0 auto; padding: 0 2rem 72px; }
.sec-dataset { max-width: var(--dataset-width); margin: 0 auto; padding: 0 2rem 72px; }

.sec-rule { border: none; border-top: 1px solid var(--border); margin-bottom: 44px; }
.sec h2, .sec-content h2, .sec-dataset h2, section h2 {
  font-family: 'DM Sans', serif; color: #444; font-size: 2.4rem; font-weight: 700;
  margin-bottom: 14px; letter-spacing: -0.01em; text-align: center;
}
.sec p, .sec-content p, .sec-dataset p { color: var(--gray); font-size: 0.95rem; margin-bottom: 14px; }

/* TEASER */
.teaser-wrap { max-width: var(--content-width); margin: 0 auto 72px; padding: 0 2rem; }
.video-full {
  border-radius: 10px; overflow: hidden;
  border: 1px solid var(--border);
  background: #0a0a0a; aspect-ratio: 16/9; position: relative;
  display: flex; align-items: center; justify-content: center;
}
.video-full video { width: 100%; height: 100%; display: block; object-fit: cover; position: absolute; inset: 0; }

.image-full {
  border-radius: 10px;
  overflow: hidden;
}

/* ABSTRACT */
.abstract-box {
  background: var(--bg); border: 1px solid var(--border); border-radius: 8px;
  padding: 26px 30px; font-size: 0.95rem; color: #444; line-height: 1.85;
  margin-bottom: 36px;
}

/* DATASET CASES — wider grid */
.dataset-cases {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
  margin-top: 30px;
}

.case-card {
  border: 1px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
  background: #fff;
  transition: box-shadow .2s;
}
.case-card:hover {
  box-shadow: 0 6px 20px rgba(0,0,0,.08);
}

.case-video {
  aspect-ratio: 1/1;
  background: #0f0f0f;
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}
.case-video video {
  width: 100%; height: 100%; object-fit: cover;
  display: block; position: absolute; inset: 0;
}

.play-overlay {
  position: absolute; inset: 0; z-index: 2;
  display: flex; align-items: center; justify-content: center;
  background: rgba(0,0,0,.22); transition: background .2s, opacity .2s; cursor: pointer;
}
.play-overlay:hover { background: rgba(0,0,0,.1); }
.play-overlay svg { width: 38px; height: 38px; opacity: .88; }

.case-info {
  padding: 12px 14px;
  border-top: 1px solid var(--border);
}

.case-tag {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  padding: 3px 10px;
  border-radius: 4px;
  margin-bottom: 8px;
  line-height: 1.5;
}

.action-tag {
  background: #eef2ff;
  color: #4338ca;
  border: 1px solid #c7d2fe;
}

.expression-tag {
  background: #fef3c7;
  color: #92400e;
  border: 1px solid #fcd34d;
}

.case-dialogue {
  font-size: 0.85rem;
  color: var(--gray);
  line-height: 1.55;
  font-style: italic;
  position: relative;
  padding-left: 14px;
}
.case-dialogue::before {
  content: '"';
  position: absolute;
  left: 0;
  top: -2px;
  font-size: 1.2rem;
  color: var(--light);
  font-family: 'EB Garamond', serif;
}

/* RESULTS TABLE */
.results-table { width: 100%; border-collapse: collapse; font-size: 0.85rem; margin-top: 8px; }
.results-table th {
  font-size: 0.72rem; font-weight: 600; letter-spacing: 0.05em; text-transform: uppercase;
  color: var(--light); padding: 10px 12px; border-bottom: 2px solid var(--border); text-align: center;
}
.results-table th:first-child, .results-table th:nth-child(2) { text-align: left; }
.results-table td { padding: 9px 12px; color: var(--gray); border-bottom: 1px solid #f0f0f0; text-align: center; }
.results-table td:first-child { color: var(--black); text-align: left; font-weight: 500; }
.results-table td:nth-child(2) { text-align: left; }
.results-table tr:last-child td { border-bottom: none; }
.results-table .real-row td { color: var(--light); font-style: italic; }
.results-table .group-header td {
  padding: 12px 12px 6px; border-bottom: none;
  font-size: 0.8rem; color: var(--gray); font-weight: 500;
}
.results-table .ours-row td { color: var(--black); font-weight: 600; background: #f0f7ff; }
.results-table .improve-row td {
  color: #16a34a; font-weight: 600; font-size: 0.8rem;
  background: #f0fdf4; border-top: 2px solid var(--border);
}

/* BIBTEX */
.bibtex {
  background: var(--bg); border: 1px solid var(--border); border-radius: 8px;
  padding: 20px 24px; font-family: 'Courier New', monospace;
  font-size: 0.8rem; color: #444; line-height: 1.85; overflow-x: auto; position: relative;
  white-space: pre-wrap; word-wrap: break-word;
}
.copy-btn {
  position: absolute; top: 12px; right: 12px;
  font-size: 0.72rem; font-family: 'DM Sans', sans-serif;
  padding: 3px 11px; border-radius: 4px; border: 1px solid var(--border);
  background: #fff; cursor: pointer; color: var(--gray); transition: all .2s;
}
.copy-btn:hover { border-color: #999; }

/* FOOTER */
footer { border-top: 1px solid var(--border); padding: 28px 2rem; text-align: center; font-size: 0.78rem; color: var(--light); }
footer a { color: var(--light); text-decoration: underline; }

/* ANIMATIONS */
@keyframes fadeUp { from { opacity:0; transform:translateY(14px); } to { opacity:1; transform:translateY(0); } }
.hero > * { animation: fadeUp .55s ease both; }
.hero h1 { animation-delay: .07s; }
.hero .authors, .hero .affiliations { animation-delay: .12s; }
.hero .btn-group { animation-delay: .18s; }

@media(max-width:860px){
  .nav-links li:nth-child(n+4) { display: none; }
  .dataset-cases { grid-template-columns: repeat(2, 1fr); }
}
@media(max-width:640px){
  nav { padding: 0 1rem; }
  .nav-links { display: none; }
  .hero, .sec, .sec-content, .sec-dataset, .teaser-wrap { padding-left: 1rem; padding-right: 1rem; }
  .dataset-cases { grid-template-columns: 1fr 1fr; }
}
@media(max-width:400px){
  .dataset-cases { grid-template-columns: 1fr; }
}
