HTML CSS
(quick & simple example)
<div style="background: ghostwhite; font-size: 20px; padding: 10px; border: 1px solid lightgray; margin: 10px;"> TEXT </div>
CONTENT
PADDING
BORDER
MARGIN
Nearly all HTML elements are rendered according to the CSS box model. Go ahead - Set different sizes for each layer and test it for yourself.