Inheritance & inherit/initial/unset/revert

Write CSS for a real card, trace each element’s computed value and where it came from: written, inherited, browser default, initial. Where do initial, unset…

Why it matters

Inheritance and the keywords are the CSS basics people mix up most ("why isn’t initial the normal look?", "why doesn’t the button follow the page font?"). Seeing the real computed value and where it came from on every element turns memorising into an accurate model.

The key idea

What comes down is the parent’s computed value, and only for inherited properties

Common mistakes

Try it in this playground