/* notifications.css - Modern glassmorphism style */
.notification-container {
    position: fixed;
    top: 80px;
    right: 20px;
    z-index: 40;
    display: flex;
    align-items: center;
    width: auto;
    max-width: 420px;
    pointer-events: none;
    background: rgba(255, 255, 255, 0.25);
    color: rgb(15 23 42);
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 
        0 15px 35px -5px rgb(0 0 0 / 0.15), 
        0 10px 15px -6px rgb(0 0 0 / 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.6),
        inset 0 -1px 0 rgba(0, 0, 0, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.3);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    opacity: 0;
    transform: translateX(100%) scale(0.95);
    backdrop-filter: blur(40px) saturate(200%) brightness(1.1);
    -webkit-backdrop-filter: blur(40px) saturate(200%) brightness(1.1);
}

body.ui-modal-open .notification-container,
body.ui-modal-open .bot-toast-container {
    pointer-events: none !important;
    z-index: 0 !important;
}

.notification-container.show {
    opacity: 1;
    transform: translateX(0) scale(1);
    pointer-events: auto;
}

.notification-container.dark {
    background: rgba(30, 41, 59, 0.25);
    color: rgb(248 250 252);
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 
        0 15px 35px -5px rgb(0 0 0 / 0.4), 
        0 10px 15px -6px rgb(0 0 0 / 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.3),
        inset 0 -1px 0 rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(40px) saturate(180%) brightness(0.9);
    -webkit-backdrop-filter: blur(40px) saturate(180%) brightness(0.9);
}

.bot-toast-container {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 40;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    width: auto;
    max-width: 420px;
    pointer-events: none;
}

.toast-stack {
    display: flex;
    flex-direction: column;
    gap: 10px;
    width: 100%;
}

.toast {
    display: flex;
    align-items: center;
    width: auto;
    max-width: 420px;
    background: rgba(255, 255, 255, 0.25);
    color: rgb(15 23 42);
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 
        0 15px 35px -5px rgb(0 0 0 / 0.15), 
        0 10px 15px -6px rgb(0 0 0 / 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.6),
        inset 0 -1px 0 rgba(0, 0, 0, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.3);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    opacity: 0;
    transform: translateX(20px) scale(0.98);
    backdrop-filter: blur(40px) saturate(200%) brightness(1.1);
    -webkit-backdrop-filter: blur(40px) saturate(200%) brightness(1.1);
    pointer-events: auto;
}

.toast.show {
    opacity: 1;
    transform: translateX(0) scale(1);
}

.toast.dark {
    background: rgba(30, 41, 59, 0.25);
    color: rgb(248 250 252);
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 
        0 15px 35px -5px rgb(0 0 0 / 0.4), 
        0 10px 15px -6px rgb(0 0 0 / 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.3),
        inset 0 -1px 0 rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(40px) saturate(180%) brightness(0.9);
    -webkit-backdrop-filter: blur(40px) saturate(180%) brightness(0.9);
}

.notification-content {
    display: flex;
    align-items: center;
    padding: 16px 20px;
    font-size: 14px;
    line-height: 1.5;
    font-weight: 500;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
    position: relative;
}

.toast.dark .notification-content {
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
}

.notification-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    margin-right: 12px;
    border-radius: 50%;
    flex-shrink: 0;
}

.notification-icon svg {
    width: 12px;
    height: 12px;
}

.notification-text {
    flex-grow: 1;
    margin-right: 8px;
}

.notification-close {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.05);
    border: 1px solid rgba(0, 0, 0, 0.1);
    cursor: pointer;
    color: rgb(148 163 184);
    transition: all 0.2s;
    flex-shrink: 0;
    backdrop-filter: blur(10px);
}

.notification-close:hover {
    background: rgba(0, 0, 0, 0.1);
    color: rgb(71 85 105);
    transform: scale(1.05);
}

.notification-container.dark .notification-close,
.toast.dark .notification-close {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: rgb(203 213 225);
}

.notification-container.dark .notification-close:hover,
.toast.dark .notification-close:hover {
    background: rgba(255, 255, 255, 0.2);
    color: rgb(255, 255, 255);
    transform: scale(1.05);
}

.toast.clickable {
    cursor: pointer;
}

/* Success notification */
.notification-container.success .notification-icon,
.toast.success .notification-icon {
    background: rgba(34, 197, 94, 0.9);
    color: white;
    box-shadow: 0 0 10px rgba(34, 197, 94, 0.3);
}

.notification-container.success,
.toast.success {
    border-left: 4px solid rgba(34, 197, 94, 0.6);
    box-shadow: 
        0 15px 35px -5px rgb(0 0 0 / 0.15), 
        0 10px 15px -6px rgb(0 0 0 / 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.6),
        inset 0 -1px 0 rgba(0, 0, 0, 0.1),
        0 0 30px rgba(34, 197, 94, 0.2);
}

/* Error notification */
.notification-container.error .notification-icon,
.toast.error .notification-icon {
    background: rgba(239, 68, 68, 0.9);
    color: white;
    box-shadow: 0 0 10px rgba(239, 68, 68, 0.3);
}

.notification-container.error,
.toast.error {
    border-left: 4px solid rgba(239, 68, 68, 0.6);
    box-shadow: 
        0 15px 35px -5px rgb(0 0 0 / 0.15), 
        0 10px 15px -6px rgb(0 0 0 / 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.6),
        inset 0 -1px 0 rgba(0, 0, 0, 0.1),
        0 0 30px rgba(239, 68, 68, 0.2);
}

/* Warning notification */
.notification-container.warning .notification-icon,
.toast.warning .notification-icon {
    background: rgba(245, 158, 11, 0.9);
    color: white;
    box-shadow: 0 0 10px rgba(245, 158, 11, 0.3);
}

.notification-container.warning,
.toast.warning {
    border-left: 4px solid rgba(245, 158, 11, 0.6);
    box-shadow: 
        0 15px 35px -5px rgb(0 0 0 / 0.15), 
        0 10px 15px -6px rgb(0 0 0 / 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.6),
        inset 0 -1px 0 rgba(0, 0, 0, 0.1),
        0 0 30px rgba(245, 158, 11, 0.2);
}

/* Info notification */
.notification-container.info .notification-icon,
.toast.info .notification-icon {
    background: rgba(59, 130, 246, 0.9);
    color: white;
    box-shadow: 0 0 10px rgba(59, 130, 246, 0.3);
}

.notification-container.info,
.toast.info {
    border-left: 4px solid rgba(59, 130, 246, 0.6);
    box-shadow: 
        0 15px 35px -5px rgb(0 0 0 / 0.15), 
        0 10px 15px -6px rgb(0 0 0 / 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.6),
        inset 0 -1px 0 rgba(0, 0, 0, 0.1),
        0 0 30px rgba(59, 130, 246, 0.2);
}

/* Dark theme adjustments */
.notification-container.dark.success,
.toast.dark.success {
    border-left: 4px solid rgba(74, 222, 128, 0.6);
    box-shadow: 
        0 15px 35px -5px rgb(0 0 0 / 0.4), 
        0 10px 15px -6px rgb(0 0 0 / 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.3),
        inset 0 -1px 0 rgba(0, 0, 0, 0.3),
        0 0 30px rgba(74, 222, 128, 0.25);
}

.notification-container.dark.success .notification-icon,
.toast.dark.success .notification-icon {
    background: rgba(74, 222, 128, 0.9);
    box-shadow: 0 0 15px rgba(74, 222, 128, 0.5);
}

.notification-container.dark.error,
.toast.dark.error {
    border-left: 4px solid rgba(248, 113, 113, 0.6);
    box-shadow: 
        0 15px 35px -5px rgb(0 0 0 / 0.4), 
        0 10px 15px -6px rgb(0 0 0 / 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.3),
        inset 0 -1px 0 rgba(0, 0, 0, 0.3),
        0 0 30px rgba(248, 113, 113, 0.25);
}

.notification-container.dark.error .notification-icon,
.toast.dark.error .notification-icon {
    background: rgba(248, 113, 113, 0.9);
    box-shadow: 0 0 15px rgba(248, 113, 113, 0.5);
}

.notification-container.dark.warning,
.toast.dark.warning {
    border-left: 4px solid rgba(251, 191, 36, 0.6);
    box-shadow: 
        0 15px 35px -5px rgb(0 0 0 / 0.4), 
        0 10px 15px -6px rgb(0 0 0 / 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.3),
        inset 0 -1px 0 rgba(0, 0, 0, 0.3),
        0 0 30px rgba(251, 191, 36, 0.25);
}

.notification-container.dark.warning .notification-icon,
.toast.dark.warning .notification-icon {
    background: rgba(251, 191, 36, 0.9);
    box-shadow: 0 0 15px rgba(251, 191, 36, 0.5);
}

.notification-container.dark.info,
.toast.dark.info {
    border-left: 4px solid rgba(96, 165, 250, 0.6);
    box-shadow: 
        0 15px 35px -5px rgb(0 0 0 / 0.4), 
        0 10px 15px -6px rgb(0 0 0 / 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.3),
        inset 0 -1px 0 rgba(0, 0, 0, 0.3),
        0 0 30px rgba(96, 165, 250, 0.25);
}

.notification-container.dark.info .notification-icon,
.toast.dark.info .notification-icon {
    background: rgba(96, 165, 250, 0.9);
    box-shadow: 0 0 15px rgba(96, 165, 250, 0.5);
}

/* Mobile responsive */
@media (max-width: 768px) {
    .notification-container {
        top: 70px;
        right: 10px;
        left: 10px;
        max-width: none;
        transform: translateY(-20px) scale(0.95);
    }

    .notification-container.show {
        transform: translateY(0) scale(1);
    }

    .bot-toast-container {
        bottom: 12px;
        right: 10px;
        left: 10px;
        max-width: none;
        align-items: center;
    }

    .toast-stack {
        width: 100%;
        align-items: stretch;
    }

    .toast {
        width: 100%;
        max-width: none;
        transform: translateY(10px) scale(0.98);
    }

    .toast.show {
        transform: translateY(0) scale(1);
    }

    .notification-content {
        padding: 14px 16px;
        font-size: 13px;
    }

    .notification-icon {
        width: 18px;
        height: 18px;
        margin-right: 10px;
    }

    .notification-icon svg {
        width: 10px;
        height: 10px;
    }
}

/* Animation for slide in */
@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(20px) scale(0.98);
    }
    to {
        opacity: 1;
        transform: translateX(0) scale(1);
    }
}

@keyframes slideOutRight {
    from {
        opacity: 1;
        transform: translateX(0) scale(1);
    }
    to {
        opacity: 0;
        transform: translateX(20px) scale(0.98);
    }
}

.notification-container.show {
    animation: slideInRight 0.3s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.notification-container.hide {
    animation: slideOutRight 0.3s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.toast.show {
    animation: slideInRight 0.3s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.toast.hide {
    animation: slideOutRight 0.3s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}