пофикины размер контактной формы, цвет бургера в моб. версии, убрана анимация ToTop

This commit is contained in:
mimi committed 2025-03-06 16:16:23 +03:00
1 parent a6ce0fc330
commit cba5165193
4 files changed
+52 -48

No files matched your search

@@ -6,11 +6,8 @@ $color-file-button: rgb(7, 42, 200);
.contact-form {
padding: 20px 22px;
border-radius: 16px;
height: 730px;
height: 100%;
background-color: $bg-form;
@media (max-width: 768px) {
height: 100%;
}
h2 {
margin-top: 0;
@@ -122,7 +119,6 @@ $color-file-button: rgb(7, 42, 200);
}
.submit-container {
//overflow: hidden;
.submit {
width: 100%;
cursor: pointer;
@@ -132,6 +128,7 @@ $color-file-button: rgb(7, 42, 200);
line-height: normal;
}
}
margin-bottom: 5%;
}
}
+16 -5
View File
@@ -7,7 +7,7 @@
width: 100%;
height: 108px;
padding: $navbar-padding-tb 10%;
background-color:rgb(255, 255, 255);
background-color: rgb(255, 255, 255);
z-index: 100;
display: flex;
@@ -27,13 +27,25 @@
&.transparent {
background-color: transparent !important;
transition: none;
.bar .nav-link {
.bar .nav-link {
color: $text-secondary;
@media (max-width: 768px) {
color:black;
color: black;
}
}
@media (max-width: 768px) {
.burger .line {
background-color: #ffffff;
&.open {
background-color: #072ac8; // Синий цвет, когда меню открыто
}
}
}
.logo {
filter: brightness(0) invert(1);
}
@@ -71,13 +83,12 @@
}
}
// Телефонна версия
@media (max-width: 768px) {
height: $navbar-height;
padding: $navbar-padding-tb 5%;
.nav-link:has(> .logo) .logo {
width: $navbar-logo-mini-height; // 100%
width: $navbar-logo-mini-height;
}
.bar {
+30 -18
View File
@@ -29,22 +29,21 @@ body {
display: flex;
flex-direction: column;
// Телефонная версия
@media (max-width: 768px) {
top: 30%;
padding: $navbar-padding-tb 5%;
}
h1 {
font-size: 52px; //
font-size: 52px;
font-weight: 600;
line-height: 63px; //
line-height: 63px;
margin: 0;
margin-bottom: 24px;
@media (max-width: 768px) {
font-size: 32px; // Уменьшаем размер шрифта на мобильных устройствах
line-height: 40px; // Уменьшаем межстрочное расстояние
font-size: 32px;
line-height: 40px;
}
}
@@ -70,6 +69,7 @@ body {
.block {
background: transparent !important;
h1 {
font-family: Montserrat;
font-size: 36px;
@@ -79,7 +79,7 @@ body {
margin-bottom: 1.5rem;
@media (max-width: 768px) {
font-size: 24px; // Уменьшаем размер заголовка на мобильных
font-size: 24px;
}
@@ -115,12 +115,22 @@ body {
@media (max-width: 768px) {
#mainpageheader {
padding: 0; // Уменьшаем padding на мобильных устройствах
padding: 0;
}
}
.block:not(:last-child) {
margin-bottom: 32px;
}
@media (max-width: 768px) {
#mainpageheader {
padding: 0;
}
}
#news-list {
position: relative; // Убедитесь, что у #news есть relative
position: relative;
&::before {
content: "";
@@ -142,17 +152,19 @@ body {
}
.row .card {
width: calc(25% - $news-card-gap); // 4 карточки в ряд
aspect-ratio: 1 / 0.8973; // Карточка всегда квадратная
@media (max-width: 768px) {
width: 100%; // 1 карточка в ряд на мобильных
margin-bottom: 1em;
}
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;
@@ -210,18 +222,18 @@ body {
position: absolute;
top: 35%;
left: 0;
width: 100%; // Увеличиваем ширину на 10%, чтобы занять отступ
width: 100%;
height: 307px;
background-image: url('../../assets/images/backround/bg_gallery_block.svg');
background-repeat: no-repeat;
background-position: right center;
background-size: contain; // Или cover, если нужно заполнить область
background-size: contain;
z-index: -1;
transform: translateX(12.5%); // Смещаем влево, компенсируя padding
transform: translateX(12.5%);
@media (max-width: 768px) {
display: none; // Скрываем картинку на мобильных
display: none;
}
}
}
+4 -20
View File
@@ -55,28 +55,12 @@ function Root() {
// Ускоренный плавный скролл вверх
const scrollToTop = () => {
const startPosition = window.scrollY;
const startTime = performance.now();
const scrollDuration = 800; // Увеличили время для суперплавности
// Функция плавного ускорения и замедления (easeInOutCubic)
const easeInOutCubic = (t) => t < 0.5 ? 4 * t * t * t : 1 - Math.pow(-2 * t + 2, 3) / 2;
const animateScroll = (currentTime) => {
const elapsedTime = currentTime - startTime;
const progress = Math.min(elapsedTime / scrollDuration, 1); // От 0 до 1
window.scrollTo(0, startPosition * (1 - easeInOutCubic(progress))); // Гладкий скролл
if (progress < 1) {
requestAnimationFrame(animateScroll);
}
};
requestAnimationFrame(animateScroll);
window.scrollTo({
top: 0,
behavior: 'instant'
});
};
return (
<RootContext.Provider value={{ setRef }}>
<Navbar />