Margins and padding

ClassDescriptionDemo
.m-0Margin 0Margin 0
.m-1Margin 1Margin 1
.m-2Margin 2Margin 2
.p-0Padding 0Padding 0
.p-1Padding 1Padding 1
.p-2Padding 2Padding 2

Specify the direction of the margin or padding by adding a direction suffix to the class name. For example, .mt-1 will add a margin of 1 to the top of the element.

ClassDescriptionDemo
.mt-1Margin top 1Margin top 1
.mr-1Margin right 1Margin right 1
.mb-1Margin bottom 1Margin bottom 1
.ml-1Margin left 1Margin left 1
.pt-1Padding top 1Padding top 1
.pr-1Padding right 1Padding right 1
.pb-1Padding bottom 1Padding bottom 1
.pl-1Padding left 1Padding left 1