/* Universal Neumorphism Toast Notifications */
.neu-toast-container {
    position: fixed;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: 12px;
    max-width: 380px;
    width: calc(100% - 40px);
    pointer-events: none;
}

/* Position Variants */
.neu-toast-container.top-right {
    top: 20px;
    right: 20px;
}

.neu-toast-container.top-left {
    top: 20px;
    left: 20px;
}

.neu-toast-container.bottom-right {
    bottom: 20px;
    right: 20px;
}

.neu-toast-container.bottom-left {
    bottom: 20px;
    left: 20px;
}

.neu-toast-container.center,
.neu-toast-container.center-top {
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
}

.neu-toast-container.center-bottom {
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
}

.neu-toast {
    pointer-events: auto;
    display: flex;
    flex-direction: column;
    padding: 0;
    border-radius: 35px;
    box-shadow: 8px 8px 16px rgba(166, 180, 200, 0.45), -8px -8px 16px #ffffff;
    font-family: var(--neu-font-family, sans-serif);
    font-size: 0.84rem;
    font-weight: 500;
    line-height: 1.4;
    position: relative;
    overflow: hidden;
    animation: neuToastSlideInRight 0.35s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
    transition: all 0.3s ease;
}

.neu-toast-body {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 0.75rem 1.25rem 0.65rem 1.25rem;
    width: 100%;
}

/* Progress Bar */
.neu-toast-progress-track {
    width: 100%;
    height: 4px;
    background: rgba(0, 0, 0, 0.06);
    overflow: hidden;
}

.neu-toast-progress-bar {
    height: 100%;
    width: 100%;
    transform-origin: left;
    animation: neuToastProgressLinear linear forwards;
}

@keyframes neuToastProgressLinear {
    from {
        transform: scaleX(1);
    }
    to {
        transform: scaleX(0);
    }
}

/* Position-dependent animations */
.neu-toast-container.top-left .neu-toast,
.neu-toast-container.bottom-left .neu-toast {
    animation-name: neuToastSlideInLeft;
}

.neu-toast-container.center .neu-toast,
.neu-toast-container.center-top .neu-toast {
    animation-name: neuToastSlideInTop;
}

.neu-toast-container.center-bottom .neu-toast {
    animation-name: neuToastSlideInBottom;
}

.neu-toast.hiding {
    animation: neuToastSlideOutRight 0.3s ease forwards !important;
}

.neu-toast-container.top-left .neu-toast.hiding,
.neu-toast-container.bottom-left .neu-toast.hiding {
    animation: neuToastSlideOutLeft 0.3s ease forwards !important;
}

.neu-toast-container.center .neu-toast.hiding,
.neu-toast-container.center-top .neu-toast.hiding {
    animation: neuToastSlideOutTop 0.3s ease forwards !important;
}

.neu-toast-container.center-bottom .neu-toast.hiding {
    animation: neuToastSlideOutBottom 0.3s ease forwards !important;
}


@keyframes neuToastSlideInRight {
    from { opacity: 0; transform: translateX(60px) scale(0.9); }
    to { opacity: 1; transform: translateX(0) scale(1); }
}

@keyframes neuToastSlideOutRight {
    from { opacity: 1; transform: translateX(0) scale(1); }
    to { opacity: 0; transform: translateX(60px) scale(0.9); }
}

@keyframes neuToastSlideInLeft {
    from { opacity: 0; transform: translateX(-60px) scale(0.9); }
    to { opacity: 1; transform: translateX(0) scale(1); }
}

@keyframes neuToastSlideOutLeft {
    from { opacity: 1; transform: translateX(0) scale(1); }
    to { opacity: 0; transform: translateX(-60px) scale(0.9); }
}

@keyframes neuToastSlideInTop {
    from { opacity: 0; transform: translateY(-40px) scale(0.9); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes neuToastSlideOutTop {
    from { opacity: 1; transform: translateY(0) scale(1); }
    to { opacity: 0; transform: translateY(-40px) scale(0.9); }
}

@keyframes neuToastSlideInBottom {
    from { opacity: 0; transform: translateY(40px) scale(0.9); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes neuToastSlideOutBottom {
    from { opacity: 1; transform: translateY(0) scale(1); }
    to { opacity: 0; transform: translateY(40px) scale(0.9); }
}


.neu-toast-icon {
    font-size: 1.1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    flex-shrink: 0;
    box-shadow: inset 2px 2px 4px rgba(0, 0, 0, 0.08), inset -2px -2px 4px rgba(255, 255, 255, 0.6);
}

.neu-toast-content {
    flex-grow: 1;
    word-break: break-word;
}

.neu-toast-close {
    background: transparent;
    border: none;
    cursor: pointer;
    font-size: 0.9rem;
    opacity: 0.6;
    padding: 2px;
    margin-left: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.2s ease;
    flex-shrink: 0;
}

.neu-toast-close:hover {
    opacity: 1;
}

/* Toast Color Variants & Corresponding Progress Bar Colors */
/* Success */
.neu-toast-success {
    background-color: #ebf9f1;
    color: #1b7a43;
    border: 1px solid #d1f4e0;
}
.neu-toast-success .neu-toast-icon {
    background-color: #d1f4e0;
    color: #1b7a43;
}
.neu-toast-success .neu-toast-progress-bar {
    background-color: #27ae60;
}

/* Info */
.neu-toast-info {
    background-color: #eaf4fb;
    color: #0b69a3;
    border: 1px solid #d4e9f7;
}
.neu-toast-info .neu-toast-icon {
    background-color: #d4e9f7;
    color: #0b69a3;
}
.neu-toast-info .neu-toast-progress-bar {
    background-color: #2980b9;
}

/* Warning */
.neu-toast-warning {
    background-color: #fff9e6;
    color: #9a6b00;
    border: 1px solid #ffe9b3;
}
.neu-toast-warning .neu-toast-icon {
    background-color: #ffe9b3;
    color: #9a6b00;
}
.neu-toast-warning .neu-toast-progress-bar {
    background-color: #f39c12;
}

/* Danger / Error */
.neu-toast-danger {
    background-color: #fdeeee;
    color: #c02b2b;
    border: 1px solid #f9d5d5;
}
.neu-toast-danger .neu-toast-icon {
    background-color: #f9d5d5;
    color: #c02b2b;
}
.neu-toast-danger .neu-toast-progress-bar {
    background-color: #e74c3c;
}

/* Dark */
.neu-toast-dark {
    background-color: #f0f3f7;
    color: #2c3e50;
    border: 1px solid #dce3ed;
}
.neu-toast-dark .neu-toast-icon {
    background-color: #dce3ed;
    color: #2c3e50;
}
.neu-toast-dark .neu-toast-progress-bar {
    background-color: #34495e;
}

/* White */
.neu-toast-white {
    background-color: #ffffff;
    color: #334155;
    border: 1px solid #e2e8f0;
}
.neu-toast-white .neu-toast-icon {
    background-color: #f1f5f9;
    color: #334155;
}
.neu-toast-white .neu-toast-progress-bar {
    background-color: #64748b;
}
