/* Custom CSS for inline header menu - Three column layout */

/* Fix header positioning */
.header-inline-menu {
    position: relative !important;
    background: transparent;
}

.header-inline-menu .navigation.navbar,
.tp-site-header .navigation,
.tp-site-header.header-inline-menu .navigation {
    position: relative;
    background: linear-gradient(135deg, rgba(30, 30, 30, 0.6) 0%, rgba(15, 15, 15, 0.55) 50%, rgba(30, 30, 30, 0.6) 100%) !important;
    background-color: transparent !important;
    backdrop-filter: blur(24px) saturate(140%) brightness(1.1) !important;
    -webkit-backdrop-filter: blur(24px) saturate(140%) brightness(1.1) !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1) !important;
    border-top: 1px solid rgba(255, 255, 255, 0.05) !important;
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.06) !important;
}

/* Three-column header container */
.header-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 15px;
}

/* Logo section - fixed width for balance */
.header-logo {
    display: flex;
    align-items: center;
    flex: 0 0 auto;
    min-width: 80px;
}

.header-logo .navbar-brand {
    height: auto;
    padding: 10px 0;
    float: none;
}

.header-logo .navbar-brand img {
    max-height: 60px;
    width: auto;
}

/* Menu section - centered */
.header-menu {
    display: flex;
    align-items: center;
    justify-content: center;
    flex: 1 1 auto;
}

.header-menu .nav.navbar-nav {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: nowrap;
    list-style: none;
    margin: 0;
    padding: 0;
}

.header-menu .nav.navbar-nav > li {
    display: inline-block;
    position: relative;
}

/* Menu link styling */
.header-inline-menu #navbar > ul li a {
    color: #fff;
    text-transform: capitalize;
    font-size: 13px;
    padding: 35px 8px;
    display: block;
    transition: all 0.3s;
    white-space: nowrap;
}

.header-inline-menu #navbar > ul li a:hover,
.header-inline-menu #navbar > ul li a.active {
    text-decoration: none;
    color: rgba(255, 255, 255, 0.6);
}

.header-inline-menu #navbar > ul li a:focus {
    text-decoration: none;
}

/* Language toggle section - fixed width for balance */
.header-language {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    flex: 0 0 auto;
    min-width: 50px;
}

.header-language .language-toggle-btn {
    background: none;
    border: none;
    cursor: pointer;
    padding: 10px 15px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.header-language .language-toggle-btn i {
    font-size: 20px;
    color: #fff;
    transition: color 0.3s;
}

.header-language .language-toggle-btn:hover i {
    color: rgba(255, 255, 255, 0.6);
}

/* RTL Support - prevent layout shift */
[dir="rtl"] .header-container {
    flex-direction: row-reverse;
}

[dir="rtl"] .header-logo {
    flex-direction: row-reverse;
}

[dir="rtl"] .header-language {
    justify-content: flex-start;
}

[dir="rtl"] .header-menu .nav.navbar-nav {
    flex-direction: row-reverse;
}

/* Hide mobile menu button on desktop */
@media screen and (min-width: 992px) {
    .header-logo .open-btn {
        display: none;
    }
    
    .header-menu .close-navbar {
        display: none;
    }
}

/* Mobile styles */
@media (max-width: 991px) {
    .header-container {
        padding: 0 15px;
        flex-wrap: wrap;
    }
    
    .header-logo {
        flex: 1;
        min-width: auto;
    }
    
    .header-logo .open-btn {
        background-color: rgba(255, 255, 255, 0.1);
        width: 40px;
        height: 35px;
        border: 0;
        padding: 0 8px;
        position: relative;
        z-index: 20;
        margin-right: 10px;
    }
    
    [dir="rtl"] .header-logo .open-btn {
        margin-right: 0;
        margin-left: 10px;
    }
    
    .header-logo .open-btn span {
        background-color: #fff;
        display: block;
        height: 2px;
        margin-bottom: 5px;
    }
    
    .header-logo .open-btn span:last-child {
        margin: 0;
    }
    
    .header-language {
        min-width: auto;
        flex: 0;
    }
    
    /* Mobile menu - slide in from side */
    .header-menu {
        background: rgba(0, 0, 0, 0.95);
        backdrop-filter: blur(40px) saturate(120%);
        -webkit-backdrop-filter: blur(40px) saturate(120%);
        display: block;
        width: 280px;
        height: 100%;
        position: fixed;
        left: -300px;
        top: 0;
        padding: 30px 20px;
        overflow: auto;
        z-index: 100;
        transition: all 0.4s ease;
    }
    
    .header-menu.slideInn {
        left: 0;
    }
    
    [dir="rtl"] .header-menu {
        left: auto;
        right: -300px;
    }
    
    [dir="rtl"] .header-menu.slideInn {
        right: 0;
    }
    
    .header-menu .close-navbar {
        display: block;
        width: 40px;
        height: 40px;
        color: #fff;
        border: 1px solid #fff;
        font-size: 13px;
        position: absolute;
        right: 15px;
        top: 15px;
        background: transparent;
        cursor: pointer;
    }
    
    [dir="rtl"] .header-menu .close-navbar {
        right: auto;
        left: 15px;
    }
    
    .header-menu .nav.navbar-nav {
        display: block;
        margin-top: 50px;
    }
    
    .header-menu .nav.navbar-nav > li {
        display: block;
        border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    }
    
    .header-inline-menu #navbar > ul li a {
        padding: 12px 15px;
        font-size: 14px;
    }
}
