/* ==========================================================================
   OVTAS project page — standard academic theme
   ========================================================================== */

:root {
  --ink:        #1a1a1a;
  --ink-soft:   #4a4a4a;
  --ink-faint:  #767676;
  --rule:       #e2e2e2;
  --rule-soft:  #efefef;
  --bg:         #ffffff;
  --bg-tint:    #f7f7f5;
  --accent:     #23527c;
  --accent-lit: #3a7ebf;
  --highlight:  #b45309;
  --maxw:       880px;
  --maxw-wide:  1100px;
  --serif: "Charter", "Bitstream Charter", "Sitka Text", Cambria, "Source Serif Pro", Georgia, serif;
  --sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", "Helvetica Neue", Arial, sans-serif;
  --mono: "SFMono-Regular", "SF Mono", Menlo, Consolas, "Liberation Mono", monospace;
}

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

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 70px; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-lit); text-decoration: underline; }

.container { max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }
.container-wide { max-width: var(--maxw-wide); margin: 0 auto; padding: 0 24px; }

/* --------------------------------------------------------------- nav ---- */

.navbar {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255,255,255,0.92);
  backdrop-filter: saturate(180%) blur(10px);
  -webkit-backdrop-filter: saturate(180%) blur(10px);
  border-bottom: 1px solid var(--rule);
}
.navbar-inner {
  max-width: var(--maxw-wide); margin: 0 auto; padding: 0 24px;
  display: flex; align-items: center; justify-content: flex-start;
  gap: 26px; height: 48px; overflow-x: auto; scrollbar-width: none;
}
.navbar-inner::-webkit-scrollbar { display: none; }
/* Centre the links without clipping the first one when the row overflows
   (justify-content: center makes leading overflow unreachable). */
.navbar-inner > :first-child { margin-left: auto; }
.navbar-inner > :last-child  { margin-right: auto; }
.navbar-inner a {
  font-size: 13.5px; font-weight: 500; letter-spacing: 0.02em;
  color: var(--ink-soft); white-space: nowrap; text-transform: uppercase;
}
.navbar-inner a:hover { color: var(--accent); text-decoration: none; }

/* ------------------------------------------------------------- header ---- */

.hero { padding: 56px 0 8px; text-align: center; }

.venue {
  font-size: 13px; font-weight: 600; letter-spacing: 0.09em;
  text-transform: uppercase; color: var(--ink-faint); margin-bottom: 18px;
}

.paper-title {
  font-family: var(--serif);
  font-size: 41px; line-height: 1.2; font-weight: 700;
  letter-spacing: -0.012em; margin: 0 auto 26px; max-width: 820px;
  text-wrap: balance;
}

.authors { font-size: 18px; line-height: 1.9; margin-bottom: 10px; }
.authors a, .authors span.author { color: var(--ink); }
.authors sup { color: var(--accent); font-size: 0.7em; font-weight: 600; }

.affiliations {
  font-size: 15px; color: var(--ink-soft); line-height: 1.8; margin-bottom: 6px;
}
.affiliations sup { color: var(--accent); font-weight: 600; }

.corresponding { font-size: 14px; color: var(--ink-faint); margin-top: 4px; }

/* ------------------------------------------------------------ buttons ---- */

.button-row {
  display: flex; flex-wrap: wrap; justify-content: center;
  gap: 10px; margin: 30px 0 10px;
}

.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 9px 20px; border-radius: 999px;
  background: #262626; color: #fff;
  font-size: 15px; font-weight: 500; line-height: 1;
  border: 1px solid #262626; transition: background .15s, border-color .15s, transform .1s;
}
.btn:hover { background: #000; border-color: #000; color: #fff; text-decoration: none; transform: translateY(-1px); }
.btn .ico { font-size: 15px; line-height: 1; }

.btn-soon {
  background: #fff; color: var(--ink-faint);
  border: 1px dashed #c4c4c4; cursor: default;
}
.btn-soon:hover { background: #fff; color: var(--ink-faint); border-color: #c4c4c4; transform: none; }
.btn-soon .tag {
  font-size: 10.5px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase;
  background: #f0eee9; color: var(--highlight); padding: 2px 7px; border-radius: 999px;
}

.filesize {
  font-size: 13px; color: var(--ink-faint);
  font-variant-numeric: tabular-nums; white-space: nowrap;
}

.dl-row {
  display: flex; flex-wrap: wrap; align-items: center; gap: 12px;
  margin: 16px 0 4px;
}
.dl-row .btn { background: var(--highlight); border-color: var(--highlight); }
.dl-row .btn:hover { background: #92400e; border-color: #92400e; }

/* ------------------------------------------------------------ notices ---- */

.notice {
  border: 1px solid #e8ddc8; background: #fdfaf3;
  border-left: 4px solid var(--highlight);
  border-radius: 4px; padding: 18px 22px; margin: 34px 0;
}
.notice h4 {
  margin: 0 0 8px; font-size: 15px; font-weight: 700;
  letter-spacing: 0.02em; color: var(--highlight);
  text-transform: uppercase;
}
.notice p { margin: 0 0 10px; font-size: 15.5px; color: var(--ink-soft); }
.notice p:last-child { margin-bottom: 0; }
.notice ul { margin: 10px 0 0; padding-left: 20px; font-size: 15.5px; color: var(--ink-soft); }
.notice li { margin-bottom: 5px; }

/* ------------------------------------------------------------ section ---- */

section { padding: 44px 0; }
section + section { border-top: 1px solid var(--rule-soft); }

h2.section-title {
  font-family: var(--serif);
  font-size: 27px; font-weight: 700; letter-spacing: -0.008em;
  text-align: center; margin: 0 0 28px;
}

h3 {
  font-family: var(--serif);
  font-size: 20px; font-weight: 700; margin: 34px 0 12px;
}

h4 { font-size: 16px; font-weight: 650; margin: 24px 0 8px; }

p { margin: 0 0 16px; }

.abstract-body {
  font-family: var(--serif); font-size: 18.5px; line-height: 1.7;
  text-align: justify; hyphens: auto;
}

.lead { font-size: 17.5px; color: var(--ink-soft); }

.center { text-align: center; }
.muted { color: var(--ink-faint); }
.small { font-size: 14.5px; }

/* ------------------------------------------------------------ figures ---- */

figure { margin: 26px 0; }
figure img { display: block; width: 100%; height: auto; border-radius: 3px; }
figure img.bordered { border: 1px solid var(--rule); }

figcaption {
  margin-top: 12px; font-size: 14.5px; line-height: 1.6;
  color: var(--ink-soft); text-align: left;
}
figcaption b, figcaption strong { color: var(--ink); }
.fig-label { font-weight: 700; color: var(--ink); }

.subfig-stack { display: grid; gap: 18px; }
.subfig { margin: 0; }
.subfig .subcap {
  margin-top: 7px; font-size: 13.5px; color: var(--ink-faint);
  text-align: center; font-style: italic;
}

.fig-grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 26px; align-items: start; }

/* ------------------------------------------------------------- pills ---- */

.tabs {
  display: flex; flex-wrap: wrap; justify-content: center; gap: 8px;
  margin: 0 0 20px;
}
.tab {
  padding: 7px 17px; border-radius: 999px; border: 1px solid var(--rule);
  background: #fff; color: var(--ink-soft);
  font-size: 14.5px; font-weight: 500; cursor: pointer;
  font-family: inherit; transition: all .15s;
}
.tab:hover { border-color: #bdbdbd; color: var(--ink); }
.tab.is-active { background: #262626; border-color: #262626; color: #fff; }

.tab-panel { display: none; }
.tab-panel.is-active { display: block; animation: fade .22s ease; }
@keyframes fade { from { opacity: 0; transform: translateY(3px);} to { opacity:1; transform:none;} }

/* ------------------------------------------------------------- tables ---- */

.table-wrap {
  overflow-x: auto; margin: 0 0 6px;
  border: 1px solid var(--rule); border-radius: 4px;
  -webkit-overflow-scrolling: touch;
}

table {
  width: 100%; border-collapse: collapse;
  font-size: 14.5px; font-variant-numeric: tabular-nums;
}
table th, table td { padding: 8px 12px; text-align: center; white-space: nowrap; }
table thead th {
  background: var(--bg-tint); font-weight: 650; color: var(--ink);
  border-bottom: 1.5px solid #d5d5d5; font-size: 13.5px;
}
table thead tr:first-child th { border-top: none; }
table tbody td { border-bottom: 1px solid var(--rule-soft); }
table tbody tr:last-child td { border-bottom: none; }
table tbody tr:hover { background: #fafafa; }
table td.name, table th.name { text-align: left; white-space: nowrap; }
table .grp {
  background: #fbfbfa; font-weight: 650; font-size: 12.5px;
  letter-spacing: 0.06em; text-transform: uppercase; color: var(--ink-faint);
  text-align: left;
}
table .best { font-weight: 700; color: var(--accent); }
table .drop { font-size: 12px; color: var(--accent-lit); }
table tr.ours td { background: #f6f9fc; }
table tr.ours:hover td { background: #eef4fa; }
table tr.sep td { border-top: 1.5px solid #d5d5d5; }
table .sub { font-size: 12.5px; color: var(--ink-faint); }

.table-caption {
  font-size: 14.5px; line-height: 1.6; color: var(--ink-soft);
  margin: 12px 0 30px;
}
.table-caption .fig-label { margin-right: 4px; }

.scroll-hint {
  font-size: 12.5px; color: var(--ink-faint); text-align: right;
  margin: 5px 0 0; font-style: italic;
}

/* --------------------------------------------------------- highlights ---- */

.stat-row {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 14px; margin: 26px 0 8px;
}
.stat {
  border: 1px solid var(--rule); border-radius: 5px;
  padding: 16px 14px; text-align: center; background: #fff;
}
.stat .num {
  font-family: var(--serif); font-size: 30px; font-weight: 700;
  line-height: 1.1; color: var(--accent); font-variant-numeric: tabular-nums;
}
.stat .lbl {
  font-size: 12.5px; letter-spacing: 0.05em; text-transform: uppercase;
  color: var(--ink-faint); margin-top: 6px;
}
.stat .sub { font-size: 12.5px; color: var(--ink-faint); margin-top: 3px; }

.takeaway {
  background: var(--bg-tint); border-radius: 5px;
  padding: 16px 20px; margin: 22px 0; font-size: 15.5px; color: var(--ink-soft);
  border-left: 3px solid #cfcfcf;
}
.takeaway b { color: var(--ink); }

/* ------------------------------------------------------------ methods ---- */

.stage-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; margin: 24px 0; }
.stage {
  border: 1px solid var(--rule); border-radius: 5px; padding: 20px 22px; background: #fff;
}
.stage .num {
  font-size: 11.5px; font-weight: 700; letter-spacing: 0.09em; text-transform: uppercase;
  color: var(--accent); margin-bottom: 6px;
}
.stage h4 { margin: 0 0 8px; font-family: var(--serif); font-size: 18px; }
.stage p { font-size: 15.5px; color: var(--ink-soft); margin-bottom: 0; }

.eq {
  margin: 18px 0; padding: 4px 0; overflow-x: auto;
  text-align: center; font-size: 16px;
}

ul.tight, ol.tight { margin: 0 0 16px; padding-left: 22px; }
ul.tight li, ol.tight li { margin-bottom: 7px; }

/* ------------------------------------------------------------- bibtex ---- */

pre.bibtex {
  background: var(--bg-tint); border: 1px solid var(--rule); border-radius: 5px;
  padding: 18px 20px; overflow-x: auto;
  font-family: var(--mono); font-size: 13.5px; line-height: 1.6;
  color: var(--ink); margin: 0;
}

.copy-row { display: flex; justify-content: flex-end; margin-bottom: 8px; }
.copy-btn {
  font-family: inherit; font-size: 13px; padding: 5px 13px;
  border: 1px solid var(--rule); border-radius: 999px;
  background: #fff; color: var(--ink-soft); cursor: pointer; transition: all .15s;
}
.copy-btn:hover { border-color: #bdbdbd; color: var(--ink); }

/* ------------------------------------------------------------- footer ---- */

footer {
  border-top: 1px solid var(--rule); margin-top: 20px;
  padding: 34px 0 46px; font-size: 14px; color: var(--ink-faint);
}
footer p { margin: 0 0 10px; }
footer a { color: var(--ink-soft); text-decoration: underline; }

/* ---------------------------------------------------------- responsive ---- */

@media (max-width: 780px) {
  body { font-size: 16px; }
  .paper-title { font-size: 30px; }
  .hero { padding: 34px 0 4px; }
  .authors { font-size: 16px; }
  .abstract-body { font-size: 17px; text-align: left; }
  .stage-grid, .fig-grid-2 { grid-template-columns: 1fr; }
  .stat-row { grid-template-columns: 1fr; }
  h2.section-title { font-size: 23px; }
  .container, .container-wide { padding: 0 18px; }
  .btn { font-size: 14px; padding: 8px 16px; }
}

@media print {
  .navbar, .tabs, .copy-row { display: none; }
  .tab-panel { display: block !important; }
  a { color: var(--ink); }
}
