<div class="outer-wrapper"> <div class="item-1"> item-1 </div> <div class="item-2"> item-2 </div> </div>
.outer-wrapper { position: relative; /* z-index:1; */ width: 200px; height: 200px; background: pink; } .item-1 { position: absolute; width: 280px; height: 50px; background: #2cef52; z-index: 0; } .item-2 { position: absolute; width: 250px; height: 50px; background: #2cd8ef; z-index: -1; left: 20px; top: 20px; }