/* Shop Page Specific Styles */

.shop-hero {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 60px 0;
    text-align: center;
    margin-bottom: 40px;
}

.shop-hero h1 {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 20px;
}

.shop-hero p {
    font-size: 1.2rem;
    opacity: 0.9;
}

.filter-toggle {
    display: none;
    background: #007bff;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 6px;
    margin-bottom: 20px;
    width: 100%;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.filter-toggle:hover {
    background: #0056b3;
}

@media (max-width: 768px) {
    .filter-toggle,
    .filter-toggle.d-md-none {
        display: block !important;
        background: #007bff !important;
        color: white !important;
        border: none !important;
        padding: 12px 20px !important;
        border-radius: 8px !important;
        margin-bottom: 20px !important;
        width: 100% !important;
        font-weight: 500 !important;
        cursor: pointer !important;
        transition: background-color 0.3s ease !important;
        position: relative !important;
        z-index: 1000 !important;
    }
    
    .filter-toggle:hover,
    .filter-toggle.d-md-none:hover {
        background: #0056b3 !important;
    }
    
    .filters-section {
        display: none !important; /* Hidden by default on mobile */
    }
    
    .filters-section.show {
        display: block !important; /* Show when toggled */
    }
    
    .shop-hero h1 {
        font-size: 2rem;
    }
    
    .shop-hero p {
        font-size: 1rem;
    }
}

/* Product Card Enhancements */
.product-card {
    position: relative;
    overflow: hidden;
}

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

.product-card:hover::before {
    left: 100%;
}

.product-image {
    transition: transform 0.3s ease;
}

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

/* Loading Animation */
.loading-spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid #f3f3f3;
    border-top: 3px solid #007bff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Price Badge */
.price-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background: #28a745;
    color: white;
    padding: 5px 10px;
    border-radius: 20px;
    font-weight: 600;
    font-size: 14px;
    z-index: 10;
}

/* Stock Status */
.stock-status {
    position: absolute;
    top: 10px;
    left: 10px;
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 500;
    z-index: 10;
    text-align: center;
}

.stock-in {
    background: #d4edda;
    color: #155724;
}

.stock-low {
    background: #fff3cd;
    color: #856404;
}

.stock-out {
    background: #f8d7da;
    color: #721c24;
}

/* Filter Enhancements */
.filter-group {
    position: relative;
}

.filter-select:focus {
    border-color: #007bff;
    box-shadow: 0 0 0 3px rgba(0,123,255,0.1);
}



/* Search Enhancement */
.search-box {
    position: relative;
}

.search-box::before {
    content: '🔍';
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    pointer-events: none;
    font-size: 16px;
}

.search-box {
    padding-left: 40px;
}

/* Mobile-specific improvements */
@media (max-width: 576px) {
    .shop-container {
        padding: 10px;
    }
    
    .filters-section {
        padding: 15px;
        margin-bottom: 20px;
        display: none; /* Hidden by default on mobile */
    }
    
    .filters-section.show {
        display: block; /* Show when toggled */
    }
    
    .filter-group {
        margin-bottom: 12px;
    }
    
    .filter-buttons {
        display: flex;
        flex-direction: column;
        gap: 10px;
    }
    
    .apply-filters-btn,
    .clear-filters-btn {
        width: 100%;
        margin-left: 0;
    }
    
    .products-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }
    
    .product-card {
        margin: 0;
        max-width: none;
    }
    
    .product-title {
        font-size: 0.9rem;
        line-height: 1.2;
    }
    
    .product-price {
        font-size: 0.85rem;
    }
    
    .view-details-btn {
        font-size: 0.8rem;
        padding: 8px 12px;
    }
    
    .filter-toggle,
    .filter-toggle.d-md-none {
        display: block !important;
        background: #007bff !important;
        color: white !important;
        border: none !important;
        padding: 12px 20px !important;
        border-radius: 8px !important;
        margin-bottom: 20px !important;
        width: 100% !important;
        font-weight: 500 !important;
        cursor: pointer !important;
        transition: background-color 0.3s ease !important;
        position: relative !important;
        z-index: 1000 !important;
    }
    
    .filter-toggle:hover,
    .filter-toggle.d-md-none:hover {
        background: #0056b3 !important;
    }
}



@media (min-width: 577px) and (max-width: 768px) {
    .filters-section {
        display: none; /* Hidden by default on mobile */
    }
    
    .filters-section.show {
        display: block; /* Show when toggled */
    }
    
    .products-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
    }
    
    .filter-toggle,
    .filter-toggle.d-md-none {
        display: block !important;
        background: #007bff !important;
        color: white !important;
        border: none !important;
        padding: 12px 20px !important;
        border-radius: 8px !important;
        margin-bottom: 20px !important;
        width: 100% !important;
        font-weight: 500 !important;
        cursor: pointer !important;
        transition: background-color 0.3s ease !important;
        position: relative !important;
        z-index: 1000 !important;
    }
    
    .filter-toggle:hover,
    .filter-toggle.d-md-none:hover {
        background: #0056b3 !important;
    }
}

@media (min-width: 769px) and (max-width: 992px) {
    .products-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 25px;
    }
}

@media (min-width: 993px) {
    .products-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 30px;
    }
}

/* Animation for product cards */
.product-card {
    animation: fadeInUp 0.6s ease-out;
}

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

/* Stagger animation for multiple cards */
.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:nth-child(5) { animation-delay: 0.5s; }
.product-card:nth-child(6) { animation-delay: 0.6s; }
.product-card:nth-child(7) { animation-delay: 0.7s; }
.product-card:nth-child(8) { animation-delay: 0.8s; }

/* Hover effects for buttons */
.apply-filters-btn,
.clear-filters-btn,
.view-details-btn {
    position: relative;
    overflow: hidden;
}

.apply-filters-btn::before,
.clear-filters-btn::before,
.view-details-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transition: left 0.5s;
}

.apply-filters-btn:hover::before,
.clear-filters-btn:hover::before,
.view-details-btn:hover::before {
    left: 100%;
} 