wtf(css)layout you can see happening

CSS, with the layout showing

Forty steps through flexbox, twenty-two builds that fail unless several concepts are right at once, and the famous wtfs underneath — margin collapsing, stacking contexts, and the invisible wall inside every flex item. This is the one subject where the output IS the picture, so every problem is rendered rather than described.

Problems

10 problems
#titletopictypedifficulty
1display: flex changes the children, not the boxMaking a flex containerTeaching stepEasy
2flex-direction: column swaps which axis is whichMain axis vs cross axisTeaching stepEasy
3justify-content is the main axis, align-items is the cross axisAlignmentTeaching stepEasy
4align-items: stretch is the defaultAlignmentTeaching stepEasy
5align-self overrides the containerAlignmentTeaching stepEasy
6justify-content distributes free space — and sometimes there is noneDistributing spaceTeaching stepEasy
7flex-grow distributes the surplus, not the containerSizingTeaching stepEasy
8flex-shrink: 0 is defensive CSSSizingTeaching stepEasy
9gap spaces items without touching themGapTeaching stepEasy
10flex-wrap: wrap turns one line into manyWrapping and the align-content trapTeaching stepEasy

44 of 87 catalogue topics are authored, with 37 drills rehearsing them. Every one of them is judged: each carries a starter that has been shown to fail, at least two different correct answers that have been shown to pass, and a set of near-misses and cheats that have been shown to be caught. Nothing reaches this list until all of that holds.