/**
 * Hero
 */
.lineParent {
    overflow: hidden;
}

.home-hero {
    position: relative;

    .hero_background {
        width: 100%;
        height: 100vh; /* Fallback for browsers that do not support Custom Properties */
        height: calc(var(--vh, 1vh) * 100);
        position: relative;

        .hero_overlay {
            width: 100%;
            height: 101%;
            position: absolute;
            top: 0;
            left: 0;
            background: linear-gradient(0deg, rgba(16,16,16,1) 0%, rgba(16,16,16,0) 70%);
            z-index: 1;

            &::after {
                content: '';
                width: 100%;
                height: 100%;
                position: absolute;
                top: 0;
                left: 0;
                background: rgba($black-color, 0.2);
            }
        }

        .hero_image {
            width: 100%;
            height: 100%;
            position: relative;
            overflow: hidden;

            img {
                width: 100%;
                height: 100%;
                position: absolute;
                top: 0;
                left: 0;
                object-fit: cover;
            }
        }
       
    }

    .hero_logo{
        position: absolute;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%);
        z-index: 2;

        .logo {
            display: none;

            @include resp-min($breakpoint-xlarge) {
                display: block;
                opacity: 0;
                animation: fadeIn 1s ease-in-out forwards;
                animation-delay: 0.5s;

                @keyframes fadeIn {
                    from {
                        opacity: 0;
                        transform: translateY(10px);
                    }
                    to {
                        opacity: 1;
                        transform: translateY(0);
                    }
                }
            }
        }

        .logo-small {
            display: block;

            @include resp-min($breakpoint-medium) {
                transform: scale(1.5);
            }

            @include resp-min($breakpoint-large) {
                transform: scale(2.5);
            }

            @include resp-min($breakpoint-xlarge) {
                display: none;
            }
        }
    }

    .hero_scroll {
        width: 2px;
        height: 40px;
        display: block;
        position: absolute;
        bottom: #{$base-spacing-unit*2};
        left: 50%;
        transform: translateX(-50%);
        background: rgba($white-color, 0.25);
        overflow: hidden;
        z-index: 3;

        &::after {
            content: '';
            width: 100%;
            height: 50%;
            position: absolute;
            top: 0;
            left: 0;
            background: $white-color;
            animation: scroll 2s infinite;
        }

        @keyframes scroll {
            from{transform: translateY(-100%);}
            to{transform: translateY(200%);}
        }
    }
}


/**
 * Mission 
 */

.home-mission {
    @include resp-min($breakpoint-medium) {
        padding: #{$base-spacing-unit*3} 0;   
    }

    .cell:first-child {
        order: 2; 

        @include resp-min($breakpoint-medium) {
            order: 0;
        }
    }

    .mission__info {
        padding: #{$base-spacing-unit*3} $base-spacing-unit #{$base-spacing-unit*2};

        @include resp-min($breakpoint-medium) {
            padding: #{$base-spacing-unit*3} 0 #{$base-spacing-unit*2};
        }

        @include resp-min($breakpoint-large) {
            padding: #{$base-spacing-unit*4} 0;   
        }
    }
}


/**
 * Factory
 */

.home-factory {
    position: relative;
    padding: #{$base-spacing-unit*3} 0 0;

    @include resp-min($breakpoint-medium) {
        padding: #{$base-spacing-unit*3} 0;
    }

    @include resp-min ($breakpoint-large) {
        padding: #{$base-spacing-unit*3} 0 0;
    }

    &:after {
        content: '';
        width: 100%;
        height: #{$base-spacing-unit*3};
        background: $white-color;
        position: absolute;
        bottom: 0;
        left: 0;
        z-index: 1;
        display: none;
        
        @include resp-min($breakpoint-large) { display: block; }
    }

    .grid-container {
        position: relative;

        .rotating-text {
            display: none;
            
            // svg { animation: rotate 10s linear infinite; }

            // @keyframes rotate {
            //     from { transform: rotate(360deg); }
            //     to { transform: rotate(0); }
            // } 

            @include resp-min($breakpoint-large) {
                display: block;
                width: 300px;
                position: absolute;
                top: -#{$base-spacing-unit*7};
                right: #{$base-spacing-unit*2};
            }

            @include resp-min($breakpoint-xlarge) {
                width: fit-content;
                right: 0;
            }
        }

        .parallax-wrapper {
            position: relative;
            z-index: 4;
        }

        .factory__info {
            padding: 0 $base-spacing-unit #{$base-spacing-unit*2};

            @include resp-min($breakpoint-medium) {
                padding: $base-spacing-unit 0 #{$base-spacing-unit*2};
            }

            @include resp-min($breakpoint-large) {
                padding: #{$base-spacing-unit*4} 0 0;
            }
        }
    }
}

/**
 * Production
 */

 .home-production {
    background: $black-color;
    padding: 0 $base-spacing-unit #{$base-spacing-unit*5};

    @include resp-min($breakpoint-medium) {
        padding: 0 0 #{$base-spacing-unit*5};
    }

    @include resp-min($breakpoint-large) {
        padding: #{$base-spacing-unit*5} 0 #{$base-spacing-unit*12};
        background: none;
    }

    .grid-container {
        display: flex;
        flex-direction: column;

        @include resp-min($breakpoint-large) {
            position: relative;
            display: block;
        }
    }

    .grid-absolute {
        order: -1;

        @include resp-min($breakpoint-large) { 
            width: 100%;
            position: absolute;
            bottom: -25%;
            left:  0;
            z-index: 2;
        }

        .production__info {
            padding: #{$base-spacing-unit*3} 0 #{$base-spacing-unit*2};

            @include resp-min($breakpoint-large) {
                padding: #{$base-spacing-unit*2.5};
            }
        }
    }

    .production__slideshow {
        width: 100%;
        position: relative;
        
        .swiper-container {
            height: 100%;
            width: 100%;
            overflow: visible !important;
    
            .swiper-slide {
                .image-wrapper {
                    height: 260px ;
                    width: 100%;
                    position: relative;

                    @include resp-min($breakpoint-medium) {
                        height: 380px;
                    }
            
                    @include resp-min($breakpoint-large) {
                        height: 640px;
                    }

                    img {
                        width: 100%;
                        height: 100%;
                        position: absolute;
                        top: 0;
                        left: 0;
                        object-fit: cover;
                    }
                }

                .slide-caption {
                    font-size: 16px;
                    display: block;
                    max-width: 460px;
                    margin-top: $base-spacing-unit;
                    color: $white-color;
                    transition: all 0.2s ease-in-out;

                    @include resp-min($breakpoint-large) { color: $black-color; }

                    @include resp-min($breakpoint-xlarge) { font-size: 18px; }
                }
            }
        }

        .prod-swiper-nav {
            svg path { fill: $white-color; }

            @include resp-min($breakpoint-large) {
                svg path { fill: $black-color; }
            }
        }
    }
}


/**
 * Services
 */

.home-services {
    padding: #{$base-spacing-unit*3} $base-spacing-unit #{$base-spacing-unit*5};

    @include resp-min($breakpoint-medium) {
        padding: #{$base-spacing-unit*3} 0 #{$base-spacing-unit*5};
    }

    @include resp-min($breakpoint-large) {
        padding: #{$base-spacing-unit*8} 0;
    }

    .services__slideshow {
        width: 100%;
        position: relative;
        margin-top: #{$base-spacing-unit*2};

        .swiper-pagination {
            font-weight: bold;
            position: absolute;
            top: -#{$base-spacing-unit*2};
            left: 0;
            display: flex;
            flex-direction: row;
            align-items: center;

            svg { margin: 0 6px; }
           
            .total { opacity: 0.5; }
        }

        .swiper-container {
            height: 100%;
            width: 100%;
            overflow: visible !important;
    
            .swiper-slide {
                .image-wrapper {
                    height: 260px;
                    width: 100%;
                    position: relative;

                    @include resp-min($breakpoint-medium) {
                        height: 380px;
                    }
            
                    @include resp-min($breakpoint-large) {
                        margin-top: 0;
                    }
        
                    img {
                        width: 100%;
                        height: 100%;
                        position: absolute;
                        top: 0;
                        left: 0;
                        object-fit: cover;
                    }
                }

                .slide-caption {
                    font-size: 16px;
                    display: block;
                    max-width: 460px;
                    margin-top: $base-spacing-unit;
                    color: $black-color;
                    transition: all 0.2s ease-in-out;

                    @include resp-min($breakpoint-xlarge) { font-size: 18px; }
                }
            }
        }
    }
}


.ser-swiper-nav, .prod-swiper-nav {
    width: 100px;
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    margin-top: #{$base-spacing-unit/2};

    .swiper-button-prev, .swiper-button-next {
        margin-top: 0;
        width: 37px;
        height: 37px;
        left: auto;
        position: relative;
        -webkit-transform: translate3d(0, 0, 0); 
        transform: translate3d(0, 0, 0);

        &:after {
            content: '';
            width: calc(100% - 2px);
            height: calc(100% - 2px);
            position: absolute;
            top: 50%;
            left: 50%;
            transform: translate(-50%, -50%);
            border: 2px solid $brand-color;
            border-radius: 50%;
            box-sizing: border-box;
            transition: all .3s ease-in-out;
        }

        &.swiper-button-disabled {
            opacity: 1; 

            &:after { opacity: 0; }
        }

        &:focus { outline: 0; }
    }  
}

/**
 * Testimonials
 */


.home-testimonials {
    padding: #{$base-spacing-unit*3} $base-spacing-unit;

    @include resp-min($breakpoint-medium) {
        padding: #{$base-spacing-unit*3} 0;
    }

    .uppertitle, .title {
        text-align: center;
    }

    .testimonials__slideshow {
        .swiper-wrapper {
            padding: #{$base-spacing-unit*3} 0 #{$base-spacing-unit*2};
        }

        .swiper-slide {
            height: auto;
            padding: #{$base-spacing-unit*2};
            overflow: visible;
            position: relative;
            box-sizing: border-box;
            display: flex;
            flex-direction: column;

            @include resp-min($breakpoint-large) {
                padding: #{$base-spacing-unit*2.5};
            }
          
            .testimonials-icon {
                width: 40px;
                height: 40px;
                position: absolute;
                left: $base-spacing-unit;
                top: -20px;
                display: flex;
                background: $brand-color;
                border-radius: 50%;

                svg { margin: auto; }
            }

            .testimonials-info {
                padding-top: #{$base-spacing-unit*2};
                margin-top: auto;

                .testimonials-picture {
                    width: 54px;
                    height: 54px;
                    margin-right: $base-spacing-unit;
                    border-radius: 50%;
                    overflow: hidden;
                    position: relative;
                    display: block;
                    float: left;

                    img {
                        width: 100%;
                        height: 100%;
                        position: absolute;
                        top: 0;
                        left: 0;
                        object-fit: cover;
                    }
                }

                .testimonials-label {
                    font-size: 16px;
                    display: block;
                    opacity: 0.5;
                }
            }
        }

        .swiper-pagination {
            position: relative;

            .swiper-pagination-bullet {
                position: relative;
                background: $white-color;
                margin: 0 $base-spacing-unit;
                transition: all 0.3s ease-in-out;

                &:after {
                    content: '';
                    width: 37px;
                    height: 37px;
                    position: absolute;
                    top: 50%;
                    left: 50%;
                    border: 2px solid $brand-color;
                    border-radius: 50%;
                    transform: translate(-50%, -50%) scale(0.5);
                    opacity: 0;
                    transition: all 0.3s ease-in-out;
                    pointer-events: none;
                }

                &:focus { outline: 0; }

                &.swiper-pagination-bullet-active, &:hover {
                    opacity: 1;

                    &:after {
                       transform: translate(-50%, -50%) scale(1);
                       opacity: 1;
                    }
                }
            }
        }
    }
}


/**
 * Contacts
 */

.home-contacts {
    padding: #{$base-spacing-unit*3} $base-spacing-unit;

    @include resp-min($breakpoint-medium) {
        padding: #{$base-spacing-unit*3} 0;
    }

    @include resp-min($breakpoint-large) {
        padding: #{$base-spacing-unit*5} 0;
    }

    .contacts__info {    
        @include resp-min($breakpoint-large) {
            padding-top: #{$base-spacing-unit*4};
        }
    
        .address, .email, .phone {
            display: block;
            font-size: 24px;
            line-height: 1.2;
            padding: 0;
            font-weight: bold;
            text-transform: uppercase;
            margin-bottom: $base-spacing-unit;
        }
    }


    .contacts__maps {
        display: none;

        @include resp-min($breakpoint-medium) {
            display: block;
            width: 100%;
            height: 400px;
        }

        @include resp-min($breakpoint-large) {
            height: 600px;
        }

        .map {
            width: 100%;
            height: 100%;
            object-fit: cover;
            object-position: right center;
            display: block;

            img[src*="png"] {
                display: none;
            }

            .gm-style-cc,
            .gmnoprint {
                display: none;
            }

            .v-marker {
                position: absolute;
                width: 8px;
                height: 8px;
                background:$brand-color;
                border-radius: 50%;

                &::before {
                content: '';
                position: absolute;
                margin: auto;
                top: 0;
                bottom: 0;
                left: 0;
                right: 0;
                width: 8px;
                height: 8px;
                background:$brand-color;
                border-radius: 50%;
                transform: scale(1);
                animation: markerPoint 3s cubic-bezier(0, 0, 0, 1) infinite;
                }

                &::after {
                content: '';
                box-sizing: border-box;
                position: absolute;
                top: 50%;
                left: 50%;
                width: 200px;
                height: 200px;
                margin: -100px 0 0 -100px;
                border: 10px solid $brand-color;
                background: rgba($brand-color, 0.1);
                border-radius: 50%;
                transform: scale(0);
                animation: marker 3s cubic-bezier(0, 0, 0, 1) infinite;
                }

                @keyframes marker {
                0% {
                    border-width: rem-calc(10);
                    opacity: 1;
                    transform: scale(0);
                }

                100% {
                    border-width: 0;
                    opacity: 0;
                    transform: scale(1);
                }
                }
                @keyframes markerPoint {
                0% {
                    transform: scale(1);
                }

                10% {
                    transform: scale(1.5);
                }

                100% {
                    transform: scale(1);
                }
                }
            }   
        }
    }   
}


