Links can exist in different states — link, visited, active, hover, and focus. These states of a link or hyperlink can be styled using pseudo-classes, depending on what state they are in.
Following are the different states, we are already discuss in HTML Links.
Note: The order of the pseudo-classes should be the following: : link, : visited, : hover, : active, : focus in order for these to work properly.
This CSS color property is used to change the color of the link or hyperlink text. If you are not set the color of links, the browser uses the default link colors.
The background-color property is used to set the background color for links.
The text-decoration property is generally used to remove the default underlines from links.
The following example shows how to remove or set the text-decoration property.
This property is defined to change the font type of a link using the font-family property.