@import "variables";

@keyframes fadeIn {
    0% { opacity: 0; }
    100% { opacity: 0.95; }
}

:host {
    position: relative;
    z-index: 1050;

    > .notification-wrapper {
        display: block;
        position: fixed;
        z-index: 1001;
        top: 0;
        right: 10px;
        border-radius: 3px;
        max-width: 98vw;
        word-wrap: break-word;
        padding: 10px;
        background-color: $color-grey-5;
        color: white;
        transition: opacity 1s, top 0.3s;
        opacity: 0;

        &.success {
            background-color: $color-success;
        }
        &.error {
            background-color: $color-error;
        }
        &.warning {
            background-color: $color-warning;
        }
        &.info {
            background-color: $color-info;
        }

        &.visible {
            opacity: 0.95;
            animation: fadeIn 0.3s 0.3s backwards;
        }
        white-space: pre-line;
    }
}
