<nav class="menu menu-1">
  <ul>
    <li><a href="#">Home</a></li>
    <li><a href="#">About</a></li>
    <li><a href="#">Blog</a></li>
    <li><a href="#">contact</a></li>
  </ul>
</nav>
<nav class="menu menu-2">
  <ul>
    <li><a href="#">Home</a></li>
    <li><a href="#">About</a></li>
    <li><a href="#">Blog</a></li>
    <li><a href="#">contact</a></li>
  </ul>
</nav>
<nav class="menu menu-3">
  <ul>
    <li><a href="#">Home</a></li>
    <li><a href="#">About</a></li>
    <li><a href="#">Blog</a></li>
    <li><a href="#">contact</a></li>
  </ul>
</nav>
<nav class="menu menu-4">
  <ul>
    <li><a href="#">Home</a></li>
    <li><a href="#">About</a></li>
    <li><a href="#">Blog</a></li>
    <li><a href="#">contact</a></li>
  </ul>
</nav>
<nav class="menu menu-5">
  <ul>
    <li><a href="#">Home</a></li>
    <li><a href="#">About</a></li>
    <li><a href="#">Blog</a></li>
    <li><a href="#">contact</a></li>
  </ul>
</nav>
@import url('https://fonts.googleapis.com/css?family=Open+Sans+Condensed:700');
*{
  margin: 0;
  padding: 0;
}
.menu{
  padding: 80px 20px;
  font-family: 'Open Sans Condensed', sans-serif;
}
.menu-1, .menu-5{
  background: #4A148C;
}
.menu-2, .menu-4{
  background: #6A1B9A;
}
.menu-3{
  background: #7B1FA2;
}
.menu ul{
  list-style: none;
  margin: 0;
  padding: 0;
  text-align: center;
}
.menu li{
  display: inline-block;
  margin: 0 15px;
}
.menu a{
  font-size: 22px;
  text-transform: uppercase;
  text-decoration: none;
  color: #fff;
  display: block;
  position: relative;
  padding: 4px 0;
}
.menu a::before{
  content: "";
  width: 100%;
  height: 4px;
  position: absolute;
  left: 0;
  bottom: 0;
  background: #fff;
  transition: 0.5s transform ease;
  transform: scale3d(0,1,1);
  transform-origin: 0 50%;
}
.menu a:hover::before{
  transform: scale3d(1,1,1);
}
.menu-1 a::before{
  background: #E91E63;
  transform-origin: 100% 50%;
}
.menu-1 a:hover::before{
  transform-origin: 0 50%;
}
.menu-2 a::before{
  background: #EC407A;
}
.menu-3 a::before{
  transform-origin: 50% 50%;
  background: #F06292;
}
.menu-4 a::before{
  transform-origin: 100% 50%;
  background: #EC407A;
}
.menu-5 a::before{
  background: #E91E63;
  transform-origin: 0 50%;
}
.menu-5 a:hover::before{
  transform-origin: 100% 50%;
}

External CSS

This Pen doesn't use any external CSS resources.

External JavaScript

This Pen doesn't use any external JavaScript resources.