Forum:Hovered link style

I added a line in my CSS to have dotted border on hovered links.

But this also applies to images which are links! I didn't expect that so I tried
 * and

But none of them seemed working. How to avoid having border on images?