/* ═══════════════════════════════════════════
   pub-scroll.css — Horizontal publications scroll section
   Mirrors team-scroll layout/animation
═══════════════════════════════════════════ */

#pub-scroll {
  background: var(--bg);
}

/* ── Sticky container ── */
.pub-sticky {
  position: sticky;
  top: 0;
  height: 100vh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: center;
  background: var(--bg);
}

/* ── Header ── */
.pub-scroll-header {
  padding: calc(var(--nav-h) + 8px) max(32px, calc((100vw - 1160px) / 2)) 24px;
  flex-shrink: 0;
}

.pub-scroll-header h2 {
  margin-bottom: 0;
  font-size: clamp(1.6rem, 3vw, 2.4rem);
  color: var(--navy);
}

.pub-scroll-hint {
  font-family: var(--font-head);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(21, 60, 95, 0.35);
  margin-top: 8px;
}

/* ── Progress bar ── */
.pub-progress-bar {
  height: 2px;
  background: rgba(21, 60, 95, 0.1);
  flex-shrink: 0;
  margin: 0 max(32px, calc((100vw - 1160px) / 2));
}

.pub-progress-fill {
  height: 100%;
  background: var(--sand);
  transform-origin: left;
  transform: scaleX(0);
}

.pub-progress-label {
  font-family: var(--font-head);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  color: var(--steel);
  margin: 8px max(32px, calc((100vw - 1160px) / 2)) 0;
}

/* ── Horizontal track ── */
.pub-track {
  display: flex;
  flex-direction: row;
  align-items: stretch;
  flex: 1;
  will-change: transform;
}

/* ── Individual card ── */
.pub-hcard {
  flex: 0 0 100vw;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 0 max(48px, calc((100vw - 1100px) / 2));
  position: relative;
  border-left: 1px solid rgba(21, 60, 95, 0.06);
}

/* Big decorative number */
.pub-hcard-num {
  position: absolute;
  top: 50%;
  right: max(48px, calc((100vw - 1100px) / 2));
  transform: translateY(-50%);
  font-family: var(--font-head);
  font-weight: 900;
  font-size: clamp(8rem, 18vw, 16rem);
  color: rgba(110, 141, 164, 0.07);
  line-height: 1;
  user-select: none;
  pointer-events: none;
}

/* Card content */
.pub-hcard-body {
  position: relative;
  z-index: 1;
  max-width: 680px;
  display: flex;
  flex-direction: column;
  gap: 0;
}

.pub-hcard-year {
  font-family: var(--font-head);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--steel);
  margin-bottom: 14px;
}

.pub-hcard-journal {
  font-family: var(--font-head);
  font-size: clamp(1.5rem, 2.8vw, 2.2rem);
  font-weight: 900;
  color: var(--navy);
  line-height: 1.1;
  margin-bottom: 20px;
}

.pub-hcard-topic {
  font-size: clamp(1rem, 1.4vw, 1.15rem);
  color: var(--muted, #6E8DA4);
  line-height: 1.5;
  margin-bottom: 28px;
  max-width: 560px;
}

.pub-hcard-author {
  font-family: var(--font-head);
  font-size: 13px;
  font-weight: 600;
  font-style: italic;
  color: var(--steel);
  letter-spacing: 0.03em;
  padding-left: 14px;
  border-left: 3px solid var(--sand);
}

/* ═══════════════════════════════════════════
   MOBILE — stack cards vertically
═══════════════════════════════════════════ */
@media (max-width: 768px) {
  .pub-sticky {
    height: auto;
    min-height: 100vh;
    position: relative;
  }

  .pub-track {
    flex-direction: column;
    transform: none !important;
  }

  .pub-hcard {
    flex: none;
    width: 100%;
    min-height: 60vh;
    padding: 48px 24px;
    border-left: none;
    border-top: 1px solid rgba(21, 60, 95, 0.06);
  }

  .pub-hcard-num {
    font-size: 7rem;
    opacity: 0.5;
    right: 24px;
  }

  .pub-hcard-journal { font-size: 1.4rem; }
  .pub-hcard-topic   { font-size: 0.95rem; }
  .pub-progress-bar,
  .pub-progress-label { display: none; }
}
