Jump to content

Adding hover color to existing custom H2 code

Recommended Posts

Site URL: https://www.menswearmag.com

I'm having issues with the custom H2 code when it comes to the link hover color.

For the labels on my site 'Fashion, Grooming, etc.' they link to further category pages.

However, the hyperlink has a preset of a dark grey that doesn't show against the custom black background of the H2 text blocks. 

Here is the code I am using for those blocks: 

h2 { font-weight: 400;
   color: white;
  background: #191919;
  &:hover color: white
padding-top: -2px;
padding-right: 0px;
padding-bottom: -2px;
padding-left: 7px; 
text-align: left;

It works perfectly fine except for hover color - I need to somehow add the custom link hover color so that I can change that to white as well. I've tried the &:hover {color: #FFFFFF} but it breaks the code each time. Would anyone be able to help with this? 

Link to comment
  • Replies 1
  • Views 271
  • Created
  • Last Reply


This topic is now archived and is closed to further replies.

  • Create New...

Squarespace Webinars

Free online sessions where you’ll learn the basics and refine your Squarespace skills.

Hire a Designer

Stand out online with the help of an experienced designer or developer.