/* sd-man — footer layout fix + pinned navigation (agent-managed) */

/* Pin the navigation to the top on every page (class added by nav-sticky.js).
   The white logo/menu row therefore stays constant; only the blue contact
   bar above it collapses on scroll. */
#g-navigation.is-pinned {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    width: 100% !important;
    z-index: 900;
}

#g-navigation.is-pinned.is-scrolled {
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.14);
}

/* The blue contact bar slides up and away once the page is scrolled */
#g-navigation > .g-container > .g-grid:first-child {
    max-height: var(--sd-contact-height, 60px);
    overflow: hidden;
    transition: max-height 0.3s ease, opacity 0.3s ease;
}

#g-navigation.is-scrolled > .g-container > .g-grid:first-child {
    max-height: 0 !important;
    opacity: 0;
}

/* Holds the pinned nav's space in the page flow (height tracked by JS) */
#g-nav-sticky-spacer {
    display: block;
}

/* Shrink the logo once the page is scrolled */
#g-navigation .g-logo img {
    transition: width 0.25s ease, margin 0.25s ease;
}

#g-navigation.is-scrolled .g-logo img {
    width: 210px !important;
    margin-top: 12px !important;
    margin-bottom: 12px !important;
}

/* Footer: the nested .footer-container must stack, not form a 3-column grid */
#g-footer .footer-container .footer-container {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 1rem;
}

/* Desktop only: keep the button and socials aligned with the heading and list */
@media (min-width: 48rem) {
    #g-footer .footer-container .footer-container .footer-actions {
        align-items: flex-start;
        margin-left: 0;
    }
}
