@font-face {
    font-family: "Roboto";
    src: url("./assets/fonts/roboto.woff2") format("woff2");
    font-weight: 100 900;
    font-style: normal;
    font-display: swap;
}


:root {
    --color-background-body: #3C4049;
    --color-background-main-display: #494D5E;
    --color-background-section: #2B2D31;
    --color-font-primary: #FFFFFF;
    --color-font-secondary: #000000;
    --color-font-link: #A9BAFF;
    --color-button-background: #FFFFFF;
    --color-button-font: #000000;
    --color-button-hover: #d3dcff;
}


::-webkit-scrollbar {
    display: none;
}


* {
    box-sizing: border-box;
    font-family: "Roboto", sans-serif;
    font-style: normal;
}


body {
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 40px;
    color: var(--color-font-primary);
    background-color: var(--color-background-body);
}


main {
    padding: 120px 0;
    justify-items: center;
    background-color: var(--color-background-main-display);
    overflow: hidden;

    & > div {
        position: relative;
        max-width: 1920px;
        width: 100%;
        padding: 0 clamp(30px, calc(30px + (300 - 30) * ((100vw - 440px) / (1920 - 440))), 300px);
        display: flex;
        align-items: center;

        & > div {
            h1 {
                margin: 0;
                text-indent: -0.06em;
                font-size: clamp(48px, calc(48px + (128 - 48) * ((100vw - 440px) / (1920 - 440))), 128px);
                font-weight: 500;
                line-height: 0.86;
            }

            h2 {
                margin: 0;
                font-size: clamp(24px, calc(24px + (32 - 24) * ((100vw - 440px) / (1920 - 440))), 32px);
                font-weight: 500;
                line-height: 1;

                span {
                    font-weight: 300;
                }
            }

            p {
                width: min(560px, 80%);
                margin: 40px 0;
                font-size: clamp(14px, calc(14px + (16 - 14) * ((100vw - 440px) / (1920 - 440))), 16px);
                line-height: clamp(18px, calc(18px + (21 - 18) * ((100vw - 440px) / (1920 - 440))), 21px);
            }

            a {
                height: 40px;
                padding: 0 40px;
                display: inline-flex;
                align-items: center;
                gap: 10px;
                font-size: 14px;
                font-weight: 500;
                border-radius: 2px;
                color: var(--color-button-font);
                background-color: var(--color-button-background);
                text-decoration: none;
                transition: background-color 0.2s;

                img {
                    width: 16px;
                    height: 16px;
                }

                span {
                    white-space: nowrap;
                }

                &:hover {
                    background-color: var(--color-button-hover);
                }
            }
        }

        & > img {
            position: absolute;
            width: 640px;
            height: 640px;
            right: clamp(-800px, calc(-800px + (300 - -800) * ((100vw - 440px) / (1920 - 440))), 300px);
            opacity: 0.4;
        }
    }
}


section {
    padding: 60px 0;
    justify-items: center;
    background-color: var(--color-background-section);

    & > div {
        max-width: 1920px;
        width: 100%;
        padding: 0 clamp(30px, calc(30px + (300 - 30) * ((100vw - 440px) / (1920 - 440))), 300px);

        h1, p {
            width: min(680px, 100%);
        }

        h1 {
            margin: 0 0 20px 0;
            text-indent: -0.04em;
            font-size: clamp(34px, calc(34px + (48 - 34) * ((100vw - 440px) / (1920 - 440))), 48px);
            font-weight: 500;
        }

        p {
            margin: 0;
            font-size: clamp(14px, calc(14px + (16 - 14) * ((100vw - 440px) / (1920 - 440))), 16px);
            line-height: clamp(18px, calc(18px + (21 - 18) * ((100vw - 440px) / (1920 - 440))), 21px);

            a {
                color: var(--color-font-link);
                transition: color 0.2s;

                &:hover {
                    color: var(--color-button-hover);
                }
            }
        }
    }
}


footer {
    height: 200px;
    padding: 40px 0;
    align-content: end;
    justify-items: center;
    background-color: var(--color-background-section);

    .wrapper {
        max-width: 1920px;
        width: 100%;
        padding: 0 clamp(30px, calc(30px + (300 - 30) * ((100vw - 440px) / (1920 - 440))), 300px);

        div {
            &:nth-child(1) {
                display: inline-flex;
                margin-bottom: 20px;
                flex-direction: column;
                color: var(--color-font-primary);

                h1 {
                    margin: 0 0 2px 0;
                    text-indent: -0.04em;
                    font-size: 24px;
                }

                a {
                    margin: 0;
                    text-indent: -0.04em;
                    font-size: 14px;
                    font-weight: 400;
                    color: inherit;
                    text-decoration: none;

                    &:hover {
                        text-decoration: underline;
                    }
                }
            }

            &:nth-child(2) {
                display: flex;
                align-items: center;
                gap: 10px;

                a {
                    transition: transform 0.2s;

                    img {
                        width: 20px;
                        height: 20px;
                    }

                    &:hover {
                        transform: scale(1.2, 1.2);
                    }
                }
            }
        }
    }
}


@media screen and (max-width: 980px) {
    main {
        & > div {
            & > img {
                display: none;
            }
        }
    }
}