css align center vertical and horizontal

CSS
.parent-class {
  display: flex;
  align-items: center;
  justify-content: space-around;
}div.center{display:block;margin:auto;width:50%;}
p.center{text-align:center;}
Source

Also in CSS: