/* Estilos otimizados para o Kanban - Layout mais compacto */

.kanban-board {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 0.75rem;
    padding: 1rem;
    background: #f8f9fa;
    border-radius: 12px;
    overflow-x: auto;
    min-height: 600px;
    max-width: 100%;
}

.kanban-column {
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    min-width: 200px;
    max-width: 250px;
    display: flex;
    flex-direction: column;
    border: 1px solid #e9ecef;
}

.kanban-column-header {
    background: linear-gradient(135deg, #4A67A1 0%, #5a77b1 100%);
    color: white;
    padding: 0.75rem;
    text-align: center;
    font-weight: 600;
    font-size: 0.9rem;
    border-radius: 8px 8px 0 0;
    font-family: 'Times New Roman', serif;
    position: sticky;
    top: 0;
    z-index: 10;
}

/* Cores específicas para cada coluna */
.kanban-column:nth-child(1) .kanban-column-header {
    background: linear-gradient(135deg, #FFD700 0%, #FFA500 100%);
    color: #333;
}

.kanban-column:nth-child(2) .kanban-column-header {
    background: linear-gradient(135deg, #87CEEB 0%, #4682B4 100%);
}

.kanban-column:nth-child(3) .kanban-column-header {
    background: linear-gradient(135deg, #90EE90 0%, #32CD32 100%);
    color: #333;
}

.kanban-column:nth-child(4) .kanban-column-header {
    background: linear-gradient(135deg, #DDA0DD 0%, #9370DB 100%);
}

.kanban-column:nth-child(5) .kanban-column-header {
    background: linear-gradient(135deg, #4169E1 0%, #0000CD 100%);
}

.kanban-column:nth-child(6) .kanban-column-header {
    background: linear-gradient(135deg, #DC143C 0%, #B22222 100%);
}

.kanban-tasks {
    flex: 1;
    padding: 0.5rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    max-height: 500px;
    overflow-y: auto;
}

.kanban-task {
    background: white;
    border: 1px solid #e9ecef;
    border-radius: 6px;
    padding: 0.75rem;
    cursor: move;
    transition: all 0.2s ease;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    font-size: 0.85rem;
    line-height: 1.4;
}

.kanban-task:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
    border-color: #4A67A1;
}

.kanban-task.dragging {
    opacity: 0.5;
    transform: rotate(5deg);
}

.kanban-task h4 {
    margin: 0 0 0.5rem 0;
    font-size: 0.9rem;
    font-weight: 600;
    color: #2c3e50;
    line-height: 1.3;
    font-family: 'Times New Roman', serif;
}

.kanban-task p {
    margin: 0.25rem 0;
    font-size: 0.8rem;
    color: #6c757d;
    line-height: 1.2;
}

.kanban-task .task-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 0.5rem;
    padding-top: 0.5rem;
    border-top: 1px solid #f1f3f4;
}

.kanban-task .task-priority {
    font-size: 0.75rem;
    padding: 0.2rem 0.4rem;
    border-radius: 10px;
    font-weight: 500;
}

.task-priority.alta {
    background: #ffebee;
    color: #c62828;
}

.task-priority.media {
    background: #fff3e0;
    color: #ef6c00;
}

.task-priority.baixa {
    background: #e8f5e8;
    color: #2e7d32;
}

.kanban-task .task-deadline {
    font-size: 0.75rem;
    color: #6c757d;
    font-weight: 500;
}

.kanban-task .task-deadline.overdue {
    color: #dc3545;
    font-weight: 600;
}

.kanban-task .task-deadline.urgent {
    color: #ffc107;
    font-weight: 600;
}

/* Indicadores visuais */
.kanban-task::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 3px;
    background: #4A67A1;
    border-radius: 6px 0 0 6px;
}

.kanban-task {
    position: relative;
    border-left: 3px solid transparent;
}

/* Cores das bordas por status */
.kanban-tasks#kanban-a_fazer .kanban-task {
    border-left-color: #FFD700;
}

.kanban-tasks#kanban-em_andamento .kanban-task {
    border-left-color: #87CEEB;
}

.kanban-tasks#kanban-feito .kanban-task {
    border-left-color: #90EE90;
}

.kanban-tasks#kanban-revisado .kanban-task {
    border-left-color: #DDA0DD;
}

.kanban-tasks#kanban-entregue .kanban-task {
    border-left-color: #4169E1;
}

.kanban-tasks#kanban-upload_feito .kanban-task {
    border-left-color: #DC143C;
}

/* Responsividade otimizada */
@media (max-width: 1400px) {
    .kanban-board {
        grid-template-columns: repeat(3, 1fr);
        grid-template-rows: repeat(2, 1fr);
        gap: 1rem;
        max-height: 800px;
    }
    
    .kanban-column {
        min-width: auto;
        max-width: none;
    }
    
    .kanban-tasks {
        max-height: 350px;
    }
}

@media (max-width: 768px) {
    .kanban-board {
        grid-template-columns: repeat(2, 1fr);
        grid-template-rows: repeat(3, 1fr);
        gap: 0.75rem;
        padding: 0.75rem;
        max-height: 900px;
    }
    
    .kanban-column {
        min-width: auto;
    }
    
    .kanban-tasks {
        max-height: 280px;
    }
    
    .kanban-task {
        padding: 0.5rem;
        font-size: 0.8rem;
    }
    
    .kanban-task h4 {
        font-size: 0.85rem;
    }
}

@media (max-width: 480px) {
    .kanban-board {
        grid-template-columns: 1fr;
        grid-template-rows: repeat(6, 1fr);
        max-height: 1200px;
    }
    
    .kanban-tasks {
        max-height: 180px;
    }
    
    .kanban-column-header {
        padding: 0.5rem;
        font-size: 0.85rem;
    }
}

/* Animações e transições */
.kanban-task {
    animation: slideIn 0.3s ease-out;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Estados de drag and drop */
.kanban-column.drag-over {
    background: rgba(74, 103, 161, 0.1);
    border: 2px dashed #4A67A1;
}

.kanban-tasks:empty::after {
    content: 'Arraste tarefas aqui';
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100px;
    color: #adb5bd;
    font-style: italic;
    font-size: 0.85rem;
    border: 2px dashed #dee2e6;
    border-radius: 6px;
    margin: 0.5rem 0;
}

/* Melhorias para scroll */
.kanban-tasks::-webkit-scrollbar {
    width: 4px;
}

.kanban-tasks::-webkit-scrollbar-track {
    background: #f1f3f4;
    border-radius: 2px;
}

.kanban-tasks::-webkit-scrollbar-thumb {
    background: #c1c8cd;
    border-radius: 2px;
}

.kanban-tasks::-webkit-scrollbar-thumb:hover {
    background: #a8b2ba;
}

/* Contador de tarefas */
.kanban-column-header::after {
    content: attr(data-count);
    background: rgba(255, 255, 255, 0.2);
    padding: 0.2rem 0.4rem;
    border-radius: 10px;
    font-size: 0.75rem;
    margin-left: 0.5rem;
    font-weight: 600;
}

