JSFiddle - React, Tailwind, and code Playground
by vjeux
HTML
<div class="container">
<div class="a">a</div>
<div class="b">b</div>
</div>
CSS
div {
display: flex;
flex-direction: column;
opacity: 0.9;
margin: 10px;
}
.container {
background: black;
height: 200px;
position: relative;
}
.a {
background: red;
position: absolute;
flex: auto;
z-index: 5;
}
.b {
background: blue;
flex: auto;
}