ul{
    margin: 0px;
    padding: 0px;
}
ul li {
    width: 100px;
    height: 30px;
    float: left;
    display: block;
    background-color: black;
   text-align: center;
   border-radius: 10px;
   margin: 1px;
}

ul li a{
    text-decoration: none;
    color: white;
    line-height: 30px;  
    transition: 1s;
    display: block;
    border-radius: 10px;
}
ul li a:hover{
    background-color: brown;
    
}

ul ul li{
    clear: both;
    position: relative;
}
ul ul{
    display: none;
}

ul li:hover > ul{
    display: block;
}

ul ul ul{
    position: absolute;
    left: 100%;
    top: 0px;
}
ul ul ul ul {
    right: -100px;
}

ul ul ul ul ul {
    left: 300%;
}