I have a flex design that looks kinda like this:
.columns {
flex-wrap: wrap;
display: flex;
}
.column {
display: block;
}
.column.is-8 {
flex: none;
width: 66.66667%;
}
.column.is-4 {
flex: none;
width: 33.33333%;
}
.box-1 {
background-color: red;
height: 200px;
}
.box-2 {
background-color: yellow;
height: 400px;
}
.box-3 {
background-color: blue;
height: 800px;
}
*, *::before, *::after {
box-sizing: inherit;
}
<div class="columns">
<div class="column is-8 box-1">
Box 1
</div>
<div class="column is-4 box-2">
Box 2
</div>
<div class="column is-8 box-3">
Box 3
</div>
</div>
<!-- on desktop: box 1, 2 and 3 -->
<!-- on mobile: box 1, 2 and 3 -->
How can I prevent box 2 from pushing down box 3? So it would look like this:
Update
I would like to add that on mobile, the boxes should be in the same order (e.g. 1, 2 then 3)