// components/StyledMotion.ts
'use client'

import styled from 'styled-components';
import { motion } from 'framer-motion';
import {darkGreenColor, lightGreenColor} from "@/styles/colors";

export const MotionStartBlock = styled(motion.section)`
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    max-width: 1920px;
    padding: 0 60px;
    margin: 0 auto;
    position: relative;
    width: 100%;
    height: 70vh;
    &::after{
        content: "";
        position: absolute;
        top: -200px;
        left: 50%;
        transform: translateX(-50%);
        width: 100vw;
        height: 1144px;
        background-image: url("/images/startBg.png");
        background-repeat: no-repeat;
        background-size: cover;
        background-position: center;
        z-index: -10;
    }
    img{
        position: absolute;
        z-index: -1;
    }
    img:nth-child(1){
        left: -80px;
    }
    img:nth-child(4){
        right: 40px;

    }
    h1{
        font-size: 64px;
        line-height: 1;
        text-align: center;
        max-width: 648px;
        margin-bottom: 40px;
        span{
            background: linear-gradient(to right, ${lightGreenColor}, ${darkGreenColor});
            -webkit-background-clip: text;
            -webkit-text-fill-color: transparent;
        }
    }

    @media (max-width: 1600px) {
        img:nth-child(4){
            right: 0;
            width: 422px;

        }
        img:nth-child(1){
            width: 452px;
        }
    }
    @media (max-width: 1400px) {
        img:nth-child(4){
            width: 360px;

        }
        img:nth-child(1){
            width: 380px;
        }
        h1{
            font-size: 50px;
            max-width: 508px;
            margin-bottom: 24px;
        }
        button{
            font-size: 32px;
            padding: 16px 38px;
        }
    }
    @media (max-width: 1180px) {
        img:nth-child(4){
            width: 300px;
        }
        img:nth-child(1){
            width: 340px;
        }
        h1{
            font-size: 50px;
            max-width: 508px;
            margin-bottom: 24px;
        }
        button{
            font-size: 32px;
        }
    }
    @media (max-width: 1040px) {
        img:nth-child(4),
        img:nth-child(1){
            display: none;
        }
    }
    @media (max-width: 600px) {
        padding: 0 20px;
        height: 80vh;
        h1{
            font-size: 40px;
            max-width: 400px;
        }
        button{
            font-size: 26px;
            padding: 12px 32px;
        }
    }
    @media (max-width: 418px) {
        h1{
            font-size: 30px;
            max-width: 300px;
        }
        button{
            font-size: 26px;
            padding: 12px 32px;
        }
    }
`;
