/* 
 * Estilos Padrão para CRUDs - Cerberus
 * Arquivo reutilizável para manter consistência visual
 */

/* === CARDS E HEADERS === */
.card-header-enhanced {
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
    border-bottom: 1px solid #e2e8f0;
}

/* === BADGES DE STATUS === */
.status-badge {
    padding: 4px 8px;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 500;
    display: inline-flex;
    align-items: center;
}

/* === BOTÕES DE AÇÕES === */
.btn-actions {
    gap: 6px;
}


/* Botões de ação menores para index (edit/excluir) */
.btn-action {
    width: 26px;
    height: 26px;
    padding: 0;
    border-radius: 6px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: none;
    transition: all 0.2s ease;
    font-size: 13px;
    text-decoration: none;
}

.btn-action:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    text-decoration: none;
}

.btn-action:focus {
    outline: none;
    box-shadow: 0 0 0 2px rgba(0, 123, 255, 0.25);
}

/* Cores específicas para botões de ação */
.btn-action.btn-warning {
    background-color: #ffc107;
    color: #212529;
}

.btn-action.btn-warning:hover {
    background-color: #ffb300;
    color: #212529;
}

.btn-action.btn-danger {
    background-color: #dc3545;
    color: white;
}

.btn-action.btn-danger:hover {
    background-color: #c82333;
    color: white;
}

/* === AVATARS === */
.avatar-sm {
    width: 32px;
    height: 32px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 600;
    color: white;
}

.avatar-md {
    width: 48px;
    height: 48px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    font-weight: 600;
    color: white;
}

/* === BOTÕES ESPECIAIS === */
.btn-save {
    background: linear-gradient(135deg, #10b981, #059669);
    border: none;
    color: white;
    transition: all 0.2s ease;
}

.btn-save:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(16, 185, 129, 0.3);
    color: white;
}

.btn-back {
    background: transparent;
    border: 1px solid #e2e8f0;
    color: #64748b;
    transition: all 0.2s ease;
}

.btn-back:hover {
    background: #f8fafc;
    border-color: #cbd5e1;
    color: #475569;
}

/* === TABELAS === */
.table-hover tbody tr:hover {
    background-color: #f8fafc;
}

/* === FORMULÁRIOS === */
.form-label.required::after {
    content: " *";
    color: #ef4444;
}

/* === ESTADOS VAZIOS === */
.empty-state {
    text-align: center;
    padding: 3rem 2rem;
    color: #64748b;
}

.empty-state-icon {
    width: 64px;
    height: 64px;
    margin: 0 auto 1rem;
    background: #e2e8f0;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    color: #94a3b8;
}

/* === TOASTS === */
.toast {
    border-radius: 8px;
    border: none;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
}

/* === MODAIS === */
.modal-content {
    border-radius: 12px;
    border: none;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

.modal-header {
    border-bottom: 1px solid #e2e8f0;
}

.modal-footer {
    border-top: 1px solid #e2e8f0;
}


@media (max-width: 768px) {
    .btn-actions {
        flex-wrap: wrap;
    }

    .table-responsive {
        font-size: 0.875rem;
    }

    .avatar-sm {
        width: 28px;
        height: 28px;
        font-size: 11px;
    }

    .btn-action {
        width: 24px;
        height: 24px;
        font-size: 12px;
    }

    .page-body {
        padding: 1rem;
    }
}

/* === ANIMAÇÕES === */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    animation: fadeIn 0.3s ease;
}

/* === UTILITÁRIOS === */
.text-truncate-2 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.border-dashed {
    border-style: dashed !important;
}

/* === CORES DE AVATAR AUTOMÁTICAS === */
.avatar-auto-1 {
    background: #3b82f6;
}

.avatar-auto-2 {
    background: #ef4444;
}

.avatar-auto-3 {
    background: #10b981;
}

.avatar-auto-4 {
    background: #f59e0b;
}

.avatar-auto-5 {
    background: #8b5cf6;
}

.avatar-auto-6 {
    background: #06b6d4;
}

.avatar-auto-7 {
    background: #84cc16;
}

.avatar-auto-8 {
    background: #f97316;
}

.avatar-auto-9 {
    background: #ec4899;
}

.avatar-auto-0 {
    background: #64748b;
}