.products-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    padding: 2rem 0;
    max-width: 1400px;
    margin: 0 auto;
    width: 100%;
}

@media (max-width: 1200px) {
    .products-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .products-grid {
        grid-template-columns: 1fr;
    }
}

.products-grid.filtering {
    pointer-events: none;
}

.product-card {
    opacity: 1;
    height: 100%;
    display: flex;
    flex-direction: column;
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
    overflow: hidden;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.15);
}

.product-card.show {
    opacity: 1;
    transform: translateY(0);
}

.product-card {
    opacity: 1;
    transition: all 0.3s ease-in-out;
    transform: translateY(0);
}

.product-card {
    animation: fadeIn 0.6s ease-out;
    animation-fill-mode: both;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.product-card:nth-child(3n+1) { animation-delay: 0.1s; }
.product-card:nth-child(3n+2) { animation-delay: 0.2s; }
.product-card:nth-child(3n+3) { animation-delay: 0.3s; }

/* تخطيط متجاوب */
@media (max-width: 1400px) {
    .products-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 1.5rem;
        padding: 1.5rem;
        margin: 0 1rem;
    }
}

@media (max-width: 1200px) {
    .products-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1.5rem;
    }
}

@media (max-width: 768px) {
    .products-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
        padding: 1rem;
    }
    
    .container {
        padding: 0 1rem;
    }
}

@media (max-width: 576px) {
    .products-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
}

/* تنسيق البحث والفلتر */
.search-filter {
    margin: 2rem auto;
    max-width: 800px;
    background: #fff;
    padding: 1.5rem;
    border-radius: 12px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.search-bar {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.search-input,
.filter-select {
    flex: 1;
    position: relative;
    background: #f8f9fa;
    border-radius: 8px;
    padding: 0.8rem 1rem;
    transition: all 0.3s ease;
}

.search-input:focus-within,
.filter-select:focus-within {
    background: #fff;
    box-shadow: 0 0 0 2px #4CAF50;
}

.search-input i,
.filter-select i {
    color: #666;
    margin-left: 0.5rem;
}

.search-input input,
.filter-select select {
    width: 100%;
    border: none;
    outline: none;
    background: transparent;
    font-size: 1rem;
    color: #333;
}

.filter-select select {
    cursor: pointer;
    padding-right: 1.5rem;
}

@media (max-width: 600px) {
    .search-bar {
        flex-direction: column;
    }
    
    .search-input,
    .filter-select {
        width: 100%;
    }
}

/* رسالة لا توجد نتائج */
.no-results {
    text-align: center;
    padding: 3rem 2rem;
    background: #f8f9fa;
    border-radius: 12px;
    margin: 2rem auto;
    max-width: 600px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.no-results i {
    font-size: 3rem;
    color: #ccc;
    margin-bottom: 1rem;
    display: block;
}

.no-results h3 {
    color: #333;
    margin-bottom: 0.5rem;
}

.no-results p {
    color: #666;
    margin-bottom: 1.5rem;
}

.no-results .btn {
    display: inline-block;
    padding: 0.8rem 2rem;
    background: #4CAF50;
    color: white;
    border-radius: 25px;
    text-decoration: none;
    transition: all 0.3s ease;
}

.no-results .btn:hover {
    background: #45a049;
    transform: translateY(-2px);
}
