Padding and margin
Padding is the inner whitespace of a block level element. In most instances, it is equal for all sides of the container.
To add spacing between objects, use margin-bottom
. Only add margin to the top as an exception. If excess spacing on the bottom is unnecessary or undesirable, use the pseudo selector :last-child
to reset the margin on the last item in a group.
Use 0.8rem
for padding and margin inside and between objects.
Use 2rem
for margin-bottom
between content sections.