I have created a grid based page where I have 2 columns at 50% width side by side (for comparison).
They work fine in a full sized screen buit in a mobile they are sqaushed side by side. I would like them to be stacked.
The css code is:
@media screen and (max-width:600px) {
body {
max-width: 98%;
margin: auto;
}
.grid-item1 {
display: none;
}
.grid-container2 {
max-width:100%;
display: stack;
}
.grid-container3 {
max-width: 98%;
}
.grid-container4 {
max-width: 98%;
}
.grid-item3 {
max-width: 98%;
}
.grid-item5 {
max-width: 98%;
}
}
In Html ther structure is:
<div class="grid-container3">
<div class="grid-item4">
-<p> text </p>
<div class="grid-item4b"></div>
</d>
</div>
<div class="grid-container4">
<div class="grid-item5">
<p> text</p>
<div class="sm-ban2">
<p>text</p>
</div>
</div>
</div>
If I put an extra div above container4 the mobile version displays 1 single coloumn. Unfortunately, so does the full size page.
I have tried stack but I think that that isn’t needed nowadays.
What do I need to do to put this right?