<div class="first">
<div class="second"></div>
</div>
<div class="third">
</div>
div{
width:50px;
height:50px;
position:absolute;
}
.first{
top:0;
background:#08ff23;
z-index:1;
}
.second{
top:20px;
background:#ce1248;
z-index:100;
}
.third{
top:40px;
background:#2235ac;
z-index:2;
}