Search code examples
cssresponsive-designmedia-queriesresponsivelimit

media query is not working, is there a limit per page?


When i make the responsive of my web-site, some media query works but the last ones don't.

/* work */
@media screen and (max-width: 1030px){

    .section2 .content-card .title-card img {
        max-width: 200px;
    }

    .section1 {
        height: 1000px;
    }
}

/* doesn't work */

@media screen and (max-width: 1030px){
    .section2 {
        padding-top: 15vh;
    }
}

@media screen and (max-width: 260px){
    .section2 {
        padding-top: 6vh;
    }

    .section1 {
        padding-top: 3vh;
    }
}
In my code there are many more media queries but I had to remove them because of the code limits on the question.

Is there a limit to the number of media queries per file?


Solution

  • See attached picture. This shows that it is working.

    enter image description here