I'm building a site and I am utilising the Bootstrap framework as it saves me a lot of development time.
The Issue
I have a collection of links a couple of dropdown links and the rest are just regular links.
I have managed to successfully change the hover state of the links without a dropdown menu by giving them a different background colour.
But the problem I am having is that I cannot change the background colour of the links that have a dropdown menu. I don't mean the actual background colour of the dropdown menu but the nav-pill link on the navbar.
I have been trying to resolve the issue in my custom styles stylesheet (styles.css) using the following CSS code
.nav-pills {
padding-top: 20px;
}
.nav-pills > li > a {
font-size: 15px;
color: #37404e;
border-radius: 5px 5px 0 0;
padding: 10px;
}
.nav-pills > li > a:hover {
background-color: #418bca;
color: #fff;
}
/* --- dropdown-menu --- */
.dropdown-menu {
margin-top: -5px;
}
.dropdown-menu > li {
font-size: 15px;
}
.dropdown-menu > li > a {
transition: .3s;
-webkit-transition: .3s;
-moz-transition: .3s;
}
.dropdown-menu > li > a:hover {
background-color: #ff6347;
color: #fff;
}
.dropdown-header {
color: #418bca;
}
I just can't seem to find a fix for this.
Any advice on how this can be fixed would be greatly appreciated!