﻿/* Страница заказов поставщика */
.page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    flex-wrap: wrap;
    gap: 15px;
}

.page-title {
    font-size: 28px;
    font-weight: 600;
    color: #333;
}

.filter-controls {
    min-width: 200px;
}

.filter-select {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid #ddd;
    border-radius: 10px;
    font-size: 14px;
    background: white;
    cursor: pointer;
}

/* Список заказов */
.orders-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.order-card {
    background: white;
    border-radius: 16px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.04);
    padding: 20px;
    transition: box-shadow 0.2s;
}

    .order-card:hover {
        box-shadow: 0 4px 12px rgba(0,0,0,0.08);
    }

.order-header {
    display: flex;
    align-items: center;
    gap: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid #eee;
    flex-wrap: wrap;
}

.order-info {
    display: flex;
    align-items: center;
    gap: 15px;
}

.order-number {
    font-weight: 600;
    font-size: 16px;
    color: #333;
}

.order-date {
    color: #888;
    font-size: 14px;
}

.order-customer {
    flex: 1;
    font-weight: 500;
    color: #555;
}

.order-status {
    padding: 6px 16px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 500;
}

.status-new {
    background: #e3f2fd;
    color: #1976d2;
}

.status-processing {
    background: #fff3e0;
    color: #f57c00;
}

.status-shipped {
    background: #e8eaf6;
    color: #3f51b5;
}

.status-delivered {
    background: #e8f5e9;
    color: #388e3c;
}

.status-cancelled {
    background: #ffebee;
    color: #d32f2f;
}

.order-total {
    font-weight: 700;
    font-size: 18px;
    color: #f54900;
}

/* Товары в заказе */
.order-items {
    padding: 15px 0;
}

.order-item {
    display: flex;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px dashed #eee;
}

    .order-item:last-child {
        border-bottom: none;
    }

.item-name {
    flex: 1;
    font-weight: 500;
    color: #333;
}

.item-quantity {
    width: 150px;
    color: #666;
    font-size: 14px;
}

.item-total {
    width: 120px;
    text-align: right;
    font-weight: 600;
    color: #333;
}

/* Действия */
.order-actions {
    display: flex;
    gap: 12px;
    padding-top: 15px;
    border-top: 1px solid #eee;
}

.btn-sm {
    padding: 8px 16px;
    font-size: 13px;
}

/* Модальное окно */
.modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.5);
    z-index: 2000;
    align-items: center;
    justify-content: center;
}

.modal-content {
    background: white;
    border-radius: 16px;
    padding: 30px;
    max-width: 500px;
    width: 90%;
    position: relative;
}

    .modal-content h2 {
        font-size: 22px;
        margin-bottom: 25px;
        color: #333;
    }

.close-modal {
    position: absolute;
    top: 15px;
    right: 15px;
    background: none;
    border: none;
    font-size: 28px;
    cursor: pointer;
    color: #999;
}

/* Адаптивность */
@media (max-width: 768px) {
    .page-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .filter-controls {
        width: 100%;
    }

    .order-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }

    .order-customer {
        width: 100%;
    }

    .order-item {
        flex-wrap: wrap;
        gap: 5px;
    }

    .item-name {
        width: 100%;
    }

    .item-quantity {
        width: auto;
    }

    .item-total {
        width: auto;
        margin-left: auto;
    }

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

        .order-actions .btn-sm {
            width: 100%;
            text-align: center;
        }
}

.loader {
    text-align: center;
    padding: 40px;
    color: #666;
}

.error {
    text-align: center;
    padding: 40px;
    color: #f44336;
}

.empty {
    text-align: center;
    padding: 40px;
    color: #999;
}
