/* =============================================================
   NAV.CSS — Two-bar sticky header + mobile hamburger
   Hillside Hope | hillsidehope.org
   ============================================================= */

/* ── Sticky wrapper ─────────────────────────────────────────── */
#site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  transition: box-shadow 0.2s ease;
}

#site-header.scrolled {
  box-shadow: 0 2px 16px rgba(0,0,0,0.2);
}

/* ── Top bar ────────────────────────────────────────────────── */
.topbar {
  background: #03172F;
  height: 32px;
  padding: 0 var(--pad-page);
  display: flex;
  align-items: center;
  justify-content: flex-end;
}

.topbar__links {
  display: flex;
  align-items: center;
  gap: 0;
}

.topbar__links a {
  font-size: 11px;
  font-weight: 400;
  color: rgba(255,255,255,0.6);
  padding: 0 14px;
  transition: color 0.2s;
  border-right: 1px solid rgba(255,255,255,0.15);
  line-height: 32px;
}

.topbar__links a:first-child {
  border-left: 1px solid rgba(255,255,255,0.15);
}

.topbar__links a:hover {
  color: rgba(255,255,255,0.9);
}

/* ── Main nav bar ───────────────────────────────────────────── */
.mainnav {
  background: linear-gradient(to right, #0D3070 0%, #03172F 100%);
  height: 64px;
  padding: 0 var(--pad-page);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

/* ── Logo block ─────────────────────────────────────────────── */
.nav-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  flex-shrink: 0;
}

.nav-logo__icon {
  height: 48px;
  width: auto;
  filter: brightness(0) invert(1);
}

.nav-logo__text {
  display: flex;
  flex-direction: column;
  line-height: 1;
}

.nav-logo__name {
  font-family: 'Montserrat', sans-serif;
  font-size: 15px;
  font-weight: 600;
  color: #fff;
  letter-spacing: 1px;
  text-transform: uppercase;
}

.nav-logo__tagline {
  font-family: 'Montserrat', sans-serif;
  font-style: italic;
  font-size: 12px;
  font-weight: 400;
  color: rgba(255,255,255,0.5);
  margin-top: 1px;
}

/* ── Desktop nav links ──────────────────────────────────────── */
.nav-links {
  display: flex;
  align-items: center;
  gap: 4px;
  margin: 0 auto 0 32px;
}

.nav-links a {
  font-size: 14px;
  font-weight: 600;
  color: rgba(255,255,255,0.88);
  padding: 8px 12px;
  border-radius: 4px;
  transition: color 0.2s;
  white-space: nowrap;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--gold);
}

/* ── Nav CTA buttons ────────────────────────────────────────── */
.nav-ctas {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

/* Override pill button sizes for nav */
.nav-ctas .btn-navy-outline {
  color: #fff;
  border-color: rgba(255,255,255,0.6);
  font-size: 12px;
  padding: 8px 18px;
}
.nav-ctas .btn-navy-outline:hover {
  background: rgba(255,255,255,0.12);
  border-color: #fff;
  color: #fff;
}

.nav-ctas .btn-gold {
  font-size: 12px;
  padding: 8px 18px;
}

/* ── Hamburger (mobile only) ────────────────────────────────── */
.nav-hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 36px;
  height: 36px;
  background: none;
  border: none;
  padding: 4px;
  cursor: pointer;
  flex-shrink: 0;
}

.nav-hamburger span {
  display: block;
  width: 24px;
  height: 2px;
  background: #fff;
  border-radius: 2px;
  transition: transform 0.25s ease, opacity 0.25s ease;
  transform-origin: center;
}

/* Hamburger → X animation */
.nav-hamburger.open span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
.nav-hamburger.open span:nth-child(2) {
  opacity: 0;
  transform: scaleX(0);
}
.nav-hamburger.open span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* ── Mobile full-screen overlay ─────────────────────────────── */
.nav-mobile-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: linear-gradient(to right, #0D3070 0%, #03172F 100%);
  z-index: 999;
  flex-direction: column;
  padding: 100px 32px 40px;
  overflow-y: auto;
}

.nav-mobile-overlay.open {
  display: flex;
}

.nav-mobile-overlay .nav-mobile-links {
  display: flex;
  flex-direction: column;
  gap: 0;
  flex: 1;
}

.nav-mobile-overlay .nav-mobile-links a {
  font-size: 22px;
  font-weight: 600;
  color: #fff;
  padding: 16px 0;
  border-bottom: 1px solid rgba(255,255,255,0.12);
  transition: color 0.2s;
}

.nav-mobile-overlay .nav-mobile-links a:hover,
.nav-mobile-overlay .nav-mobile-links a.active {
  color: var(--gold);
}

.nav-mobile-overlay .nav-mobile-donate {
  margin-top: 32px;
}

.nav-mobile-overlay .nav-mobile-donate .btn-gold {
  width: 100%;
  justify-content: center;
  font-size: 15px;
  padding: 14px 24px;
}

/* ── Responsive ─────────────────────────────────────────────── */
@media (max-width: 768px) {
  .topbar { display: none; }

  .mainnav {
    height: 60px;
    padding: 0 24px;
  }

  .nav-links,
  .nav-ctas {
    display: none;
  }

  .nav-hamburger {
    display: flex;
  }

  /* Push hamburger to right */
  .mainnav {
    justify-content: space-between;
  }
}
