If you look in desktop, there’s a red navigation bar at the top of the site. I have replaced this with a drop down menu for smaller displays but for some reason I cannot hide this one!
I have used @media statements to set the display to none for everything under 1024px but it’s still there!!!
Here is the code:
/*
GLOBAL STYLES
----------------
Add styles beneath this line that you want to be applied across your entire site */
div.drop {
display: none;
}
@media only screen and (min-width: 768px) {
div.drop {
display: none;
}
}
@media only screen and (min-width: 1024px) {
div.drop {
display: block;
}
}
I cannot see why it would still be displaying the div.drop on smaller screens when it’s clearly set to none.
Why would they be overriding it when that media query is set for a min wider of 1024px? Also there are other elements that are hidden on the smaller screen and those are working as intended.
In that same style sheet I have .header-text-container-right set to display “none” in the lower screen sizes and in the desktop media query it is set to “block”. That is working exactly as intended. I use the same technique on the div.drop and it doesn’t work! It makes no sense. That’s the whole point of media queries.
Ahh I found the culprit. There was a rogue “}” in there ending the 1024px media query prematurely. I have moved it to it’s rightful position and all is working fine now.