/*//////////////////////////////////////////////////////////////////
[ RELIV ALERT ] — Modal de alertas reutilizable (error / éxito / advertencia / info)
Uso: RelivAlert.error("Título", "Mensaje") o RelivAlert.show({ ...opciones })
//////////////////////////////////////////////////////////////////*/

.reliv-alert-overlay {
    position: fixed;
    inset: 0;
    z-index: 12000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: rgba(15, 48, 72, 0.45);
    opacity: 0;
    transition: opacity 0.18s ease;
}

.reliv-alert-overlay.is-visible {
    opacity: 1;
}

.reliv-alert-modal {
    width: 100%;
    max-width: 480px;
    background: #ffffff;
    border-radius: 22px;
    box-shadow: 0 18px 50px rgba(15, 48, 72, 0.25);
    padding: 38px 40px 34px;
    text-align: center;
    transform: translateY(12px) scale(0.98);
    transition: transform 0.18s ease;
    font-family: 'Poppins', 'Montserrat-Regular', Arial, sans-serif;
}

.reliv-alert-overlay.is-visible .reliv-alert-modal {
    transform: translateY(0) scale(1);
}

/* ----- Icono circular ----- */
.reliv-alert-icon {
    width: 84px;
    height: 84px;
    margin: 0 auto 26px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid transparent;
}

.reliv-alert-icon svg {
    width: 40px;
    height: 40px;
}

/* error */
.reliv-alert--error .reliv-alert-icon {
    background: #e4eef7;
    border-color: #b9d4ea;
}
.reliv-alert--error .reliv-alert-icon svg { stroke: #2f6aa6; }

/* success */
.reliv-alert--success .reliv-alert-icon {
    background: #e3f3ec;
    border-color: #b6dfc9;
}
.reliv-alert--success .reliv-alert-icon svg { stroke: #2e8b57; }

/* warning */
.reliv-alert--warning .reliv-alert-icon {
    background: #fcf3e0;
    border-color: #f0d9a8;
}
.reliv-alert--warning .reliv-alert-icon svg { stroke: #d99412; }

/* info */
.reliv-alert--info .reliv-alert-icon {
    background: #e4eef7;
    border-color: #b9d4ea;
}
.reliv-alert--info .reliv-alert-icon svg { stroke: #2f6aa6; }

/* ----- Textos ----- */
.reliv-alert-title {
    margin: 0 0 16px;
    font-size: 25px;
    line-height: 1.25;
    font-weight: 600;
    color: #1b3a63;
    font-family: 'Poppins', 'Montserrat-Regular', Arial, sans-serif;
}

.reliv-alert-message {
    margin: 0 auto;
    max-width: 380px;
    font-size: 16px;
    line-height: 1.6;
    color: #4a5568;
}

.reliv-alert-message p {
    margin: 0 0 12px;
}

.reliv-alert-message p:last-child {
    margin-bottom: 0;
}

.reliv-alert-message b,
.reliv-alert-message strong {
    color: #1b3a63;
    font-weight: 700;
}

/* ----- Campo de entrada (input) ----- */
.reliv-alert-input {
    display: block;
    width: 100%;
    max-width: 320px;
    margin: 4px auto 0;
    padding: 12px 16px;
    border: 1px solid #cdd9e6;
    border-radius: 10px;
    font-size: 18px;
    text-align: center;
    letter-spacing: 3px;
    color: #1b3a63;
    box-sizing: border-box;
    font-family: inherit;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.reliv-alert-input::placeholder {
    letter-spacing: normal;
    color: #9aa8b8;
}

.reliv-alert-input:focus {
    outline: none;
    border-color: #1b4f86;
    box-shadow: 0 0 0 3px rgba(27, 79, 134, 0.15);
}

/* ----- Error en línea ----- */
.reliv-alert-error {
    margin: 10px auto 0;
    max-width: 320px;
    color: #c0392b;
    font-size: 14px;
    line-height: 1.4;
}

/* ----- Acción extra (enlace) ----- */
.reliv-alert-extra {
    margin-top: 16px;
}

.reliv-alert-extra a {
    color: #1b4f86;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
}

.reliv-alert-extra a:hover {
    text-decoration: underline;
}

/* ----- Estado de carga del botón principal ----- */
.reliv-alert-btn.is-loading {
    opacity: 0.65;
    cursor: default;
    pointer-events: none;
}

/* ----- Divisor ----- */
.reliv-alert-divider {
    border: none;
    border-top: 1px solid #e2e8f0;
    margin: 28px 0 24px;
}

/* ----- Acciones ----- */
.reliv-alert-actions {
    display: flex;
    gap: 12px;
    justify-content: center;
    flex-wrap: wrap;
}

.reliv-alert-btn {
    min-width: 170px;
    padding: 13px 28px;
    border: none;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.15s ease, color 0.15s ease;
}

.reliv-alert-btn--primary {
    background: #1b4f86;
    color: #ffffff;
}
.reliv-alert-btn--primary:hover {
    background: #163f6b;
}

.reliv-alert-btn--secondary {
    background: #ffffff;
    color: #1b4f86;
    border: 1px solid #cdd9e6;
}
.reliv-alert-btn--secondary:hover {
    background: #f1f5f9;
}

@media (max-width: 540px) {
    .reliv-alert-modal { padding: 30px 24px 26px; }
    .reliv-alert-title { font-size: 22px; }
    .reliv-alert-btn { width: 100%; }
}
