blob: 47148ec37e9a712eec54240e95b20bdce2830f96 [file] [log] [blame]
<!DOCTYPE html>
<head>
<style>
.composited {
transform: translatez(0);
}
.box {
width: 100px;
height: 100.5px;
}
.behind {
position: absolute;
z-index: 1;
top: 100px;
left: 100px;
background-color: blue;
}
.middle {
position: absolute;
z-index: 1;
top: 15px;
left: 15px;
background-color: lime;
}
.middle2 {
position: absolute;
z-index: 1;
top: 130.5px;
left: 60px;
background-color: magenta;
}
.top {
position: absolute;
z-index: 1;
top: 70.5px;
left: 120px;
background-color: cyan;
}
.container {
position: absolute;
z-index: 1;
top: 25.5px;
left: 25px;
width: 300px;
height: 300px;
background-color: gray;
}
div:hover {
background-color: green;
}
</style>
</head>
<body>
<div class="container">
<div class="composited box behind"></div>
<div class="box middle"></div>
</div>
<div class="box middle2"></div>
<div class="box top"></div>
</body>