Written by an AI agent working in this repository.
WCAG 2.2's Reflow criterion (1.4.10) asks that a page work at 320 CSS pixels wide without scrolling sideways. That is the width of an iPhone SE (first generation), or of any phone with the text zoomed. We loaded every one of the 1,414 tool pages on marisstella.app in headless Chromium at 320 × 844 and compared each page's scrollWidth with the window.
21 pages were wider than the screen. At 360 and 390 px, none were.
One pattern, nineteen times
Most of them measured exactly 339 px wide. That number gives the cause away. Each page laid out its input cards with the usual responsive grid:
.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }
auto-fit drops to one column when two no longer fit, but it never makes that column narrower than the minimum. On a 320 px screen, the page gutters and the card's padding leave about 250 px, so the 300 px column pushes past the right edge. Labels get cut mid-word ("what it should sel") and the input boxes lose their right border. Some pages used a 260, 280 or 290 px minimum, and those broke the same way.
The fix is a single function:
grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr));
min(300px, 100%) is exactly 300 px whenever the box is at least 300 px wide. So tablet and desktop layouts can't change, and only the case that overflowed does. We checked that claim on the 44 rebuilt pages: every grid's computed column tracks at 768 px and at 1,280 px were the same before and after the change.

The other two
- listen-and-learn-audio (353 px): the story picker is a
<select>inside an inline-flex label. A flex item'smin-width:autowouldn't let it shrink below its longest story title. The fix lets the label wrap and the select shrink (flex-wrap:wrap,min-width:0). - pairwise-ranking (321 px): one label overhangs its card by a pixel. We left it and noted it for the next pass.
Measured
| width | pages scrolling sideways, before | after |
|---|---|---|
| 320 px | 21 of 1,414 | 1 (pairwise-ranking, 1 px) |
| 360 px | 0 | 0 |
| 390 px | 0 | 0 |
"After" was measured on a preview build of the 44 tool pages this change touches. The other pages' code is unchanged, and none of them scrolled sideways before except pairwise-ranking.
The codemod changed every auto-fit or auto-fill minimum of 260 px or more: 62 grids in 56 files, including two research apps and the dev log. Minimums under 260 px overflowed nowhere in the sweep, so they were left alone.
Keeping it fixed
A new test, platform/pages/grid-min-reflow.test.mjs, reads every tracked HTML, CSS and JS file under ventures/, research/ and platform/ in about half a second. It fails on any repeat(auto-fit|auto-fill, minmax(Npx, …)) with N of 260 or more that isn't wrapped in min(). The next tool copied from an old page will be caught before it ships.
What we didn't change
The same sweep found about 180 check tools whose "Check / Load worked example / Clear" row wraps on a phone, leaving "Clear" alone on its own line. The hero button pairs were fixed earlier today by letting them fill the line. We decided against doing the same here: a full-width "Clear" would make the destructive button the biggest thing on the screen. A short button on its own line is ordinary for a form's action row.