/*=============== GOOGLE FONTS ===============*/
@import url('https://fonts.googleapis.com/css2?family=Open+Sans:wght@400;600&family=Raleway:wght@500;600;700&display=swap');

/*=============== VARIABLES CSS ===============*/
:root{
    --header-height: 3rem;

    /*========== Colors ==========*/
    /* Change favorite color to match images */
    /*Green dark 190 - Green 171 - Grren Blue 200*/
    --hue-color: 190;

    /* HSL color mode */
    --first-color: hsl(var(--hue-color), 64%, 22%);
    --first-color-second: hsl(var(--hue-color), 64%, 22%);
    --first-color-alt: hsl(var(--hue-color), 64%, 15%);
    --title-color: hsl(var(--hue-color), 64%, 18%);
    --text-color: hsl(var(--hue-color), 24%, 35%);
    --text-color-light: hsl(var(--hue-color), 8%, 60%);
    --input-color: hsl(var(--hue-color), 24%, 97%);
    --body-color: hsl(var(--hue-color), 100%, 99%);
    --white-color: #FFF;

    --scroll-bar-color: hsl(var(--hue-color), 12%, 90%);
    --scroll-thumb-color: hsl(var(--hue-color), 12%, 75%);

    /*========== Font and typography ==========*/
    --body-font: 'Open Sans', sans-serif;
    --title-font: 'Raleway', sans-serif;

    --biggest-font-size: 2.5rem;
    --h1-font-size: 1.5rem;
    --h2-font-size: 1.25rem;
    --h3-font-size: 1rem;
    --normal-font-size: .938rem;
    --small-font-size: .813rem;
    --smaller-font-size: .75rem;

    @media screen and (min-width: 968px){
        --biggest-font-size: 4rem;
        --h1-font-size: 2.25rem;
        --h2-font-size: 1.75rem;
        --h3-font-size: 1.25rem;
        --normal-font-size: 1rem;
        --small-font-size: .875rem;
        --smaller-font-size: .813rem;
    }

    /*========== Font weight ==========*/
    --font-medium: 500;
    --font-semi-bold: 600;

    /*========== Margenes Bottom ==========*/
    --mb-0-25: .25rem;
    --mb-0-5: .5rem;
    --mb-0-75: .75rem;
    --mb-1: 1rem;
    --mb-1-25: 1.25rem;
    --mb-1-5: 1.5rem;
    --mb-2: 2rem;
    --mb-2-5: 2.5rem;

    /*========== z index ==========*/
    --z-tooltip: 10;
    --z-fixed: 100;

    /*========== Hover overlay ==========*/
    --img-transition: .3s;
    --img-hidden: hidden;
    --img-scale: scale(1.1);
}

/*========== Variables Dark theme ==========*/
body.dark-theme{
    --first-color-second: hsl(var(--hue-color), 54%, 12%);
    --title-color: hsl(var(--hue-color), 24%, 95%);
    --text-color: hsl(var(--hue-color), 8%, 75%);
    --input-color: hsl(var(--hue-color), 29%, 16%);
    --body-color: hsl(var(--hue-color), 29%, 12%);

    --scroll-bar-color: hsl(var(--hue-color), 12%, 48%);
    --scroll-thumb-color: hsl(var(--hue-color), 12%, 36%);
}

/*========== Button Dark/Light ==========*/
.nav__dark{
    display: flex;
    align-items: center;
    column-gap: 2rem;
    position: absolute;
    left: 3rem;
    bottom: 4rem;
}

.change{
    &-theme,
    &-theme-name{
        color: var(--text-color);
    }
    &-theme{
        cursor: pointer;
        font-size: 1rem;
    }
    &-theme-name{
        font-size: var(--small-font-size);
    }
}

/*=============== BASE ===============*/
*{
    box-sizing: border-box;
    padding: 0;
    margin: 0;
}

html{
    scroll-behavior: smooth;
}

body{
    margin: var(--header-height) 0 0 0;
    font-family: var(--body-font);
    font-size: var(--normal-font-size);
    background-color: var(--body-color);
    color: var(--text-color);
}
h1,h2,h3{
    color: var(--title-color);
    font-weight: var(--font-semi-bold);  
    font-family: var(--title-font);
}

ul{
    list-style: none;
}
a{
    text-decoration: none;
}
img,
video{
    max-width: 100%;
    height: auto;
}

button,
input{
    border: none;
    font-family: var(--body-font);
    font-size: var(--normal-font-size);
}

button{
    cursor: pointer;
}

input{
    outline: none;
}

.main{
    overflow-x: hidden; // for animation gsap
}

/*=============== REUSABLE CSS CLASSES ===============*/
.section{
    padding: 4.5rem 0 2.5rem;

    &__title{
        font-size: var(--h2-font-size);
        color: var(--title-color);
        text-align: center;
        text-transform: capitalize;
        margin-bottom: var(--mb-2);
    }
}

.container{
    max-width: 968px;
    margin-left: var(--mb-1);
    margin-right: var(--mb-1);
}

.grid{
    display: grid;
    gap: 1.5rem;
}

/*=============== HEADER ===============*/
.header{
    width: 100%;
    position: fixed;
    top: 0;
    left: 0;
    z-index: var(--z-fixed);
    background-color: transparent;
}

/*=============== NAV ===============*/
.nav{
    height: var(--header-height);
    display: flex;
    justify-content: space-between;
    align-items: center;

    &__logo,
    &__toggle{
        color: var(--white-color);
    }
    &__logo{
        font-weight: var(--font-semi-bold);
    }
    &__toggle{
        font-size: 1.2rem;
        cursor: pointer;
    }

    &__menu{
        position: relative;

        @media screen and (max-width: 767px){
            position: fixed;
            background-color: var(--body-color);
            top: 0;
            right: -100%;
            width: 70%;
            height: 100%;
            box-shadow: -1px 0 4px hsla(190, 64%, 15%, .15);
            padding: 3rem;
            transition: .4s;
        }
    }
    &__list{
        display: flex;
        flex-direction: column;
        row-gap: 2.5rem;
    }
    &__link{
        color: var(--text-color-light);
        font-weight: var(--font-semi-bold);
        text-transform: uppercase;

        &:hover{
            color: var(--text-color);
        }
    }
    &__close{
        position: absolute;
        top: .75rem;
        right: 1rem;
        font-size: 1.5rem;
        color: var(--title-color);
        cursor: pointer;
    }
}

/* show menu */
.show-menu{
    right: 0;
}

/* Change background header */
.scroll-header{
    background-color: var(--body-color);
    box-shadow: 0 0 4px hsla(190, 64%, 15%, .15);

    & .nav__logo,
    & .nav__toggle{
        color: var(--title-color);
    }
}

/* Active link */
.active-link{
    position: relative;
    color: var(--title-color);

    &::before{
        content: '';
        position: absolute;
        background-color: var(--title-color);
        width: 100%;
        height: 2px;
        bottom: -.75rem;
        left: 0;
    }
}

/*=============== HOME ===============*/
.home{
    &__img{
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100vh;
        object-fit: cover;
        object-position: 83%;
    }
    &__container{
        position: relative;
        height: calc(100vh - var(--header-height));
        align-content: center;
        row-gap: 3rem;
    }
    &__data-subtitle,
    &__data-title,
    &__social-link,
    &__info{
        color: var(--white-color);
    }
    &__data{
        &-subtitle{
            display: block;
            font-weight: var(--font-semi-bold);
            margin-bottom: var(--mb-0-75);
        }
        &-title{
            font-size: var(--biggest-font-size);
            font-weight: var(--font-medium);
            margin-bottom: var(--mb-2-5);
        }
    }
    &__social{
        display: flex;
        flex-direction: column;
        row-gap: 1.5rem;

        &-link{
            font-size: 1.2rem;
            width: max-content;
        }
    }
    &__info{
        background-color: var(--first-color);
        display: flex;
        padding: 1.5rem 1rem;
        align-items: center;
        column-gap: .5rem;
        position: absolute;
        right: 0;
        bottom: 1rem;
        width: 228px;

        &-title{
            display: block;
            font-size: var(--small-font-size);
            font-weight: var(--font-semi-bold);
            margin-bottom: var(--mb-0-75);
        }
        &-button{
            font-size: var(--smaller-font-size);
        }
        &-overlay{
            overflow: var(--img-hidden);
        }
        &-img{
            width: 145px;
            transition: var(--img-transition);

            &:hover{
                transform: var(--img-scale);
            }
        }
    }
}

/*=============== BUTTONS ===============*/
.button{
    display: inline-block;
    background-color: var(--first-color);
    color: var(--white-color);
    padding: 1rem 2rem;
    font-weight: var(--font-semi-bold);
    transition: .3s;
    
    &:hover{
        background-color: var(--first-color-alt);
    }
    
    &--flex{
        display: flex;
        align-items: center;
        column-gap: .25rem;
    }
    &--link{
        background: none;
        padding: 0;
        
        &:hover{
            background: none;
        }
    }
}

/*=============== ABOUT ===============*/
.about{
    &__data{
        text-align: center;
    }
    &__container{
        row-gap: 2.5rem;
    }
    &__description{
        margin-bottom: var(--mb-2);
    }
    &__img{
        display: flex;
        column-gap: 1rem;
        align-items: center;
        justify-content: center;

        &-overlay{
            overflow: var(--img-hidden);
        }

        &-one{
            width: 130px;
        }
        &-two{
            width: 180px;
        }
        &-one,
        &-two{
            transition: var(--img-transition);
        }
        &-one:hover,
        &-two:hover{
            transform: var(--img-scale);
        }
    }
}

/*=============== DISCOVER ===============*/
.discover{
    &__card{
        position: relative;
        width: 200px;
        overflow: var(--img-hidden);
    }
    &__data{
        position: absolute;
        bottom: 1.5rem;
        left: 1rem;
    }
    &__title,
    &__description{
        color: var(--white-color);
    }
    &__title{
        font-size: var(--h3-font-size);
        margin-bottom: var(--mb-0-25);
    }
    &__description{
        display: block;
        font-size: var(--smaller-font-size);
    }
    &__img{
        transition: var(--img-transition);

        &:hover{
            transform: var(--img-scale);
        }
    }
}

.swiper-container-3d .swiper-slide-shadow-left,
.swiper-container-3d .swiper-slide-shadow-right{
    background-image: none;
}


/*=============== EXPERIENCE ===============*/
.experience{
    &__container{
        row-gap: 2.5rem;
        justify-content: center;
        justify-items: center;
    }
    &__content{
        grid-template-columns: repeat(3, 1fr);
        column-gap: 1rem;
        justify-items: center;
        padding: 0 2rem;
    }
    &__number{
        font-size: var(--h2-font-size);
        font-weight: var(--font-semi-bold);
        margin-bottom: var(--mb-0-5);
    }
    &__description{
        font-size: var(--small-font-size);
    }
    &__img{
        position: relative;
        padding-bottom: 2rem;

        &-one,
        &-two{
            transition: var(--img-transition);
        }
        &-one:hover,
        &-two:hover{
            transform: var(--img-scale);
        }
    }
    &__overlay{
        overflow: var(--img-hidden);

        &:nth-child(1){
            width: 263px;
            margin-right: 2rem;
        }
        &:nth-child(2){
            width: 120px;
            position: absolute;
            top: 2rem;
            right: 0;
        }
    }
}

/*=============== VIDEO ===============*/
.video{
    &__container{
        padding-bottom: 1rem;
    }
    &__description{
        text-align: center;
        margin-bottom: var(--mb-2-5);
    }
    &__content{
        position: relative;
    }
    &__button{
        position: absolute;
        right: 1rem;
        bottom: -1rem;
        padding: 1rem 1.5rem;

        &-icon{
            font-size: 1.2rem;  
        }
    }
}

/*=============== PLACES ===============*/
.place{
    &__card,
    &__img{
        height: 230px;
    }
    &__container{
        grid-template-columns: repeat(2, max-content);
        justify-content: center;
    }
    &__card{
        position: relative;
        overflow: var(--img-hidden);

        &:hover .place__img{
            transform: var(--img-scale);
        }
    }
    &__img{
        transition: var(--img-transition);
    }
    &__content,
    &__title{
        color: var(--white-color);
    }
    &__content{
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        display: flex;
        flex-direction: column;
        justify-content: space-between;
        padding: .75rem .75rem 1rem;
    }
    &__rating{
        align-self: flex-end;
        display: flex;
        align-items: center;

        &-icon{
            font-size: .75rem;
            margin-right: var(--mb-0-25);
        }
        &-number{
            font-size: var(--small-font-size);
        }
    }
    &__subtitle,
    &__price{
        display: block;
    }
    &__title{
        font-size: var(--h3-font-size);
        margin-bottom: var(--mb-0-25);
    }
    &__subtitle{
        font-size: var(--smaller-font-size);
        margin-bottom: var(--mb-1-25);
    }
    &__button{
        position: absolute;
        right: 0;
        bottom: 0;
        padding: .75rem 1rem;
    }
}

/*=============== SUBSCRIBE ===============*/
.subscribe{
    &__bg{
        background-color: var(--first-color-second);
        padding: 2.5rem 0;
    }
    &__title,
    &__description{
        color: var(--white-color);
    }
    &__description{
        text-align: center;
        margin-bottom: var(--mb-2-5);
    }
    &__form{
        background-color: var(--input-color);
        padding: .5rem;
        display: flex;
        justify-content: space-between;
    }
    &__input{
        width: 70%;
        padding-right: .5rem;
        background-color: var(--input-color);
        color: var(--text-color);

        &::placeholder{
            color: var(--text-color);
        }
    }
}

/*=============== SPONSORS ===============*/
.sponsor{
    &__container{
        grid-template-columns: repeat(auto-fit, minmax(110px, 1fr));
        justify-items: center;
        row-gap: 3.5rem;
    }
    &__content:hover .sponsor__img{
        filter: invert(.5);
    }
    &__img{
        width: 90px;
        filter: invert(.7);
        transition: var(--img-transition);
    }
}

/*=============== FOOTER ===============*/
.footer{
    &__container{
        row-gap: 5rem;
    }
    &__content{
        grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
        row-gap: 2rem;
    }
    &__title,
    &__subtitle{
        font-size: var(--h3-font-size);
    }
    &__title{
        margin-bottom: var(--mb-0-5);
    }
    &__description{
        margin-bottom: var(--mb-2);
    }
    &__social{
        font-size: 1.25rem;
        color: var(--title-color);
        margin-right: var(--mb-1-25);
    }
    &__subtitle{
        margin-bottom: var(--mb-1);
    }
    &__item{
        margin-bottom: var(--mb-0-75);
    }
    &__link{
        color: var(--text-color);

        &:hover{
            color: var(--title-color);
        }
    }
    &__rights{
        display: flex;
        flex-direction: column;
        row-gap: 1.5rem;
        text-align: center;
    }
    &__copy,
    &__terms-link{
        font-size: var(--small-font-size);
        color: var(--text-color-light);
    }
    &__terms{
        display: flex;
        column-gap: 1.5rem;
        justify-content: center;

        &-link:hover{
            color: var(--text-color);
        }
    }
}

/*========== SCROLL UP ==========*/
.scrollup {
    position: fixed;
    right: 1rem;
    bottom: -20%;
    background-color: var(--first-color);
    padding: .5rem;
    display: flex;
    opacity: .9;
    z-index: var(--z-tooltip);
    transition: .4s;

    &:hover{
        background-color: var(--first-color-alt);
        opacity: 1;
    }

    &__icon{
        color: var(--white-color);
        font-size: 1.2rem;
    }
}

/* Show scroll */
.show-scroll {
    bottom: 5rem;
}

/*=============== SCROLL BAR ===============*/
::-webkit-scrollbar {
    width: .60rem;
    background-color: var(--scroll-bar-color);
}
  
::-webkit-scrollbar-thumb {
    background-color: var(--scroll-thumb-color);
}
  
::-webkit-scrollbar-thumb:hover {
    background-color: var(--text-color-light);
}

/*=============== MEDIA QUERIES ===============*/
/* For small devices */
@media screen and (max-width: 340px){
    .place{
        &__container{
            grid-template-columns: max-content;
            justify-content: center;
        }
    }

    .experience{
        &__content{
            padding: 0;
        }
        &__overlay:nth-child(1){
            width: 190px;
        }
        &__overlay:nth-child(2){
            width: 80px;
        }
    }

    .home{
        &__info{
            width: 190px;
            padding: 1rem;
        }
    }
    .experience__img,
    .video__container{
        padding: 0;
    }
}

/* For medium devices */
@media screen and (min-width: 568px){
    .video__container{
        display: grid;
        grid-template-columns: .6fr;
        justify-content: center;
    }

    .place{
        &__container{
            grid-template-columns: repeat(3, max-content);
        }
    }

    .subscribe{
        &__form{
            width: 470px;
            margin: 0 auto;
        }
    }
}

@media screen and (min-width: 768px){
    body{
        margin: 0;
    }

    .nav{
        height: calc(var(--header-height) + 1.5rem);

        &__link{
            color: var(--white-color);
            text-transform: initial;

            &:hover{
                color: var(--white-color);
            }
        }
        &__dark{
            position: initial;
        }
        &__menu{
            display: flex;
            column-gap: 1rem;
        }
        &__list{
            flex-direction: row;
            column-gap: 4rem;
        }
        &__toggle,
        &__close{
            display: none;
        }
    }

    .change{
        &-theme-name{
            display: none;
        }
        &-theme{
            color: var(--white-color);
        }
    }

    .active-link::before{
        background-color: var(--white-color);
    }

    .scroll-header .nav__link{
        color: var(--text-color);
    }
    .scroll-header .active-link{
        color: var(--title-color);
    }
    .scroll-header .active-link::before{
        background-color: var(--title-color);
    }

    .scroll-header .change-theme{
        color: var(--text-color);
    }

    .section{
        padding: 7rem 0 2rem;
    }

    .home{
        &__container{
            height: 100vh;
            grid-template-rows: 1.8fr .5fr;
        }
        &__data{
            align-self: flex-end;
        }
        &__social{
            flex-direction: row;
            align-self: flex-end;
            margin-bottom: 3rem;
            column-gap: 2.5rem;
        }
        &__info{
            bottom: 3rem;
        }
    }

    .about{
        &__container{
            grid-template-columns: repeat(2, 1fr);
            align-items: center;
        }
        &__data,
        &__title {
            text-align: initial;
        }
        &__title{
            margin-bottom: var(--mb-1-5);
        }
        &__description{
            margin-bottom: var(--mb-2);
        }
    }

    .discover{
        &__container{
            width: 610px;
            margin-left: auto;
            margin-right: auto;
        }
    }

    .discover__container,
    .place__container{
        padding-top: 2rem;
    }
    
    .experience{
        &__overlay:nth-child(1){
            width: 363px;
            margin-right: 4rem;
        }
        &__overlay:nth-child(2){
            width: 160px;
        }
    }

    .subscribe{
        &__bg{
            background: none;
            padding: 0;
        }
        &__container{
            background-color: var(--first-color-second);
            padding: 3.5rem 0;
        }
        &__input{
            padding: 0 .5rem;
        }
    }

    .footer{
        &__rights{
            flex-direction: row;
            justify-content: space-between;
        }
    }

}

/* For large devices */
@media screen and (min-width: 1024px){
    .container{
        margin-left: auto;
        margin-right: auto;
    }

    .home{
        &__container{
            grid-template-rows: 2fr .5fr;
        }
        &__info{
            width: 328px;
            grid-template-columns: 1fr 2fr;
            column-gap: 2rem;

            &-title{
                font-size: var(--normal-font-size);
            }
            &-img{
                width: 240px;
            }
        }
    }

    .about{
        &__img{
            &-one{
                width: 230px;
            }
            &-two{
                width: 290px;
            }
        }
    }

    .discover{
        &__card{
            width: 237px;
        }
        &__container{
            width: 700px;
        }
        &__data{
            left: 1.5rem;
            bottom: 2rem;
        }
        &__title{
            font-size: var(--h2-font-size);
        }
    }

    .experience{
        &__content{
            margin: var(--mb-1) 0;
            column-gap: 3.5rem;
        }
        &__overlay:nth-child(1){
            width: 463px;
            margin-right: 7rem;
        }
        &__overlay:nth-child(2){
            width: 220px;
            top: 3rem;
        }
    }

    .video{
        &__container{
            grid-template-columns: .7fr
        }
        &__description{
            padding: 0 8rem;
        }
    }

    .place{
        &__container{
            gap: 3rem 2rem;
        }
        &__card, 
        &__img{
            height: 263px;
        }
    }

    .footer__content{
        justify-items: center;
    }
}

@media screen and (min-width: 1200px){
    .container{
        max-width: 1024px;
    }
}

/* For tall screens on mobiles y desktop*/
@media screen and (min-height: 721px){
    body{
        margin: 0;
    }
    .home{
        &__container,
        &__img{
            height: 640px;
        }
    }
}