1

I have media queries , but in one, the font-size is not working

     @media only screen and (min-device-width: 375px) and (max-devicewidth:     667px)  
{ 
#topnav             {   padding:0px 0px 0px 0px;}
#topnav a           {   font-size:28px;}
#topnav h1          {   font-size:55px;}
#content            {   float:left;width:100%;margin: 20px 0px  0px 0px;  }
#content p          {   font-size:25px; color: #AAAAAA;text-align:justify;padding:0px 20px 10px 20px; }
#content h1         {   font-size:40px; color: #AAAAAA;line-height:140%;padding:0px 20px 0px 20px;text-align:center; }
Gdg Gdigit
  • 13
  • 5

2 Answers2

1

You have a typo error in max-devicewidth.

You should inspect your #content p element in a browser and look from what line in what css file it takes its font-size attribute, you're probably overriding it somewhere.

EDIT:

how to inspect : if you use chrome, right click on the element, click on inspect. You will have the html page as nodes, in which you can navigate. Be sure you have click on the element you want to inspect, and then look what styles are applied

https://developers.google.com/web/tools/chrome-devtools/inspect-styles/

Damien Bannerot
  • 3,085
  • 3
  • 18
  • 28
0
@media only screen and (max-width: 730px) {

 h2{
        font-size: 4.3vw;
    }

}

Responsive Font Size

Community
  • 1
  • 1
Razia sultana
  • 2,051
  • 3
  • 13
  • 20