Hover css code for SVG element

It’s hard to tell without seeing the HTML code, but it looks like you’ve a typo in your CSS code:

.svg would refer to a class called “svg”, I assume you intend to target the svg element directly, so you need to omit the dot.

.svg:hover{} would target <svg class="svg"></svg>
svg:hover{...} would target <svg></svg>.

You most likely need the latter.

1 Like