/* ===== ELEGANT NAVBAR STYLES ===== */

.header {
    background: white;
    box-shadow: 0 2px 20px rgba(0,0,0,0.1);
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    animation: slideDown 0.6s ease-out;
}

.navbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 15px 30px;
    max-width: 1400px;
    margin: 0 auto;
}

/* Logo */
.logo-container {
    display: flex;
    align-items: center;
    gap: 12px;
    animation: fadeInLeft 0.8s ease-out;
    text-decoration: none;
    color: inherit;
    transition: all 0.3s ease;
}

.logo-container:hover {
    transform: scale(1.05);
}

.logo-icon {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, #FF6B6B, #E85A4F);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: bold;
    font-size: 1.2rem;
    animation: pulse 2s infinite;
}

.logo-text {
    font-size: 1.3rem;
    font-weight: 600;
    color: #333;
}

/* Navigation Links */
.nav-links {
    display: flex;
    gap: 30px;
    animation: fadeInUp 0.8s ease-out 0.2s both;
}

.nav-link {
    text-decoration: none;
    color: #666;
    font-weight: 500;
    padding: 8px 16px;
    border-radius: 25px;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.nav-link::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,107,107,0.1), transparent);
    transition: left 0.5s ease;
}

.nav-link:hover::before {
    left: 100%;
}

.nav-link:hover,
.nav-link.active {
    color: #FF6B6B;
    background: rgba(255,107,107,0.1);
    transform: translateY(-2px);
}

/* Navigation Actions */
.nav-actions {
    display: flex;
    align-items: center;
    gap: 15px;
    animation: fadeInRight 0.8s ease-out 0.4s both;
}

.search-container,
.cart-container,
.user-container {
    display: flex;
    align-items: center;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
}

.user-container a {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    color: #666;
}

.search-container:hover,
.user-container:hover {
    background: rgba(255,107,107,0.1);
    color: #FF6B6B;
    transform: scale(1.1);
}

.cart-container {
    text-decoration: none;
    color: #666;
}

.cart-container:hover {
    background: rgba(255,107,107,0.1);
    color: #FF6B6B;
    transform: scale(1.1);
}

.cart-count {
    position: absolute;
    top: -5px;
    right: -5px;
    background: #FF6B6B;
    color: white;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    font-size: 0.7rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    animation: bounce 0.5s ease-out;
}

.profile-link {
    display: flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    color: #666;
    padding: 8px 12px;
    border-radius: 20px;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.profile-link:hover {
    background: rgba(255,107,107,0.1);
    color: #FF6B6B;
    transform: translateY(-2px);
}

.sign-out-btn {
    background: linear-gradient(135deg, #FF6B6B, #E85A4F);
    color: white;
    border: none;
    padding: 8px 12px;
    border-radius: 20px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(255,107,107,0.3);
    white-space: nowrap;
    font-size: 0.9rem;
}

.sign-out-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255,107,107,0.4);
}

#userMenu {
    display: flex;
    align-items: center;
    gap: 15px;
    position: absolute;
    top: 0;
    left: 0;
    background: rgba(255,107,107,0.1);
    border-radius: 25px;
    padding: 8px 16px;
    border: 1px solid rgba(255,107,107,0.2);
    white-space: nowrap;
}

#userMenu .profile-link {
    display: flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    color: #FF6B6B;
    font-weight: 500;
    transition: all 0.3s ease;
}

#userMenu .profile-link:hover {
    color: #E85A4F;
}

#userMenu .sign-out-btn {
    padding: 6px 12px;
    font-size: 0.9rem;
}

/* Product Grid Enhancements */
.trending-sarees {
    padding: 100px 0;
    background: white;
}

.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
    margin-top: 50px;
}

/* Mobile Product Grid Optimizations */
@media (max-width: 768px) {
    .products-grid {
        grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
        gap: 15px;
        margin-top: 30px;
        padding: 0 10px;
    }
}

@media (max-width: 480px) {
    .products-grid {
        grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
        gap: 10px;
        padding: 0 5px;
    }
}

.product-card {
    background: white;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    transition: all 0.4s ease;
    cursor: pointer;
    animation: fadeInUp 0.8s ease-out;
    position: relative;
}

.product-card:nth-child(1) { animation-delay: 0.1s; }
.product-card:nth-child(2) { animation-delay: 0.2s; }
.product-card:nth-child(3) { animation-delay: 0.3s; }
.product-card:nth-child(4) { animation-delay: 0.4s; }

.product-card:hover {
    transform: translateY(-15px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.15);
}

.product-image {
    width: 100%;
    height: 250px;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.product-card:hover .product-image {
    transform: scale(1.05);
}

.product-info {
    padding: 25px;
}

.product-name {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 10px;
    color: #333;
}

.product-price {
    font-size: 1.3rem;
    font-weight: bold;
    color: #FF6B6B;
    margin-bottom: 10px;
}

.product-rating {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 20px;
}

.stars {
    color: #FFD700;
}

.product-buttons {
    display: flex;
    gap: 10px;
    margin-top: 15px;
}

.add-to-cart-btn,
.buy-now-btn {
    flex: 1;
    padding: 12px;
    border: none;
    border-radius: 8px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.add-to-cart-btn {
    background: rgba(255,107,107,0.1);
    color: #FF6B6B;
    border: 1px solid #FF6B6B;
}

.add-to-cart-btn:hover {
    background: #FF6B6B;
    color: white;
    transform: translateY(-2px);
}

.buy-now-btn {
    background: #FF6B6B;
    color: white;
}

.buy-now-btn:hover {
    background: #E85A4F;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(255,107,107,0.3);
}

/* Animations */
@keyframes slideDown {
    from {
        transform: translateY(-100%);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

@keyframes fadeInLeft {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeInRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% { transform: translateY(0); }
    40% { transform: translateY(-10px); }
    60% { transform: translateY(-5px); }
}

/* Mobile Navigation Enhancements */
.mobile-menu-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 1.5rem;
    color: #333;
    cursor: pointer;
    padding: 8px;
    border-radius: 4px;
    transition: all 0.3s ease;
}

.mobile-menu-toggle:hover {
    background: rgba(255,107,107,0.1);
    color: #FF6B6B;
}

/* Responsive */
@media (max-width: 768px) {
    .navbar {
        padding: 12px 15px;
        flex-wrap: wrap;
        position: relative;
    }
    
    .mobile-menu-toggle {
        display: block;
        order: 3;
    }
    
    .nav-links {
        display: flex;
        width: 100%;
        order: 4;
        flex-direction: column;
        background: white;
        border-top: 1px solid #eee;
        padding: 15px 0;
        margin-top: 10px;
        gap: 5px;
        border-radius: 0 0 12px 12px;
        box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    }
    
    .nav-links.hidden {
        display: none;
    }
    
    .nav-link {
        padding: 12px 20px;
        border-radius: 8px;
        margin: 0 10px;
        text-align: center;
        font-size: 14px;
    }
    
    .nav-actions {
        gap: 10px;
        order: 2;
        flex-wrap: nowrap;
    }
    
    .nav-brand {
        order: 1;
    }
    
    .sign-out-btn {
        padding: 6px 10px;
        font-size: 0.8rem;
    }
    
    .cart-container {
        padding: 8px;
        border-radius: 8px;
    }
    
    .user-container {
        padding: 8px;
        border-radius: 8px;
    }
    
    .profile-link {
        padding: 6px 10px;
        font-size: 0.9rem;
    }
    
    .profile-link span {
        display: none;
    }
    
    #userMenu {
        position: fixed;
        top: 70px;
        right: 15px;
        left: auto;
        width: auto;
        min-width: 200px;
        background: white;
        border-radius: 12px;
        box-shadow: 0 8px 25px rgba(0,0,0,0.15);
        padding: 15px;
        border: 1px solid #e0e0e0;
    }
}

@media (max-width: 480px) {
    .navbar {
        padding: 10px 12px;
    }
    
    .logo-text {
        font-size: 1rem;
    }
    
    .logo-icon {
        width: 32px;
        height: 32px;
        font-size: 0.9rem;
    }
    
    .nav-actions {
        gap: 8px;
    }
    
    .cart-count {
        width: 18px;
        height: 18px;
        font-size: 0.6rem;
        top: -6px;
        right: -6px;
    }
    
    .sign-out-btn {
        padding: 5px 10px;
        font-size: 0.75rem;
    }
}