/*
 * Keep the shared header in document flow so page content never starts
 * underneath it. The page-specific hero styles below restore a consistent
 * breathing space after the header instead of compensating for a fixed bar.
 */
body:not(.admin-body) #mainHeader {
    position: sticky;
    top: 0;
    left: auto;
    right: auto;
}

@media (min-width: 1181px) {
    body:not(.admin-body) .main-nav {
        margin-left: auto;
        margin-right: auto;
    }
}

/* Shared first-section offset for routes that previously used fixed-header gaps. */
body:not(.admin-body) main > section:first-child,
body:not(.admin-body) main > .page-header:first-child,
body:not(.admin-body) main > .hero:first-child,
body:not(.admin-body) main > .inner-hero:first-child,
body:not(.admin-body) main > .contact-hero:first-child,
body:not(.admin-body) main > .appointment-page:first-child,
body:not(.admin-body) main > .blog-detail-hero:first-child {
    padding-top: clamp(28px, 4vw, 48px) !important;
}

/* Legacy pages render their hero section directly after the shared header. */
body:not(.admin-body) > section.contact-hero,
body:not(.admin-body) > section.page-header,
body:not(.admin-body) > section.inner-hero,
body:not(.admin-body) > section.blog-detail-hero {
    padding-top: clamp(28px, 4vw, 48px) !important;
}

/* These routes put their top spacing on a nested hero wrapper. */
body:not(.admin-body) .insurance-hero-inner {
    padding-top: clamp(28px, 4vw, 48px);
}

body:not(.admin-body) main > .legal-page:first-child,
body:not(.admin-body) main > .not-found-page:first-child {
    padding-top: clamp(36px, 5vw, 60px);
}

@media (max-width: 768px) {
    body:not(.admin-body) main > section:first-child,
    body:not(.admin-body) main > .page-header:first-child,
    body:not(.admin-body) main > .hero:first-child,
    body:not(.admin-body) main > .inner-hero:first-child,
    body:not(.admin-body) main > .contact-hero:first-child,
    body:not(.admin-body) main > .appointment-page:first-child,
    body:not(.admin-body) main > .blog-detail-hero:first-child,
    body:not(.admin-body) > section.contact-hero,
    body:not(.admin-body) > section.page-header,
    body:not(.admin-body) > section.inner-hero,
    body:not(.admin-body) > section.blog-detail-hero {
        padding-top: 26px !important;
    }

    body:not(.admin-body) .insurance-hero-inner {
        padding-top: 28px;
    }
}
