/* ==========================================================================
   SkateNav project page
   ========================================================================== */

:root {
  --bg: #ffffff;
  --bg-alt: #f7f9f8;
  --ink: #16211c;
  --ink-soft: #4a5a52;
  --ink-faint: #7d8c85;
  --rule: #e2e8e5;

  --accent: #1f8a5b;
  --accent-dark: #146848;
  --accent-mid: #8cd6a4;
  --accent-soft: #d1edd9;
  --accent-wash: #eef8f2;

  --maxw: 1020px;
  --radius: 10px;

  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", "Helvetica Neue",
          "Noto Sans KR", Arial, sans-serif;
  --mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas,
          "Liberation Mono", monospace;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

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

img, video { max-width: 100%; height: auto; display: block; }

a {
  color: var(--accent);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: border-color .15s;
}
a:hover { border-bottom-color: var(--accent); }

/* ---------- layout ------------------------------------------------------- */

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

section { padding-block: 68px; }
section.tint { background: var(--bg-alt); border-block: 1px solid var(--rule); }

h2 {
  font-size: 1.72rem;
  line-height: 1.25;
  letter-spacing: -.015em;
  margin: 0 0 6px;
}
h2 + .kicker { margin: 0 0 34px; }
h2:not(:has(+ .kicker)) { margin-bottom: 22px; }

.kicker {
  color: var(--ink-faint);
  font-size: .93rem;
  letter-spacing: .03em;
  text-transform: uppercase;
}

h3 {
  font-size: 1.12rem;
  margin: 40px 0 10px;
  letter-spacing: -.005em;
}

p { margin: 0 0 16px; }
p:last-child { margin-bottom: 0; }


.eyebrow {
  display: inline-block;
  font-size: .78rem;
  font-weight: 600;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--accent-dark);
  background: var(--accent-wash);
  border: 1px solid var(--accent-soft);
  border-radius: 999px;
  padding: 4px 12px;
  margin-bottom: 20px;
}

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

.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, .93);
  backdrop-filter: saturate(160%) blur(10px);
  border-bottom: 1px solid var(--rule);
}

.nav-inner {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  gap: 22px;
  height: 56px;
}

.nav-brand {
  font-weight: 700;
  letter-spacing: -.02em;
  font-size: 1.05rem;
  color: var(--ink);
  border: 0;
  flex: none;
}
.nav-brand:hover { border: 0; }
.nav-brand .mark { width: 24px; height: 24px; margin-right: 7px; vertical-align: -6px; display: inline-block; }
.hero-mark { display: flex; justify-content: center; margin-bottom: 14px; }
.hero-mark .mark { width: 56px; height: 56px; }
.nav-brand { color: var(--accent); }
.nav-brand em { font-style: normal; color: var(--accent); }

.nav-links {
  display: flex;
  gap: 2px;
  margin-left: auto;
  overflow-x: auto;
  scrollbar-width: none;
  align-self: stretch;
  align-items: center;
}
.nav-links::-webkit-scrollbar { display: none; }

.nav-links a {
  color: var(--ink-soft);
  font-size: .88rem;
  padding: 0 10px;
  min-height: 44px;
  display: flex;
  align-items: center;
  border-radius: 6px;
  border: 0;
  white-space: nowrap;
}
.nav-links a:hover { background: var(--bg-alt); color: var(--ink); border: 0; }
.nav-links a.active { color: var(--accent-dark); background: var(--accent-wash); }

/* ---------- hero --------------------------------------------------------- */

.hero { padding-block: 44px 52px; text-align: center; }

.hero h1 {
  font-size: clamp(1.7rem, 2.9vw, 2.15rem);
  line-height: 1.18;
  letter-spacing: -.028em;
  margin: 0 0 14px;
  max-width: 1000px;
  margin-inline: auto;
  text-wrap: balance;
}
.hero h1 .brand { color: var(--accent); }
.hero h1 .l { white-space: nowrap; }

.hero-sub {
  font-size: 1.06rem;
  color: var(--ink-soft);
  max-width: 760px;
  text-wrap: balance;
  margin: 0 auto;
}

.hero-meta { margin-top: 22px; }

.authors {
  font-size: 1.02rem;
  margin: 0 0 6px;
  line-height: 1.9;
}
.authors sup { color: var(--accent); font-size: .74em; }

.affils {
  font-size: .9rem;
  color: var(--ink-faint);
  margin: 0 0 4px;
}
.venue {
  font-size: .92rem;
  color: var(--ink-soft);
  margin: 0 0 22px;
}

.btn-row {
  display: flex;
  justify-content: center;
  gap: 10px;
  flex-wrap: wrap;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--ink);
  color: #fff;
  border: 1px solid var(--ink);
  border-radius: 999px;
  padding: 9px 20px;
  font-size: .92rem;
  font-weight: 500;
  transition: transform .12s, background .15s;
}
.btn:hover { background: var(--accent-dark); border-color: var(--accent-dark); transform: translateY(-1px); }
.btn.ghost { background: #fff; color: var(--ink); }
.btn.ghost:hover { background: var(--accent-wash); color: var(--accent-dark); border-color: var(--accent-soft); }
.btn.todo { opacity: .55; cursor: default; user-select: none; }
.btn.todo:hover { transform: none; background: var(--ink); border-color: var(--ink); }
.btn svg { width: 15px; height: 15px; fill: currentColor; }

/* ---------- hero video --------------------------------------------------- */

.wrap.wide { max-width: 1148px; margin-top: 34px; }

.hero-video {
  position: relative;
  aspect-ratio: 16 / 9;
  background: #000;
  border-radius: 14px;
  overflow: hidden;
  box-shadow: 0 18px 50px -18px rgba(22, 33, 28, .45), 0 2px 8px rgba(22, 33, 28, .08);
}
.hero-video video { width: 100%; height: 100%; object-fit: contain; background: #000; }


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

figure { margin: 0; }

.fig {
  margin-block: 30px;
}
.fig img {
  width: 100%;
  border: 1px solid var(--rule);
  border-radius: var(--radius);
  background: #fff;
}
.fig.plain img { border: 0; border-radius: 0; }

figcaption {
  font-size: .88rem;
  line-height: 1.6;
  color: var(--ink-soft);
  margin-top: 12px;
}
figcaption b { color: var(--ink); }

.hl { color: var(--accent-dark); font-weight: 700; }


.tldr { font-size: 1.08rem; color: var(--ink); }

details.abstract { margin-top: 18px; }
details.abstract summary {
  cursor: pointer;
  font-weight: 600;
  font-size: .92rem;
  color: var(--accent-dark);
  padding: 6px 0;
}
details.abstract p { font-size: .93rem; color: var(--ink-soft); margin-top: 8px; }

.limit {
  font-size: .9rem;
  color: var(--ink-soft);
  margin-top: 24px;
}



/* ---------- contributions ------------------------------------------------ */

.contribs {
  list-style: none;
  padding: 0;
  margin: 26px 0 8px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 16px;
}
.contribs li {
  background: #fff;
  border: 1px solid var(--rule);
  border-radius: var(--radius);
  padding: 22px 22px 24px;
  font-size: .94rem;
  line-height: 1.62;
  color: var(--ink-soft);
}
.contribs .ico { font-size: 1.5rem; line-height: 1; margin-bottom: 12px; }
.contribs li b {
  display: block;
  color: var(--ink);
  font-size: 1.02rem;
  letter-spacing: -.01em;
  margin-bottom: 8px;
}

/* ---------- stat callouts ----------------------------------------------- */

.stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
  margin: 8px 0 8px;
}

.stat {
  background: var(--accent-wash);
  border: 1px solid var(--accent-soft);
  border-radius: var(--radius);
  padding: 24px 20px;
  text-align: center;
}
.stat .num {
  font-size: 2.15rem;
  font-weight: 700;
  letter-spacing: -.035em;
  color: var(--accent-dark);
  line-height: 1.1;
}
.stat .lbl {
  font-size: .82rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .07em;
  color: var(--ink-soft);
  margin-top: 8px;
}
.stat .sub {
  font-size: .85rem;
  color: var(--ink-faint);
  margin-top: 6px;
  line-height: 1.5;
}

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

.table-scroll {
  overflow-x: auto;
  border: 1px solid var(--rule);
  border-radius: var(--radius);
  background: #fff;
}

table {
  border-collapse: collapse;
  width: 100%;
  font-size: .86rem;
  font-variant-numeric: tabular-nums;
}

th, td {
  padding: 7px 10px;
  text-align: center;
  white-space: nowrap;
}
th {
  font-weight: 600;
  color: var(--ink-soft);
  font-size: .8rem;
}
thead tr:last-child th { border-bottom: 1.5px solid var(--ink); }
thead tr:first-child th { padding-bottom: 2px; }
th.grp { border-bottom: 1px solid var(--rule); font-style: italic; color: var(--ink); }
th.lead, td.lead { text-align: left; white-space: nowrap; }

tbody td { border-top: 1px solid var(--rule); }
tbody tr.ours { background: #f6f6f6; }
tbody tr.ours td.lead { font-weight: 700; }

td.lead.sub { padding-left: 18px; color: var(--ink-soft); }
tbody tr.grp-end td { border-bottom: 1.5px solid var(--ink); }
tbody tr.grp-end + tr td { border-top: 0; }

td.fst { background: var(--accent-mid); font-weight: 700; }
td.snd { background: var(--accent-soft); }

.arrow { font-size: .72em; color: var(--ink-faint); }

.tbl-note {
  font-size: .85rem;
  line-height: 1.6;
  color: var(--ink-soft);
  margin-top: 12px;
}
.legend {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-right: 14px;
  font-size: .82rem;
  color: var(--ink-soft);
}
.legend i {
  width: 13px; height: 13px; border-radius: 3px;
  border: 1px solid rgba(0,0,0,.12);
  display: inline-block;
}
.legend i.a { background: var(--accent-mid); }
.legend i.b { background: var(--accent-soft); }

/* ---------- real-world speeds + clip gallery ----------------------------- */

.speeds {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  margin: 6px 0 0;
}
.speeds div {
  background: #fff;
  border: 1px solid var(--rule);
  border-top: 3px solid var(--accent-mid);
  border-radius: 8px;
  padding: 10px 12px;
  font-size: .82rem;
  color: var(--ink-faint);
  text-align: center;
  line-height: 1.4;
}
.speeds span {
  display: block;
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}

.vid-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
  margin-block: 26px;
}
.pair { margin-block: 26px; }
.pair + .pair { margin-top: 30px; }
.pair-title {
  font-size: .95rem;
  font-weight: 600;
  margin: 0 0 10px;
}
.pair-title span {
  display: block;
  font-weight: 400;
  font-size: .84rem;
  color: var(--ink-faint);
}
.vid-grid.panels { margin-block: 0; }
.vid-grid.panels .vid video { aspect-ratio: 767 / 282; }
.vid-grid.sim .vid video { aspect-ratio: 771 / 434; }
.vid {
  border: 1px solid var(--rule);
  border-radius: 8px;
  overflow: hidden;
  background: #fff;
}
.vid video {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  background: #000;
}
.vid .cap {
  font-size: .82rem;
  font-weight: 600;
  padding: 7px 10px 8px;
  border-top: 1px solid var(--rule);
  line-height: 1.4;
}
.vid .cap span { display: block; font-weight: 400; color: var(--ink-faint); }

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

.bib-box {
  position: relative;
  background: #16211c;
  border-radius: var(--radius);
  overflow: hidden;
}
.bib-box pre {
  margin: 0;
  padding: 22px 22px 24px;
  overflow-x: auto;
  font-family: var(--mono);
  font-size: .84rem;
  line-height: 1.65;
  color: #d8e6de;
}
.copy-btn {
  position: absolute;
  top: 12px;
  right: 12px;
  background: rgba(255,255,255,.1);
  color: #d8e6de;
  border: 1px solid rgba(255,255,255,.18);
  border-radius: 6px;
  padding: 5px 12px;
  font-size: .8rem;
  font-family: var(--font);
  cursor: pointer;
  transition: background .15s;
}
.copy-btn:hover { background: rgba(255,255,255,.2); }
.copy-btn.done { background: var(--accent); border-color: var(--accent); color: #fff; }

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

footer {
  border-top: 1px solid var(--rule);
  padding-block: 36px 48px;
  font-size: .88rem;
  color: var(--ink-faint);
  text-align: center;
}
footer p { margin: 0 0 6px; }

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

@media (max-width: 720px) {
  br.desk { display: none; }
  .hero h1 .l { white-space: normal; }
  body { font-size: 16px; }
  section { padding-block: 48px; }
  .nav-brand { font-size: .98rem; }
  .nav-inner { gap: 12px; padding-right: 0; }
  .nav-links {
    -webkit-mask-image: linear-gradient(to right, #000 calc(100% - 28px), transparent);
            mask-image: linear-gradient(to right, #000 calc(100% - 28px), transparent);
    padding-right: 24px;
  }
  .nav-links a.nav-opt { display: none; }
  .hero { padding-block: 30px 30px; }
  h2 { font-size: 1.45rem; }
  .stat .num { font-size: 1.8rem; }
  .wrap.wide { padding-inline: 0; margin-top: 16px; }
  .hero-video { border-radius: 0; }
  .speeds, .vid-grid { grid-template-columns: repeat(2, 1fr); }
}
