/* ============================================================
   === SHARED — INNER PAGES ===
   Active nav, compact hero, scroll reveal
   ============================================================ */

/* Active nav link (set per-page via JS) */
.nav__link.active {
  color: var(--accent-supernova);
}

/* Compact page hero */
.page-hero {
  position: relative;
  min-height: 280px;
  height: auto;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  overflow: hidden;
}

.page-hero--md { min-height: 320px; }
.page-hero--sm { min-height: 240px; }

.page-hero__bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
}

.page-hero__content {
  position: relative;
  z-index: 1;
  padding: 68px 24px 48px; /* top clears fixed navbar, sides add gutter, bottom breathing room */
  max-width: 720px;
  width: 100%;
  margin: 0 auto;
}

.page-hero__headline {
  font-family: var(--font-display);
  font-size: clamp(26px, 4.5vw, 48px);
  font-weight: 800;
  color: var(--text-primary);
  line-height: 1.15;
  margin-bottom: 14px;
}

.page-hero__subline {
  font-family: var(--font-body);
  font-size: 15px;
  color: var(--text-secondary);
  line-height: 1.75;
  max-width: 580px;
  margin: 0 auto;
}

/* Scroll reveal */
.reveal {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.4s ease, transform 0.4s ease;
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  .reveal {
    transition: none;
  }
}

/* ============================================================
   === INNER PAGES — MOBILE BREAKPOINTS ===
   ============================================================ */

@media (max-width: 767px) {

  .page-hero,
  .page-hero--md,
  .page-hero--sm {
    height: auto;
    padding: 100px 0 48px;
  }

  .project-grid,
  .talks-grid {
    grid-template-columns: 1fr;
  }

  .funding-page__body {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .stat-strip__inner {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .stat-block {
    border-right: none;
    border-bottom: 1px solid rgba(255, 255, 255, 0.07);
    padding-bottom: 32px;
  }

  .stat-block:last-child { border-bottom: none; padding-bottom: 0; }

  .contact-grid {
    grid-template-columns: 1fr;
    gap: 48px;
  }

}

/* ============================================================
   === WORK METRIC BADGE ===
   ============================================================ */

.card__metric {
  display: inline-block;
  background: rgba(255, 87, 34, 0.08);
  color: var(--accent-supernova);
  border-radius: 4px;
  font-family: var(--font-body);
  font-size: 0.72rem;
  padding: 2px 8px;
  margin-top: 0.5rem;
  line-height: 1.6;
  white-space: nowrap;
}

@media (max-width: 767px) {
  .card__metric {
    white-space: normal;
  }
}

/* ============================================================
   === MOBILE PAGE-HERO — fix double top-padding & spacing ===
   ============================================================ */
@media (max-width: 767px) {
  /* Outer .page-hero already has padding: 100px 0 48px on mobile,
     so drop the inner content's extra 68px clearance */
  .page-hero__content {
    padding-top: 0;
  }

  /* Eyebrow label: tighten gap to headline (was 48px — too much) */
  .section-eyebrow {
    margin-bottom: 14px;
  }

  /* Subline: slightly smaller on narrow screens */
  .page-hero__subline {
    font-size: 14px;
    line-height: 1.65;
  }

  /* Ensure headlines don't overflow without ugly mid-word breaks */
  .page-hero__headline {
    word-break: normal;
    overflow-wrap: break-word;
    hyphens: manual;
  }
}
