Icons above bootstrap navbar - html

I want to put some icons (facebook, instagram, youtube, whatsapp) above of navbar elements, like this:
This is my code:
<nav class="navbar fixed-top navbar-expand-lg navbar-light navbar-custom">
<a class="navbar-brand" href="http://localhost/wp/">
<img src="http://localhost/wp/wp-content/uploads/2019/05/cropped-logo-1.png"> </a>
<button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarSupportedContent" aria-controls="navbarSupportedContent" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
<div class="collapse navbar-collapse" id="navbarSupportedContent">
<ul class="navbar-nav mr-auto"></ul>
<ul id="menu-menu-principal" class="navbar-nav">
<li id="menu-item-10" class="nav-item active"><a title="INICIO" class=" nav-link" href="#">INICIO</a></li>
<li id="menu-item-12" class="nav-item"><a title="NOSOTROS" class=" nav-link" href="#">NOSOTROS</a></li>
<li id="menu-item-19" class="menu-item menu-item-type-custom menu-item-object-custom menu-item-19 nav-item"><a title="BLOG" class=" nav-link" href="#">BLOG</a></li>
<li id="menu-item-20" class="menu-item menu-item-type-custom menu-item-object-custom menu-item-20 nav-item"><a title="CONTACTO" class=" nav-link" href="#">CONTACTO</a></li>
</ul>
</div>
</nav>
Anybody can help me?

Here's how you do it, Since you want to make your icon-bar above navbar as fixed, we will have to remove the fixed-top class from the navbar, because then giving position:fixed to icon-bar would overlap with our navbar.
So wrap both navbar and icon-bar inside a wrapper div and make that div as position: fixed instead. Rest of the things are self-explanatory if you know basic css.
Here is a code snippet or a fiddle in case you can't figure it out,
#top-wrapper {
position: fixed;
top: 0; left: 0; right: 0;
background-color: green;
z-index: 999;
}
#top-wrapper .icon-bar {
width: 100%;
overflow: auto;
}
#top-wrapper .icon-bar ul {
float: right;
list-style: none;
margin: 0;
padding: 16px 16px 16px 0;
}
#top-wrapper .icon-bar ul li {
float: left;
padding: 0 16px;
border-right: 1px dotted #fff;
}
#top-wrapper .icon-bar ul li:last-child {
border: none;
}
#top-wrapper ul li i {
color: #FFF;
font-size: 14px;
}
.section {
height: 100vh;
background-color: grey;
}
<!-- Latest compiled and minified CSS -->
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/4.3.1/css/bootstrap.min.css">
<!-- jQuery library -->
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.4.0/jquery.min.js"></script>
<!-- Popper JS -->
<script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.14.7/umd/popper.min.js"></script>
<!-- Latest compiled JavaScript -->
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/4.3.1/js/bootstrap.min.js"></script>
<!-- font awesome cdn -->
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css">
<div id="top-wrapper"> <!-- this is our wrapper div -->
<div class="icon-bar">
<ul>
<li><i class="fa fa-facebook"></i></li>
<li><i class="fa fa-instagram"></i></li>
<li><i class="fa fa-youtube-play"></i></li>
<li><i class="fa fa-whatsapp"></i></li>
</ul>
</div>
<nav class="navbar navbar-expand-lg navbar-light navbar-custom">
<a class="navbar-brand" href="http://localhost/wp/">
<img src="http://localhost/wp/wp-content/uploads/2019/05/cropped-logo-1.png"> </a>
<button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarSupportedContent" aria-controls="navbarSupportedContent" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
<div class="collapse navbar-collapse" id="navbarSupportedContent">
<ul class="navbar-nav mr-auto"></ul>
<ul id="menu-menu-principal" class="navbar-nav">
<li id="menu-item-10" class="nav-item active"><a title="INICIO" class=" nav-link" href="#">INICIO</a>
</li>
<li id="menu-item-12" class="nav-item"><a title="NOSOTROS" class=" nav-link" href="#">NOSOTROS</a>
</li>
<li id="menu-item-19" class="menu-item menu-item-type-custom menu-item-object-custom menu-item-19 nav-item"><a title="BLOG" class=" nav-link" href="#">BLOG</a></li>
<li id="menu-item-20" class="menu-item menu-item-type-custom menu-item-object-custom menu-item-20 nav-item"><a title="CONTACTO" class=" nav-link" href="#">CONTACTO</a></li>
</ul>
</div>
</nav>
</div>
<div class="section">Hello world</div>
<div class="section">Hello world</div>
<div class="section">Hello world</div>

At first you need to load Font Awesome then use it.
Look at this links to understand how it works. It is simple.
Introduction Font Awesome
Brand icons
Instagram Example
Try this code.
Be sure that you loaded Font Awesome correctly.
<nav class="navbar fixed-top navbar-expand-lg navbar-light navbar-custom">
<div class="social">
<i class='fab fa-instagram' style='font-size:24px'></i>
<i class='fab fa-facebook' style='font-size:24px'></i>
<i class='fab fa-twitter' style='font-size:24px'></i>
<i class='fab fa-linkedin' style='font-size:24px'></i>
<i class='fab fa-pinterest' style='font-size:24px'></i>
</div>
<div class="menu">
<a class="navbar-brand" href="http://localhost/wp/">
<img src="http://localhost/wp/wp-content/uploads/2019/05/cropped-logo-1.png"> </a>
<button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarSupportedContent" aria-controls="navbarSupportedContent" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
<div class="collapse navbar-collapse" id="navbarSupportedContent">
<ul class="navbar-nav mr-auto"></ul>
<ul id="menu-menu-principal" class="navbar-nav">
<li id="menu-item-10" class="nav-item active"><a title="INICIO" class=" nav-link" href="#">INICIO</a></li>
<li id="menu-item-12" class="nav-item"><a title="NOSOTROS" class=" nav-link" href="#">NOSOTROS</a></li>
<li id="menu-item-19" class="menu-item menu-item-type-custom menu-item-object-custom menu-item-19 nav-item"><a title="BLOG" class=" nav-link" href="#">BLOG</a></li>
<li id="menu-item-20" class="menu-item menu-item-type-custom menu-item-object-custom menu-item-20 nav-item"><a title="CONTACTO" class=" nav-link" href="#">CONTACTO</a></li>
</ul>
</div>
</div>
</nav>

Here's your answer. I can tell you're using WordPress from your code.
1) Install the Better Font Awesome plugin and activate it - https://wordpress.org/plugins/better-font-awesome/
2) Add the following code:
Note: aria-labels in the code below is used by screen readers like VoiceOver on a Mac (see https://www.youtube.com/watch?v=5R-6WvAihms for a demo) so it's good to include this code. A screen reader (software on a computer, cell phone, or tablet) will say something like "Facebook link" and "WhatsApp link" and then people with disabilties (i.e. blind people) can know it's a link to click on.
<a href="https://www.facebook.com/" target="_blank" aria-label="Facebook">
<i class="fab fa-facebook-square"></i>
</a>
<a href="https://www.whatsapp.com/" target="_blank" aria-label="WhatsApp">
<i class="fab fa-whatsapp"></i>
</a>
etc.
3) Do searches for more Font Awesome icon code at https://fontawesome.com/icons?d=gallery

Related

Getting a subnav bar to become a dropdown in smaller screensize

Okay so first time here. Forgive me if I sound lost or silly. I hope you will help correct me if I made any mistakes. Anyways, I am trying to imitate the navbar on this website: WOHA. I am not super concerned about getting it 100%. I have been able to somewhat imitate the on hover secondary navbar by using a jQuery onclick function toggle to make the secondary navbar appear when clicked, so it's close enough and satisfactory for me. What I am lost about is how to make it so that when the screen size gets smaller(as you can see from the linked website example I am trying to make a copy of), that the secondary navbar is accessible as a dropdown option via the main navbar. Would someone be kind enough to fill me in on what to do to achieve such a result?
$( ".subnav-trigger-about" ).click(function() {
$( "#subnav-about" ).toggle();
});
$( ".subnav-trigger-services" ).click(function() {
$( "#subnav-services" ).toggle();
});
#subnav-about {
display: none;
}
#subnav-services {
display: none;
}
.navbar-brand {
color: #FFD700;
opacity: 0.75;
font-size: 2rem;
}
.navbar-brand:hover {
color: #FFD700;
opacity: 1;
}
.nav-item a:hover {
color: #FFD700;
}
#media (min-width: 988px) {
#subnav-about {
position: absolute;
right: 0;
left: 0;
}
#subnav-services {
position: absolute;
right: 0;
left: 0;
}
}
<link href="https://cdn.jsdelivr.net/npm/bootstrap#5.2.2/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-Zenh87qX5JnK2Jl0vWa8Ck2rdkQ2Bzep5IDxbcnCeuOxjzrPF/et3URy9Bv1WTRi" crossorigin="anonymous">
<script src="https://cdn.jsdelivr.net/npm/bootstrap#5.2.2/dist/js/bootstrap.min.js" integrity="sha384-IDwe1+LCz02ROU9k972gdyvl+AESN10+x7tBKgc9I5HFtuNz0wWnPclzo6p9vxnk" crossorigin="anonymous"></script>
<script src="https://code.jquery.com/jquery-3.6.1.js" integrity="sha256-3zlB5s2uwoUzrXK3BT7AX3FyvojsraNFxCc2vC/7pNI=" crossorigin="anonymous"></script>
<nav class="navbar navbar-expand-lg navbar-dark bg-dark">
<div class="container-fluid">
<a class="navbar-brand" href="index.html">TEST</a>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbarSupportedContent" aria-controls="navbarSupportedContent" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
<div class="collapse navbar-collapse" id="navbarSupportedContent">
<ul class="navbar-nav mx-auto mb-2 mb-lg-0 test">
<li class="nav-item">
ABOUT
</li>
<li class="nav-item">
SERVICES
</li>
<li class="nav-item">
<a class="nav-link" href="#">PROJECTS</a>
</li>
<li class="nav-item">
<a class="nav-link" href="#">CONTACT US</a>
</li>
</ul>
</div>
</div>
</nav>
<!-- About Us Secondary Nav -->
<nav id="subnav-about" class="navbar navbar-expand-lg bg-light">
<div class="container-fluid">
<div class="collapse navbar-collapse" id="navbarNav">
<ul class="navbar-nav mx-auto">
<li class="nav-item">
<a class="nav-link" href="#">TEST</a>
</li>
<li class="nav-item">
<a class="nav-link" href="#">EXPERTISE</a>
</li>
<li class="nav-item">
<a class="nav-link" href="#">PEOPLE</a>
</li>
</ul>
</div>
</div>
</nav>
<!-- Services Secondary Nav -->
<nav id="subnav-services" class="navbar navbar-expand-lg bg-light">
<div class="container-fluid">
<div class="collapse navbar-collapse" id="navbarNav">
<ul class="navbar-nav mx-auto">
<li class="nav-item">
<a class="nav-link" href="#">CONSULTATION</a>
</li>
<li class="nav-item">
<a class="nav-link" href="#">MANAGEMENT</a>
</li>
<li class="nav-item">
<a class="nav-link" href="#">TRAINING COURSES</a>
</li>
</ul>
</div>
</div>
</nav>
I feel like I need to do #media and interact with it somehow but I am also unsure of how to proceed
Edit: I have added a bit of content to my navbar since then but nothing that should have changed anything by much. A bit confused on why the code snippet by the guy below me works but mine doesn't. Would appreciate the help in figuring it out
Hope this works for you:
$(".subnav-trigger").click(function() {
$("#subnav").toggle();
});
#subnav {
display: none;
}
#media (min-width: 992px){
#subnav{position: absolute; right:0; left:0;}}
<link href="https://cdn.jsdelivr.net/npm/bootstrap#5.2.2/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-Zenh87qX5JnK2Jl0vWa8Ck2rdkQ2Bzep5IDxbcnCeuOxjzrPF/et3URy9Bv1WTRi" crossorigin="anonymous">
<script src="https://cdn.jsdelivr.net/npm/bootstrap#5.2.2/dist/js/bootstrap.min.js" integrity="sha384-IDwe1+LCz02ROU9k972gdyvl+AESN10+x7tBKgc9I5HFtuNz0wWnPclzo6p9vxnk" crossorigin="anonymous"></script>
<script src="https://code.jquery.com/jquery-3.6.1.js" integrity="sha256-3zlB5s2uwoUzrXK3BT7AX3FyvojsraNFxCc2vC/7pNI=" crossorigin="anonymous"></script>
<nav class="navbar navbar-expand-lg navbar-dark bg-dark">
<div class="container-fluid">
<a class="navbar-brand" href="index.html">TEST</a>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbarSupportedContent" aria-controls="navbarSupportedContent" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
<div class="collapse navbar-collapse" id="navbarSupportedContent">
<ul class="navbar-nav mx-auto mb-2 mb-lg-0">
<li class="nav-item">
ABOUT
<nav id="subnav" class="navbar navbar-expand-lg bg-light">
<div class="container-fluid">
<div class="navbar-collapse" id="navbarNav">
<ul class="navbar-nav mx-auto">
<li class="nav-item">
<a class="nav-link" href="#">TEST</a>
</li>
<li class="nav-item">
<a class="nav-link" href="#">Expertise</a>
</li>
<li class="nav-item">
<a class="nav-link" href="#">People</a>
</li>
</ul>
</div>
</div>
</nav>
</li>
<li class="nav-item">
SERVICES
</li>
<li class="nav-item">
<a class="nav-link" href="#">Link</a>
</li>
</ul>
</div>
</div>
</nav>
<!-- About Us Secondary Nav -->

Show link title on mobile menu

I want to use icons instead of text in my navbar, but display title when I hover. The "title" text displays fine on both mobile and regular versions. But on mobile display, I want to show the title text next to the icons automatically without hovering. the code below shows the icons (title) when i hover over menu item. but i want the title displayed without hovering when the hamburger menu is open on mobile.
<nav class="navbar navbar-expand-lg navbar-dark"> <a class="navbar-brand" href="/index.shtml"><img src="images/cardinal.png" width="80" alt=""/></a>
<button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarSupportedContent1" aria-controls="navbarSupportedContent1" aria-expanded="false" aria-label="Toggle navigation"> <span class="navbar-toggler-icon"></span> </button>
<div class="collapse navbar-collapse" id="navbarSupportedContent1">
<ul class="navbar-nav ml-auto">
<li class="nav-item"> <i class="fas fa-home"></i> </li>
<li class="nav-item"> <a class="nav-link text-white" href="memberinfo.html" title="Members"><i class="fas fa-user-friends"></i></a> </li>
<li class="nav-item"> <a class="nav-link text-white" href="faq.shtml" title="FAQ"><i class="far fa-question-circle"></i></a> </li>
<li class="nav-item"> <a class="nav-link text-white" href="contacts.shtml" title="Contact Us"><i class="far fa-envelope"></i></a> </li>
</ul>
</div>
</nav>
Use a pseudo element to display the title attribute. Control when it should be displayed with a media query.
#media (max-width: 768px) {
.nav-link::after {
content: attr(title);
}
}
Example:
.navbar-dark {
background: hotpink;
}
.fas,
.far {
display: inline-block;
width: 20px;
height: 20px;
outline: 1px solid white;
}
#media (max-width: 768px) {
.nav-link::after {
content: attr(title);
}
}
<link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.5.2/css/bootstrap.min.css" integrity="sha384-JcKb8q3iqJ61gNV9KGb8thSsNjpSL0n8PARn9HuZOnIxN0hoP+VmmDGMN5t9UJ0Z" crossorigin="anonymous">
<nav class="navbar navbar-expand-lg navbar-dark">
<a class="navbar-brand" href="/index.shtml"><img src="images/cardinal.png" width="80" alt="" /></a>
<button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarSupportedContent1" aria-controls="navbarSupportedContent1" aria-expanded="false" aria-label="Toggle navigation"> <span class="navbar-toggler-icon"></span> </button>
<div class="collapse navbar-collapse" id="navbarSupportedContent1">
<ul class="navbar-nav ml-auto">
<li class="nav-item"> <i class="fas fa-home"></i> </li>
<li class="nav-item"> <a class="nav-link text-white" href="memberinfo.html" title="Members"><i class="fas fa-user-friends"></i></a> </li>
<li class="nav-item"> <a class="nav-link text-white" href="faq.shtml" title="FAQ"><i class="far fa-question-circle"></i></a> </li>
<li class="nav-item"> <a class="nav-link text-white" href="contacts.shtml" title="Contact Us"><i class="far fa-envelope"></i></a> </li>
</ul>
</div>
</nav>
<script src="https://code.jquery.com/jquery-3.5.1.slim.min.js" integrity="sha384-DfXdz2htPH0lsSSs5nCTpuj/zy4C+OGpamoFVy38MVBnE+IbbVYUew+OrCXaRkfj" crossorigin="anonymous"></script>
<script src="https://stackpath.bootstrapcdn.com/bootstrap/4.5.2/js/bootstrap.min.js" integrity="sha384-B4gt1jrGC7Jh4AgTPSdUtOBvfO8shuf57BaghqFfPlYxofvL8/KUEfYiJOMMV+rV" crossorigin="anonymous"></script>

How can I place my elements inside my navbar?

The elements of my navbar seem to be stuck outside of it. I'm not sure why?
Here's my code:
<nav class="navbar navbar-expand-lg navbar-inverse"></nav>
<div class="container-fluid">
<div class="navbar-header">
<a
style="color: black; text-decoration: none; font-size: 2rem;"
class="navbar-brand"
href="#"
>name<span class="fas fa-microscope fa-1x"></span
></a>
<button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarSupportedContent" aria-controls="navbarSupportedContent" aria-expanded="false" aria-label="Toggle navigation">
<i class="material-icons">menu</i>
</button>
</div>
<div class="collapse navbar-collapse" id="navbarSupportedContent">
<ul class="navbar-nav mr-auto">
<li class="nav-item active">
<a class="nav-link" href="#">Dashboard <span class="sr-only">(current)</span></a>
</li>
<li class="nav-item">
<a class="nav-link" href="#">Link</a>
</li>
<li class="nav-item">Protect</li>
<li class="nav-item">About</li>
</ul>
</div>
</nav>
.nav a{
color: white !important;
font-size: 20px;
}
.navbar-brand{
color: white !important;
font-size: 20px;
font-family: sans-serif;
}
And here's what the navbar looks like:
website
Does anyone know how to fix this? (Also does the menu icon have a white background and is black, whereas the microscope icon has an invisible bg and is white?)
Thanks!
You close the navbar in the beginning, so remove the </nav> tag from your first line.
Remove 2nd line, it is unnecessary code here.
Assign class "nav-link" for "Protect" & "About menu".
<nav class="navbar navbar-expand-lg navbar-inverse">
<div class="navbar-header">
<a
style="color: black; text-decoration: none; font-size: 2rem;"
class="navbar-brand"
href="#">name<span class="fas fa-microscope fa-1x"></span></a>
<button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarSupportedContent" aria-controls="navbarSupportedContent" aria-expanded="false" aria-label="Toggle navigation">
<i class="material-icons">menu</i>
</button>
</div>
<div class="collapse navbar-collapse" id="navbarSupportedContent">
<ul class="navbar-nav mr-auto">
<li class="nav-item active">
<a class="nav-link" href="#">Dashboard <span class="sr-only">(current)</span></a>
</li>
<li class="nav-item">
<a class="nav-link" href="#">Link</a>
</li>
<li class="nav-item"><a class="nav-link" href="#">Protect</a></li>
<li class="nav-item"><a class="nav-link" href="#">About</a></li>
</ul>
</div>
</nav>

How can I centralize my brand + name with my pages?

I am using bootstrap to create my navbar but I am having a problem.
My brand img and brand img is not aligned with my pages names...
I would like the brand img and name Ghiro to be aligned with "Home" "Products" "Services" "About us".
This is my HTML:
<nav class="navbar navbar-expand-lg brand-colors">
<a class="navbar-brand" href="/">
<img src="../../assets/images/ghiro-logo-no-shadow.png" width="50" height="50">
<h5 class="navbar-brand">Ghiro</h5>
</a>
<button class="navbar-toggler custom-toggler" type="button" data-toggle="collapse" data-target="#navbarNavDropdown" aria-controls="navbarNavDropdown" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
<div class="collapse navbar-collapse" id="navbarNavDropdown">
<ul class="navbar-nav">
<li class="nav-item" routerLinkActive="active">
<a class="nav-link" routerLink="/home">Home</a>
</li>
<li class="nav-item">
<a routerLinkActive="active" class="nav-link" routerLink="/products">Products</a>
</li>
<li class="nav-item" routerLinkActive="active">
<a class="nav-link" routerLink="/services">Services</a>
</li>
<li class="nav-item" routerLinkActive="active">
<a class="nav-link" routerLink="/about-us">About us</a>
</li>
</ul>
</div>
</nav>
I am new at programming and could not fix this. If anyone can help me I appreciate.
I am building this website for a friend and I am going to use as my portfolio at the end.
I will post on my github and put the website live.
Thank you!
To change the style of your website you have to use css. To do that there are 2 different options, first you create a new file and link it in your tag in your html file or second write it directly in your "html code" (also in tag). Here an example of the second method:
<head>
<!-- Here is your css code -->
<style>
body{
margin: 0;
padding: 0;
font-family: sans-serif; /* here you can set your favorite font family */
}
nav{
background-color: white; /* set the background color in your navbar to white */
padding-top: 10px;
min-height: 70px;
border-bottom: black 3px solid; /* if you want to have a border under your navbar */
align-items: center;
}
.nav-item{
margin: 0;
padding: 20px;
display: inline-block; /* brings all of your li (nav-item) in one line */
list-style: none;
float: right;
}
.navbar-brand{
float: left;
}
h5{
padding-right: 50px;
}
</style>
</head>
<body>
<nav class="navbar navbar-expand-lg brand-colors">
<a class="navbar-brand" href="/">
<img src="../../assets/images/ghiro-logo-no-shadow.png" width="50" height="50">
<h5 class="navbar-brand">Ghiro</h5>
</a>
<button class="navbar-toggler custom-toggler" type="button" data-toggle="collapse" data-target="#navbarNavDropdown" aria-controls="navbarNavDropdown" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
<div class="collapse navbar-collapse" id="navbarNavDropdown">
<ul class="navbar-nav">
<li class="nav-item" routerLinkActive="active">
<a class="nav-link" routerLink="/home">Home</a>
</li>
<li class="nav-item">
<a routerLinkActive="active" class="nav-link" routerLink="/products">Products</a>
</li>
<li class="nav-item" routerLinkActive="active">
<a class="nav-link" routerLink="/services">Services</a>
</li>
<li class="nav-item" routerLinkActive="active">
<a class="nav-link" routerLink="/about-us">About us</a>
</li>
</ul>
</div>
</nav>
</body>
try this one and test some things in the " part" to customize it, I just don't want to do the whole stuff, this is just to give you some idea.

How to make navbar more prominent?

I have a navbar on my page but for some reason only the 'homepage' link is pure white. the rest of the links are not as bright. I am trying to create a transparent navbar with a picture as a background. i have managed to do that but the 'Home' link is considerably brighter and more prominent then the rest of the links. the image can be seen below:
<div class="container-fluid p-0">
<nav class="navbar navbar-expand-lg fixed-top navbar-dark">
<a class="navbar-brand" href="#">
<i class="fas fa-mountain fa-2x mx-3"></i>Greatness</a> <!--This is the icon for the brand-->
<button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarNav"
aria-controls="navbarNav" aria-expanded="false"
aria-label="Toggle navigation">
<i class="fas fa-align-right text-light"></i>
</button>
<div class="collapse navbar-collapse" id="navbarNav">
<div class="mr-auto"></div>
<ul class="navbar-nav justify-content-center">
<li class="nav-item active">
<a class="nav-link" href="indexHome.html">HOME</a>
</li>
<li class="nav-item">
<a class="nav-link" href="AboutUs.html">ABOUT US
<span class="sr-only">(current)</span>
</a>
</li>
<li class="nav-item">
<a class="nav-link" href="#">IDEAS</a>
</li>
<li class="nav-item">
<a class="nav-link" href="#">MOTIVATION</a>
</li>
<li class="nav-item">
<a class="nav-link" href="#">LOG IN</a>
</li>
</ul>
</div>
</nav>
</div>
CSS
.nav-item:last-child{
padding-right: 10.5em;
}
.nav-item{
padding: 0.9em;
color: white;
font-size: 17px;
}
.navbar-brand{
padding-left: 8em;
}
It is because an active class is defined in the li which is wrapped around it, like <li class="nav-item active">. Add the active class to its siblings and it should work.