Greetings to the Stack Overflow community!
I have a scenario with two div blocks containing images of dimensions 1280px width and 700px height each.
In the first block, there is a div with a width of 400px and a height of 100% floating left.
The second block also contains a div of the same size, floating right. The issue arises from the transparency at the bottom of the first block's image, about 10%.
On the other hand, the top of the second block's image is transparent by 10%. To connect them, I used margin-top on the second image. However, I am unable to hide these divs with a height of 100% beneath them. I attempted to use z-index, but it only hides one of the divs.
For a better understanding, please refer to this JSFiddle example: https://jsfiddle.net/c7m6pm4w/. In the JSFiddle, you will observe that the green and aqua sections are under the blue one. My goal is to have div.three (aqua) on top of div.four (blue) but beneath div.one (red), while div.two (green) should be on top of div.one (red) but beneath div.four (blue).
<div class="one">
<div class="two"></div>
</div>
<div class="four">
<div class="three"></div>
</div>
Here is a visual representation of the scenario: https://i.sstatic.net/9oIEL.png