Медиа-запросы работают на локальном хосте, но не на сервере - PullRequest
0 голосов
/ 17 декабря 2018

Я ищу несколько других сообщений на эту тему, но все еще не могу заставить мои медиазапросы работать на мобильных устройствах.Я добавил все, что могу придумать, в свою голову и css, но, похоже, ничего не работает.

Вот мой код:

html

<!DOCTYPE html>
<html>

<meta name="viewport" content="initial-scale=1, maximum-scale=1, user- 
scalable=yes">
<link rel="stylesheet" href="https://fonts.googleapis.com/icon? 
family=Material+Icons">
<link rel="stylesheet" type="text/css" href="style.css" media="screen" />
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<body>

css

@media screen and (max-width: 900px) {
.material-icons{
font-size: 100%;
}
.header h1{
margin-top: 5px;
font-size: 150%;
}
}

@media screen and (max-device-width: 750px) {
.material-icons{
font-size: 50%;
}
.header h1{
margin-top: 10px;
font-size: 80%;
}
.main-pic{
    height: 25%;
}
}

@media screen and (max-device-width: 480px){
.material-icons{
display: none;
}
.header h1{
margin-top: 10px;
font-size: 80%;
}

.main-pic{
    height: 25%;
}


}
...