/* Modal Personalizado - We Coft */
.we-coft-modal {
    display: none;
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.5);
    animation: fadeIn 0.3s ease-in-out;
}

.we-coft-modal.show {
    display: flex;
    align-items: center;
    justify-content: center;
}

.we-coft-modal-content {
    background-color: #ffffff;
    margin: auto;
    padding: 0;
    border: none;
    border-radius: 0.5rem;
    width: 90%;
    max-width: 400px;
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.3);
    animation: slideDown 0.3s ease-in-out;
    position: relative;
}

.we-coft-modal-header {
    padding: 1.5rem;
    border-bottom: 1px solid #e3e6f0;
    border-radius: 0.5rem 0.5rem 0 0;
    text-align: center;
}

.we-coft-modal-icon {
    font-size: 3rem;
    margin-bottom: 0.5rem;
    display: block;
}

.we-coft-modal-title {
    margin: 0;
    font-size: 1.25rem;
    font-weight: 600;
    color: #5a5c69;
}

.we-coft-modal-body {
    padding: 1.5rem;
    text-align: center;
    color: #858796;
    font-size: 1rem;
    line-height: 1.5;
}

/* Estilos para contenido HTML en el body */
.we-coft-modal-body br {
    display: block;
    margin: 0.5rem 0;
    content: "";
}

.we-coft-modal-body strong {
    color: #5a5c69;
    font-weight: 600;
}

.we-coft-modal-body a {
    color: #4b2e83;
    text-decoration: underline;
}

.we-coft-modal-body a:hover {
    color: #221849;
}

/* Para mensajes de error largos */
.we-coft-modal-error .we-coft-modal-body {
    text-align: left;
    max-height: 400px;
    overflow-y: auto;
    font-size: 0.9rem;
}

.we-coft-modal-footer {
    padding: 1rem 1.5rem;
    border-top: 1px solid #e3e6f0;
    border-radius: 0 0 0.5rem 0.5rem;
    text-align: center;
}

.we-coft-modal-btn {
    padding: 0.75rem 2rem;
    font-size: 1rem;
    border-radius: 2rem;
    border: none;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s;
    min-width: 120px;
}

.we-coft-modal-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 0.25rem 0.5rem rgba(0, 0, 0, 0.2);
}

.we-coft-modal-btn:active {
    transform: translateY(0);
}

/* Tipos de modales */
.we-coft-modal-success .we-coft-modal-header {
    background: linear-gradient(180deg, #1cc88a 10%, #13a072 100%);
    color: white;
}

.we-coft-modal-success .we-coft-modal-title {
    color: white;
}

.we-coft-modal-success .we-coft-modal-btn {
    background: linear-gradient(180deg, #1cc88a 10%, #13a072 100%);
    color: white;
}

.we-coft-modal-success .we-coft-modal-btn:hover {
    background: linear-gradient(180deg, #13a072 10%, #0e7e57 100%);
}

.we-coft-modal-error .we-coft-modal-header {
    background: linear-gradient(180deg, #e74a3b 10%, #d32f2f 100%);
    color: white;
}

.we-coft-modal-error .we-coft-modal-title {
    color: white;
}

.we-coft-modal-error .we-coft-modal-btn {
    background: linear-gradient(180deg, #e74a3b 10%, #d32f2f 100%);
    color: white;
}

.we-coft-modal-error .we-coft-modal-btn:hover {
    background: linear-gradient(180deg, #d32f2f 10%, #b71c1c 100%);
}

.we-coft-modal-warning .we-coft-modal-header {
    background: linear-gradient(180deg, #f6c23e 10%, #f4b30d 100%);
    color: white;
}

.we-coft-modal-warning .we-coft-modal-title {
    color: white;
}

.we-coft-modal-warning .we-coft-modal-btn {
    background: linear-gradient(180deg, #f6c23e 10%, #f4b30d 100%);
    color: white;
}

.we-coft-modal-warning .we-coft-modal-btn:hover {
    background: linear-gradient(180deg, #f4b30d 10%, #dda00a 100%);
}

.we-coft-modal-info .we-coft-modal-header {
    background: linear-gradient(180deg, #4e73df 10%, #2e59d9 100%);
    color: white;
}

.we-coft-modal-info .we-coft-modal-title {
    color: white;
}

.we-coft-modal-info .we-coft-modal-btn {
    background: linear-gradient(180deg, #4e73df 10%, #2e59d9 100%);
    color: white;
}

.we-coft-modal-info .we-coft-modal-btn:hover {
    background: linear-gradient(180deg, #2e59d9 10%, #2653d4 100%);
}

/* Animaciones */
@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

@keyframes slideDown {
    from {
        transform: translateY(-50px);
        opacity: 0;
    }

    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* Responsive para móviles */
@media (max-width: 576px) {
    .we-coft-modal-content {
        width: 95%;
        margin: 1rem;
    }

    .we-coft-modal-header {
        padding: 1rem;
    }

    .we-coft-modal-icon {
        font-size: 2.5rem;
    }

    .we-coft-modal-title {
        font-size: 1.1rem;
    }

    .we-coft-modal-body {
        padding: 1rem;
        font-size: 0.9rem;
    }

    .we-coft-modal-footer {
        padding: 0.75rem 1rem;
    }

    .we-coft-modal-btn {
        padding: 0.65rem 1.5rem;
        font-size: 0.9rem;
        min-width: 100px;
    }
}

/* Para pantallas muy pequeñas */
@media (max-width: 360px) {
    .we-coft-modal-content {
        width: 98%;
        margin: 0.5rem;
    }

    .we-coft-modal-icon {
        font-size: 2rem;
    }
}