mirror of
https://github.com/MarijnDoeve/TijdVoorDeTest.git
synced 2026-07-04 22:50:15 +02:00
Fix quiz page vertical centering regression
The CSS cleanup broke vertical centering: flex on body causes main to stretch full-width; place-items:center on a grid body only centers items within their auto-sized track (not the track within body). Fix: move background/color to html (full-viewport grid that centers body), give body height:100% + display:grid + align-content:center (centers the content track within full-height body) + justify-self:center (shrink-wraps body width). Matches production behavior exactly.
This commit is contained in:
+13
-7
@@ -1,17 +1,23 @@
|
||||
html {
|
||||
height: 100%;
|
||||
}
|
||||
|
||||
body {
|
||||
min-height: 100%;
|
||||
background-image: url("../img/background.png");
|
||||
background-position: center;
|
||||
background-repeat: no-repeat;
|
||||
background-color: black;
|
||||
color: white;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: center;
|
||||
display: grid;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
body {
|
||||
height: 100%;
|
||||
background-image: url("../img/background.png");
|
||||
background-position: center;
|
||||
background-repeat: no-repeat;
|
||||
background-color: black;
|
||||
display: grid;
|
||||
align-content: center;
|
||||
justify-self: center;
|
||||
}
|
||||
|
||||
.elimination-screen {
|
||||
|
||||
Reference in New Issue
Block a user