html, body { box-sizing: border-box; height: 100%; } body { display: flex; flex-direction: column; } #page { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; #content { display: flex; flex-direction: column; padding: 10px; box-shadow: none; background-color: white; margin: 0; .alert { word-wrap: break-word; white-space: normal; text-align: center; display: block; width: fit-content; } >.title { text-align: center; margin: 0; } >div, >form { box-sizing: border-box; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; width: 100%; max-width: 500px; margin-top: 20px; input[type="submit"] { width: 100%; max-width: 300px; margin: 0; } .errorlist { color: red; text-align: center; margin: 10px 0 0 0; list-style-type: none; } div, fieldset { max-width: 300px; } .captcha { box-sizing: border-box; >img { width: 70px; object-fit: contain; } } } } }