/* ==========================================================================
   Header section
   Only styles for the top site header live here. Edit this file to change
   the header without touching hero.css or any other section.
   ========================================================================== */

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  height: var(--header-height);
  display: flex;
  align-items: center;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid rgba(40, 16, 115, 0.08);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-md);
  /* Full bleed to match the hero below it — same fluid side padding
     instead of the boxed 1200px .container. */
  width: 100%;
  height: 100%;
  padding-inline: var(--edge-pad);
}

.header-logo {
  display: flex;
  align-items: center;
  gap: 0.65rem;
}

.header-logo-mark {
  width: 40px;
  height: 40px;
}

.header-logo-text {
  font-size: 1.15rem;
  font-weight: 800;
  letter-spacing: -0.01em;
  line-height: 1;
  white-space: nowrap;
}

.header-logo-text .logo-purple {
  color: var(--color-orange);
}

.header-logo-text .logo-data {
  color: var(--color-indigo-deep);
}

.header-nav {
  display: flex;
  align-items: center;
  gap: var(--space-md);
}

.header-cta {
  padding: 0.7rem 1.4rem;
}

/* Hamburger button — controls the side nav on smaller screens. Hidden on
   desktop where the side nav is always visible (see sidenav.css). */
.menu-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  width: 42px;
  height: 42px;
  border: 1px solid rgba(40, 16, 115, 0.14);
  border-radius: var(--radius-sm);
  background: var(--color-bg);
  padding: 0;
}

.menu-toggle-bar {
  width: 20px;
  height: 2px;
  border-radius: 2px;
  background: var(--color-indigo-deep);
  transition: transform var(--transition-fast), opacity var(--transition-fast);
}

.menu-toggle[aria-expanded="true"] .menu-toggle-bar:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.menu-toggle[aria-expanded="true"] .menu-toggle-bar:nth-child(2) {
  opacity: 0;
}

.menu-toggle[aria-expanded="true"] .menu-toggle-bar:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

@media (max-width: 1099px) {
  .menu-toggle {
    display: flex;
  }
}

/* Below ~640px, shrink the wordmark text so it doesn't crowd the CTA button */
@media (max-width: 640px) {
  .header-logo-text {
    font-size: 0.95rem;
  }

  .header-cta span {
    display: none; /* hide the arrow glyph, keep the button compact */
  }
}

/* Below ~420px there isn't room for the full wordmark next to the CTA
   button — drop to just the icon mark (it still has an aria-label). */
@media (max-width: 420px) {
  .header-logo-text {
    display: none;
  }

  .header-cta {
    padding: 0.65rem 1.1rem;
    font-size: 0.85rem;
  }
}
