/* =========================================
   SYS KANBAN - SOFT SAAS THEME
   Ref: [cite: 67, 72] Notion/Asana Style
   ========================================= */

/* Icones https://phosphoricons.com */
.ph {font-size:22px !important;}

/* PRE para código em descrição (markdown) */
.sys-desc-inner > pre, .sys-item-desc > pre { border-left: 4px solid #6d788b; padding-left: 4px; color: #ffffff; background-color: #414040; }

.sys-code-block {
    position: relative;
    margin: 10px 0;
    border-radius: 6px;
    overflow: hidden; /* Garante que bordas arredondadas funcionem */
}

/* Ajuste no PRE para dar espaço ao botão */
.sys-code-block pre {
    margin: 0;
    padding: 30px 15px 15px 15px; /* Padding extra no topo */
    background: #1e293b; /* Fundo escuro */
    color: #e2e8f0;
    font-family: 'Fira Code', monospace;
    font-size: 12px;
    overflow-x: auto;
    white-space: pre-wrap; /* Quebra linha se necessário */
}

/* botão copiar para area de transferencia */
.sys-copy-btn {
    position: absolute;
    top: 40px; right: 5px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #fff !important;
    width: 32px; height: 32px;
    border-radius: 4px;
    cursor: pointer;
    display: flex !important; /* Essencial para o ícone aparecer */
    align-items: center;
    justify-content: center;
    z-index: 10;
}
.sys-copy-btn svg {
    width: 18px !important;
    height: 18px !important;
    display: block;
}
.sys-copy-btn:hover {
    background: rgba(255, 255, 255, 0.2);
}
.sys-copy-btn.copied {
    background: #10b981;
    border-color: #10b981;
    color: #fff !important;
}

:root {
    /* Paleta de Cores [cite: 77, 78] */
    --sys-bg-page: #F3F4F6;
    --sys-bg-card: #FFFFFF;
    
    --sys-primary: #00568e;
    --sys-secondary: #0077bb;
    
    --sys-text-primary: #1F2937; /* Cinza Escuro */
    --sys-text-secondary: #6B7280; /* Cinza Médio */
    
    /* Cores de Status [cite: 18] */
    --sys-status-delayed: #F59E0B;
    --sys-status-blocked: #EF4444;
    --sys-status-done: #10B981;
    
    /* Tipografia [cite: 72] */
    --sys-font-title: 'Nunito', sans-serif;
    --sys-font-body: 'Inter', sans-serif;
}

/* Base do Kanban */
body.elementor-page {
    background-color: var(--sys-bg-page);
    font-family: var(--sys-font-body);
}

/* Estilo dos Cards (Loop Items) [cite: 70, 71] */
.sys-kanban-card {
    background: var(--sys-bg-card);
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 12px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.05); /* Sombra Suave */
    border: 1px solid transparent;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.sys-kanban-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.08);
    border-color: rgba(0,86,142, 0.1);
}

/* Tipografia Hierárquica [cite: 73, 75] */
.sys-card-title {
    font-family: var(--sys-font-title);
    font-weight: 700;
    font-size: 16px; /* Ajustado para Card */
    line-height: 1.3em;
    color: var(--sys-text-primary);
    margin-bottom: 8px;
}

.sys-card-meta {
    font-family: var(--sys-font-body);
    font-size: 13px;
    color: var(--sys-text-secondary);
    display: flex;
    align-items: center;
    gap: 8px;
}

/* Etiquetas (Chips) */
.sys-chip {
    display: inline-flex;
    align-items: center;
    padding: 2px 8px;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
}

.sys-chip.client {
    background-color: #E0F2FE;
    color: #0369A1;
}

.sys-chip.priority-high {
    background-color: #FEF2F2;
    color: #B91C1C;
}

/* Layout das Colunas (Elementor Containers) */
.sys-column-header {
    font-family: var(--sys-font-title);
    font-size: 18px;
    font-weight: 700;
    color: var(--sys-text-primary);
    margin-bottom: 16px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* --- MODAL E FORMULÁRIOS --- */

/* Overlay Fundo Escuro */
.sys-modal-overlay {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 10000;
    opacity: 1;
    transition: opacity 0.3s ease;
}

.sys-modal-overlay.hidden {
    display: none;
    opacity: 0;
}

/* Caixa do Modal */
.sys-modal-content {
    background: #fff;
    width: 94%;
    max-width: 600px;
    border-radius: 12px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.2);
    overflow: hidden;
    animation: slideUp 0.3s ease;
}

@keyframes slideUp {
    from { transform: translateY(20px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

/* Header */
.sys-modal-header {
    padding: 16px 24px;
    border-bottom: 1px solid #eee;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.sys-modal-header h3 { margin: 0; font-size: 18px; color: var(--sys-primary); }

.sys-close-btn {
    background: none; border: none; font-size: 24px; cursor: pointer; color: #999;
}

/* Body & Inputs */
.sys-modal-body { padding: 24px; }

.sys-form-group { margin-bottom: 16px; }
.sys-form-group label { display: block; font-size: 13px; font-weight: 600; margin-bottom: 6px; color: #444; }

.sys-form-group input, 
.sys-form-group select, 
.sys-form-group textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 14px;
    font-family: var(--sys-font-body);
}

.sys-form-group textarea { resize: vertical; }

.sys-form-row { display: flex; gap: 16px; }
.sys-form-row .sys-form-group { flex: 1; }

/* Footer & Buttons */
.sys-modal-footer {
    margin-top: 20px;
    display: flex;
    justify-content: flex-end;
    gap: 10px;
}

.sys-btn-primary {
    background: var(--sys-primary);
    color: #fff;
    border: none;
    padding: 10px 20px;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 600;
    transition: background 0.2s;
}
.sys-btn-primary:hover { background: var(--sys-secondary); }

.sys-btn-danger {
    background: #fee2e2;
    color: #991b1b;
    border: none;
    padding: 10px 20px;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 600;
}
.sys-btn-danger:hover { background: #fecaca; }

/* Botão de Edição (Lápis) no Card */
.sys-btn-icon {
    background: transparent;
    border: none;
    cursor: pointer;
    color: var(--sys-text-secondary);
    padding: 4px;
    border-radius: 4px;
}
.sys-btn-icon:hover { background: #f3f4f6; color: var(--sys-primary); }
.hidden { display: none !important; }

/* --- CONSTRUTOR DE CHECKLIST --- */
.sys-btn-secondary {
    background: #fff; border: 1px solid #ddd; color: #444;
    padding: 10px 20px; border-radius: 6px; cursor: pointer; font-weight: 600;
}
.sys-btn-secondary:hover { background: #f9f9f9; border-color: #bbb; }

.sys-input-group {
    display: flex; gap: 8px; margin-bottom: 12px;
}
.sys-btn-small {
    background: var(--sys-secondary); color: white; border: none;
    padding: 0 16px; border-radius: 6px; cursor: pointer;
}

.sys-checklist-preview {
    list-style: none; padding: 0; margin: 0;
    background: #f9fafb; border: 1px solid #eee; border-radius: 6px;
    max-height: 200px; overflow-y: auto;
}

.sys-checklist-preview li {
    padding: 10px; border-bottom: 1px solid #eee;
    display: flex; justify-content: space-between; align-items: center;
    background: #fff;
}
.sys-checklist-preview li:last-child { border-bottom: none; }

.sys-remove-item {
    color: #ef4444; cursor: pointer; font-weight: bold; font-size: 18px;
    background: none; border: none;
}
.sys-remove-item:hover { color: #b91c1c; }

/* --- EXTRA FASE 5.1: EDITOR LITE & HEADERS (REFINADO) --- */

/* Toggle Switch */
.sys-toggle-wrapper {
    display: flex; align-items: center; gap: 10px; margin-bottom: 12px; cursor: pointer;
    user-select: none;
}
.sys-toggle-input { display: none; }
.sys-toggle-track {
    width: 40px; height: 22px; background: #e5e7eb; border-radius: 20px;
    position: relative; transition: all 0.2s ease; border: 1px solid #d1d5db;
}
.sys-toggle-input:checked + .sys-toggle-track { 
    background: var(--sys-primary); border-color: var(--sys-primary); 
}
.sys-toggle-track::after {
    content: ''; position: absolute; left: 2px; top: 2px;
    width: 16px; height: 16px; background: #fff; border-radius: 50%;
    transition: transform 0.2s cubic-bezier(0.4, 0.0, 0.2, 1);
    box-shadow: 0 1px 2px rgba(0,0,0,0.2);
}
.sys-toggle-input:checked + .sys-toggle-track::after { transform: translateX(18px); }

/* Editor Lite Container */
.sys-lite-editor-container {
    border: 1px solid #d1d5db; border-radius: 6px; overflow: hidden; background: #fff; margin-bottom: 12px;
    transition: opacity 0.3s, filter 0.3s;
}

/* Estado Desabilitado (Quando é Seção) */
.sys-editor-disabled {
    opacity: 0.4;
    pointer-events: none; /* Bloqueia cliques */
    background-color: #f3f4f6;
    filter: grayscale(1);
}

/* Toolbar - Botões Centralizados */
.sys-lite-toolbar {
    background: #f9fafb; border-bottom: 1px solid #e5e7eb; padding: 6px 8px; display: flex; gap: 6px;
}
.sys-lite-btn {
    background: #fff; border: 1px solid #d1d5db; border-radius: 4px;
    width: 32px; height: 32px; /* Altura fixa maior */
    display: flex; align-items: center; justify-content: center; /* Centralização Flexbox */
    cursor: pointer; font-family: 'Times New Roman', serif; font-weight: bold; font-size: 16px;
    color: #374151; transition: all 0.1s;
    line-height: 1; /* Remove espaçamento de fonte */
}
.sys-lite-btn:hover { background: #f3f4f6; color: #000; border-color: #9ca3af; }
.sys-lite-btn:active { transform: translateY(1px); }

/* Ícones específicos */
.sys-lite-btn.code-btn { font-family: monospace; font-size: 14px; font-weight: 700; color: #ec4899; }

/* Editor Markdown */
.sys-lite-textarea {
    width: 100%;
    min-height: 120px;
    padding: 12px;
    border: none;
    resize: vertical;
    font-family: 'Inter', sans-serif; /* Fonte legível */
    font-size: 14px;
    line-height: 1.5;
    color: #1f2937;
    outline: none;
    background: #fff;
}

.sys-lite-textarea:focus {
    background: #fafafa;
}

/* Editor Markdown - Mantemos o estilo visual do PRE para a LISTA DE PREVIEW (Isso não muda) */
.sys-item-has-desc pre {
    background: #1f2937;
    color: #e5e7eb;
    padding: 8px 12px;
    border-radius: 4px;
    font-family: monospace;
    font-size: 12px;
    border-left: 4px solid var(--sys-primary);
    margin: 6px 0;
    white-space: pre-wrap;
    display: block;
}

/* Editor Markdown - Formatação básica no preview */
.sys-item-has-desc b, .sys-item-has-desc strong { font-weight: 700; color: #000; }
.sys-item-has-desc ul, .sys-item-has-desc ol { margin: 4px 0 4px 20px; padding: 0; }

/* Estilos da Lista Preview (Mantidos) */
.sys-item-row { width: 100%; display: flex; justify-content: space-between; align-items: center; }
.sys-item-header-badge {
    background: #e0e7ff; color: #3730a3; font-size: 10px; font-weight: 800;
    text-transform: uppercase; padding: 2px 6px; border-radius: 4px; margin-right: 8px;
}
.sys-item-has-desc { font-size: 11px; color: #6b7280; margin-left: 8px; display: flex; align-items: center; gap: 4px; }
.sys-is-header { background-color: #f1f5f9 !important; border-left: 4px solid var(--sys-primary); }
.sys-is-header span { font-weight: 800; color: var(--sys-primary); }

/* --- FASE 5.2: CHECKLISTS NO CARD --- */
.sys-task-checklists-wrapper {
    display: flex; flex-wrap: wrap; gap: 6px; margin-top: 3px;
}

/* Chip (Etiqueta) */
.sys-checklist-chip {
    background: #eef2ff; border: 1px solid #c7d2fe; color: #4338ca;
    border-radius: 12px; padding: 2px 8px; font-size: 11px;
    display: flex; align-items: center; gap: 6px; cursor: pointer;
    transition: all 0.2s;
}
.sys-checklist-chip:hover { background: #e0e7ff; border-color: #a5b4fc; }

/* Status Concluído (Verde) */
.sys-chip-done {
    background: #ecfdf5; border-color: #6ee7b7; color: #065f46;
}

/* Botão (+) Pequeno */
.sys-btn-add-checklist {
    width: 18px; height: 18px; border-radius: 50%; border: 1px dashed #999;
    color: #666; background: none; font-size: 20px; line-height: 1;
    cursor: pointer; display: flex; align-items: center; justify-content: center;
}
.sys-btn-add-checklist:hover { border-color: var(--sys-primary); color: var(--sys-primary); }

/* --- MODAL DE EXECUÇÃO --- */
.sys-progress-container {
    background: #f3f4f6; height: 8px; width: 100%; position: relative;
}
.sys-progress-bar {
    height: 100%; background: #10b981; transition: width 0.3s ease;
}
#sys-exec-percent {
    position: absolute; right: 0; top: -20px; font-size: 11px; font-weight: bold; color: #10b981;
}

.sys-exec-list {
    list-style: none; padding: 0; margin: 0; max-height: 400px; overflow-y: auto;
}
.sys-exec-header {
    background: #f9fafb; padding: 8px 20px; font-weight: 800; font-size: 12px;
    color: #6b7280; text-transform: uppercase; border-bottom: 1px solid #eee;
}
.sys-exec-item {
    padding: 12px 20px; border-bottom: 1px solid #f3f4f6;
}
.sys-check-wrapper {
    display: flex; align-items: center; gap: 10px; cursor: pointer;
}
.sys-item-checkbox {
    width: 18px; height: 18px; cursor: pointer;
}
.sys-check-text { font-size: 14px; color: #374151; }
.sys-check-text.done { text-decoration: line-through; color: #9ca3af; }

.sys-item-desc {
    margin-top: 4px; margin-left: 28px; font-size: 13px; color: #6b7280;
    background: #f9fafb; padding: 8px; border-radius: 4px;
}

.sys-btn-text-danger {
    background: none; border: none; color: #ef4444; font-size: 12px; cursor: pointer; text-decoration: underline;
}


/* --- FASE 5.2 - ETAPA 1: ACTIONS & EDIT --- */

.sys-item-row-content {
    display: flex; justify-content: space-between; align-items: center; width: 100%;
}

/* Actions Group (Hidden by default, show on hover) */
.sys-item-actions {
    display: flex; gap: 4px; opacity: 0; transition: opacity 0.2s;
}
.sys-exec-item:hover .sys-item-actions { opacity: 1; }

.sys-action-btn {
    background: none; border: none; color: #9ca3af; cursor: pointer;
    padding: 4px; border-radius: 4px; display: flex; align-items: center;
}
.sys-action-btn:hover { background: #f3f4f6; color: var(--sys-primary); }
.sys-action-btn.delete-item:hover { color: #ef4444; background: #fee2e2; }

/* Accordion Description */
.sys-item-desc {
    margin-top: 8px; margin-left: 28px; padding: 10px;
    background: #f9fafb; border-radius: 6px; border: 1px solid #eee;
    font-size: 13px; color: #555;
    animation: fadeIn 0.3s;
}

/* Inline Add Row */
.sys-exec-add-row {
    padding: 12px 20px; border-top: 1px solid #eee; background: #fff;
}
.sys-add-inline-group { display: flex; gap: 8px; }
.sys-input-clean {
    flex: 1; border: none; background: #f3f4f6; padding: 8px 12px; border-radius: 6px;
    font-size: 13px; outline: none; transition: background 0.2s;
}
.sys-input-clean:focus { background: #fff; box-shadow: 0 0 0 2px var(--sys-primary); }
.sys-btn-icon-primary {
    background: var(--sys-primary); color: #fff; border: none; border-radius: 6px;
    width: 32px; height: 32px; display: flex; align-items: center; justify-content: center; cursor: pointer;
}

/* Edit Mode Box */
.sys-edit-box {
    background: #fff; border: 1px solid #e5e7eb; padding: 12px; border-radius: 8px;
    box-shadow: 0 4px 6px -1px rgba(0,0,0,0.05); margin-top: 8px;
}
.sys-edit-title {
    width: 100%; padding: 8px; border: 1px solid #ddd; border-radius: 4px; margin-bottom: 8px;
    font-weight: 600; font-size: 14px;
}
.sys-edit-desc {
    width: 100%; border: 1px solid #ddd; border-radius: 4px; padding: 8px; font-size: 13px;
    min-height: 80px; resize: vertical; margin-bottom: 8px;
}
.sys-edit-actions { display: flex; gap: 8px; justify-content: flex-end; }
.sys-btn-small-save {
    background: var(--sys-primary); color: #fff; border: none; padding: 6px 12px; border-radius: 4px; cursor: pointer; font-size: 12px;
}
.sys-btn-small-cancel {
    background: #f3f4f6; color: #555; border: none; padding: 6px 12px; border-radius: 4px; cursor: pointer; font-size: 12px;
}




/* --- FASE 6: CLIENTES (INTERFACE CORRIGIDA) --- */

/* Badge (Etiqueta) */
.sys-client-badge {
    display: inline-block; padding: 2px 8px; border-radius: 4px;
    font-size: 11px; font-weight: 700; text-transform: uppercase;
    margin-right: 6px; vertical-align: middle;
    box-shadow: 0 1px 2px rgba(0,0,0,0.1);
}

/* Container Principal do Gerenciador */
.sys-manager-box {
    background: #f8fafc; /* Fundo cinza bem claro */
    border: 1px solid #e2e8f0; 
    padding: 15px;
    border-radius: 8px; 
    margin-top: 10px; 
    animation: slideDown 0.2s;
    box-shadow: 0 4px 6px -1px rgba(0,0,0,0.05);
}
.sys-manager-box h4 { margin: 0 0 12px 0; font-size: 12px; color: #64748b; text-transform: uppercase; letter-spacing: 0.5px; font-weight: 700; }

/* Linha do Formulário (Onde estava o problema) */
.sys-client-form-row { 
    display: flex; 
    gap: 10px; 
    margin-bottom: 15px; 
    align-items: center; 
}

/* 1. Correção do Input de Texto (Nome) */
.sys-input-small { 
    flex: 1; /* Ocupa todo espaço disponível */
    height: 40px !important; /* Altura forçada */
    padding: 0 12px !important; 
    font-size: 14px !important; 
    color: #334155 !important; /* Cinza escuro para o texto */
    background-color: #ffffff !important; /* Fundo Branco */
    border: 1px solid #cbd5e1 !important; 
    border-radius: 6px !important;
    outline: none;
}
.sys-input-small:focus {
    border-color: var(--sys-primary) !important;
    box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.2);
}

/* 2. Correção do Input de Cor */
.sys-color-wrapper {
    position: relative;
    width: 40px; 
    height: 40px;
    border-radius: 6px;
    border: 1px solid #cbd5e1;
    cursor: pointer;
    overflow: hidden;
    box-shadow: 0 1px 2px rgba(0,0,0,0.1);
    transition: transform 0.1s, border-color 0.2s;
}
.sys-color-wrapper:hover {
    transform: scale(1.05);
    border-color: #94a3b8;
}
/* O Input real fica invisível por cima de tudo */
.sys-input-color-hidden { 
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    opacity: 0; /* Invisível */
    cursor: pointer;
    padding: 0; margin: 0;
    border: none;
}
.sys-input-color { 
    position: absolute;
    top: -50%; left: -50%;
    width: 200%; height: 200%; /* Faz o input ficar maior que a div para cobrir tudo */
    padding: 0; margin: 0;
    border: none;
    cursor: pointer;
    appearance: none;
    background: none;
}

/* Botões de Ação */
.sys-btn-small-primary {
    height: 40px; padding: 0 20px;
    background: var(--sys-primary); color: white;
    border: none; border-radius: 6px; font-weight: 600; cursor: pointer;
    font-size: 13px;
}
.sys-btn-small-primary:hover { opacity: 0.9; }

.sys-btn-small {
    height: 40px; padding: 0 15px;
    background: #fff; border: 1px solid #cbd5e1; color: #64748b;
    border-radius: 6px; font-weight: 600; cursor: pointer;
    font-size: 13px;
}
.sys-btn-small:hover { background: #f1f5f9; }

/* Lista de Clientes Existentes */
.sys-mini-list { 
    list-style: none; padding: 0; margin: 0; 
    max-height: 150px; overflow-y: auto; 
    border-top: 1px solid #e2e8f0; 
}
.sys-mini-list li {
    padding: 10px 8px; border-bottom: 1px solid #f1f5f9;
    display: flex; justify-content: space-between; align-items: center; 
    font-size: 14px; color: #334155;
    background: #fff;
}
.sys-mini-list li:hover { background: #f8fafc; }

.sys-client-dot {
    width: 12px; height: 12px; border-radius: 50%; display: inline-block; margin-right: 8px;
    border: 1px solid rgba(0,0,0,0.1);
}




/* --- FASE 6 (ETAPA 3): VISUAL DO CARD --- */

/* 1. STATUS ICON & DROPDOWN */
.sys-status-wrapper { position: relative; display: inline-block; }

.sys-status-btn {
    background: none; border: none; cursor: pointer; padding: 4px;
    border-radius: 4px; transition: background 0.2s;
    display: flex; align-items: center; justify-content: center;
}
.sys-status-btn:hover { background: #f3f4f6; }

.sys-status-dropdown {
    position: absolute; top: 100%; left: 0; z-index: 50;
    background: #fff; border: 1px solid #e5e7eb; border-radius: 6px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1); padding: 4px;
    min-width: 140px; animation: fadeIn 0.1s;
}
.sys-status-opt {
    display: flex; align-items: center; gap: 8px; width: 100%;
    background: none; border: none; padding: 6px 10px;
    text-align: left; font-size: 13px; color: #374151; cursor: pointer;
    border-radius: 4px;
}
.sys-status-opt:hover { background: #f3f4f6; }
.sys-status-opt.active { background: #eff6ff; font-weight: 600; }

/* 2. FOOTER DO CARD */
.sys-card-footer {
    display: flex; justify-content: space-between; align-items: center;
    font-family: 'Inter', sans-serif;
}

/* Prioridade */
.sys-prio-badge {
    font-size: 10px; font-weight: 700; text-transform: uppercase;
    padding: 2px 6px; border-radius: 4px; letter-spacing: 0.5px; margin: 1px 5px 0 0;
}

/* Datas */
.sys-card-dates {
    display: flex; gap: 4px; font-size: 14px; color: #64748b;
}
.sys-date-tag { display: flex; align-items: center; gap: 4px; }

/* Expansão */
.sys-expand-btn {
    background: none; border: none; color: #94a3b8; cursor: pointer;
    padding: 2px; transition: all 0.2s;
}
.sys-expand-btn:hover { color: var(--sys-primary); background: #f1f5f9; border-radius: 4px; }
.sys-expand-btn.open i { transform: rotate(180deg); } /* Gira a seta */

/* Área de Descrição Expandida */
.sys-card-desc-content {
    background: #f3f4f6; 
    border-top: 1px solid #f1f1f1;
    margin: 0;
    padding: 12px 15px;
    font-size: 13px; color: #4b5563; line-height: 1.5;
}
.sys-desc-inner p { margin-bottom: 8px; }
.sys-desc-inner p:last-child { margin-bottom: 0; }

/* Garante que o container interno do grid ocupe altura */
#sys-col-inbox .elementor-grid,
#sys-col-scheduled .elementor-grid,
#sys-col-focus .elementor-grid,
#sys-col-done .elementor-grid,
#sys-col-archive .elementor-grid,
.e-loop-item-container {
    min-height: 200px; /* Área mínima de drop */
    height: 100%;
    display: flex;
    flex-direction: column;
    gap: 15px; /* Espaço entre cards */
    padding-bottom: 50px; /* Área extra no final para soltar */
}

/* Visual do Card sendo arrastado */
.sys-sortable-ghost {
    opacity: 0.4;
    background: #e2e8f0;
    border: 2px dashed #94a3b8;
}

/* Garante área de drop mesmo em colunas vazias */
.sys-fake-dropzone, 
.elementor-grid:empty {
    min-height: 400px !important;
    width: 100%;
    display: flex;
    flex-direction: column;
}
.sys-fake-dropzone {
    position: absolute !important;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    
    /* Z-Index: 0 garante que ela fique no fundo, 
       permitindo que você clique no Título da coluna se ele estiver acima */
    z-index: 0; 
    
    margin: 0 !important;
    
    /* Flexbox para alinhar itens soltos lá dentro */
    display: flex;
    flex-direction: column;
    padding: 10px;
    box-sizing: border-box;
}
/* Ajuste para os Grids REAIS (quando tem tarefa) */
/* Garante que eles fiquem acima do background fake se houver sobreposição */
.elementor-grid, .e-loop-item-container {
    position: relative;
    z-index: 5;
    min-height: 100px;
}

/* Data Atrasada */
.sys-date-tag.sys-overdue {
    color: #EF4444 !important; /* Vermelho */
    font-weight: 600;
}




















/* --- CHECKLIST ITEM REFACTOR (FASE 1) --- */

.sys-checklist-li {
    display: flex;
    flex-direction: column; /* Para permitir que a descrição abra abaixo */
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    margin-bottom: 8px;
    padding: 8px 12px;
    transition: all 0.2s ease;
}

.sys-checklist-li:hover {
    border-color: #cbd5e1;
    box-shadow: 0 2px 4px rgba(0,0,0,0.02);
}

/* Container do Cabeçalho do Item (Checkbox + Texto + Ícones) */
.sys-li-header {
    display: flex;
    align-items: center; /* Centraliza verticalmente */
    gap: 10px;
    width: 100%;
}

.sys-li-checkbox {
    cursor: pointer;
    accent-color: #3b82f6;
    width: 16px;
    height: 16px;
}

.sys-li-title {
    flex: 1; /* Ocupa o espaço restante */
    font-size: 14px;
    color: #334155;
    line-height: 1.4;
    cursor: default;
}

.sys-li-title.completed {
    text-decoration: line-through;
    color: #94a3b8;
}

/* --- ÍCONES E AÇÕES --- */

/* Container Lado Direito */
.sys-li-controls {
    display: flex;
    align-items: center;
    gap: 4px;
}

/* Ícone de Descrição (Sempre Visível se houver descrição) */
.sys-btn-toggle-desc {
    color: #64748b;
    font-size: 18px; /* Phosphor Icon Size */
    padding: 4px;
    border-radius: 4px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}

.sys-btn-toggle-desc:hover {
    background-color: #f1f5f9;
    color: #334155;
}

/* Ícones de Edição/Exclusão (Só aparecem no Hover do item pai) */
.sys-li-actions {
    display: flex;
    gap: 2px;
    opacity: 0; /* Invisível por padrão */
    transform: translateX(5px);
    transition: all 0.2s ease;
    pointer-events: none; /* Evita cliques acidentais quando invisível */
}

/* Mostra ações quando passa o mouse no LI inteiro */
.sys-checklist-li:hover .sys-li-actions {
    opacity: 1;
    transform: translateX(0);
    pointer-events: auto;
}

.sys-btn-action-icon {
    color: #94a3b8;
    padding: 4px;
    cursor: pointer;
    border-radius: 4px;
    font-size: 16px;
}

.sys-btn-action-icon:hover {
    background-color: #eff6ff;
    color: #3b82f6;
}

.sys-btn-action-icon.danger:hover {
    background-color: #fef2f2;
    color: #ef4444;
}

/* Container da Descrição (Hidden por padrão) */
.sys-li-desc-body {
    display: none;
    margin-top: 8px;
    padding-left: 26px; /* Alinhado com o texto (pula o checkbox) */
    font-size: 13px;
    color: #64748b;
    border-top: 1px dashed #e2e8f0;
    padding-top: 8px;
}

.sys-li-desc-body p { margin: 0 0 8px 0; }
.sys-li-desc-body.open { display: block; animation: fadeIn 0.3s ease; }

@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }