CSS box model properties
Basically, the CSS box model is a set of rules that define how every web page on the Internet is rendered. You can set each box's size separately with associated properties.
To set the size of the content area, we use the width
and height
and related properties.[1]
For padding, border, and margin, we use properties with the same name — padding
, border
, and margin
— as well as specific properties for each side of the element.
If we don't specify any of these properties, browsers will use their default values for specific elements, for example:
body {
margin: 8px;
}