/**
 * Responsive Menu Styles
 * Created: November 2025
 * Production Version
 */

/* ============================================
   HEADER CONTAINER
   ============================================ */

.new-header {
    background: url('/images/background.jpg') center center / cover no-repeat;
    height: 60px;
    position: relative;
    width: 100%;
    /* border-bottom: 4px solid #0c3b6f; */
    box-shadow: 0 4px 8px rgba(12, 59, 111, 0.3);
}

.new-header__container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 20px;
    height: 100%;
    direction: rtl;
}

/* ============================================
   LOGO - RIGHT SIDE
   ============================================ */

.new-header__logo {
    display: flex;
    align-items: center;
    flex-shrink: 0;
}

.new-header__logo-img {
    height: auto;
    width: auto;
    display: block;
}

/* ============================================
   NAVIGATION MENU - CENTER
   ============================================ */

.new-header__nav {
    flex: 1;
    display: flex;
    justify-content: flex-start;
    margin: 0 10px;
    background: transparent;
    overflow-x: auto;
    overflow-y: hidden;
}

.new-header__nav::-webkit-scrollbar {
    height: 0;
    display: none;
}

.new-header__menu {
    list-style: none;
    margin: 0;
    padding: 0;
    display: -webkit-box;
    align-items: center;
    gap: 4px;
    background: transparent;
    flex-wrap: nowrap;
    min-width: min-content;
}

.new-header__menu-item {
    list-style: none;
    flex-shrink: 0;
    padding: 0px 8px;
}

.new-header__menu-link {
    color: #0c3b6f;
    text-decoration: none;
    font-size: 17px;
    font-weight: 400;
    padding: 6px 6px;
    border-radius: 4px;
    transition: all 0.3s ease;
    white-space: nowrap;
    display: block;
}

.new-header__menu-link:hover {
    color: #0c3b6f;
    opacity: 0.8;
}

/* ============================================
   SEARCH BOX - LEFT SIDE (DESKTOP)
   ============================================ */

.new-header__search-wrapper {
    flex-shrink: 0;
}

.new-header__search-wrapper--desktop {
    display: block;
}

.new-header__search-wrapper--mobile {
    display: none !important;
}

.new-header__search-form {
    margin: 0;
}

.new-header__search-input-group {
    position: relative;
    display: flex;
    align-items: center;
    width: 130px;
    background: #ffffff;
    border-radius: 20px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
}

.new-header__search-input-group:focus-within {
    box-shadow: 0 4px 12px rgba(0, 191, 255, 0.2);
    width: 150px;
}

.new-header__search-input {
    width: 100%;
    padding: 9px 32px 9px 12px;
    border: none;
    border-radius: 20px;
    font-size: 14px;
    outline: none;
    transition: all 0.3s ease;
    direction: rtl;
    background: transparent;
    color: #2d3748;
}

.new-header__search-input:focus {
    background: #ffffff;
}

.new-header__search-input::placeholder {
    color: #a0aec0;
}

.new-header__search-btn {
    position: absolute;
    left: 6px;
    background: none;
    border: none;
    color: #00BFFF;
    font-size: 15px;
    cursor: pointer;
    padding: 6px 8px;
    transition: all 0.3s ease;
    border-radius: 50%;
}

.new-header__search-btn:hover {
    color: #0099cc;
    background: rgba(0, 191, 255, 0.1);
}

/* ============================================
   MOBILE SEARCH ICON
   ============================================ */

.new-header__search-icon-mobile {
    display: none;
    color: #8093A8;
    font-size: 25px;
    padding: 8px;
    text-decoration: none;
    transition: opacity 0.3s ease;
}

.new-header__search-icon-mobile:hover {
    opacity: 0.7;
}

/* ============================================
   HAMBURGER BUTTON - MOBILE ONLY
   ============================================ */

.new-header__hamburger {
    display: none;
    flex-direction: column;
    justify-content: space-around;
    width: 30px;
    height: 20px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
    z-index: var(--z-fixed);    
}

.new-header__hamburger-line {
    width: 80%;
    height: 0px;
    background-color: #8093A8;
    transition: all 0.3s ease;
    border-radius: 2px;
}

.new-header__hamburger.active .new-header__hamburger-line:nth-child(1) {
    transform: translateY(10px) rotate(45deg);
}

.new-header__hamburger.active .new-header__hamburger-line:nth-child(2) {
    opacity: 0;
}

.new-header__hamburger.active .new-header__hamburger-line:nth-child(3) {
    transform: translateY(-11px) rotate(-45deg);
}

/* ============================================
   RESPONSIVE - MOBILE (≤768px)
   ============================================ */

@media screen and (max-width: 768px) {
    /* Hide floating ad that covers menu on mobile */
    .new-header__menu {
        display: flex;
    }
    #floatdiv {
        display: none !important;
    }

    .new-header {
        height: auto;
    }

    .new-header__container {
        flex-wrap: wrap;
    }

    /* Logo stays on the right */
    .new-header__logo {
        order: 1;
        flex: 0 0 auto;
    }

    .new-header__logo-img {
        height: 45px !important;
        width: auto !important;
    }

    /* Search icon - between logo and hamburger */
    .new-header__search-icon-mobile {
        display: block;
        order: 2;
        margin-right: auto;
        margin-left: 15px;
    }

    /* Hamburger on the left */
    .new-header__hamburger {
        display: flex;
        order: 3;
        width: 17px;
        height: 14px;
    }

    .new-header__hamburger-line {
        height: 3px;
    }

    /* Hide desktop search */
    .new-header__search-wrapper--desktop {
        display: none;
    }

    /* Navigation - dropdown style */
    .new-header__nav {
        order: 4;
        width: 100%;
        flex-basis: 100%;
        margin: 0;
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.3s ease;
    }

    .new-header__nav.open {
        max-height: 600px;
        margin-top: 10px;
    }

    .new-header__menu {
        flex-direction: column;
        gap: 0;
        width: 100%;
        background: #fff;
        border-radius: 8px;
        box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
        padding: 10px 0;
    }

    .new-header__menu-item {
        width: 100%;
        border-bottom: 1px solid #f0f0f0;
    }

    .new-header__menu-item:last-child {
        border-bottom: none;
    }

    .new-header__menu-link {
        width: 100%;
        text-align: right;
        padding: 12px 20px;
        border-radius: 0;
    }
}

/* ============================================
   TABLET ADJUSTMENTS (768px - 1024px)
   ============================================ */

@media screen and (min-width: 769px) and (max-width: 1024px) {
    .new-header__menu {
        gap: 5px;
    }

    .new-header__menu-link {
        font-size: 15px;
        padding: 5px 6px;
    }

    .new-header__search-input-group {
        width: 130px;
    }

    .new-header__logo-img {
        height: 50px;
    }
}

/* ============================================
   LARGE SCREENS (>1280px)
   ============================================ */

@media screen and (min-width: 1281px) {
    .new-header__logo-img {
        height: 52px;
    }

    .new-header__menu-link {
        font-size: 16px;
        padding: 8px 15 px;
    }

    .new-header__search-input-group {
        /* width: 180px; */
        margin-left: 15px;
    }
}
