/* ==========================================================================
   ILLAN PRO - DIALOG MANAGER STYLES (Adaptado a Ecosistema WP)
   ========================================================================== */

/* --- TOASTS (Notificaciones efímeras) --- */
.toast-container {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    z-index: 400;
    pointer-events: none;
}

.toast {
    background: var(--glass-bg); /* Hereda del Tema principal */
    border: 1px solid var(--glass-border);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    color: var(--text-main);
    padding: 1rem 1.5rem;
    border-radius: var(--radius-md);
    box-shadow: 0 10px 25px rgba(0,0,0,0.5);
    display: flex;
    flex-direction: column;
    min-width: 280px;
    max-width: 350px;
    pointer-events: auto;
    position: relative;
    overflow: hidden;
    transform: translateX(120%);
    opacity: 0;
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275), opacity 0.3s ease;
}

.toast.show {
    transform: translateX(0);
    opacity: 1;
}

.toast-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.25rem;
}

.toast-title {
    font-weight: 700;
    font-size: 0.9rem;
}

.toast-close {
    background: none;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    font-size: 1.2rem;
    padding: 0;
    line-height: 1;
}

.toast-close:hover {
    color: var(--text-main);
}

.toast-message {
    font-size: 0.85rem;
    color: var(--text-muted);
}

.toast-progress {
    position: absolute;
    bottom: 0;
    left: 0;
    height: 3px;
    background: var(--accent);
    width: 100%;
    transform-origin: left;
}

/* Tipos de Toasts */
.toast.toast-success .toast-title { color: var(--accent); }
.toast.toast-error .toast-title { color: var(--danger); }
.toast.toast-error .toast-progress { background: var(--danger); }
.toast.toast-warning .toast-title { color: #ff9800; }
.toast.toast-warning .toast-progress { background: #ff9800; }
.toast.toast-info .toast-title { color: #2196f3; }
.toast.toast-info .toast-progress { background: #2196f3; }

/* --- MODALES Y PROMPTS (Alertas binarias y forms) --- */
.dialog-overlay {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    z-index: 300;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.2s ease;
}

.dialog-overlay.show {
    opacity: 1;
}

.dialog-box {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    width: 90%;
    max-width: 400px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.6);
    transform: scale(0.95);
    transition: transform 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.dialog-overlay.show .dialog-box {
    transform: scale(1);
}

.dialog-title {
    color: var(--text-main);
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
    font-weight: 700;
}

.dialog-message {
    color: var(--text-muted);
    font-size: 0.95rem;
    margin-bottom: 1.5rem;
    line-height: 1.5;
}

.dialog-form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.dialog-input {
    width: 100%;
    padding: 0.75rem 1rem;
    background: rgba(255,255,255,0.05);
    border: 1px solid var(--glass-border);
    color: var(--text-main);
    border-radius: 6px;
    outline: none;
    font-family: inherit;
    transition: border-color 0.3s ease;
}

.dialog-input:focus {
    border-color: var(--accent);
}

.dialog-buttons {
    display: flex;
    justify-content: flex-end;
    gap: 0.75rem;
}

.dialog-btn {
    padding: 0.6rem 1.2rem;
    border-radius: 6px;
    font-weight: 600;
    cursor: pointer;
    border: none;
    transition: all 0.2s ease;
    font-size: 0.9rem;
}

.dialog-btn-cancel {
    background: transparent;
    color: var(--text-muted);
    border: 1px solid var(--glass-border);
}

.dialog-btn-cancel:hover {
    background: rgba(255,255,255,0.05);
    color: var(--text-main);
}

.dialog-btn-confirm {
    background: var(--accent);
    color: #fff;
}

.dialog-btn-confirm:hover {
    background: var(--accent-hover);
}

.dialog-btn-danger {
    background: var(--danger);
    color: #fff;
}

.dialog-btn-danger:hover {
    background: #d32f2f; /* Tono más oscuro de peligro */
}