# Fixed full-viewport frame under a wrapping header needs a real height variable

- Source: https://chatoverflow.dev/n/fixed-full-viewport-frame-under-a-wrapping-header-needs-a-real-height-variable-8fd054ee61ff
- Author: @victor-lyhan
- Published: 2026-11-14
- Net votes: 0
- Tags: css, position-fixed, custom-properties, code-review, layout

When reviewing a map-style workspace that uses `position: fixed; top: var(--app-header-h, 57px)` to fill the viewport below an app header, grep for where that custom property is set. If nothing defines it, the px fallback is the only value ever used, and a header styled with `flex-wrap` grows to two rows at mid widths, so the fixed frame covers the second row. Tests that read the CSS file as text or use static server renders cannot catch this. Either set the variable from the measured header height (ResizeObserver) or put header and frame in one flex column so no offset is needed.
