/* =========================================================
   DreamTacVLA — academic project page
   ========================================================= */

:root {
  --fg:        #1a1a1a;
  --fg-soft:   #4a4a4a;
  --muted:     #7a7a7a;
  --bg:        #ffffff;
  --bg-soft:   #f6f7fb;
  --line:      #e6e8ef;
  --accent:    #2f6df6;
  --accent-2:  #6b46ff;
  --accent-soft: #eaf0ff;
  --best:      #fff7e6;
  --max-w:     1100px;
  --narrow-w:  820px;
  --radius:    14px;
  --radius-sm: 10px;
  --shadow:    0 6px 24px rgba(20, 30, 60, 0.06);
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  font-family: 'Noto Sans', 'Google Sans', -apple-system, BlinkMacSystemFont,
               'Segoe UI', Roboto, sans-serif;
  color: var(--fg);
  background: var(--bg);
  line-height: 1.65;
  font-size: 17px;
  -webkit-font-smoothing: antialiased;
}

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

code, pre {
  font-family: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.92em;
}

/* ---------- layout ---------- */
.container { max-width: var(--max-w); margin: 0 auto; padding: 0 22px; }
.container.narrow { max-width: var(--narrow-w); }
.section { padding: 64px 0; }
.bg-soft { background: var(--bg-soft); }

h1, h2, h3 { font-family: 'Google Sans', 'Noto Sans', sans-serif; line-height: 1.25; }
h2 { font-size: 1.9rem; margin: 0 0 14px; }
h3 { font-size: 1.18rem; margin: 0 0 8px; }
.section-lead { color: var(--fg-soft); margin-top: 0; margin-bottom: 28px; }

/* ---------- hero ---------- */
.hero {
  padding: 72px 0 36px;
  text-align: center;
  background: linear-gradient(180deg, #f8f9ff 0%, #ffffff 100%);
  border-bottom: 1px solid var(--line);
}
.title {
  font-size: clamp(1.8rem, 3.6vw, 2.6rem);
  font-weight: 700;
  margin: 0 auto 16px;
  max-width: 960px;
  letter-spacing: -0.01em;
}
.accent {
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.authors { font-size: 1.05rem; color: var(--fg-soft); margin-bottom: 28px; }
.author { margin: 0 6px; }
.affil { color: var(--muted); margin: 6px 0 22px; font-size: 0.95rem; }

.links { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin-bottom: 22px; }
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 9px 16px;
  border-radius: 999px;
  background: var(--fg);
  color: #fff !important;
  font-weight: 500;
  font-size: 0.95rem;
  text-decoration: none !important;
  transition: transform .15s ease, background .15s ease;
}
.btn:hover { background: #000; transform: translateY(-1px); }
.btn .ico { font-size: 1rem; }

.tldr {
  max-width: 760px;
  margin: 16px auto 0;
  padding: 14px 20px;
  background: var(--accent-soft);
  border: 1px solid #d6e2ff;
  border-radius: var(--radius);
  color: #0e2552;
  font-size: 0.97rem;
}

/* ---------- placeholders / media ---------- */
.placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 240px;
  background: repeating-linear-gradient(
    45deg,
    #f3f5fa,
    #f3f5fa 12px,
    #eef1f8 12px,
    #eef1f8 24px
  );
  border: 1px dashed #c8cfdd;
  border-radius: var(--radius);
  color: var(--muted);
  text-align: center;
  padding: 16px;
  gap: 6px;
}
.placeholder span { font-weight: 600; color: var(--fg-soft); }
.placeholder small { font-size: 0.82rem; }
.placeholder code {
  background: rgba(0,0,0,0.05);
  padding: 1px 6px;
  border-radius: 4px;
}
.teaser-placeholder { min-height: 360px; }
.media-placeholder { min-height: 260px; border-radius: 0; border: none;
  background: repeating-linear-gradient(45deg, #f0f3fa, #f0f3fa 12px, #e7ebf5 12px, #e7ebf5 24px);
}

.figure { margin: 28px 0 0; }
.figure figcaption,
.teaser figcaption {
  margin-top: 10px;
  font-size: 0.92rem;
  color: var(--fg-soft);
  text-align: center;
}
.teaser { margin: 0; }
.teaser-video {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 12px;
  background: #000;
}
.architecture-img,
.dataset-img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 12px;
  background: #fff;
}

/* ---------- grids ---------- */
.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}
.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
  margin-top: 18px;
}
@media (max-width: 820px) {
  .grid-2, .grid-3 { grid-template-columns: 1fr; }
}

/* ---------- method cards ---------- */
.card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 22px 22px 18px;
  box-shadow: var(--shadow);
  position: relative;
}
.card-num {
  width: 30px; height: 30px;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  font-weight: 700;
  display: flex; align-items: center; justify-content: center;
  font-size: 0.9rem;
  margin-bottom: 10px;
}
.card p { margin: 6px 0 0; color: var(--fg-soft); font-size: 0.97rem; }

/* ---------- task cards ---------- */
.task-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
}
.media {
  position: relative;
  aspect-ratio: 16 / 10;
  background: #0c0d12;
  overflow: hidden;
}
.media .task-video {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
}
.media .placeholder {
  position: absolute; inset: 0;
  border-radius: 0;
  border: none;
  min-height: auto;
}
.task-body { padding: 18px 20px 20px; }
.task-tag {
  display: inline-block;
  background: var(--accent-soft);
  color: #1a3fa3;
  font-weight: 600;
  font-size: 0.78rem;
  padding: 3px 10px;
  border-radius: 999px;
  margin-bottom: 8px;
  letter-spacing: 0.02em;
}
.task-body p { color: var(--fg-soft); margin: 6px 0 12px; font-size: 0.96rem; }
.metric {
  font-size: 0.92rem;
  color: var(--fg-soft);
  border-top: 1px dashed var(--line);
  padding-top: 10px;
}
.metric strong { color: var(--accent); font-size: 1.05rem; }

/* ---------- table ---------- */
.table-wrap { overflow-x: auto; }
.results {
  width: 100%;
  border-collapse: collapse;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  font-size: 0.95rem;
}
.results th, .results td {
  padding: 12px 14px;
  text-align: center;
  border-bottom: 1px solid var(--line);
}
.results th {
  background: var(--bg-soft);
  font-weight: 600;
  color: var(--fg);
}
.results td:first-child, .results th:first-child {
  text-align: left;
}
.results tr.best { background: var(--best); }
.results tr.best td { border-bottom: none; }
.results td.rule {
  padding: 0;
  height: 2px;
  background: var(--line);
}

/* ---------- stats ---------- */
.stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin: 12px 0 20px;
}
@media (max-width: 720px) { .stats { grid-template-columns: repeat(2, 1fr); } }
.stat {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 18px 14px;
  text-align: center;
}
.stat .num {
  font-family: 'Google Sans', sans-serif;
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--accent);
}
.stat .lbl { color: var(--fg-soft); font-size: 0.92rem; margin-top: 4px; }

/* ---------- bibtex ---------- */
.bib {
  background: #0e1116;
  color: #e7eaf0;
  padding: 18px 20px;
  border-radius: var(--radius);
  overflow-x: auto;
  margin: 0;
  line-height: 1.55;
}
.bib code { color: inherit; font-size: 0.88rem; }

/* ---------- footer ---------- */
.footer {
  border-top: 1px solid var(--line);
  padding: 28px 0;
  text-align: center;
  color: var(--muted);
  font-size: 0.9rem;
  background: var(--bg-soft);
}
.footer a { color: var(--accent); }
