﻿/* Toast Container */
.toast-container {
    position: fixed;
    top: 2rem;
    right: 2rem;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    width: 360px;
    pointer-events: none;
}

/* Toast Base */
.toast-premium {
    position: relative;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.03));
    backdrop-filter: blur(24px) saturate(180%);
    -webkit-backdrop-filter: blur(24px) saturate(180%);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-left-width: 6px;
    border-radius: 1.5rem;
    padding: 1.25rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    pointer-events: auto;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.3);
    overflow: hidden;
}

/* Toast Animations */
@keyframes toastSlideIn {
    0% {
        transform: translateX(120%) scale(0.9);
        opacity: 0;
        filter: blur(4px);
    }
    100% {
        transform: translateX(0) scale(1);
        opacity: 1;
        filter: blur(0);
    }
}

@keyframes toastSlideOut {
    0% {
        transform: translateX(0) scale(1);
        opacity: 1;
    }
    100% {
        transform: translateX(150%) scale(0.95);
        opacity: 0;
    }
}

.toast-enter {
    animation: toastSlideIn 0.6s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.toast-exit {
    animation: toastSlideOut 0.5s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

/* Toast Icon Container */
.toast-icon-container {
    flex-shrink: 0;
    width: 3rem;
    height: 3rem;
    border-radius: 1rem;
    background: rgba(0, 0, 0, 0.4);
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

/* Icon Glow Effect */
.toast-icon-glow {
    position: relative;
    z-index: 1;
}

.toast-icon-glow::after {
    content: '';
    position: absolute;
    inset: -8px;
    background: currentColor;
    filter: blur(12px);
    opacity: 0.25;
    border-radius: 50%;
    z-index: -1;
}

/* Toast Content */
.toast-content {
    flex-grow: 1;
}

.toast-title {
    color: white;
    font-weight: 900;
    font-size: 0.8125rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 0.125rem;
}

.toast-message {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.75rem;
    font-weight: 500;
    line-height: 1.4;
}

/* Close Button */
.toast-close-btn {
    width: 32px;
    height: 32px;
    min-width: 32px;
    min-height: 32px;
    border-radius: 9999px;
    background: rgba(255, 62, 62, 0.05);
    border: 1px solid rgba(255, 62, 62, 0.2);
    box-shadow: 0 0 10px rgba(255, 62, 62, 0.1);
    color: rgba(255, 62, 62, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    flex-shrink: 0;
    cursor: pointer;
}

.toast-close-btn:hover {
    background: rgba(255, 62, 62, 0.15);
    border-color: rgba(255, 62, 62, 0.5);
    box-shadow: 0 0 15px rgba(255, 62, 62, 0.3);
    color: #ff3e3e;
    transform: scale(1.1);
}

/* Progress Bar */
.toast-progress-container {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: rgba(255, 255, 255, 0.05);
}

.toast-progress-bar {
    height: 100%;
    width: 100%;
    transition: width 5000ms linear;
}

/* Toast Types - Color Variations */
.toast-success {
    border-left-color: #00ff88;
    box-shadow: 0 8px 32px 0 rgba(0, 255, 136, 0.15);
}

.toast-error {
    border-left-color: #ff3e3e;
    box-shadow: 0 8px 32px 0 rgba(255, 62, 62, 0.15);
}

.toast-warning {
    border-left-color: #ff9f0a;
    box-shadow: 0 8px 32px 0 rgba(255, 159, 10, 0.15);
}

.toast-info {
    border-left-color: #00e0ff;
    box-shadow: 0 8px 32px 0 rgba(0, 224, 255, 0.15);
}

/* Accessibility */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
    .toast-enter,
    .toast-exit,
    .toast-progress-bar {
        animation: none;
        transition: none;
    }
}