/* =============================================
   HEADER STYLES
   ============================================= */

/* Header & Menu Styles */
#header .max-width-1400 {
    max-width: 1400px !important;
    margin: 0 auto !important;
}

/* Menu Optimization - Giảm padding và font-size */
#primary-menu ul li > a {
    padding: 30px 12px !important;
    font-size: 13px !important;
    font-weight: 600 !important;
    letter-spacing: 0px !important;
    transition: none !important;
}

/* Dropdown menu spacing - font nhỏ hơn menu cha */
#primary-menu ul ul li > a {
    padding: 10px 15px !important;
    font-size: 12px !important;
}

/* Dropdown cấp 3 (menu cháu) - đảm bảo hiển thị đúng */
#primary-menu ul ul:not(.mega-menu-column) ul {
    display: none !important;
    position: absolute !important;
    width: 340px !important;
    background-color: #FFF !important;
    box-shadow: 0px 13px 42px 11px rgba(0, 0, 0, 0.05) !important;
    border: 1px solid #EEE !important;
    border-top: 2px solid #1ABC9C !important;
    top: -2px !important;
    left: 340px !important;
    z-index: 200 !important;
    margin: 0 !important;
}

/* Hiển thị dropdown cấp 3 khi hover - quan trọng! */
#primary-menu ul ul li:hover > ul,
#primary-menu ul ul li.sfHover > ul,
body.no-superfish #primary-menu ul ul li:hover > ul {
    display: block !important;
    opacity: 1 !important;
    visibility: visible !important;
}

/* Style cho link trong dropdown cấp 3 - font nhỏ hơn menu cha */
#primary-menu ul ul ul li > a {
    padding: 10px 15px !important;
    font-size: 12px !important;
}

#header-wrap {
    background: #ffffff;
}

.margin-0-auto {
    margin: 0 auto;
}

/* Header fixed nhưng không thu nhỏ khi scroll */
#header,
#header-wrap {
    height: 80px !important;
    transition: none !important;
}

#logo img {
    max-height: 80px !important;
    height: auto !important;
    transition: none !important;
}

#header.sticky-header:not(.static-sticky),
#header.sticky-header:not(.static-sticky) #header-wrap {
    height: 80px !important;
    transition: none !important;
}

#header.sticky-header:not(.static-sticky):not(.sticky-style-2):not(.sticky-style-3) #logo img {
    max-height: 80px !important;
    height: auto !important;
    transition: none !important;
}

#header.sticky-header:not(.static-sticky) #primary-menu > ul > li > a {
    padding-top: 30px !important;
    padding-bottom: 30px !important;
    transition: none !important;
}

#top-search,
#top-cart {
    transition: none !important;
    margin-top: 30px !important;
}

/* Responsive Logo - Make smaller and centered */
@media (max-width: 991px) {
    #logo {
        float: none !important;
        text-align: center !important;
        margin: 0 auto !important;
        height: auto !important;
        max-width: 250px !important;
    }
    
    #logo img {
        max-height: 60px !important;
        height: auto !important;
        width: auto !important;
    }

    #primary-menu {
        background-color: #fff !important;
    }
}

