html, body { height: 100%; margin: 0; font-family: sans-serif; } #wrapper { min-height: calc(100% - 2em); display: flex; flex-direction: column; row-gap: 1em; padding: 1em; } #main { flex-grow: 1; } header { font-size: 1.5em; font-weight: bold; }