:root {
  --bg: #ffffff;
  --fg: #1a1a1a;
  --muted: #6b6b6b;
  --line: #e6e6e6;
  --accent: #2b5cd9;
  --accent-hover: #1e46b0;
  --surface: #f7f8fa;
  --code-bg: #f4f4f6;
  --max-width: 980px;
  --narrow-width: 760px;
  --radius: 10px;
  --font-sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
  --font-serif: "Newsreader", Georgia, "Times New Roman", serif;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

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

/* ---------- Hero ---------- */
.hero {
  padding: 72px 0 36px;
  text-align: center;
  border-bottom: 1px solid var(--line);
}
.title {
  font-family: var(--font-serif);
  font-weight: 600;
  font-size: clamp(28px, 4.2vw, 44px);
  line-height: 1.2;
  letter-spacing: -0.01em;
  margin: 0 0 28px;
}
.authors {
  font-size: 17px;
  margin-bottom: 6px;
}
.authors .author { margin: 0 10px; }
.authors a {
  color: var(--fg);
  border-bottom: 1px dotted #bbb;
}
.authors a:hover { color: var(--accent); border-bottom-color: var(--accent); }
.authors sup { color: var(--muted); font-weight: 500; }

.affiliations {
  color: var(--muted);
  font-size: 15px;
  margin-bottom: 4px;
}
.affiliations span { margin: 0 10px; }

.note {
  color: var(--muted);
  font-size: 13px;
  margin-bottom: 28px;
}

/* ---------- Buttons ---------- */
.buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
  margin-top: 14px;
}
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  background: var(--surface);
  color: var(--fg);
  border: 1px solid var(--line);
  border-radius: 999px;
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
  transition: background .15s ease, border-color .15s ease, color .15s ease, transform .05s ease;
}
.btn:hover {
  background: #fff;
  border-color: #c8c8c8;
  border-bottom-color: #c8c8c8;
  color: var(--fg);
}
.btn:active { transform: translateY(1px); }
.btn svg { width: 16px; height: 16px; flex-shrink: 0; }

.btn.primary {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}
.btn.primary:hover {
  background: var(--accent-hover);
  border-color: var(--accent-hover);
  color: #fff;
}

/* ---------- Sections ---------- */
section {
  padding: 56px 0;
  border-bottom: 1px solid var(--line);
}
section:last-of-type { border-bottom: none; }

h2 {
  font-family: var(--font-serif);
  font-weight: 600;
  font-size: 28px;
  letter-spacing: -0.01em;
  margin: 0 0 20px;
}

h3 {
  font-weight: 600;
  font-size: 18px;
  margin: 0 0 6px;
}

p { margin: 0 0 14px; }
p.lead { color: #333; font-size: 17px; margin-bottom: 28px; }

em { font-style: italic; }
strong { font-weight: 600; }

/* ---------- Teaser & figures ---------- */
.teaser { padding: 40px 0; border-bottom: 1px solid var(--line); }

.teaser-figure img {
  max-width: 392px;
  width: 100%;
  margin: 0 auto;
  display: block;
}

figure {
  margin: 0 0 12px;
  text-align: center;
}
figure img {
  max-width: 100%;
  height: auto;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: #fff;
}
figcaption {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.55;
  margin-top: 12px;
  text-align: left;
  max-width: var(--narrow-width);
  margin-left: auto;
  margin-right: auto;
}

/* ---------- Download card ---------- */
.download-card {
  margin-top: 28px;
  padding: 20px 24px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}
.download-card h3 { margin-bottom: 4px; }
.download-card p { margin: 0; color: var(--muted); font-size: 14px; }

/* ---------- More-in-paper list ---------- */
.more-list {
  list-style: none;
  padding: 0;
  margin: 0;
}
.more-list li {
  padding: 14px 0 14px 22px;
  border-bottom: 1px solid var(--line);
  position: relative;
  line-height: 1.6;
}
.more-list li:last-child { border-bottom: none; }
.more-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 24px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
  opacity: 0.7;
}
.more-list strong { color: var(--fg); }

/* ---------- BibTeX ---------- */
pre {
  background: var(--code-bg);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 18px 20px;
  overflow-x: auto;
  font-size: 13.5px;
  line-height: 1.6;
}
code {
  font-family: "SF Mono", ui-monospace, Menlo, Monaco, Consolas, monospace;
}

/* ---------- Footer ---------- */
footer {
  padding: 32px 0 48px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 13px;
  text-align: center;
}
footer p { margin: 0 0 6px; }
.muted { color: var(--muted); }

/* ---------- Responsive ---------- */
@media (max-width: 640px) {
  .hero { padding: 48px 0 28px; }
  section { padding: 40px 0; }
  .authors .author, .affiliations span { display: inline-block; margin: 2px 6px; }
  .download-card { flex-direction: column; align-items: flex-start; }
}
