/* Make header fixed to the top */
header {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    z-index: 9999;
    transition: all 0.3s ease-in-out !important;
    box-sizing: border-box; /* Prevent menu sliding out right */
}

/* Base logo transition */
#logo, #logo img {
    transition: all 0.3s ease-in-out !important;
    transform-origin: left center;
}

/* Ensure the body content doesn't jump under the fixed header */
body {
    padding-top: 120px; /* Adjust this value based on initial header height */
    overflow-x: hidden; /* Fallback to prevent right side slide out */
}

/* Respect WP Admin bar */
body.admin-bar header {
    top: var(--wp-admin--admin-bar--height, 32px) !important;
}
@media screen and (max-width: 782px) {
    body.admin-bar header {
        top: 46px !important;
    }
}

/* Scrolled state for header */
body.header-scrolled-bdc0a4cd header {
    padding-top: 10px !important;
    padding-bottom: 10px !important;
    min-height: auto !important;
}

/* Scrolled state for logo - 40% reduction (scale 0.6) */
body.header-scrolled-bdc0a4cd #logo {
    transform: scale(0.6);
}

/* If the logo is an image inside #logo, apply max-width constraint */
body.header-scrolled-bdc0a4cd #logo img {
    max-height: 60%;
    width: auto;
}
