# :hover

Styles an element while the mouse is over it.

## What does `:hover` do?

`:hover` applies styles while the mouse pointer is over an element.

```css
.product-card:hover { box-shadow: 0 4px 12px rgb(0 0 0 / 20%); }
```

Level: Apprentice · [More CSS terms at this level](https://www.ask-codey.com/glossary/subjects/css/apprentice)

Updated: September 27, 2026

Source: https://www.ask-codey.com/glossary/hover
