As you can see in the image the element with the class “inner“ is centered inside the “outer“ div, for that I used this stack overflow post. I have tried getting the Hello World paragraph to appear underneath the centered div without cheating with the margin property, but no success.
.outer {
position: relative;
height: 80%;
width: 100%;
}
.inner {
position: relative;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
vertical-align: middle;
}
<div class="outer">
<div class="inner"></div>
<p>Hello World</p>
</div>