I have a top navbar on my test site that has space above with the body background color. I want to remove this so that the nav extends vertically to cover the viewport (that light blue color becomes the dark blue color of nav background color):
body {
background-color: #cce6ff;
margin: 0px;
border: 0px;
}
nav {
font-family: 'Nunito Sans', sans-serif;
font-size: 20px;
background-color: #000033;
height: 45px;
}
li {
list-style-type: none;
float: right;
border-right: 2px solid white;
}
li:first-child {
border-right: hidden;
}
li a {
color: white;
padding-left: 5px;
padding-right: 5px;
}
<nav id="navbar">
<ul>
<li><a class="top-nav" id="home" href="#home">Home</a></li>
<li><a class="top-nav" id="about-me" href="#about-me">About Me</a></li>
<li><a class="top-nav" id="my-work" href="#my-work">My Work</a></li>
<li><a class="top-nav" id="contact" href="#contact">Contact</a></li>
</ul>
</nav>
I don't know where it's inheriting that space/padding from so I don't know how to troubleshoot it. I feel like I've tried everything.