Bacground blur problem

I noticed that one element with a blur background overlaps the other one ignoring the z-index, how can I solve this problem?
12 Replies
~MARSMAN~
~MARSMAN~2y ago
We can't do anything without live code Make a CodePen
Eighth
EighthOP2y ago
The problem is not in the code, I checked, if I change the bacground backdrop filter footer property to any color, then the block works as it should, the nuance is that the header menu uses the same property and when it hits the footer, it overlaps it without looking on z-index
WebMechanic
WebMechanic2y ago
We can't do anything without live code
Unknown User
Unknown User2y ago
Message Not Public
Sign In & Join Server To View
glutonium
glutonium2y ago
Eighth
EighthOP2y ago
Sorry, I recovered the password from codepen https://codepen.io/Mister-Eighth/pen/zYJoLmw
glutonium
glutonium2y ago
glutonium
glutonium2y ago
where the overlapping
WebMechanic
WebMechanic2y ago
The owner of this Pen needs to verify their email address to enable Full Page View.
please do, browser devtools are easier to use in full page view for starters avoid *{padding: 0;margin: 0;border: 0;} ot doesn't pay out in the long run esp. with images or svg; you end up re-adding margins and paddings which makes things harder to manage
Eighth
EighthOP2y ago
The problem is that when you open the mobile menu, it goes under the footer and not above But if you remove blur from the background of one, then everything is fine, but when the menu and the footer have blur in the background, it does not work correctly
WebMechanic
WebMechanic2y ago
the other one ignoring the z-index
your SVGs are part of header and are "z-indexed" withing this element. A z-index can't escape it's parent (layering group/stacking context). You need to change the z-index for header to sit above footer as a whole. header { z-index: 10 } filter and backdrop-filter create new stacking contexts (had to learn this the hard way, too) so your position go down the drain for their child elements and z order changes because now something else became the "relative" parent your positioned content aligns to.
Eighth
EighthOP2y ago
Thank you
Want results from more Discord servers?
Add your server