I am facing an issue with my navigation bar...
- I want it to be centered but it is not working.
- I want it to fill from left to right.
I have tried using the following CSS: text-align: center in .navbar a text-align: center in navbar.
.navbar {
background-color: gray;
position: fixed;
top: 0%;
}
.navbar a {
color: white;
text-align: center;
font-family: monospace;
font-size: 20px;
text-decoration: none;
padding: 15px;
display: block;
float: left;
}
.navbar a:hover {
background: lightgray;
color: orange;
}
<div class="navbar">
<a href="../index.html">Home</a>
<a href="Guides.html">Guides</a>
<a href="#">Clips</a>
<a href="#">Leaderboard</a>
<a href="Support the server.html">Support the server</a>
<a href="Help.html">Help</a>
</div>