Support » Theme: Astra » Astra, header, menue, changing font colours, hover?

  • Resolved clavigo

    (@clavigo)


    Hi everybody,
    I need help with the folllowing issue:
    In the header of the Astra theme, I want to change the font colours of the main menue with custom css, because this is not possible within the customizer (unless you have pro…).
    With this code, it worked well to change the colour of the menue font:

    .main-header-menu a {
    color: #990066;
    }

    Now I also want to change the colour when moving the mouse over the menue:

    .main-header-menu a:hover {
    color: #ff9933;
    }

    But this did not work…
    What am I doing wrong?

    In fact there are a “link colour” and “hover colour” in the customizers general colours, but these do not affect the hover colour in the header menue…
    Any ideas?

    Thank you in advance,
    Tobias

Viewing 2 replies - 1 through 2 (of 2 total)
  • clavigo

    (@clavigo)

    Hi everybody,

    I solved this already by myself 🙂
    I used the following code and it worked:

    .main-header-menu a:hover {
    color: #ff9933 !important;
    }

    I have learned that sometimes there can be a piece of code somewhere in the style sheet, that has a higher priority and overruns custom css settings.
    This is new to me. I always thought that any css written in the customizer would overrun the basic css of the theme.
    So if you use “!important”, you can force in your changes.

    Regards, Tobias

    deepakl

    (@deepakl)

    Hi @clavigo,

    Glad that you were able to solve your issue. Yes, using !important is not considered always a good practice, but to overwrite some predefined code you can do that.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Astra, header, menue, changing font colours, hover?’ is closed to new replies.