Padding, sets the position of the internal content in relation to its border. It sets the internal position of the content of an element while margin sets the position of an element around other external elements.
Border, is the property that separates the internal content from the external content of an element. It is also nestled between padding and the margin like a wall.
Margin, is the property that sets the distance in-between an element and other external elements around it.