/* ========================================
   ORDENS DE PRODUÇÃO - KANBAN LAYOUT
   ======================================== */

/* Sobrescrever dark mode - forçar tema claro */
body {
    background: #F7F7F8 !important;
    color: #18191A !important;
}

/* Page Header */
.page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 24px;
    background: #FFFFFF;
    border-bottom: 1px solid #E7E9E9;
}

.page-header-left {
    display: flex;
    align-items: center;
    gap: 16px;
}

.page-title {
    font-family: 'Archivo', -apple-system, sans-serif;
    font-size: 18px;
    font-weight: 600;
    color: #0A0A0A;
    margin: 0;
    line-height: 1.3;
}

.page-header-right {
    display: flex;
    gap: 12px;
    align-items: center;
}

.view-toggle {
    display: flex;
    gap: 0;
    background: transparent;
    padding: 0;
}

.view-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    background: transparent;
    border: 1px solid #E7E9E9;
    border-radius: 4px;
    color: #61666A;
    cursor: pointer;
    transition: all 200ms ease;
}

.view-btn:first-child {
    border-right: none;
    border-top-right-radius: 0;
    border-bottom-right-radius: 0;
}

.view-btn:last-child {
    border-top-left-radius: 0;
    border-bottom-left-radius: 0;
}

.view-btn:hover {
    background: rgba(0, 0, 0, 0.05);
}

.view-btn.active {
    background: #0068AB;
    color: #FFFFFF;
    border-color: #0068AB;
}

.view-btn i {
    width: 16px;
    height: 16px;
}

.btn-filtros {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    height: 36px;
    padding: 0 14px;
    background: #FFFFFF;
    border: 1px solid #E7E9E9;
    border-radius: 4px;
    font-family: 'Archivo', -apple-system, sans-serif;
    font-size: 13px;
    font-weight: 500;
    color: #18191A;
    cursor: pointer;
    transition: all 200ms ease;
    position: relative;
    line-height: 1;
}

.btn-filtros:hover {
    background: #F9FAFA;
}

.btn-filtros i {
    width: 16px;
    height: 16px;
}

.notification-badge {
    position: absolute;
    top: -6px;
    right: -6px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 18px;
    height: 18px;
    padding: 0 5px;
    background: #DC2626;
    color: #FFFFFF;
    font-family: 'Archivo', -apple-system, sans-serif;
    font-size: 11px;
    font-weight: 600;
    border-radius: 9px;
    line-height: 1;
}

.btn-novo-pedido {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    height: 36px;
    padding: 0 14px;
    background: #0068AB;
    color: #FFFFFF;
    border: none;
    border-radius: 4px;
    font-family: 'Archivo', -apple-system, sans-serif;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 200ms ease;
    white-space: nowrap;
    line-height: 1;
}

.btn-novo-pedido:hover {
    background: #064974;
}

.btn-novo-pedido i {
    width: 16px;
    height: 16px;
}

/* Active Filters */
.active-filters {
    display: flex;
    gap: 16px;
    padding: 16px 24px;
    background: #FFFFFF;
    flex-wrap: wrap;
}

.filter-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 0 8px;
    height: 24px;
    background: rgba(6, 73, 116, 0.10);
    border: 1px solid #064974;
    border-radius: 500px;
    font-family: 'Archivo', -apple-system, sans-serif;
    font-size: 12px;
    font-weight: 500;
    color: #0068AB;
}

.filter-badge-remove {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 16px;
    height: 16px;
    background: transparent;
    border: none;
    border-radius: 50%;
    color: #0068AB;
    cursor: pointer;
    transition: all 200ms ease;
    margin-left: 4px;
}

.filter-badge-remove:hover {
    background: rgba(6, 73, 116, 0.15);
}

.filter-badge-remove i {
    width: 12px;
    height: 12px;
}

/* Kanban Board */
.kanban-board {
    display: flex;
    gap: 16px;
    padding: 24px 16px;
    overflow-x: auto;
    overflow-y: auto;
    flex: 1;
    align-items: flex-start;
    background: #F7F7F8;
}

/* Kanban Column */
.kanban-column {
    min-width: 308px;
    max-width: 308px;
    display: flex;
    flex-direction: column;
    gap: 0;
    height: fit-content;
    background: #F1F2F2;
    border: 1px solid #E5E7EB;
    border-radius: 8px;
    overflow: visible;
}

.kanban-column-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px;
    background: #F1F2F2;
    border: none;
    border-bottom: 1px solid #E5E7EB;
    border-radius: 8px 8px 0 0;
}

.kanban-column-title {
    font-family: 'Archivo', -apple-system, sans-serif;
    font-size: 14px;
    font-weight: 700;
    line-height: 20px;
    color: #18191A;
    margin: 0;
}

.kanban-column-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 24px;
    height: 24px;
    padding: 0 8px;
    background: #F1F2F2;
    border: 1px solid #E7E9E9;
    border-radius: 500px;
    font-family: 'Archivo', -apple-system, sans-serif;
    font-size: 12px;
    font-weight: 500;
    line-height: 14.52px;
    color: #61666A;
}

.kanban-column-cards {
    display: flex;
    flex-direction: column;
    gap: 10px;
    overflow: visible;
    padding: 12px;
}

/* OP Card */
.op-card {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 12px;
    width: 100%;
    min-width: 284px;
    max-width: 284px;
    background: #FFFFFF;
    border: 1px solid #E7E9E9;
    border-radius: 8px;
    transition: all 200ms ease;
    cursor: pointer;
    position: relative;
    height: fit-content;
    box-sizing: border-box;
    margin: 0;
    flex-shrink: 0;
}

.op-card:hover {
    border-color: #0068AB;
    box-shadow: 0 4px 12px rgba(0, 104, 171, 0.1);
    transform: translateY(-2px);
}

/* Card Header */
.op-card-header {
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    align-items: flex-start;
    gap: 8px;
    flex-wrap: wrap;
    min-height: 24px;
}

.op-numero {
    display: flex;
    align-items: center;
    gap: 6px;
    white-space: nowrap;
}

.op-id {
    font-family: 'Archivo', -apple-system, sans-serif;
    font-size: 14px;
    font-weight: 700;
    color: #0068AB;
    line-height: 20px;
}

.op-codigo {
    font-family: 'Archivo', -apple-system, sans-serif;
    font-size: 11px;
    font-weight: 500;
    color: #9CA3AF;
    line-height: 16px;
    margin-top: 4px;
}

/* Badges */
.op-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 8px;
    border-radius: 4px;
    font-family: 'Archivo', -apple-system, sans-serif;
    font-size: 10px;
    font-weight: 500;
    line-height: 12px;
    white-space: nowrap;
    width: fit-content;
}

.badge-urgente {
    background: #FEF2F2;
    color: #991B1B;
}

.badge-normal {
    background: #EFF6FF;
    color: #1E40AF;
}

.badge-exemplo {
    background: #F3F4F6;
    color: #374151;
}

.badge-pendente {
    background: #FFFBEB;
    color: #92400E;
}

.badge-semana {
    background: #F0F9FF;
    color: #0369A1;
}

.badge-planejado {
    background: #F5F3FF;
    color: #6B21A8;
}

/* Info Rows */
.op-info-row {
    display: flex;
    align-items: center;
    gap: 8px;
    font-family: 'Archivo', -apple-system, sans-serif;
    font-size: 12px;
    font-weight: 500;
    color: #18191A;
    line-height: 18px;
}

.op-info-row i {
    width: 12px;
    height: 12px;
    color: #9CA3AF;
    flex-shrink: 0;
    stroke-width: 1.5px;
}

.op-info-row.op-vendedor {
    color: #717182;
    margin-left: 22px;
    font-weight: 400;
}

.op-info-row.op-quantidade {
    margin-left: 22px;
}

/* Produto */
.op-produto {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    background: transparent;
    padding: 0;
    font-family: 'Archivo', -apple-system, sans-serif;
    font-size: 12px;
    font-weight: 500;
    color: #18191A;
    line-height: 18px;
}

.op-produto i {
    width: 12px;
    height: 12px;
    color: #9CA3AF;
    flex-shrink: 0;
    margin-top: 2px;
    stroke-width: 1.5px;
}

/* Divider */
.op-divider {
    height: 0;
    border: none;
    border-top: 1px solid #E7E9E9;
    margin: 0;
}

/* Cultura e Status */
.op-cultura {
    font-family: 'Archivo', -apple-system, sans-serif;
    font-size: 13px;
    font-weight: 600;
    color: #18191A;
    line-height: 18px;
    margin-top: 8px;
}

.op-status {
    font-family: 'Archivo', -apple-system, sans-serif;
    font-size: 11px;
    font-weight: 400;
    color: #6A7282;
    line-height: 16px;
    margin-bottom: 4px;
}

/* Label */
.op-label {
    font-weight: 600;
    color: #6A7282;
}

/* Empty State */
.kanban-empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 32px 16px;
    text-align: center;
    gap: 12px;
}

.kanban-empty-state i {
    width: 48px;
    height: 48px;
    color: #D1D5DB;
    stroke-width: 1.5px;
}

.kanban-empty-state p {
    font-family: 'Archivo', -apple-system, sans-serif;
    font-size: 13px;
    font-weight: 400;
    color: #9CA3AF;
    margin: 0;
}

/* Badges da Tabela */
.badge-urgente-table {
    background: #FEF2F2;
    color: #991B1B;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 10px;
    font-weight: 500;
    display: inline-block;
}

.badge-semana-table {
    background: #F0F9FF;
    color: #0369A1;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 10px;
    font-weight: 500;
    display: inline-block;
}

.badge-normal-table {
    background: #EFF6FF;
    color: #1E40AF;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 10px;
    font-weight: 500;
    display: inline-block;
}

/* Status Tags da Tabela */
.status-tag {
    padding: 4px 12px;
    border-radius: 500px;
    font-size: 11px;
    font-weight: 500;
    display: inline-block;
    white-space: nowrap;
}

.status-aprovacao {
    background: #FEF3C7;
    color: #92400E;
}

.status-producao {
    background: #DBEAFE;
    color: #1E40AF;
}

.status-bloqueado {
    background: #FEE2E2;
    color: #991B1B;
}

.status-planejado {
    background: #F3E8FF;
    color: #6B21A8;
}

.status-expedicao {
    background: #D1FAE5;
    color: #065F46;
}

.status-entregue {
    background: #D1FAE5;
    color: #065F46;
}

/* Ícones nas células da tabela */
.table-icon {
    width: 12px;
    height: 12px;
    color: #9CA3AF;
    flex-shrink: 0;
    margin-right: 6px;
}

/* Coluna de produto na tabela */
.pedido-produto-td {
    max-width: 250px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Responsivo */
@media (max-width: 1024px) {
    .kanban-board {
        padding: 16px;
    }
}

@media (max-width: 768px) {
    .page-header {
        flex-direction: column;
        gap: 12px;
        align-items: flex-start;
    }

    .page-header-right {
        width: 100%;
        flex-wrap: wrap;
    }

    .btn-novo-pedido {
        width: 100%;
        justify-content: center;
    }

    .kanban-board {
        flex-direction: column;
    }

    .kanban-column {
        min-width: 100%;
        max-width: 100%;
    }

    .op-card {
        min-width: 100%;
        max-width: 100%;
    }
}
