Long description of illustration of box areas

This diagram illustrates the four areas of the generic CSS box: content, padding, border, and margin.

There are four nested boxes: the content area is the innermost, then padding, border, and margin areas. Each area has a different border style to distinguish its edge: the content edge is thin and solid; padding is thin and dashed; border is thick and solid; margin is thick and dashed.

Below the boxes, a legend lists the border styles used for the four edges.

Return to image.