score:0

Try using the transition css property in the navbar-collapse class. Something like this :-

.navbar-collapse{
  transition: width 2s;
  background-color: rgb(238, 236, 236);
  width: 100vw;
}

Related Query

More Query from same tag