Site logo

Archived topic

Menu CTA

3 replies · Started by scott doel on July 27, 2019

Viewing posts 1–4 of 4

Having a really stupid brain fade and cant use the tutorial here to create a solid colour button which changes colour on hover. Can I be cheeky and ask for the CSS please?

I wanted the normal colour to be #1e6fb7 and on hover to be #66A1D5

Hi there,

You currently have this CSS:

@media (min-width: 769px) {
    .main-navigation .main-nav ul li.nav-button a, .main-navigation .main-nav ul li.nav-button a:hover, .main-navigation .main-nav ul li.nav-button a:focus {
        border: 2px solid #ffffff;
        color: #ffffff;
        margin: 10px 5px 10px 5px;
        line-height: 35px;
    }
}

Try replacing it with this:

@media (min-width: 769px) {
    .main-navigation .main-nav ul li.nav-button a {
        border: 2px solid #ffffff;
        color: #ffffff;
        margin: 10px 5px 10px 5px;
        line-height: 35px;
        background: #1e6fb7;
    }

    .main-navigation .main-nav ul li.nav-button:hover a, 
    .main-navigation .main-nav ul li.nav-button:focus a {
        background: #66A1D5;
    }
}

Amazing! Thanks Tom

You're welcome :)

This archived topic is closed to new replies.