Layout adapts when device is rotated to landscape
Why it matters
A hero section with height: 100vh becomes roughly 350px tall when the user rotates their phone to landscape. Headline, subhead, and CTA button get crammed into that tiny vertical window — often only the headline remains visible, with the CTA below the fold. 100vh also misbehaves on iOS Safari because mobile browser chrome shrinks and grows dynamically. 100dvh (dynamic viewport height) is the modern replacement that handles both cases correctly.
Severity rationale
Info because landscape use on phones is a minority of sessions, but the fix is cheap and worth doing.
Remediation
Replace height: 100vh with min-height: 100dvh so content can grow past the viewport when necessary, and add a landscape media query to reduce padding on short viewports. Update hero and full-screen overlay components in src/components/.
.hero { min-height: 100dvh; }
@media (orientation: landscape) and (max-height: 500px) {
.hero { min-height: auto; padding: 3rem 0; }
}
Detection
-
ID:
landscape-support -
Severity:
info -
What to look for: Check for landscape-specific media queries (
@media (orientation: landscape)or@media (max-height: 500px)) in CSS. In Tailwind, look forlandscape:variant usage. Examine whether fixed-height elements (hero sections withheight: 100vh, modals, full-screen overlays) would become unusably cramped in landscape orientation on phones where viewport height drops to 300-500px. -
Pass criteria: Count all
height: 100vhandh-screendeclarations in the project. For each, classify as "content element" (renders text/interactive content) or "background wrapper" (purely decorative). No more than 0 content elements may useheight: 100vhwithout a landscape media query override ormin-height: 100dvhalternative. Report even on pass: "Found X instances of height: 100vh/h-screen; Y are content elements, Z have landscape overrides." -
Fail criteria: At least 1 content element uses
height: 100vh(or Tailwindh-screen) without a landscape media query override ormin-height: 100dvhalternative — content becomes cramped at approximately 350px height in landscape on phones.Pass when: No
height: 100vhusage found, ORheight: 100vhis accompanied by landscape adjustments, ORmin-height: 100dvhis used instead. -
Skip (N/A) when: Never — check for landscape media queries in the codebase. Full visual verification across device rotations requires live URL testing.
-
Detail on fail:
"Hero section uses height: 100vh (or h-screen) with no landscape override — 1 of 3 content elements becomes approximately 350px tall in landscape on phones". -
Remediation:
.hero { min-height: 100dvh; /* dynamic viewport height */ } @media (orientation: landscape) and (max-height: 500px) { .hero { min-height: auto; padding: 3rem 0; } }In Tailwind:
<section class="min-h-screen landscape:min-h-0 landscape:py-12">
Taxons
History
- 2026-04-18·v1.0.0·Initial import from mobile-responsiveness·automated