My intro HTML/CSS course has asked us to place a box in the nav bar: It should have a generic box for a logo on the right side of the nav that has a black background color. It should be 80 pixels by 80 pixels and touch the right side of the nav.
However, I've been unable to find any way to place something on top of the navbar. I tried adding div to the nav, but then the box was hidden under the navbar. Any tips?
HTML(I know this isn't the best way to create a navbar, but it's what was shown so far:
nav {
height: 80px;
width: 100%;
background-color: white;
border-bottom: 4px solid green;
box-shadow: 10px 10px 10px;
box-sizing: border-box;
position: fixed;
top: 0;
left: 0;
}
.box1 {
height: 80px;
width: 80px;
background-color: red;
border: 3px green;
background-color: black;
}
<nav>
<p class="p1">Home</p>
<p class="p2">About</p>
<p class="p3">Contact</p>
<div class="box1"></div>
</nav>