/* toast.css - Modern floating notifications */

.toast-container {
    position: fixed;
    top: 24px;
    right: 24px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    z-index: 10000;
    pointer-events: none;
}

.toast {
    pointer-events: auto;
    min-width: 320px;
    max-width: 450px;
    background: var(--glass-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    padding: 16px;
    display: flex;
    align-items: flex-start;
    gap: 12px;
    box-shadow: 
        0 10px 15px -3px rgba(0, 0, 0, 0.1),
        0 4px 6px -2px rgba(0, 0, 0, 0.05),
        inset 0 0 0 1px rgba(255, 255, 255, 0.1);
    transform: translateX(120%);
    transition: all 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    overflow: hidden;
    position: relative;
}

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

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

.toast-icon {
    flex-shrink: 0;
    width: 32px;
    height: 32px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
}

.toast-content {
    flex-grow: 1;
}

.toast-title {
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--text-primary);
    margin-bottom: 2px;
}

.toast-message {
    font-size: 0.85rem;
    color: var(--text-secondary);
    line-height: 1.4;
}

.toast-close {
    flex-shrink: 0;
    background: transparent;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 4px;
    border-radius: 6px;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.toast-close:hover {
    background: rgba(0, 0, 0, 0.05);
    color: var(--text-primary);
}

/* Success Theme */
.toast-success .toast-icon {
    background: rgba(34, 197, 94, 0.15);
    color: #22c55e;
}

/* Error Theme */
.toast-error .toast-icon {
    background: rgba(239, 68, 68, 0.15);
    color: #ef4444;
}

/* Info Theme */
.toast-info .toast-icon {
    background: rgba(59, 130, 246, 0.15);
    color: #3b82f6;
}

/* Warning Theme */
.toast-warning .toast-icon {
    background: rgba(245, 158, 11, 0.15);
    color: #f59e0b;
}

/* Progress bar for auto-hide */
.toast-progress {
    position: absolute;
    bottom: 0;
    left: 0;
    height: 3px;
    background: rgba(255, 255, 255, 0.2);
    width: 100%;
}

.toast-progress-bar {
    height: 100%;
    width: 100%;
    background: currentColor;
    opacity: 0.5;
    transform-origin: left;
}

@keyframes toast-progress-anim {
    from { transform: scaleX(1); }
    to { transform: scaleX(0); }
}

.toast.show .toast-progress-bar {
    animation: toast-progress-anim linear forwards;
}

[data-theme="dark"] .toast {
    background: rgba(30, 41, 59, 0.8);
    border-color: rgba(255, 255, 255, 0.1);
}

[data-theme="dark"] .toast-close:hover {
    background: rgba(255, 255, 255, 0.1);
}
