Explore Bato Web Agency Webflow Certified Partner Profile Explore Bato Web Agency Webflow Certified Partner Profile

How do you stack columns on mobile without changing the HTML order?

Illustration without a description Illustration without a description

Stack columns by using a single-column base layout and adding multiple columns at a wider content breakpoint. Grid and Flexbox can change track structure without changing the HTML. Keep the source order equal to the order users should read and focus through on mobile.

 

With Grid, the narrow layout needs little more than a gap. At the breakpoint, define the columns:

 

.columns {
display: grid;
gap: 1.5rem;
}

@media (min-width: 48rem) {
.columns { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

 

Flexbox can use flex-direction: column as the base and switch to row, or rely on wrapping and flexible bases. Grid is often clearer when columns should align across rows. Neither approach requires duplicating content or moving nodes with JavaScript.

 

Avoid the order property unless the visual change is minor and does not confuse navigation. CSS ordering changes appearance but generally leaves DOM, screen-reader and keyboard focus order unchanged. A user could see the second panel first while Tab reaches controls in the visually lower panel.

 

Test with keyboard, screen reader and browser zoom in both arrangements. Long labels may make two columns unusable before the planned breakpoint. Let content determine the transition and preserve the same semantic grouping so stacking does not detach a heading from its controls. Keep the layout rule beside the component and document why the threshold or constraint exists. This reduces accidental overrides and gives future editors a concrete condition to retest after content changes. Add this case to responsive regression tests with long content, browser zoom and at least one narrow embedded container. Record the expected wrapping and focus behavior so later component changes can be checked against a known result.