CSS Vertical Menu on Hover and Focus
Expanding vertical menu playground
Hover the rail or Tab to a navigation link. Use the checkbox for a persistent expanded view. Links jump to the example sections shown beside or below the menu.
Overview
A compact rail expands to reveal labels. The wide layout reserves room, so the menu does not cover this content.
Examples
Hover the rail with a mouse, Tab through its links, or keep labels visible with the checkbox above.
Source
The downloadable project is plain HTML and CSS. Its four links navigate to these example sections.
Accessibility
Real links retain their names when labels are visually clipped. Small and touch screens show all labels by default.
At narrow widths and on touch-oriented devices, labels remain visible automatically. Unchecking the box cannot collapse that layout. No JavaScript, external icons or fonts are required.