/* ── Reset & Base ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: 'Inter', -apple-system, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  font-size: 16px;
  line-height: 1.7;
  color: #1a1a1a;
  background: #f7f8fa;
  -webkit-font-smoothing: antialiased;
}

a { color: #2254a8; text-decoration: none; }
a:hover { text-decoration: underline; }

/* ── Layout ── */
.container {
  max-width: 860px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ── Accent color ── */
.accent { color: #2a5da8; }

/* ── Hero ── */
.hero {
  text-align: center;
  padding: 4.5rem 0 1.8rem;
  background: linear-gradient(180deg, #ffffff 0%, #f7f8fa 100%);
}

.hero .title {
  font-size: 2.3rem;
  font-weight: 750;
  color: #111;
  line-height: 1.25;
  margin-bottom: 1.4rem;
  letter-spacing: -0.03em;
}

.authors {
  font-size: 1.02rem;
  color: #333;
  line-height: 1.9;
  font-weight: 400;
}

.authors a { color: #2254a8; }

.affiliations {
  font-size: 0.88rem;
  color: #777;
  margin-top: 0.6rem;
  line-height: 1.6;
}

.affiliations .corresponding {
  display: block;
  margin-top: 0.35rem;
  font-style: italic;
  color: #999;
}

/* ── Resource Links ── */
.links {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 12px;
  padding: 1.4rem 0 2.5rem;
}

.link-button {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 22px;
  border: 1.5px solid #d4d8de;
  border-radius: 8px;
  color: #333;
  text-decoration: none;
  font-weight: 500;
  font-size: 0.9rem;
  background: #fff;
  box-shadow: 0 1px 3px rgba(0,0,0,0.04);
  transition: border-color 0.2s, transform 0.2s, box-shadow 0.2s;
}

.link-button:hover {
  border-color: #a0a8b4;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
  text-decoration: none;
}

.link-button svg {
  width: 16px;
  height: 16px;
  fill: currentColor;
}

/* ── Sections ── */
.content-section {
  padding: 2rem 0;
}

.content-section h2 {
  font-size: 0.75rem;
  font-weight: 600;
  color: #a0a0a0;
  text-transform: uppercase;
  letter-spacing: 1.8px;
  margin-bottom: 1.2rem;
  padding-top: 1.8rem;
  border-top: 1px solid #e4e6ea;
}

/* ── TL;DR Box ── */
.tldr-box {
  background: #fff;
  border-left: 4px solid #2a5da8;
  padding: 1.5rem 1.8rem;
  border-radius: 0 8px 8px 0;
  font-size: 0.95rem;
  line-height: 1.8;
  color: #3a3a3a;
  box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}

.tldr-box p:first-child em {
  font-size: 1.08rem;
  color: #1a1a1a;
  font-weight: 500;
}

/* ── Figure ── */
.figure-container {
  text-align: center;
  margin: 1.2rem 0;
}

.figure-container img {
  max-width: 100%;
  height: auto;
  border-radius: 8px;
  box-shadow: 0 2px 16px rgba(0,0,0,0.06);
}

.caption {
  font-size: 0.85rem;
  color: #666;
  line-height: 1.6;
  margin-top: 1rem;
  text-align: left;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

/* ── BibTeX ── */
.bibtex-wrapper {
  position: relative;
  background: #f0f2f5;
  border: 1px solid #e4e6ea;
  border-radius: 8px;
  padding: 1.4rem 1.5rem;
}

.bibtex-block {
  font-family: 'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, monospace;
  font-size: 0.82rem;
  line-height: 1.55;
  white-space: pre-wrap;
  word-break: break-all;
  margin: 0;
  color: #333;
}

.copy-btn {
  position: absolute;
  top: 12px;
  right: 12px;
  background: #fff;
  border: 1px solid #d4d8de;
  border-radius: 6px;
  padding: 5px 14px;
  font-family: inherit;
  font-size: 0.75rem;
  color: #666;
  cursor: pointer;
  transition: all 0.2s;
}

.copy-btn:hover {
  background: #2a5da8;
  color: #fff;
  border-color: #2a5da8;
}

/* ── Bottom spacing ── */
body > section:last-of-type {
  padding-bottom: 4rem;
}

/* ── Responsive ── */
@media (max-width: 640px) {
  .hero { padding: 3rem 0 1.2rem; }
  .hero .title { font-size: 1.5rem; }
  .authors { font-size: 0.9rem; }
  .link-button { padding: 8px 16px; font-size: 0.85rem; }
  .container { padding: 0 16px; }
  .tldr-box { padding: 1.2rem 1.3rem; }
}
