I am attempting to modify the color of a tab when it is active. Currently, I am using Bootstrap 4.1.3.
My goal is to have the active tab appear orange when clicked, while the inactive one remains white as it is now. How can I achieve this using CSS? I have searched through several questions on Stackoverflow but none of them have provided a solution that works for me.
The code in question is as follows: HTML:
<div class="container" align="center">
<nav>
<div class="nav nav-tabs nav-fill nav-test" role="tablist">
<a class="nav-item nav-link active" id="nav-proxims-tab" data-toggle="tab" href="#nav-proxims" role="tab" aria-controls="nav-proxims" aria-selected="true">Pròxims</a>
<a class="nav-item nav-link" id="nav-historic-tab" data-toggle="tab" href="#nav-historic" role="tab" aria-controls="nav-historic" aria-selected="false">Històric</a>
</div>
</nav>
CSS
.nav-diables {
color: Black;
background-color: White;
text-decoration:none;
font-weight: bold;
}
.nav-diables > li.active {
color: White;
background-color: #FF7400 !important;
text-decoration:none;
font-weight: bold;
}
Thank you for any assistance you can provide.
Sincerely, Miquel