/* Galeri Produk Styles */

.product-gallery {
    padding: 4rem 0;
    background-color: #f8f9fa;
}

.gallery-controls {
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;
    margin-bottom: 2rem;
    padding: 2rem;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.filter-group {
    flex: 1;
    min-width: 200px;
}

.filter-group h3 {
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
    color: #666;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.filter-group select {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 1rem;
    background: white;
    cursor: pointer;
}

.filter-group select:focus {
    outline: none;
    border-color: #007bff;
    box-shadow: 0 0 0 2px rgba(0,123,255,0.25);
}

.search-group {
    display: flex;
    flex: 2;
    min-width: 250px;
    gap: 0.5rem;
}

.search-group input {
    flex: 1;
    padding: 0.75rem;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 1rem;
}

.search-group input:focus {
    outline: none;
    border-color: #007bff;
    box-shadow: 0 0 0 2px rgba(0,123,255,0.25);
}

.search-group button {
    padding: 0.75rem 1rem;
    background: #007bff;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.3s;
}

.search-group button:hover {
    background: #0056b3;
}

.gallery-stats {
    margin-bottom: 2rem;
    text-align: center;
}

.gallery-stats p {
    color: #666;
    font-size: 1.1rem;
}

.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.product-card {
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    transition: transform 0.3s, box-shadow 0.3s;
    opacity: 0;
    transform: translateY(20px);
    animation: fadeInUp 0.6s ease forwards;
}

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

.product-image {
    position: relative;
    overflow: hidden;
    height: 250px;
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s;
}

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

.product-image a {
    display: block;
    height: 100%;
}

.stock-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: bold;
    text-transform: uppercase;
}

.stock-badge.low-stock {
    background: #ffc107;
    color: #212529;
}

.stock-badge.out-of-stock {
    background: #dc3545;
    color: white;
}

.product-info {
    padding: 1.5rem;
}

.product-info h3 {
    margin-bottom: 0.5rem;
    font-size: 1.2rem;
    font-weight: 600;
}

.product-info h3 a {
    color: #333;
    text-decoration: none;
    transition: color 0.3s;
}

.product-info h3 a:hover {
    color: #007bff;
}

.product-info .price {
    font-size: 1.3rem;
    font-weight: bold;
    color: #007bff;
    margin-bottom: 0.5rem;
}

.product-info .category {
    color: #666;
    font-size: 0.9rem;
    margin-bottom: 1rem;
    text-transform: capitalize;
}

.product-actions {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.btn-small {
    padding: 0.5rem 1rem;
    border: none;
    border-radius: 4px;
    font-size: 0.9rem;
    cursor: pointer;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    transition: all 0.3s;
    flex: 1;
    justify-content: center;
}

.btn-small:hover {
    transform: translateY(-2px);
}

.btn-outline {
    background: transparent;
    border: 1px solid #007bff;
    color: #007bff;
}

.btn-outline:hover {
    background: #007bff;
    color: white;
}

.loading {
    text-align: center;
    padding: 4rem 2rem;
    color: #666;
}

.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #007bff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 1rem;
}

.no-products {
    text-align: center;
    padding: 4rem 2rem;
    color: #666;
}

.no-products i {
    font-size: 3rem;
    margin-bottom: 1rem;
    display: block;
}

.no-products h3 {
    margin-bottom: 0.5rem;
    color: #333;
}

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

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

/* Responsive Design */
@media (max-width: 768px) {
    .gallery-controls {
        flex-direction: column;
        gap: 1rem;
    }

    .search-group {
        flex-direction: column;
    }

    .product-grid {
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
        gap: 1rem;
    }

    .product-actions {
        flex-direction: column;
    }

    .btn-small {
        margin-bottom: 0.5rem;
    }
}

@media (max-width: 480px) {
    .product-grid {
        grid-template-columns: 1fr;
    }

    .gallery-controls {
        padding: 1rem;
    }

    .product-info {
        padding: 1rem;
    }
}
