/* =====================================================
   HEADER / NAVBAR / NEWS BAR STYLES
   File: header-navbar-news-final.css
===================================================== */

/* =========================
   NAVBAR BACKGROUND CONTROL
========================= */
.main-navbar {
    background-color: #02A35D;
}

@media (max-width: 991px) {
    .main-navbar {
        background-color: #ffffff !important;
    }
}

/* =========================
   NAVBAR BASE
========================= */
.navbar, 
.navbar .nav-link,
.navbar .dropdown-menu {
    font-family: "Poppins", sans-serif !important;
    color: #fff !important;
}

.nav-link { 
    font-size: 13px; 
    transition: 0.3s; 
    white-space: nowrap !important; 
}

.navbar-nav .nav-link:hover { 
    background-color: #008149 !important;
    color: #ffffff !important;
}

/* =========================
   DROPDOWN MENU
========================= */
.navbar-nav .dropdown-menu {
    background-color: #008149 !important;
    border: none;
    border-radius: 0;
    margin-top: 0;
    padding: 0;
}

.dropdown-item {
    color: #ffffff !important;
    font-weight: 600;
    padding: 8px 20px;
    border-bottom: 1px solid rgba(255,255,255,0.15);
    font-size: 12px; 
    text-transform: uppercase;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.dropdown-menu .dropdown-item:hover,
.dropdown-menu .dropdown-item:focus,
.dropdown-submenu:hover > .dropdown-item {
    background-color: #009F4C !important;
    color: #ffffff !important;
}

.dropdown-menu li:last-child > .dropdown-item {
    border-bottom: none;
}

/* =========================
   ACTIVE STATES
========================= */
.navbar-nav .nav-link.active,
.navbar-nav .nav-item.active .nav-link {
    background-color: #009F4C !important;
    color: #ffffff !important;
}

/* REMOVE submenu active highlight */
.dropdown-item.active {
    background: transparent !important;
    color: #ffffff !important;
    border-left: none !important;
    box-shadow: none !important;
}

/* =========================
   DROPDOWN ANIMATION
========================= */
.dropdown-menu {
    display: block;
    opacity: 0;
    visibility: hidden;
    transform: translateY(15px);
    transition: all 0.3s ease;
    border-radius: 8px;
    border: none;
    box-shadow: 0 10px 25px rgba(0,0,0,0.08);
}

.nav-item.dropdown:hover > .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

/* =========================
   SUBMENU
========================= */
.dropdown-submenu {
    position: relative;
}

.dropdown-submenu .dropdown-menu {
    top: 0;
    left: 100%;
    transform: translateX(15px);
}

.dropdown-submenu:hover > .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateX(0);
}

/* =========================
   HOVER STATES
========================= */
.nav-link:hover,
.dropdown-item:hover {
    background: #fff;
    color: #009B5D;
}

/* =========================
   NEWS BAR
========================= */
.news-bar {
    background: #fff;
    border-top: 1px solid #ddd;
    font-size: 14px;
}

/* =========================
   SCROLL TEXT
========================= */
.news-scroll {
    overflow: hidden;
    position: relative;
    white-space: nowrap;
}

.news-track {
    display: inline-block;
    padding-left: 100%;
    animation: scrollText 40s linear infinite;
    color: #333;
}

@keyframes scrollText {
    0% { transform: translateX(0); }
    100% { transform: translateX(-100%); }
}

/* =========================
   BLINK TEXT
========================= */
.blink {
    color: red;
    font-weight: bold;
    margin-right: 10px;
    animation: blinkAnim 1s infinite;
}

@keyframes blinkAnim {
    0%, 100% { opacity: 1; }
    50% { opacity: 0; }
}

/* =========================
   SOCIAL ICONS
========================= */
.social-icons-container {
    display: flex;
    justify-content: flex-end; 
    align-items: center;
    gap: 10px;
}

.social-icons-container a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 35px;
    height: 35px;
    border-radius: 50%;
    color: #ffffff !important;
    text-decoration: none;
}

.social-icons-container a:hover {
    background-color: #02a35d;
}

/* =========================
   DESKTOP RESPONSIVE
========================= */
@media (min-width: 992px) {
    .dropdown-submenu > .dropdown-menu {
        display: none;
        position: absolute;
        left: 100%;
        top: 0;
    }

    .dropdown-submenu:hover > .dropdown-menu {
        display: block;
    }
}

/* =========================
   MOBILE RESPONSIVE (UPDATED)
========================= */
@media (max-width: 991px) {

    .custom-search-group { 
        margin-bottom: 10px; 
    }

    .navbar-collapse {
        background-color: #ffffff;
        padding: 0;
        border-radius: 12px;
        overflow: hidden;
    }

    /* MAIN MENU */
    .navbar-nav .nav-link {
        color: #000 !important;
        background: #ffffff;
        border-bottom: 1px solid #eee;
        padding: 14px 16px !important;
        font-weight: 600;
    }

    .navbar-nav .nav-link.active {
        background-color: #02A35D !important;
        color: #fff !important;
    }

    /* SUBMENU (LEVEL 2) */
    .dropdown-menu {
        background: #f8f9fa !important;
        display: none;
    }

    .dropdown-menu .dropdown-item {
        padding-left: 30px !important;
        background: #f8f9fa;
        color: #000 !important;
    }

    /* THIRD LEVEL */
    .dropdown-submenu .dropdown-menu {
        background: #f1f3f5 !important;
    }

    .dropdown-submenu .dropdown-menu .dropdown-item {
        padding-left: 45px !important;
        background: #f1f3f5;
        color: #000 !important;

        /* REMOVE GREEN LINE */
        border-left: none !important;
        box-shadow: none !important;
    }

    .dropdown-item:hover {
        background: #e9ecef !important;
        color: #000 !important;
    }

    .nav-link.dropdown-toggle::after {
        margin-left: auto;
    }

    .top-bar { 
        display: none; 
    }
}

/* =========================
   FINAL FIX (REMOVE ANY GREEN LINE)
========================= */
.dropdown-item,
.dropdown-item.active,
.dropdown-item:focus,
.dropdown-submenu .dropdown-item {
    border-left: none !important;
    box-shadow: none !important;
    outline: none !important;
}

/* =========================
   NEWS HOVER CONTROL
========================= */
.news-scroll:hover .news-track {
    animation-play-state: paused;
    cursor: pointer;  
}

@media (max-width: 991px) {

    /* FORCE LEVEL 2 FULL WHITE */
    .navbar-nav .dropdown-menu {
        background: #f8f9fa !important;
    }

    /* FIX: remove inherited green from parent */
    .dropdown-submenu {
        background: #f8f9fa !important;
    }

    /* FIX: ensure no green bleed */
    .dropdown-submenu > .dropdown-item {
        background: #f8f9fa !important;
    }

} 