Why is * given more specificity than property inheritance in CSS?
问题 Put simply, I have a page with these two styles: * { color: black; } div.error { color: red } And a page structure like: <html> ... <div class="error"> <div class="row form"> <div class="column"> Error text. </div> </div> </div> ... </html> You would expect "Error text" to be red, wouldn't you. But it is, in fact, rendered black in all browsers. Is this the expected behavior? My second question, is contingent on whether this is the expected behavior. if it is, then why would a designer ever