The build post-processes the rendered HTML with Pillow: real image sizes, loading priority and WebP srcset variants from a content-hash cache.
- Images in the header and the first image of the main content get high fetch priority; the rest load lazily.
- srcset is added only for classes whose CSS sets a definite width; otherwise the browser would take the sizes value as the natural width.