CSS - Paddings
The padding property allows you to specify how much
space should appear between the content of an
element and its border.
What is CSS Padding?
Padding in CSS is the transparent area between the outer edge of the element and
the inner edge of the border.
In simple words, Padding is the space around the element.
Using CSS padding property, you can specify the padding at top, right, bottom and
left side around the element.
Padding has 4 sides –
padding-top – Padding-top is the top padding of an element.
padding-right – Padding-right is the right padding of an element.
padding-bottom– Padding-bottom is the bottom padding of an element.
padding-left– Padding-left is the left padding of an element.
There are 2 ways to set the padding:
Using shorthand padding property
Using the individual property of padding-top, padding-right,
padding-bottom, and padding-left
Individual Padding property