/* Project-page layout on top of the Academic Project Page Template. */
:root {
  --primary-color: #155eaa;
  --primary-hover: #104d8c;
  --text-primary: #17263a;
  --text-secondary: #526276;
  --background-secondary: #f5f8fc;
  --border-color: #dfe7f0;
}

.skip-link { position: absolute; top: -4rem; left: 1rem; z-index: 100; padding: .5rem .8rem; background: #1e293b; color: #fff; }
.skip-link:focus { top: .5rem; color: #fff; }
a:focus-visible, button:focus-visible { outline: 3px solid #62a9f5; outline-offset: 3px; }
html { scroll-padding-top: 4.5rem; }

.section-nav-bar { position: sticky; top: 0; z-index: 50; background: rgba(255, 255, 255, .97); border-bottom: 1px solid var(--border-color); backdrop-filter: blur(12px); }
.section-nav { display: flex; align-items: center; gap: 1.3rem; min-height: 3.8rem; padding: 0 1.25rem; }
.nav-home { flex: none; color: var(--text-primary); font-size: 1rem; font-weight: 750; letter-spacing: -.02em; white-space: nowrap; }
.nav-home span { color: var(--primary-color); font-weight: 500; }
.nav-home:hover { color: var(--primary-color); }
.nav-links { display: flex; align-items: center; justify-content: flex-end; gap: 1.35rem; width: 100%; overflow-x: auto; white-space: nowrap; scrollbar-width: none; }
.nav-links::-webkit-scrollbar { display: none; }
.nav-links a { flex: none; color: var(--text-secondary); font-size: .88rem; font-weight: 600; }
.nav-links a:hover { color: var(--primary-color); }

/* Restore the exact pre-redesign publication header layout. */
.publication-header { --primary-color: #2563eb; --text-primary: #1e293b; --text-secondary: #64748b; color: #1e293b; }
.publication-header .hero-body { padding-bottom: 2.5rem; }
.publication-title { font-size: clamp(2rem, 4.4vw, 3.5rem) !important; line-height: 1.17 !important; }
.publication-authors { margin-bottom: .75rem; line-height: 1.8; }
.publication-authors .author-block { margin-right: .25rem; }
.publication-authors sup { color: var(--text-secondary); font-size: .65em; }
.publication-affiliations { display: flex; flex-wrap: wrap; justify-content: center; gap: .15rem 1.1rem; color: var(--text-secondary); font-size: .95rem; }
.contribution-note { margin: .65rem 0 1.25rem; color: var(--text-secondary); font-size: .85rem; }
.publication-links .button { margin: .25rem !important; }
.section-kicker { margin: 0 0 .7rem; color: var(--primary-color); font-size: .78rem; font-weight: 800; letter-spacing: .11em; text-transform: uppercase; }

.project-section { padding: 4rem 1.5rem; }
.project-section .title.is-3 { text-align: left; margin-bottom: 1rem; }
.project-section .title.is-3::after { left: 0; transform: none; }
.section-intro { max-width: 800px; color: var(--text-secondary); font-size: 1.04rem; line-height: 1.75; }
.resource-section { background: #f8fafc; border-bottom: 1px solid var(--border-color); }
.resource-grid { margin-top: 1.2rem; }
.resource-panel { height: 100%; padding: 1.4rem; border: 1px solid var(--border-color); border-radius: 14px; background: #fff; box-shadow: 0 5px 20px rgba(23,38,58,.035); }
.resource-panel .title { margin-bottom: 1rem; font-size: 1.05rem; }
.resource-panel > a { display: flex; justify-content: space-between; gap: .5rem; padding: .7rem 0; border-top: 1px solid var(--border-color); }
.resource-row { display: flex; flex-wrap: wrap; justify-content: space-between; gap: .2rem; padding: .7rem 0; border-top: 1px solid var(--border-color); }
.resource-row strong { color: var(--text-primary); font-size: .82rem; white-space: nowrap; }
.resource-row span { display: flex; flex-wrap: nowrap; gap: .2rem; white-space: nowrap; }
.resource-panel .resource-row a { font-size: .82rem; }
.training-links { display: flex; flex-wrap: wrap; gap: .35rem .8rem; }
.training-links { border-top: 1px solid var(--border-color); padding-top: .8rem; }
.resource-panel a { color: var(--primary-color); font-size: .9rem; text-decoration: none; }
.resource-panel a:hover { text-decoration: underline; }

.project-overview { background: #fff; }
.overview-heading { display: grid; grid-template-columns: 1.15fr 1fr; align-items: end; gap: 1.5rem; margin-bottom: 1.6rem; }
.overview-heading p:last-child { margin: 0 0 .2rem; color: var(--text-secondary); line-height: 1.75; }
.publication-banner { margin: 0; max-height: none; border-radius: 12px; box-shadow: none; }
.publication-banner img { width: 100%; height: auto; border: 1px solid var(--border-color); border-radius: 12px; box-shadow: none; }
.figure-caption, .paper-figure figcaption { margin-top: .7rem; color: var(--text-secondary); font-size: .86rem; line-height: 1.5; text-align: center; }
.paper-figure { margin: 2rem 0 0; text-align: center; }
.paper-figure img { width: 100%; height: auto; border-radius: 10px; border: 1px solid var(--border-color); background: #fff; }
.compact-figure { max-width: 850px; margin-left: auto; margin-right: auto; }
.project-section.is-light { background: var(--background-secondary); }
.result-block { border-top: 1px solid var(--border-color); margin-top: 2.5rem; padding-top: 2.3rem; }
.result-block .title.is-4 { margin-bottom: .8rem; }
.result-block .content { max-width: 900px; color: var(--text-secondary); line-height: 1.75; }
.result-table { min-width: 620px; font-size: .91rem; }
.result-table caption { text-align: left; color: var(--text-secondary); font-size: .84rem; margin-bottom: .6rem; }
.result-table td:not(:first-child), .result-table th:not(:first-child) { text-align: right; }
.result-table .ours { background: #eaf2ff !important; }

#BibTeX { padding: 3.5rem 1.5rem; }
#BibTeX .title.is-3 { margin: 0 !important; padding: 0; }
#BibTeX .title.is-3::after { display: none; }
.copy-bibtex-btn.copied .copy-text::after { display: none; }
.footer { padding-top: 2rem; padding-bottom: 2rem; }
.footer .content { font-size: .85rem; }

@media (min-width: 769px) {
  .resource-row { flex-wrap: nowrap; align-items: center; }
}

@media (max-width: 768px) {
  .section-nav { gap: .9rem; padding: 0 1rem; }
  .nav-home { font-size: .88rem; }
  .nav-links { justify-content: flex-start; gap: 1rem; }
  .nav-links a { font-size: .82rem; }
  .project-section { padding: 3rem 1rem; }
  .overview-heading { grid-template-columns: 1fr; gap: .3rem; }
  .resource-panel { padding: 1.2rem; }
}
