/* ============================================================
   BarySLAM �?Clean White Minimal Academic Theme
   ============================================================ */

:root {
  --bg:        #ffffff;
  --bg-alt:    #f7f7f9;
  --ink:       #1a1a1a;
  --ink-soft:  #444444;
  --ink-dim:   #6b6b6b;
  --rule:      #e2e2e6;
  --accent:    #3b51c3;   /* refined indigo, used sparingly */
  --accent-d:  #2a3c99;
  --accent-l:  #eef1fb;
}

html { scroll-behavior: smooth; }

body {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  color: var(--ink);
  background: var(--bg);
  font-size: 16px;
  line-height: 1.7;
}

::selection { background: var(--accent-l); color: var(--accent-d); }

/* ---------- Typography ---------- */
h1, h2, h3, h4 { font-family: 'Inter', system-ui, sans-serif; color: var(--ink); }

.section-title {
  font-family: 'Lora', Georgia, serif;
  font-weight: 500;
  font-size: 1.9rem;
  letter-spacing: 0.2px;
  color: var(--ink);
  position: relative;
  display: inline-block;
  padding-bottom: 0.35rem;
  margin-bottom: 1.4rem;
}
.section-title::after {
  content: "";
  position: absolute; left: 0; bottom: 0;
  width: 48px; height: 2px;
  background: var(--accent);
}
.section-title.is-centered { display: inline-block; }
.section-title.is-centered::after { left: 50%; transform: translateX(-50%); }

/* ---------- Navbar ---------- */
.navbar {
  background: rgba(255,255,255,0.92);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--rule);
  position: sticky; top: 0; z-index: 30;
}
.navbar-item, .navbar-link {
  color: var(--ink-soft) !important;
  font-family: 'Inter', sans-serif;
  font-weight: 500;
  font-size: 0.95rem;
}
.navbar-item:hover, .navbar-link:hover {
  color: var(--accent) !important;
  background: transparent !important;
}
.navbar-link::after { border-color: var(--ink-dim); }
.navbar-burger { color: var(--ink-soft); }
.navbar-menu { background: #fff; }
.navbar-brand .navbar-item { font-weight: 700; color: var(--accent) !important; }

/* ---------- Hero ---------- */
.hero {
  background: var(--bg);
  position: relative;
  padding-bottom: 1rem;
}
.hero::before { display: none; }

.publication-title {
  font-family: 'Lora', Georgia, serif;
  font-weight: 500;
  font-size: clamp(1.8rem, 3.8vw, 2.9rem);
  line-height: 1.25;
  color: var(--ink);
  letter-spacing: -0.2px;
}
.title-accent { color: var(--accent); }

.venue-badge {
  display: inline-block;
  margin-bottom: 0.8rem;
  padding: 0.2rem 0.85rem;
  border: 1px solid var(--accent);
  border-radius: 999px;
  background: var(--accent-l);
  color: var(--accent-d);
  font-family: 'Inter', sans-serif;
  font-weight: 600;
  font-size: 0.8rem;
  letter-spacing: 0.4px;
  white-space: nowrap;
}

.venue-badge.hero-badge {
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  line-height: 1.3;
  padding: 0.5rem 0.85rem;
  margin-bottom: 0;
  margin-top: 0.5rem;
  border-radius: 10px;
  font-size: 0.78rem;
  text-align: center;
}

@media screen and (max-width: 768px) {
  .hero-row { flex-direction: column !important; }
  .hero-row .hero-badge { align-self: flex-start; }
}

.publication-authors {
  font-family: 'Inter', sans-serif;
  color: var(--ink);
}
.publication-authors a { color: var(--accent) !important; }
.publication-authors a:hover { text-decoration: underline; }
.author-block { display: inline-block; }
.affil { color: var(--ink-dim); font-size: 0.95rem; }

/* ---------- Link buttons ---------- */
.publication-links .link-block a {
  background: #fff;
  border: 1px solid var(--ink);
  color: var(--ink);
  font-family: 'Inter', sans-serif;
  font-weight: 500;
  transition: all 0.18s ease;
}
.publication-links .link-block a:hover {
  background: var(--ink);
  color: #fff;
  transform: translateY(-1px);
}
.publication-links .link-block a:hover .icon i { color: #fff; }

/* ---------- Sections ---------- */
.section {
  background: var(--bg);
  padding: 4rem 0;
}
.section.is-alt { background: var(--bg-alt); }
.section .container { max-width: 920px; }

.content { color: var(--ink-soft); }
.content p { line-height: 1.8; }
.content a { color: var(--accent); text-decoration: none; }
.content a:hover { text-decoration: underline; }
.content b, .content strong { color: var(--ink); }

/* ---------- Method cards (simple, flat) ---------- */
.method-card {
  background: #fff;
  border: 1px solid var(--rule);
  border-radius: 10px;
  padding: 1.5rem 1.6rem;
  height: 100%;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
.method-card:hover {
  border-color: var(--accent);
  box-shadow: 0 2px 12px rgba(0,0,0,0.05);
}
.method-card .card-tag {
  display: inline-block;
  font-family: 'Inter', sans-serif;
  font-weight: 700;
  letter-spacing: 1px;
  font-size: 0.72rem;
  text-transform: uppercase;
  color: #fff;
  background: var(--accent);
  padding: 0.15rem 0.6rem;
  border-radius: 4px;
  margin-bottom: 0.7rem;
}
.method-card h3 {
  color: var(--ink);
  font-size: 1.15rem;
  margin-bottom: 0.5rem;
}
.method-card p { font-size: 0.95rem; line-height: 1.7; color: var(--ink-soft); }

/* ---------- Placeholders ---------- */
.placeholder {
  position: relative;
  width: 100%;
  border: 1px dashed #c4c4cc;
  border-radius: 10px;
  background: #fafafa;
  overflow: hidden;
}
.placeholder img { display: block; width: 100%; }
.placeholder .ph-label {
  position: absolute;
  left: 50%; bottom: 0.7rem;
  transform: translateX(-50%);
  font-family: 'Inter', sans-serif;
  font-size: 0.8rem;
  color: var(--ink-dim);
  background: rgba(255,255,255,0.9);
  padding: 0.2rem 0.7rem;
  border-radius: 999px;
  border: 1px solid var(--rule);
  white-space: nowrap;
}

/* ---------- Video ---------- */
.publication-video {
  position: relative;
  width: 100%; height: 0;
  padding-bottom: 56.25%;
  overflow: hidden;
  border-radius: 10px;
  border: 1px solid var(--rule);
  background: var(--bg-alt);
}
.publication-video iframe,
.publication-video video {
  position: absolute; top: 0; left: 0;
  width: 100%; height: 100%; border: 0;
}
.video-ph {
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  color: var(--ink-dim);
  font-family: 'Inter', sans-serif;
}

/* ---------- Tables ---------- */
.results-table-wrap {
  overflow-x: auto;
  border: 1px solid var(--rule);
  border-radius: 10px;
  background: #fff;
}
table.results {
  width: 100%;
  border-collapse: collapse;
  font-family: 'Inter', sans-serif;
  font-size: 0.9rem;
  color: var(--ink-soft);
}
table.results thead th {
  background: var(--bg-alt);
  color: var(--ink);
  font-weight: 600;
  padding: 0.65rem 0.6rem;
  border-bottom: 2px solid var(--rule);
  white-space: nowrap;
}
table.results td {
  padding: 0.5rem 0.6rem;
  text-align: center;
  border-bottom: 1px solid var(--rule);
}
table.results td.method {
  text-align: left;
  font-weight: 500;
  color: var(--ink);
}
table.results tr.ours { background: var(--accent-l); }
table.results tr.ours td { color: var(--ink); font-weight: 600; }
table.results tr.ours td.method { color: var(--accent-d); }
table.results .best { font-weight: 700; color: var(--accent-d); }
table.results tbody tr:hover { background: #f5f5f8; }
table.results tr.ours:hover { background: #e6ecfb; }
.table-caption {
  font-size: 0.85rem;
  color: var(--ink-dim);
  margin-top: 0.6rem;
  line-height: 1.55;
}

/* ---------- Math / KaTeX ---------- */
.eq-block {
  background: var(--bg-alt);
  border: 1px solid var(--rule);
  border-left: 3px solid var(--accent);
  border-radius: 8px;
  padding: 1rem 1.2rem;
  margin: 1rem 0;
  overflow-x: auto;
}
.eq-block .katex { font-size: 1rem; }
.eq-label {
  display: block;
  font-family: 'Inter', sans-serif;
  font-size: 0.74rem;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 0.3rem;
  font-weight: 600;
}

/* ---------- Teaser ---------- */
.teaser .hero-body { padding-top: 0; padding-bottom: 2.5rem; }
.teaser { font-family: 'Inter', sans-serif; }
.teaser .subtitle { color: var(--ink-dim); }

/* ---------- BibTeX ---------- */
.bibtex pre {
  background: var(--bg-alt);
  border: 1px solid var(--rule);
  border-radius: 10px;
  padding: 1.1rem 1.3rem;
  color: var(--ink-soft);
  font-family: 'JetBrains Mono', 'Consolas', monospace;
  font-size: 0.85rem;
  line-height: 1.7;
  overflow-x: auto;
}
.bibtex pre .k { color: var(--accent-d); font-weight: 600; }
.bibtex pre .s { color: #7a5a00; }

/* ---------- Footer ---------- */
.footer {
  background: var(--bg-alt);
  border-top: 1px solid var(--rule);
  padding: 2.5rem 0;
  color: var(--ink-dim);
}
.footer .icon-link { font-size: 20px; color: var(--ink-soft); margin: 0 0.4rem; }
.footer .icon-link:hover { color: var(--accent); }
.footer a { color: var(--accent); }

/* ---------- Carousel ---------- */
.results-carousel { overflow: hidden; }
.results-carousel .item {
  margin: 5px;
  overflow: hidden;
  border: 1px solid var(--rule);
  border-radius: 10px;
  padding: 0;
  font-size: 0;
  background: #fff;
}

/* ---------- Misc ---------- */
hr.soft {
  border: 0; height: 1px;
  background: var(--rule);
  margin: 2.5rem 0;
}

