It may sound a stupid question but I need this div2
behind the div1
. But div2
is inside div1
and I need it this way. I tried with z-index
but for some reason doesn't work. I even declared its position
.
I want to display back-sq-1
behind the box-ft1
.
Note that is not possible changing the order of divs, so obviously it would be much easier.
Here is the code:
HTML
<div class="box-ft1">
<span class="back-sq-1"></span>
</div>
CSS:
.box-ft1{
position: absolute;
z-index: 250;
background-color: white;
height: 230px;
width: 400px;
right: 5%;
top:15%;
}
.back-sq-1{
display: block;
z-index: 0;
top: -15px;
left: -15px;
width: 50%;
height: 50%;
position: absolute;
background-color: #a36103;
}