I need my text to be transparent towards the video behind it but not the background of the text.
<main>
<div class="container">
<video
src="./pexels-tima-miroshnichenko-5377684.mp4"
autoplay
muted
loop
></video>
<h2>Hello There!</h2>
</div>
</main>
main {
width: 100%;
height: 100vh;
display: flex;
justify-content: center;
align-items: center;
}
.container {
width: 60%;
height: fit-content;
overflow: hidden;
display: grid;
}
video,
h2 {
grid-column: 1;
grid-row: 1;
width: 100%;
display: inline;
}
.container h2 {
margin: 0;
height: 100%;
background: #ffdb99;
font-size: 13vw;
padding: 0;
color: #fff;
text-align: center;
text-transform: uppercase;
z-index: 2;
mix-blend-mode: screen;
font-family: 'Poppins', sans-serif;
}
This is the result: image of text/video overlay
I need the background to stay opaque but the text to be transparent towards the video behind it!
Thanks for your input in advance!! Hope my question is clear!