html, body { height: 100%; } body { display: flex; align-items: center; padding-top: 40px; padding-bottom: 40px; background-color: #f5f5f5; } .form-qrcode { width: 100%; max-width: 330px; padding: 15px; margin: auto; } .form-qrcode .form-floating:focus-within { z-index: 2; }