I'm having a problem editing a h2
with css and within that h2
has a span
but wanted to apply the style in h2
but I do not want the style to apply to my span
I'm using the :not(span)
selector for this however does not work follow my code:
html
<div class="text-center box-product band-product">
<h2>Quero<br>anunciar meu<br><span>produto</span></h2>
<a href="#" title="Saiba mais">Saiba mais <i class="fas fa-arrow-right"></i></a>
</div>
SCSS:
.box-product{
background-color: $light-gray;
h2:not(span){
line-height: 30px;
@include gradient-orange(#f97c16, #feb226);
-webkit-background-clip: text;
-webkit-text-fill-color: transparent;
span{
color: $gray;
font-weight: normal;
font-family: "good_vibes", sans-serif;
font-size: 2em;
text-transform: capitalize;
}
}
}
Notice that the color I am applying in h2
is applying in my span tbm I do not want this as I can solve it follows the image