JSFiddle - React, Tailwind, and code Playground

by Bartek Legięć

HTML

<div class="wrapper">
  <header></header>
  <main>
    <p>Lorem ipsum dolor sit amet, consectetur adipiscing elit.</p>
  </main>
  <footer>&copy John Doe</footer>
</div>

CSS

.wrapper {
  display: grid;
  grid-template-columns: 1fr 70vw 1fr;
  grid-template-rows: auto 1fr auto;
  grid-template-areas: "start main end";
  min-height: 100vh;
}

header {
  grid-column: start / end;
}
  
main {
  grid-column: main;
}
  
footer {
  grid-column: start / end;
}

body {
  margin: 0;
  font-family: "Noto Serif";
  font-size: calc(16px + .25vw);
}

header {
  background: #673AB7;
  width: 100%;
  height: 64px;
}
  
footer {
  background: #673AB7;
  text-align: center;
  padding: 1em;
  box-sizing: border-box;
  color: #fff;
}