Skip to main content
PProfileMatch
← Path

CSS Fundamentals · CSS Selectors, the Cascade and Specificity Explained

0 XP
  1. 1 current stop: learning
  2. 2 upcoming
  3. 3 upcoming
  4. 4 upcoming
  5. 5 upcoming

Finish after stop 5

Stop 1 of 5 · Bike shop: sorting the spare parts

Trick to keep in mind+3 XP

A space means 'inside of'; no space means 'also is'.

In a selector, what sits between two parts changes the meaning. Parts written together with no gap all describe the same element, so it must satisfy every one. A space looks for a descendant at any depth, > looks only at direct children, and a comma simply gives two separate selectors that share one rule.

Read it once, then a question tests whether the trick stuck.