/* pedidos.css*/

:root {
    --primary-color: #160503;
    --primary-color-opacity: rgba(22, 5, 3, 0.7607843137);
    --background-white: #FFF;
    --primary-brown: #9F5524;
    --background-gray: #F3F4F6;
    --light-gray: #E5E7EB;
    --success-green: #10B981;
    --error-red: #EF4444;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Open Sans', sans-serif;
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
    min-height: 100vh;
    color: #160503;
}

.header {
    background: #160503;
    color: white;
    padding: 20px 0;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

.header-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.header-title {
    display: flex;
    align-items: center;
    gap: 15px;
}

.header-title h1 {
    font-family: 'Fredoka', sans-serif;
    font-size: 28px;
    font-weight: 600;
}

.header-title .material-symbols-outlined {
    font-size: 32px;
    color: #F2AF2A;
}

.back-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    background: transparent;
    border: 2px solid #F2AF2A;
    border-radius: 25px;
    color: #F2AF2A;
    text-decoration: none;
    transition: all 0.3s ease;
    font-weight: 500;
}

.back-btn:hover {
    background: #F2AF2A;
    color: #160503;
    transform: translateY(-2px);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 20px;
    display: flex;
    flex-direction: row-reverse;
    gap: 20px;
    align-content: center;
    justify-content: center;
}

.stats-section {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 40px;
}

.stat-card {
    background: white;
    padding: 25px;
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    text-align: center;
    transition: transform 0.2s ease;
}

.stat-card:hover {
    transform: translateY(-2px);
}

.stat-card .material-symbols-outlined {
    font-size: 40px;
    color: #9F5524;
    margin-bottom: 10px;
}

.stat-number {
    font-size: 32px;
    font-weight: 700;
    color: #160503;
    margin-bottom: 5px;
}

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

.orders-section {
    background: white;
    border-radius: 20px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    width: 70%;
}

.section-header {
    background: linear-gradient(135deg, #160503, #2d1b17);
    color: white;
    padding: 30px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.section-title {
    font-size: 24px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 12px;
}

.refresh-btn {
    background: #F2AF2A;
    color: #160503;
    border: none;
    padding: 10px 20px;
    border-radius: 10px;
    cursor: pointer;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.2s ease;
}

.refresh-btn:hover {
    background: #e09f1f;
    transform: scale(1.05);
}

.orders-content {
    padding: 30px;
}

.loading {
    text-align: center;
    padding: 60px 20px;
    color: #666;
}

.loading .material-symbols-outlined {
    font-size: 48px;
    color: #9F5524;
    margin-bottom: 15px;
    animation: spin 1s linear infinite;
}

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

.empty-state {
    text-align: center;
    padding: 80px 20px;
}

.empty-state .material-symbols-outlined {
    font-size: 80px;
    color: #cbd5e1;
    margin-bottom: 20px;
}

.empty-state h3 {
    font-size: 24px;
    color: #475569;
    margin-bottom: 12px;
}

.empty-state p {
    color: #64748b;
    margin-bottom: 30px;
    font-size: 16px;
}

.order-card {
    background: #f8fafc;
    border: 2px solid #e2e8f0;
    border-radius: 16px;
    margin-bottom: 20px;
    overflow: hidden;
    transition: all 0.3s ease;
}

.order-card:hover {
    border-color: #9F5524;
    box-shadow: 0 8px 25px rgba(159, 85, 36, 0.15);
}

.order-header {
    background: white;
    padding: 20px 25px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #e2e8f0;
}

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

.order-id {
    font-weight: 700;
    font-size: 18px;
    color: #160503;
}

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

.order-status {
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.status-creado {
    background: #fef3c7;
    color: #92400e;
}

.status-preparado {
    background: #dbeafe;
    color: #1e40af;
}

.status-entregado {
    background: #d1fae5;
    color: #065f46;
}

.order-body {
    padding: 25px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.order-total {
    font-size: 24px;
    font-weight: 700;
    color: #160503;
}

.order-actions {
    display: flex;
    gap: 12px;
}

.action-btn {
    padding: 12px 20px;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    font-weight: 600;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.2s ease;
    text-decoration: none;
}

.btn-primary {
    background: #9F5524;
    color: white;
}

.btn-primary:hover {
    background: #8b4a1f;
    transform: translateY(-1px);
}

.btn-secondary {
    background: #e2e8f0;
    color: #475569;
}

.btn-secondary:hover {
    background: #cbd5e1;
}

.primary-btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: linear-gradient(135deg, #9F5524, #b8652a);
    color: white;
    padding: 15px 30px;
    border-radius: 12px;
    text-decoration: none;
    font-weight: 600;
    font-size: 16px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(159, 85, 36, 0.3);
}

.primary-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(159, 85, 36, 0.4);
}

.error-message {
    text-align: center;
    padding: 40px 20px;
    color: #dc2626;
    background: #fef2f2;
    border-radius: 12px;
    border: 1px solid #fecaca;
}

.error-message .material-symbols-outlined {
    font-size: 48px;
    margin-bottom: 15px;
}

@media (max-width: 768px) {
    .header-content {
        flex-direction: column;
        gap: 20px;
        text-align: center;
    }

    .stats-section {
        grid-template-columns: repeat(2, 1fr);
    }

    .order-header,
    .order-body {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }

    .order-actions {
        flex-direction: column;
        width: 100%;
    }

    .action-btn {
        justify-content: center;
    }
}

