JSFiddle - React, Tailwind, and code Playground

HTML

<div class="wrapper">
    <div class="centered">
        <h1>Some text</h1>
        <p>But he stole up to us again, and suddenly clapping his hand on my shoulder, said&mdash;"Did ye see anything looking like men going towards that ship a while ago?"</p>
    </div>
</div>

CSS

.wrapper {
    text-align: center;
    background: #c0c0c0;
    border: #a0a0a0 solid 1px;
    position: fixed;
    top: 0;
    bottom: 0;
    right: 0;
    left: 0;
}
.centered {
    width: 500px;
    padding: 10px 15px;
    border: #a0a0a0 solid 1px;
    background: #f5f5f5;
    position: absolute;
    left: 50%;
    top: 50%;
    -ms-transform: translate(-50%, -50%);
    -webkit-transform: translate(-50%, -50%);
    transform: translate(-50%, -50%);
}