JSFiddle - React, Tailwind, and code Playground
by Krzysztof Jedraszewski
HTML
<body>
<header>
</header>
<main>
<section></section>
<section></section>
</main>
<footer>
</footer>
</body>
CSS
* {
box-sizing: border-box;
margin: 0;
padding: 0;
}
html {
width: 100%;
}
body {
display: flex;
flex-direction: column;
min-height: 100%;
height: 100vh;
}
header {
flex: 0 0 70px;
background-color: red;
}
main {
flex: 0 0 calc(100% - 165px);
display: flex;
flex-direction: row;
}
main >:first-child {
flex: 1 calc(100% - 200px);
background-color: yellow;
height: auto;
}
main >:last-child {
flex: 1 200px;
background-color: black;
height: auto;
}
footer {
flex: 0 0 95px;
background-color: green;
}