/* Sticky Responsive Navbar Styles */
.custom-navbar {
    position: sticky;
    top: 0;
    width: 100%;
    background: #fff;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.07);
    z-index: 1000;
}

.custom-navbar .container {
    display: flex !important;
    align-items: center;
    justify-content: space-between;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
    height: 70px;
    position: relative;
    flex-wrap: nowrap;
}

.navbar-brand {
    z-index: 1100;
    flex-shrink: 0;
    display: flex;
    align-items: center;
}

.navbar-brand .logo {
    height: 50px;
    width: auto;
    display: block;
}

/* Mobile Navigation Icons (Cart, Wishlist, Hamburger) */
.mobile-nav-icons {
    display: none;
    align-items: center;
    gap: 16px;
    margin-left: auto;
}

.mobile-icon-btn {
    position: relative;
    color: #222;
    font-size: 1.3rem;
    padding: 8px;
    transition: color 0.2s;
    text-decoration: none;
    display: flex;
    align-items: center;
    justify-content: center;
}

.mobile-icon-btn:hover {
    color: #8b0000;
}

.mobile-cart-count,
.mobile-wishlist-count {
    position: absolute;
    top: 2px;
    right: 2px;
    background: #8b0000;
    color: #fff;
    border-radius: 50%;
    width: 18px;
    height: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
    font-weight: 600;
}

.navbar-links {
    display: flex;
    gap: 32px;
    list-style: none;
    margin: 0;
    padding: 0;
    align-items: center;
}

.navbar-links li {
    margin: 0;
}

.navbar-links li a {
    color: #222;
    text-decoration: none;
    font-size: 1rem;
    font-weight: 500;
    padding: 8px 12px;
    transition: color 0.2s;
    display: block;
}

.navbar-links li a:hover,
.navbar-links li a.active {
    color: #8b0000;
}

.navbar-links .cart-nav,
.navbar-links .wishlist-nav {
    display: flex;
}

.navbar-links .cart-nav a,
.navbar-links .wishlist-nav a {
    position: relative;
    color: #222;
    font-size: 1.2rem;
}

.navbar-links .cart-count,
.navbar-links .wishlist-count {
    position: absolute;
    top: -5px;
    right: -10px;
    background: #8b0000;
    color: #fff;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: 600;
}

.navbar-toggle {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 30px;
    height: 24px;
    cursor: pointer;
    z-index: 1100;
    background: transparent;
    border: none;
    padding: 0;
    margin-left: auto;
    outline: none;
}

.navbar-toggle span {
    display: block;
    height: 3px;
    width: 100%;
    background: #8b0000;
    border-radius: 2px;
    transition: all 0.3s ease-in-out;
    transform-origin: center;
}

/* Hamburger animation */
.navbar-toggle.active span:nth-child(1) {
    transform: translateY(10px) rotate(45deg);
}

.navbar-toggle.active span:nth-child(2) {
    opacity: 0;
    transform: rotate(180deg);
}

.navbar-toggle.active span:nth-child(3) {
    transform: translateY(-10px) rotate(-45deg);
}

/* Mobile Responsive */
@media (max-width: 900px) {
    .custom-navbar .container {
        height: 60px;
        padding: 0 16px;
    }
    
    .navbar-brand .logo {
        height: 40px;
    }
    
    /* Show mobile icons container */
    .mobile-nav-icons {
        display: flex !important;
    }
    
    /* Hide cart/wishlist from navbar-links on mobile */
    .navbar-links .cart-nav,
    .navbar-links .wishlist-nav {
        display: none !important;
    }
    
    .navbar-links {
        position: fixed;
        top: 60px;
        left: 0;
        width: 100%;
        background: #fff;
        flex-direction: column;
        align-items: flex-start;
        gap: 0;
        max-height: 0;
        overflow: hidden;
        box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
        transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    }
    
    .navbar-links.active {
        max-height: 500px;
        overflow-y: auto;
    }
    
    .navbar-links li {
        width: 100%;
        border-bottom: 1px solid #eee;
    }
    
    .navbar-links li:last-child {
        border-bottom: none;
    }
    
    .navbar-links li a {
        display: block;
        width: 100%;
        padding: 16px 24px;
        font-size: 1.1rem;
    }
}

@media (max-width: 600px) {
    .custom-navbar .container {
        padding: 0 12px;
    }
    
    .navbar-brand .logo {
        height: 35px;
    }
    
    .mobile-nav-icons {
        gap: 12px;
    }
    
    .mobile-icon-btn {
        font-size: 1.2rem;
        padding: 6px;
    }
    
    .mobile-cart-count,
    .mobile-wishlist-count {
        width: 16px;
        height: 16px;
        font-size: 0.65rem;
        top: 0;
        right: 0;
    }
    
    .navbar-toggle {
        width: 28px;
        height: 22px;
    }
}

/* Force visibility on mobile - override any conflicting styles */
@media (max-width: 900px) {
    button.navbar-toggle {
        display: flex !important;
        visibility: visible !important;
        opacity: 1 !important;
        pointer-events: auto !important;
    }
}
