I have the following CSS code in a custom.css style sheet which is part of the Main theme
.thm-unit-test h3 {
font-size: 28px !important;
}
I have added the following code to my child theme CSS
.thm-unit-test h3 {
font-size: 18px !important;
color: #222;
font-weight: 700;
}
But it is not not working. With this in mind how do I override the !important in the main custom.css. Because if I can override it than the code in my child theme can take effect
Use the Body tag in front of it... be more specific:
Or other parent elements...
Take some time to understand CSS Selector Priority:
Understanding CSS selector priority / specificity
https://www.w3.org/TR/CSS2/cascade.html#cascading-order
I'd use an ID in front of it tbf.