/* 
1. Add your custom Css styles below
2. Place the this code in your template: 

 <link href="css/custom.css" rel="stylesheet">

*/

/* ============================================
   Unified Menu Bar - 3 Distinct Areas
   Left: Logo (max 40px, top) | Middle: Menu | Right: Social
   Overrides template style.css rules
   ============================================ */

/* Full-width unified header bar */
#header.header-unified .header-inner .container {
    max-width: 100% !important;
    padding: 0 24px !important;
}

/* Single row - no overflow, no wrap */
#header.header-unified .header-unified-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: nowrap;
    width: 100%;
    min-height: 52px;
    gap: 16px;
    overflow: hidden;
}

/* AREA 1 - LEFT: Logo max 40px, tucked to top of container */
#header.header-unified .header-logo,
#header.header-unified #logo {
    flex: 0 0 auto;
    flex-shrink: 0;
    float: none !important;
    margin: 0 !important;
    order: 1;
    display: flex !important;
    align-items: flex-start !important;
    justify-content: flex-start;
    min-width: 0;
    height: auto !important;
    align-self: flex-start !important;
}

#header.header-unified .header-logo a,
#header.header-unified #logo a {
    display: flex !important;
    align-items: flex-start !important;
}

/* Override template's 80px logo - force max 40px */
#header.header-unified .header-logo img,
#header.header-unified .header-logo a img,
#header.header-unified .header-logo a .logo-default img,
#header.header-unified .header-logo a .logo-dark img,
#header.header-unified #logo img,
#header.header-unified #logo a > img,
#header.header-unified #logo a .logo-default img,
#header.header-unified #logo a .logo-dark img {
    height: 40px !important;
    max-height: 40px !important;
    width: auto !important;
    vertical-align: top !important;
    object-fit: contain;
    padding: 0 !important;
}

/* AREA 2 - MIDDLE: Main menu */
#header.header-unified #mainMenu {
    flex: 1 1 auto;
    min-width: 0;
    display: flex !important;
    justify-content: flex-start;
    align-items: center;
    padding: 0 12px;
    order: 2;
    overflow: hidden;
}

#header.header-unified #mainMenu nav {
    float: none !important;
    margin: 0 !important;
    display: flex !important;
    align-items: center;
    min-width: 0;
    overflow: hidden;
}

#header.header-unified #mainMenu > .container {
    width: 100% !important;
    min-width: 0 !important;
    display: flex !important;
    justify-content: flex-start !important;
    padding: 0 !important;
}

#header.header-unified #mainMenu nav > ul {
    display: flex !important;
    justify-content: flex-start;
    flex-wrap: nowrap;
    width: 100%;
    min-width: 0;
    overflow: hidden;
}

#header.header-unified #mainMenu nav > ul > li {
    margin-left: 4px !important;
}

#header.header-unified #mainMenu nav > ul > li > a {
    padding: 8px 6px !important;
    font-size: 12px !important;
    white-space: nowrap;
}

/* AREA 3 - RIGHT: Social icons */
#header.header-unified .header-social {
    flex: 0 0 auto;
    flex-shrink: 0;
    order: 3;
    margin-left: auto !important;
}

#header.header-unified .header-social .social-icons {
    float: none !important;
    margin: 0 !important;
    display: flex !important;
}

#header.header-unified .header-social .social-icons ul {
    display: flex !important;
    flex-wrap: nowrap;
    list-style: none;
    margin: 0;
    padding: 0;
    gap: 2px;
}

#header.header-unified .header-social .social-icons li {
    float: none !important;
}

#header.header-unified .header-social .social-icons li a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    font-size: 14px;
    border-radius: 0;
    margin: 0 !important;
}

/* Bar height - override template's 80px */
#header.header-unified .header-inner,
#header.header-unified #header-wrap {
    height: 52px !important;
}

#header.header-unified {
    height: 52px !important;
    line-height: 52px !important;
}

#header.header-unified #mainMenu-trigger {
    height: 52px !important;
}

/* Override template's logo positioning (absolute, width:100% on mobile) */
#header.header-unified #logo {
    position: relative !important;
    width: auto !important;
    left: auto !important;
    right: auto !important;
    text-align: left !important;
}

/* Mobile: hide social, keep logo and hamburger in row */
@media (max-width: 991.98px) {
    #header.header-unified #logo {
        position: relative !important;
        width: auto !important;
        left: auto !important;
        right: auto !important;
        text-align: left !important;
    }
    
    .header-unified .header-social {
        display: none;
    }
    
    .header-unified .header-unified-row {
        min-height: 54px;
        flex-wrap: wrap;
    }
    
    .header-unified #mainMenu {
        flex: none;
        order: 3;
        width: 100%;
        padding: 0;
        display: block !important;
    }
    
    /* Mobile menu: stack links vertically, not in one line */
    .header-unified #mainMenu nav {
        display: block !important;
    }
    
    .header-unified #mainMenu nav > ul {
        display: block !important;
        flex-direction: column;
    }
    
    .header-unified #mainMenu nav > ul > li {
        display: block !important;
        float: none !important;
    }
    
    .header-unified #mainMenu > .container {
        display: block !important;
        padding: 0 20px 20px !important;
    }
    
    /* Allow header to expand when menu opens */
    .header-unified .header-inner,
    .header-unified #header-wrap {
        height: auto !important;
        min-height: 54px;
    }
    
    /* White background for mobile menu bar and dropdown */
    .header-unified .header-inner,
    .header-unified #header-wrap {
        background-color: #fff !important;
    }
    
    .mainMenu-open .header-unified .header-inner,
    .mainMenu-open .header-unified #header-wrap {
        background-color: #fff !important;
        box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
    }
    
    /* Push hamburger trigger to the right on mobile */
    .header-unified #mainMenu-trigger {
        margin-left: auto;
        height: 54px !important;
    }
}
