/* صفحة المنتجات */
.products-page {
    padding: 40px 0;
}

.page-title {
    text-align: center;
    color: var(--primary-dark);
    margin-bottom: 40px;
    font-size: 2.2rem;
}

.products-filter {
    display: grid;
    grid-template-columns: 250px 1fr;
    gap: 30px;
}

.filter-section {
    background: white;
    padding: 20px;
    border-radius: 10px;
    box-shadow: var(--shadow);
    height: fit-content;
}

.filter-section h3 {
    color: var(--primary-dark);
    margin-bottom: 20px;
    display: flex;
    align-items: center;
}

.filter-section h3 i {
    margin-left: 10px;
}

.filter-group {
    margin-bottom: 25px;
}

.filter-group h4 {
    color: var(--text-color);
    margin-bottom: 10px;
    font-size: 1rem;
}

.filter-group label {
    display: block;
    margin-bottom: 8px;
    cursor: pointer;
    color: var(--light-text);
}

.filter-group input[type="checkbox"] {
    margin-left: 8px;
}

.filter-group input[type="range"] {
    width: 100%;
    margin: 15px 0;
}

.price-display {
    text-align: center;
    font-weight: 600;
    color: var(--primary-color);
}

.filter-group select {
    width: 100%;
    padding: 8px;
    border: 1px solid var(--border-color);
    border-radius: 5px;
    font-family: 'Cairo', sans-serif;
}

.apply-filter, .reset-filter {
    width: 100%;
    margin-top: 10px;
}

.reset-filter {
    background: #6c757d;
}

.reset-filter:hover {
    background: #5a6268;
}

.products-display {
    background: white;
    padding: 20px;
    border-radius: 10px;
    box-shadow: var(--shadow);
}

.products-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    padding-bottom: 15px;
    border-bottom: 1px solid var(--border-color);
}

.search-box {
    display: flex;
    flex: 1;
    max-width: 400px;
}

.search-box input {
    flex: 1;
    padding: 10px 15px;
    border: 1px solid var(--border-color);
    border-radius: 5px 0 0 5px;
    font-family: 'Cairo', sans-serif;
}

.search-box button {
    background: var(--primary-color);
    color: white;
    border: none;
    padding: 0 20px;
    border-radius: 0 5px 5px 0;
    cursor: pointer;
}

.view-options {
    display: flex;
    gap: 10px;
}

.view-btn {
    background: white;
    border: 1px solid var(--border-color);
    width: 40px;
    height: 40px;
    border-radius: 5px;
    cursor: pointer;
    color: var(--light-text);
}

.view-btn.active {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

.products-container {
    min-height: 500px;
}

/* عرض الشبكة */
.grid-view {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 25px;
}

/* عرض القائمة */
.list-view .product-card {
    display: flex;
    flex-direction: row;
    height: auto;
}

.list-view .product-image {
    width: 200px;
    height: 200px;
    flex-shrink: 0;
}

.list-view .product-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.list-view .product-actions {
    flex-direction: row;
}

.pagination {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 40px;
}

.page-btn {
    width: 40px;
    height: 40px;
    border: 1px solid var(--border-color);
    background: white;
    border-radius: 5px;
    cursor: pointer;
    font-family: 'Cairo', sans-serif;
}

.page-btn.active {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

.page-btn.disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

@media (max-width: 992px) {
    .products-filter {
        grid-template-columns: 1fr;
    }
    
    .products-header {
        flex-direction: column;
        gap: 15px;
        align-items: stretch;
    }
    
    .search-box {
        max-width: 100%;
    }
}