Length 9:37Quick guide to CSS focus states
About this video
Kevin Powell explains the differences between the CSS pseudo-classes :focus, :focus-within and :focus-visible and what each one lets you style. It is aimed at developers and designers who already write CSS.
What you’ll learn
- Style an element when it or a child receives focus with :focus-within
- Apply focus styles only for keyboard users with :focus-visible
- Tell apart :focus, :focus-within and :focus-visible in a form and menu










