# Layout and composition

Begin with reading order. A sequence is an argument: context before evidence, prerequisites before installation, eligibility before application, or an object before dimensions. Color changes do not change that argument.

## Primitives and recipes

`.sds-container` centers a bounded page with gutters. `.sds-section` supplies vertical rhythm. `.sds-grid` has twelve equal columns with a four-column fallback at its narrow breakpoint. `.sds-stack` arranges vertical siblings and `.sds-cluster` wraps related controls or labels.

The catalogue describes **recipe-specific** grids: 12 columns at 64rem and above, 8 from 48rem to below 64rem, and one below 48rem. Implement these rules locally; they are not automatically produced by `.sds-grid`.

```css
.case-opening { display: grid; gap: var(--sds-space-8); }
.case-opening > * { min-inline-size: 0; }
@media (min-width: 48rem) {
  .case-opening { grid-template-columns: repeat(8, minmax(0,1fr)); }
  .case-opening__copy { grid-column: span 5; }
  .case-opening__figure { grid-column: span 3; }
}
@media (min-width: 64rem) {
  .case-opening { grid-template-columns: repeat(12,minmax(0,1fr)); }
  .case-opening__copy { grid-column: span 7; }
  .case-opening__figure { grid-column: span 5; }
}
```

Spans such as `[2,8,2]` describe spatial lanes including empty margins. Use grid placement for those margins; do not create empty landmark elements. `[7,5]` describes two information-bearing lanes. Read each section's purpose and element list to map content.

## Order and density

DOM order must match mobile reading and focus order. Do not visually move actions ahead of conditions while leaving keyboard order elsewhere. Use `minmax(0,1fr)`, wrapping labels, `min-inline-size:0` and bounded media to prevent page overflow.

Budgets are planning targets. If copy exceeds them, edit with the author, split the section or move reference detail to a dedicated page. Do not line-clamp essential text or set fixed text heights. Keep prose near 65 characters per line even when images span the page.

Make an index sticky only when it fits and does not obscure focus. Remove sticky behavior on narrow or short screens. Tables can scroll in a named region; the page should not require horizontal scrolling at 320px.

Select a recipe by task, copy, imagery and evidence. Avoid unsupported social proof or repeated decorative cards. See [schema](layout-schema.md) and [quality](quality.md).
