# Writing

Posts and short notes by Hassan Hafez on building products, from pixels to production.

## Posts

- [How I built two Claude Code mods to stay focused](https://hassanhafez.com/writing/how-i-built-two-claude-code-mods-to-stay-focused) (2026-10-30): Why a Pomodoro timer and a context meter ended up inside Claude Code, and how I built them to stay at the edge of my attention.

## Nuggets

### `text-wrap: balance` ends the one-word last line

2026-10-16 · CSS, Typography

Use it on headings. Browsers cap it at a few lines, so it is cheap.

```
h1, h2 { text-wrap: balance; }
```

### `inert` beats `aria-hidden` for off-screen UI

2026-10-09 · Accessibility, HTML

One attribute removes the element from the tab order and the accessibility tree, so nothing can focus into a hidden panel.

### `scrollbar-gutter: stable` stops the layout shift

2026-10-02 · CSS

Reserve the scrollbar’s space up front and the page stops jumping when content grows past the fold.
