/**
 * Estilos dos Modais Customizados
 */

.custom-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

.custom-modal.active {
    display: flex;
}

.custom-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    animation: fadeIn 0.3s ease;
}

.custom-modal-content {
    position: relative;
    background: white;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
    max-width: 500px;
    width: 100%;
    max-height: 90vh;
    overflow: hidden;
    animation: slideUp 0.3s ease;
    z-index: 1;
}

.custom-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.5rem;
    border-bottom: 1px solid #e0e0e0;
}

.custom-modal-title {
    margin: 0;
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--cor-texto);
}

.custom-modal-close {
    background: none;
    border: none;
    font-size: 1.5rem;
    color: #999;
    cursor: pointer;
    padding: 0.5rem;
    line-height: 1;
    transition: all 0.3s ease;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.custom-modal-close:hover {
    background: #f5f5f5;
    color: var(--cor-texto);
}

.custom-modal-body {
    padding: 1.5rem;
    max-height: 60vh;
    overflow-y: auto;
}

.custom-modal-footer {
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
    padding: 1.5rem;
    border-top: 1px solid #e0e0e0;
    background: #fafafa;
}

/* Animações */
@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

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

/* Estilos dos botões dentro do modal */
.custom-modal-footer .btn {
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
    font-weight: 500;
}

.custom-modal-footer .btn-primary {
    background: var(--cor-secundaria);
    color: white;
}

.custom-modal-footer .btn-primary:hover {
    background: var(--cor-secundaria-escura);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.custom-modal-footer .btn-secondary {
    background: #757575;
    color: white;
}

.custom-modal-footer .btn-secondary:hover {
    background: #616161;
}

.custom-modal-footer .btn-danger {
    background: #f44336;
    color: white;
}

.custom-modal-footer .btn-danger:hover {
    background: #d32f2f;
}

/* Mobile */
@media (max-width: 768px) {
    .custom-modal-content {
        max-width: 95%;
        border-radius: 8px;
    }

    .custom-modal-header {
        padding: 1rem;
    }

    .custom-modal-title {
        font-size: 1.25rem;
    }

    .custom-modal-body {
        padding: 1rem;
    }

    .custom-modal-footer {
        padding: 1rem;
        flex-direction: column;
    }

    .custom-modal-footer .btn {
        width: 100%;
    }
}

