html{
    width: 100%;
    height: 100%;
}

body{
    display: flex;
    height: 100%;
    justify-content: center;
    align-items: center;
    background: #291e1e;
}

.menu{
    max-width: 150px;
    width: 100%;
    position: relative;
}

.item{
    height: 36px;
    padding: 0 10px;
    position: relative;
    z-index: 3;
    text-align: center;
    font-size: 12px;
    line-height: 36px;
    cursor: pointer;
    text-decoration: none;
    color: white;
    font-family: sans-serif;
    display: block;
}

.back-menu{
    position: absolute;
    top: 0;
    left: 0;
    height: 36px;
    width: 100%;
    background: #007be5;
    border-radius: 40px;
    z-index: 2;
    transition: 0.3s;
}

.item:nth-of-type(1):hover ~ .back-menu{
    transform: translateY(0);
}

.item:nth-of-type(2):hover ~ .back-menu{
    transform: translateY(calc(100% * 1));
}

.item:nth-of-type(3):hover ~ .back-menu{
    transform: translateY(calc(100% * 2));
}

.item:nth-of-type(4):hover ~ .back-menu{
    transform: translateY(calc(100% * 3));
}

.item:nth-of-type(5):hover ~ .back-menu{
    transform: translateY(calc(100% * 4));
}

.item:nth-of-type(6):hover ~ .back-menu{
    transform: translateY(calc(100% * 5));
}

ul.navbar {
    list-style-type: none;
    padding: 0;
    margin: 0;
    top: 2em;
    left: 1em;
    width: 9em }

  ul.navbar li {
    background: white;
    margin: 0.5em 0;
    padding: 0.3em;
    border-right: 1em solid black }
  ul.navbar a {
    text-decoration: none }
  a:link {
    color: blue }
  a:visited {
    color: purple }







