I'm trying to use two different background colors for different sections of the page. Right now I haven't scaled it appropriately but I'm currently just trying to fix this issue. The issue is that the text doesn't appear over the background, but instead under it.
The expected output is that the text is above the background colors. The actual output is that the text appears below the whole background (Not behind, but below it).
.bg-container {
min-height: 100vh;
}
.top {
height: 50vh;
background: #76a3b1;
position: relative;
}
.bottom {
height: 50vh;
background-color: #fff;
}
.title1 {
position: absolute;
}
<div class="bg-container">
<div class="top"></div>
<div class="bottom"></div>
</div>
<div class="main-page">
<span class="title1">
TEXT
</span>
</div>