/**
 * استایل صفحه موکب ایران
 */

/* Container اصلی */
.moukeb-page-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 20px;
}

/* Header صفحه */
.moukeb-page-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 40px;
    border-radius: 15px;
    margin-bottom: 30px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.1);
}

.moukeb-page-header h1 {
    font-size: 2.5em;
    margin-bottom: 10px;
}

/* فیلترها */
.moukeb-filters {
    background: white;
    padding: 25px;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    margin-bottom: 30px;
}

.filter-row {
    display: flex;
    gap: 15px;
    margin-bottom: 15px;
    flex-wrap: wrap;
}

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

.filter-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 600;
    color: #333;
}

.filter-group select,
.filter-group input {
    width: 100%;
    padding: 10px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    transition: all 0.3s;
}

.filter-group select:focus,
.filter-group input:focus {
    border-color: #667eea;
    outline: none;
}

/* گرید محصولات */
.moukeb-products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 25px;
    margin-bottom: 40px;
}

/* کارت محصول */
.moukeb-product-card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0,0,0,0.08);
    transition: all 0.3s ease;
    position: relative;
}

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

/* بج تخفیف */
.discount-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background: #ff6b6b;
    color: white;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: bold;
    z-index: 10;
    animation: pulse 2s infinite;
}

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

/* تصویر محصول */
.product-image {
    position: relative;
    overflow: hidden;
    height: 250px;
    background: #f8f9fa;
}

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

.moukeb-product-card:hover .product-image img {
    transform: scale(1.1);
}

/* اطلاعات محصول */
.product-info {
    padding: 20px;
}

.product-title {
    font-size: 16px;
    margin-bottom: 15px;
    height: 50px;
    overflow: hidden;
}

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

.product-title a:hover {
    color: #667eea;
}

/* قیمت‌ها */
.product-prices {
    margin-bottom: 15px;
}

.market-price {
    margin-bottom: 8px;
}

.market-price .price-label {
    color: #999;
    font-size: 12px;
}

.market-price .price-value {
    color: #dc3545;
    text-decoration: line-through;
    font-size: 14px;
    margin-right: 5px;
}

.moukeb-price .price-label {
    color: #28a745;
    font-size: 13px;
    font-weight: 600;
}

.moukeb-price .price-value {
    color: #28a745;
    font-size: 18px;
    font-weight: bold;
    margin-right: 5px;
}

/* دکمه‌ها */
.product-actions {
    display: flex;
    gap: 10px;
}

.btn-add-to-cart,
.btn-view-product {
    flex: 1;
    padding: 10px 15px;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    text-align: center;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
}

.btn-add-to-cart {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.btn-add-to-cart:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.4);
}

.btn-add-to-cart.loading {
    opacity: 0.7;
    pointer-events: none;
}

.btn-add-to-cart.added {
    background: #28a745;
}

.btn-view-product {
    background: #f8f9fa;
    color: #333;
    border: 2px solid #e0e0e0;
}

.btn-view-product:hover {
    background: #667eea;
    color: white;
    border-color: #667eea;
}

.btn-out-of-stock {
    flex: 1;
    padding: 10px 15px;
    background: #6c757d;
    color: white;
    border: none;
    border-radius: 8px;
    cursor: not-allowed;
    opacity: 0.5;
}

/* Loading Spinner */
.loading-spinner {
    text-align: center;
    padding: 50px;
    font-size: 18px;
    color: #667eea;
}

.spinner {
    display: inline-block;
    width: 16px;
    height: 16px;
    border: 3px solid rgba(255,255,255,0.3);
    border-radius: 50%;
    border-top-color: white;
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* صفحه‌بندی */
.moukeb-pagination {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 40px;
}

.page-btn {
    padding: 8px 16px;
    background: white;
    color: #333;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s;
}

.page-btn:hover {
    background: #667eea;
    color: white;
    border-color: #667eea;
}

.page-btn.active {
    background: #667eea;
    color: white;
    border-color: #667eea;
}

/* Notifications */
.moukeb-notification {
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%) translateY(-100px);
    background: white;
    padding: 15px 25px;
    border-radius: 10px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.2);
    display: flex;
    align-items: center;
    gap: 10px;
    z-index: 99999;
    transition: transform 0.3s ease;
}

.moukeb-notification.show {
    transform: translateX(-50%) translateY(0);
}

.success-notification {
    border-right: 4px solid #28a745;
}

.error-notification {
    border-right: 4px solid #dc3545;
}

.notification-icon {
    font-size: 20px;
    font-weight: bold;
}

.success-notification .notification-icon {
    color: #28a745;
}

.error-notification .notification-icon {
    color: #dc3545;
}

/* Responsive Design */
@media (max-width: 768px) {
    .moukeb-page-header {
        padding: 20px;
    }
    
    .moukeb-page-header h1 {
        font-size: 1.8em;
    }
    
    .moukeb-products-grid {
        grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
        gap: 15px;
    }
    
    .product-image {
        height: 180px;
    }
    
    .product-actions {
        flex-direction: column;
    }
    
    .filter-row {
        flex-direction: column;
    }
}

/* تب‌ها */
.moukeb-tabs {
    display: flex;
    gap: 10px;
    margin-bottom: 30px;
    border-bottom: 2px solid #e0e0e0;
}

.tab-btn {
    padding: 12px 24px;
    background: none;
    border: none;
    color: #666;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    position: relative;
    transition: all 0.3s;
}

.tab-btn:hover {
    color: #667eea;
}

.tab-btn.active {
    color: #667eea;
}

.tab-btn.active::after {
    content: '';
    position: absolute;
    bottom: -2px;
    right: 0;
    width: 100%;
    height: 3px;
    background: #667eea;
}

/* آمار */
.moukeb-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: white;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    text-align: center;
}

.stat-card .stat-value {
    font-size: 28px;
    font-weight: bold;
    color: #667eea;
    margin-bottom: 5px;
}

.stat-card .stat-label {
    color: #666;
    font-size: 14px;
}