/* ============================================================
   SIAE — Global sticky main navbar (behavior/styling only)
   Loaded in addition to style.css (style.css is left untouched).
   The utility bar is a separate sibling above .site-header, so
   only the navbar sticks; the utility bar scrolls away normally.
   ============================================================ */

/* Main navbar sticks to the top; utility bar (sibling above) scrolls away. */
.site-header {
  position: sticky;
  top: 0;
  /* keep above page content, dropdowns/mega-menu render within/above it */
  z-index: 1035;
  transition: box-shadow .25s ease, background-color .25s ease;
}

/* Slightly stronger, still subtle shadow once scrolled. */
.site-header.is-scrolled {
  box-shadow: 0 4px 18px rgba(0, 0, 0, .07);
}

/* Subtle compaction when scrolled (padding + logo), smooth transition. */
.main-navbar {
  transition: min-height .25s ease, padding-block .25s ease;
}
.site-header.is-scrolled .main-navbar {
  min-height: 68px;
  padding-block: 0.5rem;
}
.site-logo {
  transition: height .25s ease;
}
.site-header.is-scrolled .site-logo {
  height: 44px;
  width: auto; /* preserve aspect ratio, no distortion */
}

/* Anchor links / in-page jumps must not hide headings behind the sticky navbar. */
html {
  scroll-padding-top: 96px;
}

/* Ensure dropdowns / the More mega-menu layer above page content while sticky. */
.site-header .dropdown-menu,
.site-header .more-mega-menu {
  z-index: 1055;
}

@media (prefers-reduced-motion: reduce) {
  .site-header,
  .main-navbar,
  .site-logo {
    transition: none;
  }
}
