- This topic is empty.
Viewing 5 posts - 1 through 5 (of 5 total)
Viewing 5 posts - 1 through 5 (of 5 total)
- The forum ‘CSS’ is closed to new topics and replies.
The forums ran from 2008-2020 and are now closed and viewable here as an archive.
Hi
I am dealing with the margins of the header and I have put on my custom stylesheet this:
@media screen and (max-width: 760px) {
#header {margin: 0 -10px 0 -10px;}
However it doesn’t apply. When I inspect the header on chrome I see that I have this:
@media screen and (max-width: 760px) {
#header {margin: 0;}
And the other querie that I put appears under strikethrough. How do I do to remove the margin 0 querie? Should I edit the original stylesheet directly?
Thanks
We would need to see the site but it’s possible you have missed a closing “brace”
}
I have checked that but I think it is ok.
The website is http://www.abaratando.com
Thanks again
One way to deal with this would be to add !important
to the end of it:
@media screen and (max-width: 760px) {
#header {margin: 0 -10px 0 -10px!important;}
Although I don’t like to use that method because it can make things difficult to follow in the future.
As an alternative, I am looking at your responsive.css stylesheet now and your issue appears to be on line 185. Just remove (or comment out) this line, margin: 0;
. This should be an ok thing to do because it will only effect the #header which is what you want.
Thanks!
I did both things and it worked with the “!important”
:)