<div class=”absolute” id=”one”>One</div>
<div class=”absolute” id=”two”>Two</div>
<div class=”absolute” id=”three”>Three</div>
.absolute {
position: absolute;
background: red;
padding: 10px;
}
As you can see, the divs all stack on top of each other. By default, the top element will be the element positioned last in the HTML code. Let’s override this default functionality by assigning a z-index to our first div.