/* ============================================================
   SS Advertising - Header / Navbar CSS
   File: assets/css/header.css
   ============================================================ */

:root {
    --primary-blue:  #1565C0;
    --accent-blue:   #2196F3;
    --light-blue:    #E3F2FD;
    --dark-text:     #1A1A2E;
    --white:         #ffffff;
    --transition:    all 0.3s ease;
    --font-main:     'Poppins', sans-serif;
    --border-color: #545454;
}

/* -------------------------------------------------------
   1. SITE HEADER
   ------------------------------------------------------- */
.site-header {
    /* position: sticky; */
    top: 0;
    z-index: 9999;
    background: transparent;
    /* box-shadow: 0 2px 16px rgba(0, 0, 0, 0.07); */
    transition: box-shadow 0.3s ease;
}

.site-header.scrolled {
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.12);
}

/* -------------------------------------------------------
   2. NAVBAR
   ------------------------------------------------------- */
.navbar-custom {
    padding: 10px 0 0 0;
}
    .site-header {
        /* border-bottom: 1px solid #e8e8e8; */
        position: relative;
        z-index: 999999999999999999;
    }
.navbar-custom .container {
    border-bottom: 1px solid var(--border-color);
}

/* -------------------------------------------------------
   3. LOGO
   ------------------------------------------------------- */
.navbar-brand {
    display: flex;
    align-items: center;
    gap: 0;
    text-decoration: none;
}

.brand-ss {
    font-family: var(--font-main);
    font-size: 1.85rem;
    font-weight: 900;
    color: var(--primary-blue);
    letter-spacing: -1px;
    line-height: 1;
    position: relative;
}

.brand-ss::after {
    content: '';
    display: block;
    height: 3px;
    background: var(--accent-blue);
    border-radius: 2px;
    margin-top: 2px;
}

.brand-text {
    font-family: var(--font-main);
    font-size: 0.9rem;
    font-weight: 500;
    color: #444;
    margin-left: 6px;
    line-height: 1;
    padding-top: 2px;
}

/* -------------------------------------------------------
   4. NAV LINKS
   ------------------------------------------------------- */
.navbar-custom .nav-link {
    font-family: var(--font-main);
    font-size: 18px;
    font-weight: 500;
    color: var(--dark-text);
    padding: 8px 18px !important;
    border-radius: 8px;
    transition: var(--transition);
    position: relative;
}

.container.nav-con {
    padding-bottom: 2px;
}

.navbar-custom .nav-link:hover {
    color: var(--dark-text);
    background: transparent;
}

.dropdown-toggle::after {
    display: none;
}

.navbar-custom .nav-item.active > .nav-link,
.navbar-custom .nav-link.active {
    color: var(--primary-blue);
    border-radius: 8px;
    font-weight: 600;
}

a.nav-link {
    font-size: 20px;
}

/* -------------------------------------------------------
   5. CONTACT BUTTON
   ------------------------------------------------------- */
.nav-contact-btn {
    background: var(--primary-blue) !important;
    color: var(--white) !important;
    border-radius: 50px !important;
    padding: 10px 26px !important;
    font-family: var(--font-main);
    font-weight: 600 !important;
    font-size: 14px !important;
    box-shadow: 0 4px 16px rgba(21, 101, 192, 0.30);
    transition: var(--transition);
    display: inline-block;
    text-decoration: none;
    line-height: 1.5;
}

.nav-contact-btn:hover {
    background: #0D47A1 !important;
    color: var(--white) !important;
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(21, 101, 192, 0.40);
}

/* -------------------------------------------------------
   6. DESKTOP MEGA DROPDOWN (992px+)
   ------------------------------------------------------- */
.navbar-custom .dropdown-menu {
    border: none;
    border-radius: 14px;
    background: #2C2C2CE5;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    box-shadow: 0 12px 48px rgba(0, 0, 0, 0.22);
    padding: 22px;
    min-width: 700px;
    left: 50%;
    transform: translateX(-50%) translateY(12px);
    opacity: 0;
    display: block;
    pointer-events: none;
    transition: opacity 0.22s ease, transform 0.22s ease;
    margin-top: 10px;
}

.navbar-custom .dropdown-menu::before {
    content: '';
    position: absolute;
    top: -8px;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 0;
    border-left: 9px solid transparent;
    border-right: 9px solid transparent;
    border-bottom: 9px solid #2C2C2CE5;
}

.navbar-custom .dropdown:hover .dropdown-menu,
.navbar-custom .dropdown.show .dropdown-menu {
    opacity: 1;
    transform: translateX(-50%) translateY(-10px);
    pointer-events: auto;
}

/* -------------------------------------------------------
   7. DROPDOWN GRID
   ------------------------------------------------------- */
.dropdown-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 4px;
}

.dropdown-item-custom {
    padding: 14px 16px;
    border-radius: 8px;
    transition: var(--transition);
    cursor: pointer;
    display: block;
    text-decoration: none;
}

.dropdown-item-custom:hover {
       background: #343434;
    border: 1px solid #1059B64D;
}

.dropdown-item-custom .item-title {
    font-family: var(--font-main);
    font-size: 12.5px;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 5px;
    display: block;
}

.dropdown-item-custom .item-desc {
    font-family: var(--font-main);
    font-size: 12px;
    color: rgba(255, 255, 255, 0.60);
    line-height: 1.55;
    display: block;
}

/* -------------------------------------------------------
   8. TABLET + MOBILE — max 991px
   
   IMPORTANT: 991px sudhi (tablet + mobile) badha fixes
   - Collapse floats over content (position fixed)
   - Dropdown click pe open thay
   - Menu scrollable
   ------------------------------------------------------- */
@media (max-width: 991px) {

    .site-header {
        border-bottom: 1px solid #e8e8e8;
            position: relative;
    z-index: 999999999999999999;
    }
.container.nav-con {
    /* padding: 0; */
}
    .navbar-custom {
        padding: 8px 0;
        position: relative;
    }

    /* Container border hataviye — header border use kariye */
    .navbar-custom .container {
        border-bottom: none;
    }

    .navbar-brand img {
        max-height: 42px;
    }

    .navbar-toggler {
        padding: 6px 10px;
    }

    /* ===================================================
       KEY FIX 1: Collapse floats OVER page content
       Hero section push nahi thay
       =================================================== */
    .navbar-collapse {
        position: fixed;
        top: 57px;
        left: 0;
        right: 0;
        bottom: 0;
        z-index: 9998;
        background: #ffffff;
        border-top: 2px solid #eeeeee;
        box-shadow: 0 4px 20px rgba(0, 0, 0, 0.12);
        padding: 0;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
    }

    .navbar-collapse .navbar-nav {
        padding: 4px 0 40px;
    }

    /* Nav link styling — clean list */
    .navbar-custom .nav-link {
        font-size: 16px;
        font-weight: 500;
        padding: 14px 20px !important;
        border-radius: 0;
        border-bottom: 1px solid #f0f0f0;
        color: var(--dark-text);
        display: flex;
        justify-content: space-between;
        align-items: center;
    }

    a.nav-link {
        font-size: 16px;
    }

    .navbar-custom .nav-link.active {
        color: var(--primary-blue);
        background: #f0f7ff;
        font-weight: 600;
    }

    .navbar-custom .nav-link:hover {
        background: #f8f9fa;
        color: var(--primary-blue);
    }

    /* ===================================================
       KEY FIX 2: Services dropdown — click pe open/close
       Desktop ni opacity trick remove kariye
       =================================================== */
    .navbar-custom .dropdown-menu {
        position: static !important;
        transform: none !important;
        opacity: 1 !important;
        pointer-events: auto !important;
        display: none !important;      /* default hidden */
        box-shadow: none;
        background: #2C2C2CE5;
        border-radius: 0;
        margin: 0;
        min-width: 100% !important;
        padding: 6px 12px 12px;
    }

    /* .show class add thay tyare open */
    .navbar-custom .dropdown-menu.show {
        display: block !important;
    }

    .navbar-custom .dropdown-menu::before {
        display: none !important;
    }

    /* Single column dropdown on tablet/mobile */
    .dropdown-grid {
        grid-template-columns: 1fr;
        gap: 2px;
    }

    .dropdown-item-custom {
        padding: 10px 14px;
        border-bottom: 1px solid rgba(255, 255, 255, 0.07);
        border-radius: 6px;
    }

    .dropdown-item-custom:last-child {
        border-bottom: none;
    }

    .dropdown-item-custom .item-title {
        font-size: 14px;
        color: #ffffff;
    }

    .dropdown-item-custom .item-desc {
        font-size: 11.5px;
        color: rgba(255, 255, 255, 0.55);
    }

    /* Arrow indicator on Services toggle */
    .navbar-custom .dropdown-toggle::after {
        display: inline-block !important;
        content: '';
        width: 7px;
        height: 7px;
        border-right: 2px solid #999;
        border-bottom: 2px solid #999;
        transform: rotate(45deg);
        transition: transform 0.25s ease;
        flex-shrink: 0;
        margin-left: auto;
    }

    /* Arrow rotate when open */
    .navbar-custom .dropdown.show .dropdown-toggle::after {
        transform: rotate(-135deg);
        border-color: var(--primary-blue);
    }

    .nav-contact-btn {
        margin: 12px 20px 8px;
        width: calc(100% - 40px);
        text-align: center;
        display: block;
    }
}

/* -------------------------------------------------------
   9. SMALL MOBILE (max 480px)
   ------------------------------------------------------- */
@media (max-width: 480px) {
    .brand-ss {
        font-size: 1.55rem;
    }

    .brand-text {
        font-size: 0.8rem;
    }

    .navbar-brand img {
        max-height: 34px;
    }

    .navbar-collapse {
        top: 50px;
    }
}
