JSFiddle - React, Tailwind, and code Playground
HTML
<div class="parent">
<div style="background-color:lightgrey;">
<p>
I stay on top on desktop and I'm on bottom on mobile
</p>
</div>
<div style="background-color:grey;">
<p>
I stay on bottom on desktop and I'm on bottom on mobile
</p>
</div>
</div>
CSS
.parent1{
display:flex;
flex-direction:column;
}
@media (max-width: px) {
}