If I have the following HTML markup:
<div class="wrapper">
<div id="container-1">
<div class="child-1-1"></div>
<div class="child-1-2"></div>
</div>
<div id="container-2">
<div class="child-2-1"></div>
<div class="child-2-2"></div>
</div>
</div>
I can apply a display of flex to wrapper, and then make container-2 appear above container-1 using order.
I would like the final order of the elements to be:
- child-2-1
- child-1-1
- child-1-2
- child-2-2
What I basically want is for the children of the two containers to pretend as if their parents are not there, and instead take their ordering from the outer wrapper.
This could of course be achieved via either duplicating the components and hiding/showing depending on the breakpoint, or via JS - so no points for suggesting those.