The any-hover
media feature detects if any input device can hover over elements—unlike hover
, which checks the primary pointer only. It's useful for building responsive interfaces that adapt to hybrid devices (e.g. laptops with touchscreens).
Example: @media (any-hover: hover) { ... }
lets you safely apply hover styles only when at least one input supports it.