html, body {
    overflow-x: hidden;
}

*, ::before, ::after {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: 'Montserrat', sans-serif;
}

img {
    width: 100%;
    height: auto;
}

h1, h2, h3 {
    margin: 0;
}

.hero {
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    background-color: #f0f0f0; /* Добавлен фон для красоты */
}

.container {
    max-width: 1230px;
    width: 100%;
    margin: 0 auto;
    padding: 0 15px;
}

.hero_container {
    display: flex;
    flex-wrap: wrap; /* Позволяет элементам переноситься на новую строку при недостаточной ширине */
    gap: 20px; /* Заменяем grid-gap на gap для flexbox */
    align-items: center; /* Выравнивание по вертикали */
}

.hero_about {
    flex: 1 1 60%; /* Описание займёт 60% доступного пространства */
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.hero_title {
    margin-bottom: 20px;
    font-size: 48px;
    line-height: 1.1;
}

.hero_subtitle {
    margin-bottom: 10px;
    font-size: 32px;
    font-weight: 400;
}

.hero_description {
    margin-bottom: 10px;
    font-size: 18px;
    line-height: 1.5;
    color: rgb(51, 51, 51);
}

.hero_links {
    display: flex;
    gap: 10px; /* Расстояние между иконками */
    margin-top: 20px; /* Отступ сверху для иконок */
}

.hero_link {
    font-size: 20px;
    color: rgb(51, 51, 51);
    transition: color 0.3s ease;
}

.hero_link:hover {
    color: rgb(24, 24, 24);
}

.hero_box {
    flex: 1 1 40%; /* Изображение займёт 40% доступного пространства */
    max-width: 400px;
    justify-self: center;
    overflow: hidden;
    animation: ava-animate 15s infinite alternate;
    border-radius: 15px; /* Сглаживаем углы изображения */
    background-image: linear-gradient(-20deg, #e9defa 0%, #fbfcdb 100%); /* Фон для красоты */
}

.hero_box-img {
    width: 100%;
    height: auto;
    object-fit: cover;
}

@media screen and (max-width: 750px) {
    .hero {
        padding-top: 30px;
    }

    .hero_container {
        flex-direction: column; /* Элементы располагаются вертикально на маленьких экранах */
        align-items: center; /* Центрируем элементы */
    }

    .hero_title {
        font-size: 28px;
        margin-bottom: 10px;
    }

    .hero_subtitle {
        font-size: 22px;
        font-weight: 400;
    }

    .hero_description {
        font-size: 14px;
    }

    .hero_box {
        max-width: 250px;
    }
}

@keyframes ava-animate {
    0% {
        border-radius: 70% 30% 33% 67% / 67% 67% 33% 33%;
    }
    40% {
        border-radius: 37% 63% 50% 50% / 44% 44% 56% 56%;
    }
    60% {
        border-radius: 60% 40% 70% 30% / 55% 62% 38% 45%;
    }
    100% {
        border-radius: 34% 66% 38% 62% / 43% 37% 63% 57%;
    }
}
