<!DOCTYPE html>
<html>
<head>
<style>
.box-x {
width: 150px;
height: 350px;
border: 1px dashed red;
background-color: rgba(255, 153, 153, 0.7);
float: left;
}
.box-y {
width: 300px;
height: 120px;
border: 1px dashed green;
background-color: rgba(179, 255, 153, 0.7);
}
.one {
position: absolute;
top: 5px;
left: 5px;
z-index: 4;
}
.two {
position: relative;
top: 30px;
left: 80px;
z-index: 3;
}
.three {
position: relative;
top: -10px;
left: 120px;
z-index: 2;
}
.four {
position: absolute;
top: 5px;
right: 5px;
z-index: 1;
}
.five {
margin-left: 100px;
margin-top: -50px;
background-color: rgba(255, 255, 153, 0.7);
z-index: 5;
}
</style>
</head>
<body>
<div class="box-x one">one</div>
<div class="box-y two">two</div>
<div class="box-y three">three</div>
<div class="box-x four">four</div>
<div class="box-y five">five</div>
</body>
</html>