How can i make that an element contained in a stacking context at the bottom of the stacking order appears in front of another element in a different stacking context that is higher in the stacking order ?
e.g:
HTML:
<div class="Parent-1"></div>
<div class="Parent-2">
<div class="pepe"></div>
<div class="pepin"></div>
</div>
CSS:
.Parent-1{
position: absolute;
z-index: 10;
background-color: green;
}
.Parent-2 {
position: absolute;
z-index: 5;
background-color: red;
}
.pepe, .pepin{
background-color: blue;
}
.pepin{
position: fixed;
z-index: 100;
}
this is what i have (this is what it's suppose to happen):
this is what i want:
Bare in mind that i can't change the elemnts order in HTML neither remove the z-index in Parents element