#toastBox{
    position: fixed;
    top:30px;
    right: 10px;
    display: flex;
    align-items: flex-end;
    flex-direction: column;
    overflow: visible;
    padding:20px;
    z-index: 1051;
}

.toast{
    width:400px;
    height:80px;
    background: #fff;
    font-weight: 500;
    margin:15px 0;
    box-shadow: 0 0 20px rgba(0,0,0,0.3);
    display: flex !important;
    align-items: center;
    position:relative;
    transform: translateX(100%);
    animation: moveleft 0.5s linear forwards;
}

@keyframes moveleft {
    100%{
        transform: translateX(0);
    }
}

.toast i{
    margin:0 20px;
    font-size: 35px;
}

.toast.error i{
    color:red;
}
.toast.info i{
    color:#17a2b8; ;
}

.toast.success i{
    color:green;
}

.toast.invalid i{
    color:orange;
}

.toast::after{
    content:'';
    position: absolute;
    left:0;
    bottom:0;
    width: 100%;
    height: 5px;
    animation: anim 5s linear forwards;
}

@keyframes anim{
    100%{
        width:0;
    }
}

.toast.success::after{
    background-color: green;
}

.toast.info::after{
    background-color: #17a2b8; 
}

.toast.error::after{
    background-color: red;
}

.toast.invalid::after{
    background-color: orange;
}

/*.toast{
    height: 60px;
    width: 250px;
}*/

@media screen and (max-width: 768px) {
    #toastBox {
        right: 10px;
        bottom: 20px;
        padding: 10px;
    }

    .toast {
        width: 250px;
        max-width: 100%;
        height: 60px; 
        font-size: 14px;
    }
    .toast i {
        font-size: 25px;
        margin: 0 10px;
    }
}

@media screen and (max-width: 480px) {
    .toast {
        width: 200px;
        height: 40px;
        font-size: 12px;
    }

    .toast i {
        font-size: 20px;
    }
}