.flash {
    margin: 0;
    border-radius: 0.75rem;
    border: 1px solid #D7DFE0;
    border-left-width: 4px;
    background: #ffffff;
    color: #052E31;
    box-shadow: 0 12px 24px rgba(5, 46, 49, 0.08);
    overflow: hidden;
    animation: flash-slide-in 0.3s ease-out forwards;
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: start;
    gap: 0.75rem;
    padding: 1rem;
    position: relative;
}

.flash--success {
    border-left-color: #0CAF60;
}

.flash--danger,
.flash--error {
    border-left-color: #FB2C36;
}

.flash--info {
    border-left-color: #4ea1ff;
}

.flash--warning {
    border-left-color: #F59E0B;
}

.flash-stack {
    position: fixed;
    top: 86px;
    right: 1rem;
    z-index: 1100;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    width: min(420px, calc(100% - 2rem));
    pointer-events: none;
}

.flash-stack .flash {
    pointer-events: auto;
}

.flash__body {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.flash__title {
    margin: 0;
    font-size: 0.875rem;
    font-weight: 600;
    color: #052E31;
}

.flash__text {
    margin: 0;
    font-size: 0.75rem;
    color: #5F777B;
}

.flash__icon {
    width: 1.5rem;
    height: 1.5rem;
    border-radius: 999px;
    background: rgba(12, 175, 96, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #0CAF60;
}

.flash__icon svg {
    width: 1rem;
    height: 1rem;
}

.flash--danger .flash__icon,
.flash--error .flash__icon {
    background: rgba(251, 44, 54, 0.1);
    color: #FB2C36;
}

.flash--warning .flash__icon {
    background: rgba(245, 158, 11, 0.1);
    color: #F59E0B;
}

.flash--info .flash__icon {
    background: rgba(78, 161, 255, 0.1);
    color: #4ea1ff;
}

.flash__close {
    border: none;
    background: transparent;
    color: #5F777B;
    font-size: 1.1rem;
    line-height: 1;
    padding: 0;
    cursor: pointer;
    opacity: 0.6;
    transition: opacity 0.2s ease;
}

.flash__close:hover {
    opacity: 1;
    color: #0CAF60;
}

.flash--danger .flash__close:hover,
.flash--error .flash__close:hover {
    color: #FB2C36;
}

.flash--warning .flash__close:hover {
    color: #F59E0B;
}

.flash--info .flash__close:hover {
    color: #4ea1ff;
}

.flash__progress {
    position: absolute;
    left: 0;
    bottom: 0;
    height: 2px;
    width: 100%;
    background: #0CAF60;
    animation: flash-shrink var(--flash-timeout, 5000ms) linear forwards;
}

.flash--danger .flash__progress,
.flash--error .flash__progress {
    background: #FB2C36;
}

.flash--warning .flash__progress {
    background: #F59E0B;
}

.flash--info .flash__progress {
    background: #4ea1ff;
}

@keyframes flash-slide-in {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes flash-shrink {
    from {
        width: 100%;
    }
    to {
        width: 0%;
    }
}
}
