@import "../../assets/styles/theme.scss"; $news-card-gap: 1em; body { overflow-x: hidden; // Скрываем горизонтальный скролл } #react-page:has(> #mainpageheader) { margin-top: 0; #mainpageheader { position: relative; height: 100vh; padding: 0 10%; margin: 0; color: $text-secondary; background-image: url(/assets/images/car.jpeg); background-color: $bg-image; background-blend-mode: multiply; background-position: center; background-size: cover; .container { position: absolute; top: 40%; display: flex; flex-direction: column; // Телефонная версия @media (max-width: 768px) { top: 30%; padding: $navbar-padding-tb 5%; } h1 { font-size: 52px; // font-weight: 600; line-height: 63px; // margin: 0; margin-bottom: 24px; @media (max-width: 768px) { font-size: 32px; // Уменьшаем размер шрифта на мобильных устройствах line-height: 40px; // Уменьшаем межстрочное расстояние } } h2 { font-size: 24px; font-weight: 400; line-height: 36px; @media (max-width: 768px) { font-size: 24px; line-height: 28px; } } .btn { margin: 0; margin-top: 24px; } } } .block { background: transparent !important; h1 { font-family: Montserrat; font-size: 36px; font-weight: 600; margin-top: 1.5rem; margin-bottom: 1.5rem; @media (max-width: 768px) { font-size: 24px; // Уменьшаем размер заголовка на мобильных } } .heading { display: flex; justify-content: space-between; align-items: center; a { font-size: 20px; font-weight: 500; text-align: right; color: $text-primary; @media (max-width: 768px) { font-size: 16px; } } } #news-list .row { grid-template-columns: repeat(4, calc((100% - $news-card-gap * 3) / 4)); justify-content: space-between; gap: $news-card-gap; } } .block:not(:last-child) { margin-bottom: 32px; } @media (max-width: 768px) { #mainpageheader { padding: 0; // Уменьшаем padding на мобильных устройствах } } #news-list { position: relative; // Убедитесь, что у #news есть relative &::before { content: ""; position: absolute; top: 0%; left: 0; width: 100%; height: 364px; background-image: url('../../assets/images/backround/bg_news_block.svg'); background-repeat: no-repeat; background-position: left center; background-size: contain; z-index: -1; transform: translateX(-12.6%); @media (max-width: 768px) { display: none; } } .row .card { width: calc(25% - $news-card-gap); // 4 карточки в ряд aspect-ratio: 1 / 0.8973; // Карточка всегда квадратная @media (max-width: 768px) { width: 100%; // 1 карточка в ряд на мобильных margin-bottom: 1em; } } } .project-list { position: relative; &::before { content: ""; position: absolute; top: 35%; left: 0; width: 100%; // Увеличиваем ширину на 10%, чтобы занять отступ height: 465px; background-image: url('../../assets/images/backround/bg_projects_block.svg'); background-repeat: no-repeat; background-position: right center; background-size: contain; // Или cover, если нужно заполнить область z-index: -1; transform: translateX(11.3%); // Смещаем влево, компенсируя padding @media (max-width: 768px) { display: none; // Скрываем картинку на мобильных } } } .row.lab-list { position: relative; &::before { content: ""; position: absolute; top: 10%; left: 0; width: 100%; // Увеличиваем ширину на 10%, чтобы занять отступ height: 436px; background-image: url('../../assets/images/backround/bg_labs_block.svg'); background-repeat: no-repeat; background-position: left center; background-size: contain; // Или cover, если нужно заполнить область z-index: -1; transform: translateX(-11.6%); // Смещаем влево, компенсируя padding @media (max-width: 768px) { display: none; // Скрываем картинку на мобильных } } } #gallery { margin-left: 0; margin-right: 0; position: relative; &::before { content: ""; position: absolute; top: 35%; left: 0; width: 100%; // Увеличиваем ширину на 10%, чтобы занять отступ height: 307px; background-image: url('../../assets/images/backround/bg_gallery_block.svg'); background-repeat: no-repeat; background-position: right center; background-size: contain; // Или cover, если нужно заполнить область z-index: -1; transform: translateX(12.5%); // Смещаем влево, компенсируя padding @media (max-width: 768px) { display: none; // Скрываем картинку на мобильных } } } }