/* Global Toast Notification System */
.toast-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-width: 400px;
    pointer-events: none;
}

.toast {
    background: rgba(20, 20, 20, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 12px;
    padding: 16px 20px;
    color: #e0e0e0;
    font-size: 14px;
    font-weight: 500;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
    border: 1px solid #333333;
    transform: translateX(100%);
    opacity: 0;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    pointer-events: auto;
    position: relative;
    overflow: hidden;
    min-width: 300px;
}

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

.toast.hide {
    transform: translateX(100%);
    opacity: 0;
}

.toast-success {
    border-color: #4a7060;
    background: linear-gradient(135deg, rgba(60, 179, 113, 0.1), rgba(20, 20, 20, 0.95));
}

.toast-success::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: linear-gradient(180deg, #4a7060, #3a5a4a);
}

.toast-error {
    border-color: #6a5050;
    background: linear-gradient(135deg, rgba(139, 96, 96, 0.1), rgba(20, 20, 20, 0.95));
}

.toast-error::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: linear-gradient(180deg, #6a5050, #5a4040);
}

.toast-info {
    border-color: #505060;
    background: linear-gradient(135deg, rgba(100, 100, 120, 0.1), rgba(20, 20, 20, 0.95));
}

.toast-info::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: linear-gradient(180deg, #606070, #505060);
}

.toast-warning {
    border-color: #7a6a4a;
    background: linear-gradient(135deg, rgba(168, 144, 80, 0.1), rgba(20, 20, 20, 0.95));
}

.toast-warning::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: linear-gradient(180deg, #7a6a4a, #6a5a3a);
}

.toast-content {
    display: flex;
    align-items: center;
    gap: 12px;
    position: relative;
    z-index: 1;
}

.toast-icon {
    font-size: 18px;
    flex-shrink: 0;
}

.toast-success .toast-icon {
    color: #5a8070;
}

.toast-error .toast-icon {
    color: #8a7070;
}

.toast-info .toast-icon {
    color: #707080;
}

.toast-warning .toast-icon {
    color: #9a8a6a;
}

.toast-message {
    flex: 1;
    line-height: 1.4;
}

.toast-close {
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.7);
    font-size: 18px;
    cursor: pointer;
    padding: 0;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.toast-close:hover {
    background: rgba(255, 255, 255, 0.1);
    color: white;
}

/* Progress bar for auto-dismiss */
.toast-progress {
    position: absolute;
    bottom: 0;
    left: 0;
    height: 3px;
    background: linear-gradient(90deg, #505050, #707070, #505050);
    border-radius: 0 0 10px 10px;
    transform-origin: left;
    animation: toast-progress 5s linear;
}

.toast-success .toast-progress {
    background: linear-gradient(90deg, #4a7060, #3a5a4a);
}

.toast-error .toast-progress {
    background: linear-gradient(90deg, #6a5050, #5a4040);
}

.toast-info .toast-progress {
    background: linear-gradient(90deg, #505060, #404050);
}

.toast-warning .toast-progress {
    background: linear-gradient(90deg, #7a6a4a, #6a5a3a);
}

@keyframes toast-progress {
    0% {
        transform: scaleX(1);
    }
    100% {
        transform: scaleX(0);
    }
}

/* Mobile responsive */
@media (max-width: 640px) {
    .toast-container {
        top: 10px;
        right: 10px;
        left: 10px;
        max-width: none;
    }
    
    .toast {
        min-width: auto;
        font-size: 13px;
        padding: 14px 16px;
    }
    
    .toast-icon {
        font-size: 16px;
    }
    
    .toast-close {
        width: 20px;
        height: 20px;
        font-size: 16px;
    }
}