@DannYLook
Программист

Почему media запрос перекрывает стили под другой экран?

У меня есть css код с media запросами:

media screen and (min-width: 1440px) { } @media screen and (max-width: 1280px) { } @media screen and (max-width: 1024px) { }

Перед всеми этими запросами есть еще код:
.descriptionOne{
    /* Новый формат. Впервые в Израиле */


position: absolute;
width: 999px;
height: 55px;
left: 370px;
top: 304px;

font-family: 'Raleway';
font-style: normal;
font-weight: 400;
font-size: 22px;
line-height: 55px;
/* identical to box height, or 250% */


color: #FFFFFF;
}



.poragraf{
    position: absolute;
    width: 657px;
    height: 225px;
    left: 370px;
    top: 307px;
    
    font-family: 'Raleway';
    font-style: normal;
    font-weight: 700;
    font-size: 64px;
    line-height: 75px;
    
    color: #FFFFFF;

}

.descriptionTwo{
    position: absolute;
width: 633px;
height: 55px;
left: 370px;
top: 590px;

font-family: 'Raleway';
font-style: normal;
font-weight: 400;
font-size: 22px;
line-height: 55px;
/* identical to box height, or 250% */


color: #FFFFFF;
}

.Button{
    cursor: pointer;
box-sizing: border-box;

position: absolute;
width: 326px;
height: 56px;
left: 370px;
top: 701px;

border: 2px solid #FBB03B;
filter: drop-shadow(0px 4px 10px rgba(0, 0, 0, 0.15));
border-radius: 30px;
}

.ButtonText{
/* Получить презентацию */

cursor: pointer;
position: absolute;
width: 218px;
height: 23px;
left: 413px;
top: 705px;

font-family: 'Raleway';
font-style: normal;
font-weight: 400;
font-size: 20px;
line-height: 23px;
text-align: center;

color: #FFFFFF;
}
.ButtonTextTwo{
    /* Vector 662 */

    cursor: pointer;

position: absolute;
width: 6px;
height: 14px;
left: 647px;
top: 722px;
}

.descriptionTree{
    /* Кофейня самообслуживания UpCup */


position: absolute;
width: 382px;
height: 55px;
left: 370px;
top: 757px;

font-family: 'Raleway';
font-style: normal;
font-weight: 400;
font-size: 22px;
line-height: 55px;
/* identical to box height, or 250% */


color: #FFFFFF;
}

.Stacan2{
    /* СТАКАН 2 */


position: absolute;
width: 121.59px;
height: 161.32px;
left: 1045.58px;
top: 321.69px;

filter: blur(5px);
transform: rotate(-20.91deg);
}

.Vector{
    /* Vector */
    height: 595.4396419788378px;
    width: 592.281682963976px;
    left: 1170px;
    border-radius: 0px;
    
    position: absolute;
    right: 0.1%;
    top: 153px;
    bottom: 89.9%;
    
    background: rgba(22, 22, 22, 0.01);
    transform: rotate(42.19deg);
    
}

.CofeeAvt{
    /* 5 2 */


position: absolute;
width: 503.53px;
height: 761.2px;
left: 1114.46px;
top: 141px;

transform: rotate(6.6deg);
}

.Stacan1{
    /* СТАКАН 1 */


position: absolute;
width: 168.6px;
height: 223.7px;
left: 1560.26px;
top: 456px;

transform: rotate(18.85deg);
}
.Elipse{

/* Ellipse 999 */


position: absolute;
width: 918px;
height: 918px;
left: 1350px;
top: 496px;

background: rgba(145, 94, 254, 0.4);
filter: blur(300px);    
}

.modal { 
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: #1C1C1C;
    width: 480px;
    height: 420px;
    border-radius: 15px;
    overflow: hidden;
    z-index: 9999; /* добавлено для уверенности */
  }

  .InputOne{
    position: absolute;
width: 473px;
height: 81px;
top: 70px;
outline: none;
border: none;

background: rgba(21, 21, 21, 0.75);
border-radius: 39px;
margin-bottom: 10px;

}

.InputTwo{
    outline: none;
    border: none;

position: absolute;
width: 473px;
height: 81px;
top: 165px;

background: rgba(21, 21, 21, 0.75);
border-radius: 39px;
margin-bottom: 10px;

}

.InputThree{
    position: absolute;
width: 473px;
height: 81px;
top: 260px;
border: none;

    outline: none;
background: rgba(21, 21, 21, 0.75);
border-radius: 39px;
margin-bottom: 10px;

}
.PriceButtonTextForm{
    position: absolute;
    width: 156px;
    height: 23px;
    top: 360px;
    left: 155px;

    font-family: 'Raleway';
    font-style: normal;
    font-weight: 400;
    font-size: 20px;
    line-height: 23px;
    text-align: center;
    cursor: pointer;
    color: #000000;
}

.PriceButtonForm{
    position: absolute;
    width: 326px;
    height: 56px;
    left: 70px;
    top: 360px;
    cursor: pointer;
    background: #FBB03B;
    box-shadow: 0px 4px 10px rgba(0, 0, 0, 0.15);
    border-radius: 30px;
}

.iconsOut{
    cursor: pointer;
    position: absolute;
    right: 20px;
    bottom: 345px;
}

.SendMessage{
    color: chartreuse;
    margin-left: 150px;
    
}

У меня стили (min-width: 1440px) работают хорошо, как сделать, чтобы первые стили перед этими всеми запросами работали под экран 1920x1080px c расширением 2910 1080? Я думаю, скорее всего дело в масштабе, так как у меня экран 1920x1080px и все хорошо отображается. Пример как отображается у меня:

649e9f49d55d2285487700.png
Как у человека с 1920x1080px c расширением 2910 1080:

649e9f93e07b7849148232.jpeg
И если у брать все media запросы и оставить код выше, то все будет ок. Как сделать, чтобы под 1920x1080px c расширением 2910 1080 код выше отображался корректно? Весь код оставлю в комментариях из-за ограничения.
  • Вопрос задан
  • 72 просмотра
Решения вопроса 1
@DannYLook Автор вопроса
Программист
media (min-width: 1920px){
// Код для 1920px
}
media screen and (min-width: 1440px) and (max-width: 1919px) {
}
Ответ написан
Комментировать
Пригласить эксперта
Ваш ответ на вопрос

Войдите, чтобы написать ответ

Войти через центр авторизации
Похожие вопросы