CSS padding property
Padding creates space around an element within the defined borders of its container. We need padding to let the content breathe and bring visual clarity to the design. CSS provides you complete control over the padding.
You can either use a common padding
property and define all four values (top, right, bottom, and left padding) at once. Or you can specify each value separately with the padding-top
, padding-right
, padding-bottom
, and padding-left
properties.