I created a webpage with a navigation bar that has links which scroll to different sections on the page. I added a hover animation to the links using the code below:
.navbar-default .navbar-nav li a:hover,
.navbar-default .navbar-nav li a:active {
box-shadow: 0 4px 0px 0px #62c4a4;
}
In addition to this custom hover animation, Bootstrap has a default hover effect that makes the text darker. You can see a demo of it on CodePen here.
However, I noticed that on smaller devices, when the collapsing list expands, the blue box-shadow hover effect also triggers. I don't want this effect to show on the expanded navbar, as the default Bootstrap hover effect is sufficient for that.
https://i.sstatic.net/0xuGk.png
Is there a way to prevent the hover effect from displaying on the expanded navbar?