JSFiddle - React, Tailwind, and code Playground

HTML

<a class="item" href="#">
<span class="wrapper">
    <span class="inner">
        test
    </span>
</span>
</a>

CSS

body
{
    background-color:black;
}

a.item{
    padding-left: 20px;
    display: inline-block;
    text-decoration: none;
    color: white;
}

a.item:hover {
    background:url(http://www.textsensor.com/test/images/submenuImg1.png) no-repeat left 50%; 
    
}

a.item span.wrapper{
    height:40px;
    line-height:40px;
    padding-right: 20px;
    display: block;
}

a.item span.inner{
    display: inline-block;
    vertical-align: center;
    line-height: 1em;
    height: 1em;
    margin-bottom: 5px;
}
a.item:hover span.inner{
    border-bottom: #a00 5px double;
    margin-bottom: 0;
}
a.item:hover span.wrapper{
    background:url(http://www.textsensor.com/test/images/submenuImg3.png) no-repeat right 50%; 
}