<!DOCTYPE html>
<html>
<body>
<style>
html, body {
height:100%;
}
div.container4 {
height: 100%;
position: relative }
div.container4 h1 {
margin: 0;
color: blue;
position: absolute;
top: 50%;
left: 50%;
margin-right: -50%;
transform: translate(-50%, -50%) }
</style>
<div class=container4>
<h1> This is a Blue Heading</h1>
</div>
</body>
</html>