UX Design and Development course

Margin collapsing

Top and bottom margins of blocks are sometimes combined (collapsed) into a single margin whose size is the largest of the margins combined into it, a behavior known as margin collapsing.

A tricky little quark in layouts. Read this MDN article for more information.