To understand the effect of the CSS padding and margin properties on the layout and design of your website, it is worth keeping in mind a few HTML basics. In this language, it is possible to create a series of different elements for final display on a site. Among these elements, two groups can be distinguished: Inline elements and Block elements.
Inline HTML elements are elements that blend in with the text of your site without the need for a separate paragraph. Tags em- Where b- are typical examples. In the HTML script, these tags are used to display the content in italics or bold between the opening tag and the closing tag in the web browser.
Unlike inline elements, block elements are one level above and require a clean paragraph. You can think of Block elements as a sort of frame that spans the width of the screen. It is also possible to adapt the width and the height of the Block elements, so as to enlarge or shrink this frame in relation to the screen. Block elements can be defined relative to each other ; they constitute a basic element for the layout of a website. Typical elements of this HTML category include, for example, headers h1 at h6 or the container div.