Skip to content

Commit af0e668

Browse files
committed
Move mediaquery to text-container, fix columns widths for xs screen
This mediaquery seems to work better. It needs to go in front of the non-query selector. The xs screens didn't do 1 column cards, that seems to be fixed with higher number in the minmax. Trial and error for different sizes. /shrug
1 parent 5a7ba12 commit af0e668

File tree

1 file changed

+11
-9
lines changed

1 file changed

+11
-9
lines changed

app/assets/stylesheets/home.scss

Lines changed: 11 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,14 @@ hr.separator-line {
6161
margin: 35px 3vw 0 3vw;
6262
}
6363

64+
@media screen and (min-width: 1800px) {
65+
.text-container {
66+
//background-color: deeppink;
67+
max-width: 1800px;
68+
margin: 35px auto;
69+
}
70+
}
71+
6472
.intro {
6573
//padding: 0 19vw 15vh 20vw;
6674
font-size: larger;
@@ -70,7 +78,7 @@ hr.separator-line {
7078
margin-top: 30px;
7179
margin-left: auto;
7280
margin-right: auto; // this auto margins is needed to center the text block...
73-
//text-align: center; // ... and this is needed to center the button (See below)
81+
//text-align: center; // ... and this is needed to center the button (moved, see below)
7482
}
7583

7684
.intro-with-button-centered {
@@ -81,18 +89,12 @@ hr.separator-line {
8189
//@include content-layout;
8290
display: grid;
8391
grid-gap: 1rem;
84-
grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
92+
grid-template-columns: repeat(auto-fit, minmax(470px, 1fr));
8593
// ^ no media queries needed for smaller screens
94+
// 470 is trial and error: full column card on small screens,
8695
margin-bottom: 3vh;
8796
}
8897

89-
@media screen and (min-width: 1400px) {
90-
.cards {
91-
//background-color: deeppink;
92-
grid-template-columns: repeat(auto-fit, minmax(1fr, 300px));
93-
}
94-
}
95-
9698
.card {
9799
background-color: $DJSbackground_grey;
98100
padding: 1rem;

0 commit comments

Comments
 (0)