/* ============================================================
   Efficient Hallucination Detection — Project Page
   Custom CSS (Bulma overrides + bespoke components)
   ============================================================ */

/* ─── Google Fonts ─────────────────────────────────────────── */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');

/* ─── CSS Variables ─────────────────────────────────────────── */
:root {
  --navy:        #1a2744;
  --navy-light:  #243660;
  --blue:        #2563eb;
  --blue-hover:  #1d4ed8;
  --teal:        #0ea5e9;
  --teal-light:  #e0f2fe;
  --orange:      #ea580c;
  --bg:          #ffffff;
  --bg-alt:      #f8fafc;
  --bg-alt2:     #f1f5f9;
  --border:      #e2e8f0;
  --text:        #1e293b;
  --text-muted:  #64748b;
  --radius:      12px;
  --radius-sm:   8px;
  --shadow-sm:   0 1px 3px rgba(0,0,0,.08);
  --shadow-md:   0 4px 12px rgba(0,0,0,.10);
  --shadow-lg:   0 10px 30px rgba(0,0,0,.12);
  --transition:  all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ─── Base ─────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: 'Inter', 'Segoe UI', -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 16px;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  line-height: 1.6;
}

a { color: var(--blue); transition: var(--transition); }
a:hover { color: var(--blue-hover); }

/* ─── More-Works Dropdown (fixed top-right) ─────────────────── */
.more-works-container {
  position: fixed;
  top: 1.5rem;
  right: 1.5rem;
  z-index: 1000;
}

.more-works-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  background: rgba(255,255,255,0.95);
  border: 1px solid var(--border);
  border-radius: 50px;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--navy);
  cursor: pointer;
  box-shadow: var(--shadow-md);
  backdrop-filter: blur(10px);
  transition: var(--transition);
}
.more-works-btn:hover {
  background: var(--navy);
  color: #fff;
  border-color: var(--navy);
  transform: translateY(-1px);
  box-shadow: var(--shadow-lg);
}
.more-works-btn i { font-size: 0.8rem; }

.more-works-dropdown {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  width: 360px;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  padding: 16px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-8px);
  transition: var(--transition);
}
.more-works-dropdown.is-active {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}
.dropdown-header {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 12px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--border);
}
.work-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 10px 8px;
  border-radius: var(--radius-sm);
  transition: var(--transition);
  text-decoration: none;
  color: inherit;
}
.work-item:hover {
  background: var(--bg-alt);
  transform: translateX(4px);
}
.work-item-badge {
  flex-shrink: 0;
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 0.7rem;
  font-weight: 700;
  background: var(--teal-light);
  color: #0369a1;
}
.work-item-info strong { display: block; font-size: 0.85rem; }
.work-item-info span { font-size: 0.78rem; color: var(--text-muted); }

/* ─── Hero ──────────────────────────────────────────────────── */
#hero {
  background: linear-gradient(165deg, var(--navy) 0%, #2d4a8a 60%, #1e3a70 100%);
  padding: 5rem 1.5rem 4rem;
  text-align: center;
  position: relative;
  overflow: hidden;
}
#hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.03'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
}

.venue-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 16px;
  background: linear-gradient(135deg, #ea580c, #dc2626);
  border-radius: 50px;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: .05em;
  color: #fff;
  text-transform: uppercase;
  margin-bottom: 1.5rem;
  box-shadow: 0 4px 15px rgba(234, 88, 12, 0.4);
}
.venue-badge i { font-size: 0.75rem; }

/* ─── Oral Stats Bar (hero) ──────────────────────────────────── */
.oral-stats-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0.5rem 0.75rem;
  margin-bottom: 1.25rem;
  font-size: 0.82rem;
  color: rgba(255,255,255,0.65);
}
.oral-stat-item {
  display: flex;
  align-items: center;
  gap: 5px;
}
.oral-stat-item strong { color: rgba(255,255,255,0.95); }
.oral-stat-highlight {
  background: rgba(255,255,255,0.12);
  color: rgba(255,255,255,0.9);
  padding: 4px 12px;
  border-radius: 99px;
  border: 1px solid rgba(255,255,255,0.2);
  font-weight: 600;
  gap: 6px;
}
.oral-stat-highlight strong { color: #fbbf24; }
.oral-stat-sep {
  color: rgba(255,255,255,0.25);
  font-size: 0.85em;
  line-height: 1;
}
@media (max-width: 640px) {
  .oral-stat-sep { display: none; }
  .oral-stats-bar { flex-direction: column; gap: 0.4rem; }
}

.paper-title {
  font-size: clamp(1.6rem, 4vw, 2.8rem);
  font-weight: 800;
  color: #fff;
  line-height: 1.25;
  max-width: 900px;
  margin: 0 auto 1.5rem;
  letter-spacing: -0.02em;
}

.author-list {
  font-size: 1rem;
  color: rgba(255,255,255,0.85);
  margin-bottom: 0.5rem;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}
.author-list a {
  color: rgba(255,255,255,0.95);
  font-weight: 600;
  text-decoration: none;
  transition: var(--transition);
}
.author-list a:hover { color: var(--teal); }
.author-equal { font-size: 0.75em; color: #94d8fb; vertical-align: super; }
.author-corr  { font-size: 0.75em; color: #fca5a5; vertical-align: super; }
.author-note {
  font-size: 0.82rem;
  color: rgba(255,255,255,0.5);
  margin: 0.4rem 0 0;
}

.affil-list {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  margin: 1rem 0 2rem;
}
.affil-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 14px;
  background: rgba(255,255,255,0.12);
  border: 1px solid rgba(255,255,255,0.2);
  border-radius: 50px;
  font-size: 0.82rem;
  color: rgba(255,255,255,0.85);
  backdrop-filter: blur(10px);
}
.affil-pill i { color: var(--teal); }

.button-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  margin-top: 0.5rem;
}

.pub-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  border-radius: 50px;
  font-size: 0.9rem;
  font-weight: 600;
  text-decoration: none;
  transition: var(--transition);
  cursor: pointer;
  border: 2px solid transparent;
}
.pub-btn-primary {
  background: #fff;
  color: var(--navy);
}
.pub-btn-primary:hover {
  background: var(--teal);
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(14,165,233,.4);
}
.pub-btn-outline {
  background: transparent;
  border-color: rgba(255,255,255,0.5);
  color: #fff;
}
.pub-btn-outline:hover {
  background: rgba(255,255,255,0.15);
  border-color: #fff;
  transform: translateY(-2px);
}
.pub-btn i { font-size: 0.9em; }

/* ─── Section Wrapper ────────────────────────────────────────── */
.page-section {
  padding: 4.5rem 1.5rem;
}
.page-section.alt-bg { background: var(--bg-alt); }
.page-section.dark-bg {
  background: var(--navy);
  color: #fff;
}

.section-title {
  font-size: 1.7rem;
  font-weight: 800;
  color: var(--navy);
  text-align: center;
  margin-bottom: 0.4rem;
  letter-spacing: -0.02em;
  position: relative;
  display: inline-block;
}
.section-title::after {
  content: '';
  display: block;
  width: 50px;
  height: 3px;
  background: linear-gradient(90deg, var(--blue), var(--teal));
  border-radius: 2px;
  margin: 10px auto 0;
}
.section-header {
  text-align: center;
  margin-bottom: 2.5rem;
}
.section-subtitle {
  font-size: 1rem;
  color: var(--text-muted);
  margin-top: 0.5rem;
}

.inner { max-width: 1000px; margin: 0 auto; }
.inner-wide { max-width: 1200px; margin: 0 auto; }
.inner-narrow { max-width: 720px; margin: 0 auto; }

/* ─── Teaser ─────────────────────────────────────────────────── */
#teaser {
  padding: 3rem 1.5rem 4rem;
  background: var(--bg-alt);
  text-align: center;
}
.teaser-img-wrap {
  max-width: 860px;
  margin: 0 auto 1.5rem;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--border);
}
.teaser-img-wrap img {
  width: 100%;
  display: block;
}
.teaser-caption {
  font-size: 0.9rem;
  color: var(--text-muted);
  font-style: italic;
  max-width: 700px;
  margin: 0 auto;
  line-height: 1.6;
}

/* ─── Abstract ──────────────────────────────────────────────── */
#abstract .abstract-box {
  background: #fff;
  border: 1px solid var(--border);
  border-left: 4px solid var(--blue);
  border-radius: var(--radius);
  padding: 2rem 2.5rem;
  font-size: 1rem;
  line-height: 1.85;
  color: var(--text);
  box-shadow: var(--shadow-sm);
}

/* ─── Stats Bar ─────────────────────────────────────────────── */
#stats {
  background: linear-gradient(135deg, var(--navy) 0%, #2d4a8a 100%);
  padding: 3.5rem 1.5rem;
}
.stats-header {
  text-align: center;
  margin-bottom: 2rem;
}
.stats-section-title {
  font-size: 1.4rem;
  font-weight: 800;
  color: #fff;
  letter-spacing: -0.01em;
  margin: 0 0 0.3rem;
}
.stats-section-sub {
  font-size: 0.85rem;
  color: rgba(255,255,255,0.55);
  margin: 0;
}
.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  max-width: 960px;
  margin: 0 auto;
}
.stat-item {
  text-align: center;
  padding: 1.5rem 1rem;
  position: relative;
}
.stat-item:not(:last-child)::after {
  content: '';
  position: absolute;
  right: 0;
  top: 20%;
  height: 60%;
  width: 1px;
  background: rgba(255,255,255,0.12);
}
.stat-number {
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 800;
  color: #fff;
  line-height: 1;
  letter-spacing: -0.03em;
}
.stat-number span {
  font-size: 0.55em;
  font-weight: 700;
  vertical-align: middle;
  color: var(--teal);
}
.stat-label {
  font-size: 0.82rem;
  color: rgba(255,255,255,0.75);
  margin-top: 0.5rem;
  font-weight: 600;
  letter-spacing: .02em;
}
.stat-desc {
  font-size: 0.72rem;
  color: rgba(255,255,255,0.4);
  margin-top: 0.3rem;
  line-height: 1.4;
}

/* ─── Method ─────────────────────────────────────────────────── */
#method { background: var(--bg); }

.pipeline-card {
  background: var(--bg-alt);
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  padding: 2rem 1.5rem 1.5rem;
  margin: 2rem 0;
  position: relative;
  box-shadow: var(--shadow-sm);
}
.pipeline-card-label {
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  background: linear-gradient(90deg, var(--blue), var(--teal));
  color: #fff;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
  padding: 3px 16px;
  border-radius: 50px;
  white-space: nowrap;
}

.pipeline {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0;
  margin: 2rem 0;
}
.pipeline-step {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 1rem 1.2rem;
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  min-width: 130px;
  max-width: 160px;
  box-shadow: var(--shadow-sm);
  position: relative;
}
.pipeline-step .step-icon {
  width: 44px;
  height: 44px;
  background: linear-gradient(135deg, var(--blue), var(--teal));
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 1.1rem;
  margin-bottom: 0.5rem;
}
.pipeline-step .step-label {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text);
}
.pipeline-step.decision {
  background: #fef3c7;
  border-color: #fcd34d;
}
.pipeline-step.decision .step-icon { background: linear-gradient(135deg, #f59e0b, #d97706); }
.pipeline-step.highlight {
  background: linear-gradient(135deg, #eff6ff, #e0f2fe);
  border-color: var(--blue);
}
.pipeline-step.highlight .step-icon { background: linear-gradient(135deg, var(--navy), var(--blue)); }

.pipeline-arrow {
  color: var(--text-muted);
  font-size: 1.2rem;
  margin: 0 4px;
  flex-shrink: 0;
}
.pipeline-branch {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

.contributions-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  margin-top: 2.5rem;
}
.contrib-card {
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
  transition: var(--transition);
  position: relative;
  overflow: hidden;
}
.contrib-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--blue), var(--teal));
}
.contrib-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}
.contrib-num {
  width: 32px;
  height: 32px;
  background: linear-gradient(135deg, var(--blue), var(--teal));
  color: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
  font-weight: 700;
  margin-bottom: 0.75rem;
}
.contrib-card h4 {
  font-size: 0.95rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  color: var(--navy);
}
.contrib-card p {
  font-size: 0.83rem;
  color: var(--text-muted);
  line-height: 1.6;
}

/* ─── Performance Chart ──────────────────────────────────────── */
#performance { background: var(--bg-alt); }

.chart-controls {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-bottom: 1.5rem;
  flex-wrap: wrap;
}
.chart-tab {
  padding: 7px 18px;
  border-radius: 50px;
  font-size: 0.85rem;
  font-weight: 600;
  border: 2px solid var(--border);
  background: #fff;
  color: var(--text-muted);
  cursor: pointer;
  transition: var(--transition);
}
.chart-tab:hover { border-color: var(--blue); color: var(--blue); }
.chart-tab.active {
  background: var(--blue);
  border-color: var(--blue);
  color: #fff;
}

.chart-wrap {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
  box-shadow: var(--shadow-sm);
  max-width: 1000px;
  margin: 0 auto;
}
.chart-note {
  text-align: center;
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-top: 1rem;
}

/* ─── Results Table ──────────────────────────────────────────── */
#results { background: var(--bg); }

.table-controls {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-bottom: 1.5rem;
}
.table-tab {
  padding: 7px 20px;
  border-radius: 50px;
  font-size: 0.85rem;
  font-weight: 600;
  border: 2px solid var(--border);
  background: #fff;
  color: var(--text-muted);
  cursor: pointer;
  transition: var(--transition);
}
.table-tab:hover { border-color: var(--navy); color: var(--navy); }
.table-tab.active {
  background: var(--navy);
  border-color: var(--navy);
  color: #fff;
}

.results-table-wrap {
  overflow-x: auto;
  border-radius: var(--radius);
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border);
}
.results-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.88rem;
}
.results-table thead tr {
  background: var(--navy);
  color: #fff;
}
.results-table thead th {
  padding: 0.9rem 1rem;
  font-weight: 700;
  text-align: center;
  letter-spacing: .02em;
  white-space: nowrap;
}
.results-table thead th:first-child,
.results-table thead th:nth-child(2) { text-align: left; }
.results-table tbody tr {
  border-bottom: 1px solid var(--border);
  transition: background 0.15s;
}
.results-table tbody tr:hover { background: var(--bg-alt); }
.results-table tbody tr:last-child { border-bottom: none; }
.results-table td {
  padding: 0.75rem 1rem;
  text-align: center;
  color: var(--text);
}
.results-table td:first-child,
.results-table td:nth-child(2) { text-align: left; font-weight: 600; }
.results-table td.model-cell { color: var(--text-muted); font-weight: 500; font-size: 0.82rem; }
.results-table .ours-col {
  background: linear-gradient(180deg, #eff6ff, #dbeafe);
  font-weight: 700;
  color: var(--blue);
}
.results-table .best { font-weight: 800; color: var(--navy); }
.model-row td:first-child {
  padding-left: 1.5rem;
  color: var(--text-muted);
  font-style: normal;
}
.results-table tbody tr:nth-child(4n+1) { background: var(--bg-alt2); }
.results-table tbody tr:nth-child(4n+2) { background: var(--bg-alt2); }
.results-table tbody tr:nth-child(4n+3) { background: var(--bg-alt2); }
.results-table .group-header td {
  background: #e8edf5;
  font-weight: 700;
  color: var(--navy);
  padding: 0.5rem 1rem;
  font-size: 0.8rem;
  letter-spacing: .04em;
  text-transform: uppercase;
}

/* ─── Authors ────────────────────────────────────────────────── */
#authors { background: var(--bg-alt); }

.authors-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
}
.author-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem 1rem;
  text-align: center;
  transition: var(--transition);
  box-shadow: var(--shadow-sm);
}
.author-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}
.author-photo {
  width: 100px;
  height: 100px;
  border-radius: 50%;
  object-fit: cover;
  margin: 0 auto 0.75rem;
  display: block;
  border: 3px solid var(--bg-alt);
  box-shadow: var(--shadow-sm);
}
.author-photo-placeholder {
  width: 100px;
  height: 100px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--bg-alt2), var(--border));
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 0.75rem;
  font-size: 2rem;
  color: var(--text-muted);
  border: 3px solid var(--bg-alt);
}
.author-name {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--navy);
}
.author-affil {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: 3px;
}
.author-tags {
  display: flex;
  justify-content: center;
  gap: 4px;
  margin-top: 6px;
}
.tag-equal, .tag-corr {
  font-size: 0.68rem;
  padding: 2px 7px;
  border-radius: 20px;
  font-weight: 600;
}
.tag-equal {
  background: #e0f2fe;
  color: #0369a1;
}
.tag-corr {
  background: #fee2e2;
  color: #b91c1c;
}

/* ─── Figures Gallery ────────────────────────────────────────── */
#gallery { background: var(--bg); }

.figures-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5rem;
}
.figure-card {
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
  cursor: pointer;
  background: var(--bg-alt);
}
.figure-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}
.figure-card img {
  width: 100%;
  display: block;
  aspect-ratio: 16/9;
  object-fit: contain;
  background: #fff;
  padding: 12px;
}
.figure-caption {
  padding: 0.75rem 1rem;
  font-size: 0.82rem;
  color: var(--text-muted);
  font-style: italic;
  border-top: 1px solid var(--border);
  background: #fff;
}
.figure-caption strong {
  color: var(--navy);
  font-style: normal;
}

/* ─── BibTeX ─────────────────────────────────────────────────── */
#bibtex { background: var(--bg-alt); }

.bibtex-wrap {
  position: relative;
  max-width: 760px;
  margin: 0 auto;
}
.bibtex-box {
  background: #0f172a;
  border-radius: var(--radius);
  padding: 1.5rem 2rem;
  font-family: 'SF Mono', 'Cascadia Code', 'Roboto Mono', monospace;
  font-size: 0.82rem;
  line-height: 1.7;
  color: #e2e8f0;
  overflow-x: auto;
  box-shadow: var(--shadow-lg);
}
.bibtex-box .bib-key   { color: #7dd3fc; }
.bibtex-box .bib-field { color: #86efac; }
.bibtex-box .bib-value { color: #fde68a; }
.bibtex-box .bib-brace { color: #94a3b8; }

.copy-btn {
  position: absolute;
  top: 12px;
  right: 12px;
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: var(--radius-sm);
  color: rgba(255,255,255,0.7);
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
}
.copy-btn:hover { background: rgba(255,255,255,0.15); color: #fff; }
.copy-btn.copied { background: #166534; border-color: #22c55e; color: #86efac; }

/* ─── Contact Card ───────────────────────────────────────────── */
#contact { background: var(--bg-alt); }

.contact-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2rem 2.5rem;
  box-shadow: var(--shadow-md);
  max-width: 760px;
  margin: 0 auto;
}
.contact-person {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  margin-bottom: 1.25rem;
  padding-bottom: 1.25rem;
  border-bottom: 1px solid var(--border);
}
.contact-avatar {
  flex-shrink: 0;
  width: 72px;
  height: 72px;
  border-radius: 50%;
  overflow: hidden;
  border: 3px solid var(--bg-alt);
  box-shadow: var(--shadow-sm);
}
.contact-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.contact-details { flex: 1; }
.contact-name {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--navy);
  margin: 0 0 3px;
}
.contact-role {
  font-size: 0.82rem;
  color: var(--text-muted);
  margin: 0 0 8px;
}
.contact-email-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--blue);
  text-decoration: none;
  padding: 5px 12px;
  background: var(--teal-light);
  border-radius: var(--radius-sm);
  transition: var(--transition);
}
.contact-email-link:hover {
  background: var(--blue);
  color: #fff;
  transform: translateY(-1px);
}
.contact-note {
  font-size: 0.88rem;
  color: var(--text-muted);
  line-height: 1.7;
  margin: 0;
}
.contact-note a { color: var(--blue); }
.contact-note strong { color: var(--navy); }

/* ─── Visitor Map ────────────────────────────────────────────── */
.visitor-map-section {
  background: var(--navy);
  padding: 2.5rem 1.5rem;
  text-align: center;
}
.visitor-map-label {
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.45);
  margin-bottom: 1rem;
}
.clustrmap-container {
  margin: 0 auto;
  max-width: 600px;
  width: 100%;
  border-radius: var(--radius-sm);
  overflow: hidden;
}

/* ─── Footer ─────────────────────────────────────────────────── */
footer {
  background: var(--navy);
  color: rgba(255,255,255,0.5);
  text-align: center;
  padding: 2rem 1.5rem;
  font-size: 0.83rem;
  line-height: 1.8;
}
footer a { color: rgba(255,255,255,0.7); }
footer a:hover { color: #fff; }

/* ─── Scroll-to-top ──────────────────────────────────────────── */
#scroll-top {
  position: fixed;
  bottom: 2rem;
  right: 1.5rem;
  width: 42px;
  height: 42px;
  background: var(--navy);
  color: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  transition: var(--transition);
  box-shadow: var(--shadow-md);
  z-index: 900;
  border: none;
}
#scroll-top.visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}
#scroll-top:hover { background: var(--blue); transform: translateY(-2px); }

/* ─── Responsive ─────────────────────────────────────────────── */
@media (max-width: 1024px) {
  .authors-grid { grid-template-columns: repeat(4, 1fr); gap: 1rem; }
  .contributions-grid { grid-template-columns: repeat(3, 1fr); }
  .stats-grid { grid-template-columns: repeat(4, 1fr); }
}

@media (max-width: 768px) {
  #hero { padding: 4rem 1rem 3rem; }
  .paper-title { font-size: 1.5rem; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .stat-item:nth-child(2)::after { display: none; }
  .contributions-grid { grid-template-columns: 1fr; }
  .authors-grid { grid-template-columns: repeat(2, 1fr); }
  .figures-grid { grid-template-columns: 1fr; }
  .pipeline { flex-direction: column; }
  .pipeline-arrow { transform: rotate(90deg); }
  .more-works-dropdown { width: 280px; }
  .contact-person { flex-direction: column; text-align: center; }
  .contact-card { padding: 1.5rem; }
}

@media (max-width: 480px) {
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .button-row { flex-direction: column; align-items: center; }
  .pub-btn { width: 100%; max-width: 260px; justify-content: center; }
  .affil-list { flex-direction: column; align-items: center; }
  .more-works-container { top: 1rem; right: 1rem; }
  .authors-grid { grid-template-columns: repeat(2, 1fr); gap: 0.75rem; }
}

/* ─── Animation Utilities ────────────────────────────────────── */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(24px); }
  to   { opacity: 1; transform: translateY(0); }
}
.anim-in { animation: fadeInUp 0.6s ease-out forwards; }

.fade-target {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}
.fade-target.visible {
  opacity: 1;
  transform: translateY(0);
}
