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

  /*========== Colors ==========*/
  /*Color mode HSL(hue, saturation, lightness)*/
  --title-color: hsl(0, 0%, 95%);
  --text-color: hsl(0, 0%, 70%);
  --first-color-light-light: hsl(40, 24%, 85%);
  --text-color-light: hsl(0, 0%, 60%);
  --body-color: hsl(0, 0%, 0%);
  --container-color: hsl(0, 0%, 5%);

  /*========== Font and typography ==========*/
  /*.5rem = 8px | 1rem = 16px ...*/
  --body-font: "Poppins", sans-serif;
  --second-font: "Montserrat", sans-serif;
  --biggest-font-size: 1.75rem;
  --h1-font-size: 1rem;
  --h2-font-size: 1.5rem;
  --h3-font-size: .9rem;
  --normal-font-size: .938rem;
  --small-font-size: .813rem;
  --smaller-font-size: .75rem;
  --mb-2-5: 2.5rem;

  /*========== Font weight ==========*/
  --font-regular: 200;
  --font-medium: 250;
  --font-semi-bold: 300;

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


/*========== Responsive typography ==========*/
@media screen and (min-width: 1152px) {
  :root {
    --biggest-font-size: 5.5rem;
    --h1-font-size: 2.5rem;
    --h2-font-size: 1.5rem;
    --h3-font-size: 1.25rem;
    --normal-font-size: 1rem;
    --small-font-size: .875rem;
    --smaller-font-size: .813rem;
  }
}

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

html {
  scroll-behavior: smooth;
}

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

body {
  background-color: var(--body-color);
}

button,
input {
  outline: none;
  border: none;
}

h1, h2, h3, h4 {
  color: var(--title-color);
  font-family: var(--second-font);
  font-weight: var(--font-semi-bold);
}

ul {
  list-style: none;
}

a {
  text-decoration: none;
}

img {
  display: block;
  max-width: 100%;
  height: auto;
}

/*=============== REUSABLE CSS CLASSES ===============*/
.container {
  max-width: 1120px;
  margin-right: 1.5rem;
  margin-left: 1.5rem;
}

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

.section {
  padding: 5rem 0rem;
}

.section__title {
  text-align: center;
  font-size: var(--h1-font-size);
  margin-bottom: 1.5rem;
}

.main {
  overflow: hidden; /* For animation ScrollReveal */
}

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

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

.nav__logo{
  color: var(--title-color);
  font-family: var(--second-font);
  font-weight: var(--font-semi-bold);
}

.nav__toggle,
.nav__close{
  display: flex;
  font-size: 1rem;
  color: var(--title-color);
  cursor: pointer;
}

/* Navigation for mobile devices */
@media screen and (max-width: 1023px){
  .nav__menu{
    position: fixed;
    top: -100%;
    left: 0;
    background-color: hsla(0, 0%, 0%, .3);
    width: 100%;
    padding: 4rem;
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px); /* Safari */
    transition: top .4s;
  }
}

.nav__list{
  text-align: center;
  display: flex;
  flex-direction: column;
  row-gap: 2.5rem;
}

.nav__link{
  position: relative;
  color: var(--title-color);
  font-family: var(--second-font);
  font-weight: var(--font-medium);
}

.nav__link::after{
  content: '';
  width: 0;
  height: 1px;
  background-color: var(--title-color);
  position: absolute;
  left: 0;
  bottom: -.5rem;
  transition: width .3s;
}

.nav__link:hover::after{
  width: 70%;
}

.nav__close{
  position: absolute;
  top: 1rem;
  right: 1.5rem;
}
/* Show menu */
.show-menu{
  top: 0;
}

/* Add blur to header */
.blur-header::after{
  content: '';
  position: absolute;
  width: 1000%;
  height: 100%;
  background-color: hsla(0, 0%, 0%, .3);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  top: 0;
  left: 0;
  z-index: -1;
}

/* Active link */
.active-link::after{
  width: 70%;
}

/*=============== HOME ===============*/
.home{
  position: relative;
}

.home__bg{
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 750px;
  object-fit: cover;
  object-position: center;
  filter: opacity(50%);
}

#sliderImg{
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 750px;
  object-fit: cover;
  object-position: center;
  animation: zoom 20s linear;
}

@keyframes zoom{
  0%{
    transform: scale(1.5);
  }
  15%{
    transform: scale(1);
  }
  85%{
    transform: scale(1);
  }
  100%{
    transform: scale(1);
  }
}

.home__shadow{
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 800px;
  background: linear-gradient(180deg,
              hsla(0, 0%, 0%, 0) 58%,
              hsl(0, 0%, 0%) 78%);
}

.home__container{
  position: relative;
  padding-top: 8rem;
  row-gap: 3rem;
}

.home__data{
  text-align: center;
}

.home__subtitle{
  font-size: var(--h3-font-size);
  margin-bottom: .5rem;
}

.home__title{
  font-size: var(--biggest-font-size);
  margin-bottom: 1rem;
}

.home__description{
  margin-bottom: 2rem;
  color: var(--title-color);
}

.home__cards{
  grid-template-columns: 240px;
  justify-content: center;
  padding-top: 200px;
}

.home__card{
  position: relative;
  overflow: hidden;
}

.home__card-img{
  transition: transform .4s;
}

.home__card-shadow{
  position: absolute;
  width: 100%;
  height: 100%;
  top: 0;
  left: 0;
  background: linear-gradient(180deg,
              hsla(0, 0%, 0%, 0) 50%,
              hsl(0, 0%, 0%) 125%);
}

.home__card-title{
  position: absolute;
  left: 1rem;
  bottom: 1rem;
  font-size: var(--h3-font-size);
  z-index: 1;
}

.home__card:hover .home__card-img{
  transform: scale(1.2);
}
/*=============== BUTTON ===============*/
.button{
  background-color: rgba(112, 112, 112, 0.2);
  padding: 1.25rem 1.5rem;
  color: var(--title-color);
  display: inline-flex;
  align-items: center;
  column-gap: .5rem;
  font-family: var(--second-font);
  font-weight: var(--font-semi-bold);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
}

.button i{
  font-size: 1rem;
  transition: transform .4s;
}

.button:hover i{
  transform: translateX(.25rem);
}

/*=============== ABOUT ===============*/
.about__container{
  row-gap: 3rem;
}

.about__data{
  text-align: center;
}

.about__description{
  margin-bottom: 2rem;
}

.about__image{
  position: relative;
  justify-self: center;
  overflow: hidden;
}

.about__img{
  width: 300px;
  transition: transform .4s;
}

.about__shadow{
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(180deg,
              hsla(0, 0%, 0%, 0) 50%,
              hsl(0, 0%, 0%) 125%);
}

.about__image:hover .about__img{
  transform: scale(1.2);
}

/*=============== QUESTIONS ===============*/
.questions{
  background-color: var(--first-color-light);
}

.questions__container{
  gap: 1.5rem;
  padding: 1.5rem 0;
}

.questions__group{
  display: grid;
  row-gap: 1.5rem;
}

.questions__item{
  background-color: var(--container-color);
  border-radius: .25rem;
}

.questions__item-title{
  font-size: var(--small-font-size);
  font-weight: var(--font-medium);
}

.questions__icon{
  font-size: 1.25rem;
  color: var(--title-color);
}

.questions__description{
  font-size: var(--smaller-font-size);
  padding: 0 1.25rem 1.25rem 2.5rem;
}

.questions__header{
  display: flex;
  align-items: center;
  column-gap: .5rem;
  padding: .75rem .5rem;
  cursor: pointer;
}

.questions__content{
  overflow: hidden;
  height: 0;
}

.questions__item,
.questions__header,
.questions__item-title,
.questions__icon,
.questions__description,
.questions__content{
  transition: .3s;
}

.questions__item:hover{
  box-shadow: 0 2px 8px hsla(var(--hue), 4%, 15%, .15);
}

/*Rotate icon, change color of titles and background*/
.accordion-open .questions__header,
.accordion-open .questions__content{
  background-color: var(--first-color);
}

.accordion-open .questions__item-title,
.accordion-open .questions__description,
.accordion-open .questions__icon{
  color: #FFF;
}

.accordion-open .questions__icon{
  transform: rotate(45deg);
}

/*=============== POPULAR ===============*/
.popular__container{
  padding-top: 1.5rem;
  grid-template-columns: 240px;
  justify-content: center;
  row-gap: 2.5rem;
}

.popular__image{
  position: relative;
  overflow: hidden;
  margin-bottom: 1rem;
}

.popular__img{
  transition: transform .4s;
}

.popular__shadow{
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(180deg,
            hsla(0, 0%, 0%, 0) 50%,
            hsl(0, 0%, 0%) 125%);
}

.popular__title{
  font-size: var(--h3-font-size);
  margin-bottom: .5rem;
}

.popular__location{
  display: inline-flex;
  align-items: center;
  column-gap: .25rem;
  font-size: var(--small-font-size);
  font-family: var(--second-font);
  font-weight: 500;
}

.popular__location i{
  font-size: 1rem;
}

.popular__image:hover .popular__img{
  transform: scale(1.2);
}

/*=============== EXPLORE ===============*/
.explore{
  position: relative;
}

.explore__image{
  position: absolute;
  overflow: hidden;
}

.explore__img{
  width: 100%;
  height: 333px;
  object-fit: cover;
  object-position: center;
}

.explore__shadow{
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(180deg,
              hsl(0, 0%, 0%)5%,
              hsla(0, 0%, 0%, 0)40%,
              hsla(0, 0%, 0%, 0)60%,
              hsla(0, 0%, 0%)95%);
}

.explore__content{
  position: relative;
  padding-top: 16rem;
  text-align: center;
  row-gap: 2.5rem;
}

.explore__user{
  display: inline-flex;
  align-items: center;
  justify-content: center;
  column-gap: .5rem;
}

.explore__perfil{
  width: 30px;
  border-radius: 50%;
}

.explore__name{
  font-size: var(--small-font-size);
  color: var(--title-color);
}

/*=============== FEATURED ===============*/
.featured_container {
  padding-top: 1rem;
}

.product__description{
  text-align: center;
  color: var(--text-color);
}

.featured_filters {
  display: flex;
  align-items: center;
  justify-content: center;
  column-gap: 1rem;
  margin-bottom: 3.5rem;
}

.featured_item {
  width: 48px;
  height: 48px;
  border: none;
  outline: none;
  padding: .75rem;
  border-radius: 0rem .4rem 0rem .4rem;
  background-color: rgba(33, 33, 33, 0.722);
  color: var(--white-color);
  font-size: var(--normal-font-size);
  cursor: pointer;
  transition: .3s;
}

.featured_item img {
  width: 1.5rem;
}

.featured_item span,
.featured_item img {
  opacity: .3;
  transition: .3s;
}

.featured_item:hover {
  background-color: var(--container-color);
}

.featured_item:hover span,
.featured_item:hover img {
  opacity: 1;
}

.featured_content {
  grid-template-columns: 228px;
  row-gap: 2.5rem;
  justify-content: center;
}

.featured_card {
  position: relative;
  background-color: rgba(47, 47, 47, 0.313);
  padding: 2rem 1.5rem 1.5rem;
  border-radius: .4rem 0rem .4rem 0rem;
}

.featured_card .shape_smaller {
  position: absolute;
  inset: 0;
  margin: auto;
}

.featured_title,
.featured_subtitle,
.featured_img {
  position: relative;
}

.featured_title {
  font-size: var(--h1-font-size);
  margin-bottom: .25rem;
}

.featured_subtitle {
  font-size: var(--small-font-size);
  color: var(--text-color-dark);
}

.featured_img {
  width: 180px;
  margin: 1.5rem 0;
  transition: .3s;
}

.featured_price {
  font-size: var(--h3-font-size);
}

.featured_button {
  border: none;
  outline: none;
  padding: .75rem 1rem;
  position: absolute;
  right: 0;
  bottom: 0;
  border-radius: 1rem 0 .8rem 0;
  cursor: pointer;
  background-color: var(--bg-color);
}

.featured_button i {
  font-size: 1.25rem;
  color: #fff;
}

.featured_card:hover .featured_img {
  transform: translateX(-.25rem);
}



/* Active link featured */
.active-featured {
  background-color: var(--container-color);
}

.active-featured span,
.active-featured img {
  opacity: 1;
}

/*=============== JOIN ===============*/
.join__container{
  row-gap: 3rem;
  padding-bottom: 2.5rem;
}

.join__data{
  text-align: center;
}

.join__description{
  margin-bottom: 2rem;
}

.join__form{
  display: grid;
  row-gap: 1rem;
}

.join__input{
  padding: 1.25rem 1rem;
  background-color: var(--container-color);
}

.join__button{
  cursor: pointer;
}

.join__image{
  position: relative;
  justify-self: center;
  overflow: hidden;
}

.join__img{
  width: 300px;
  transition: transform .4s;
}

.join__shadow{
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(180deg,
              hsla(0, 0%, 0%, 0)50%,
              hsl(0, 0%, 0%)125%);
}

.join__image:hover .join__img{
  transform: scale(1.2);
}

.subscribe__message {
  color: #ccc;
}

/*=============== CONTACT ===============*/
.contact__container{
  row-gap: 3.5rem;
  padding-top: 20px;
  padding-bottom: 80px;
}

.contact__data{
  display: grid;
  row-gap: 2rem;
  text-align: center;
}

.contact__description{
  display: inline-flex;
  align-items: center;
  column-gap: .5rem;
  color: var(--title-color);
  font-weight: var(--font-medium);
}

.contact__icon{
  font-size: 1.25rem;
}

.contact__inputs{
  display: grid;
  row-gap: 2rem;
  margin-bottom: var(--mb-2-5);
}

.contact__content{
  position: relative;
  height: 3rem;
  border-bottom: 1px solid var(--text-color);
}

.contact__input{
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  padding: 1rem 1rem 1rem 0;
  background: none;

  color: var(--text-color-dark);

  
  border: none;
  outline: none;
  z-index: 1;
}

.contact__label{
  position: absolute;
  top: .75rem;
  width: 100%;
  font-size: var(--small-font-size);
  color: var(--text-color-dark);
  transition: .3s;
}

.contact__area{
  height: 7rem;
}

.contact__area textarea{
  resize: none;
}



/*Input focus move up label*/
.contact__input:focus + .contact__label{
  top: -.75rem;
  left: 0;
  font-size: var(--smaller-font-size);
  z-index: 10;
}

/*Input focus sticky top label*/
.contact__input:not(:placeholder-shown).contact__input:not(:focus) + .contact__label{
  top: -.75rem;
  font-size: var(--smaller-font-size);
  z-index: 10;
}

/*=============== FOOTER ===============*/
.footer{
  padding: 2.5rem;
  background-color: var(--container-color);
}

.footer__content{
  row-gap: 3.5rem;
}

.footer__logo{
  display: inline-block;
  color: var(--title-color);
  font-size: var(--h2-font-size);
  font-family: var(--second-font);
  font-weight: var(--font-semi-bold);
  margin-bottom: 1rem;
}

.footer__data{
  grid-template-columns: repeat(2, max-content);
  gap: 2.5rem 3.5rem;
}

.footer__title{
  font-size: var(--h3-font-size);
  margin-bottom: 1rem;
}

.footer__links{
  display: grid;
  row-gap: .75rem;
}

.footer__link{
  color: var(--text-color);
  transition: color .4s;
}

.footer__link:hover{
  color: var(--title-color);
}

.footer__group,
.footer__social{
  display: flex;
}

.footer__group{
  margin-top: 5rem;
  flex-direction: column;
  align-items: center;
  row-gap: 2rem;
}

.footer__social{
  column-gap: 1.5rem;
}

.footer__social-link{
  color: var(--text-color);
  font-size: 1.25rem;
  transition: color .4s, transform .4s;
}

.footer__social-link:hover{
  color: var(--title-color);
  transform: translateY(-.25rem);
}

.footer__copy{
  font-size: var(--smaller-font-size);
  color: var(--text-color-light);
  text-align: center;
}
/*=============== SCROLL BAR ===============*/
::-webkit-scrollbar{
  width: .6rem;
  background-color: var(--body-color)
}

::-webkit-scrollbar-thumb{
  background-color: hsl(0, 0%, 20%);
}

::-webkit-scrollbar-thumb:hover{
  background-color: hsl(0, 0%, 30%);
}

/*=============== SCROLL UP ===============*/
.scrollup{
  position: fixed;
  right: 1rem;
  bottom: -50%;
  background-color: hsla(0, 0%, 100%, .1);
  padding: 6px;
  display: inline-flex;
  color: var(--title-color);
  font-size: 1rem;
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px); /* For Safari */
  z-index: var(--z-tooltip);
  transition: bottom .4s, transform .4s;
}

.scrollup:hover{
  transform: translateY(-.25rem);
}

/* Show Scroll Up */
.show-scroll{
  bottom: 3rem;
}

/*=============== BREAKPOINTS ===============*/
/* For small devices */
@media screen and (max-width: 340px){
  .container{
    margin-right: 2rem;
    margin-left: 2rem;
  }

  .home__bg{
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 750px;
    object-fit: cover;
    object-position: center;
    filter: opacity(50%);
  }

  .footer__data{
    grid-template-columns: max-content;
  }

  .featured_filters {
    display: flex;
    align-items: center;
    justify-content: center;
    column-gap: .2rem;
    margin-bottom: 3.5rem;
  }

  .featured_item {
    width: 38px;
    height: 38px;
    border: none;
    outline: none;
    padding: .75rem;
    border-radius: .4rem;
    background-color: var(--bg-color);
    color: var(--white-color);
    font-size: var(--normal-font-size);
    cursor: pointer;
    transition: .3s;
  }
}

/* For medium devices */
@media screen and (min-width: 576px){
  .home__container,
  .about__container,
  .explore__content,
  .join__container{
    grid-template-columns: 380px;
    justify-content: center;
  }

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

@media screen and (min-width: 768px){
  .home__cards{
    grid-template-columns: repeat(2, 240px);
  }

  .about__container,
  .join__container{
    grid-template-columns: repeat(2, 350px);
    align-items: center;
  }

  .about__data,
  .about__data .section__title,
  .join__data,
  .join__data .section__title,
  .contact__data,
  .contact__data .section__title{
    text-align: initial;
  }


  .questions__container{
    grid-template-columns: repeat(2, 1fr);
  }

  .questions__container{
    align-items: flex-start;
  }

  .popular__container{
    grid-template-columns: repeat(2, 240px);
  }

  .explore__img{
    width: 100vw;
  }

  .join__image{
    order: -1;
  }

  .contact .section__title{
    padding-right: 300px;
  }

  .contact__container{
    grid-template-columns: repeat(2, 1fr);
  }

  .footer__content{
    grid-template-columns: repeat(2, max-content);
    justify-content: space-between;
  }

  .footer__group{
    flex-direction: row;
    justify-content: space-between;
  }

  .footer__copy{
    order: -1;
  }
}

/* For large devices */
@media screen and (min-width: 1023px) {
  .nav__close,
  .nav__toggle{
    display: none;
  }
  .nav__list{
    flex-direction: row;
    column-gap: 4rem;
  }

  .popular__container{
    grid-template-columns: repeat(3, 240px);
  }

  .questions__container{
    grid-template-columns: repeat(2, 1fr);
  }

  .questions__container{
    padding: 1rem 0 4rem;
  }
  .questions__title{
    text-align: initial;
  }
  .questions__group{
    row-gap: 2rem;
  }
  .questions__header{
    padding: 1rem;
  }
  .questions__description{
    padding: 0 3.5rem 2.25rem 2.75rem;
  }

  .featured_container{
    padding-bottom: 9.5rem;
  }

  .featured_filters{
    column-gap: 2rem;
    margin-bottom: 4.5rem;
  }

  .featured_item{
    width: 52px;
    height: 52px;
  }

  .featured_item img{
    width: 2rem;
  }

  .featured_content{
    grid-template-columns: repeat(3,248px);
    gap: 4rem;
  }

  .featured_title{
    font-size: 1.5rem;
  }

  .featured_subtitle{
    font-size: .9rem;
  }

  .footer__data{
    grid-template-columns: repeat(4, max-content);
    column-gap: 4.5rem;
  }
}

@media screen and (min-width: 1152px) {
  .container{
    margin-left: auto;
    margin-right: auto;
  }

  .section{
    padding: 7rem 0rem;
  }

  .nav{
    height: calc(var(--header-height) + 1.5rem);
  }
  .blur-header::after{
    backdrop-filter: blur(25px);
    -webkit-backdrop-filter: blur(25px); /* For Safari */
  }

  .home__container{
    grid-template-columns: initial;
    justify-content: initial;
    row-gap: 4rem;
    padding-top: 5.5rem;
  }
  .home__shadow{
    height: 780px;
  }
  .home__data{
    text-align: initial;
    width: 480px;
  }
  .home__title{
    font-size: 40px;
  }
  .home__subtitle{
    font-size: 20px;
  }
  .home__description{
    margin-bottom: 1rem;
  }
  .home__cards{
    grid-template-columns: repeat(3, 360px);
  }
  .home__card-title{
    left: 1.5rem;
    bottom: 1.5rem;
  }

  .button{
    column-gap: 1.5rem;
  }

  .about__container{
    grid-template-columns: 400px 460px;
    column-gap: 8.5rem;
    padding: 1rem;
  }
  .about__description{
    margin-bottom: 4rem;
  }
  .about__img{
    width: 460px;
  }

  .popular__container{
    grid-template-columns: repeat(3, 300px);
    column-gap: 3rem;
    padding-top: 4rem;
  }
  .popular__title{
    font-size: var(--h2-font-size);
  }
  .popular__location{
    font-size: var(--normal-font-size);
  }

  .explore__img{
    height: 680px;
  }
  .explore__content{
    padding-top: 33rem;
    grid-template-columns: 670px 1fr;
  }
  .explore__data,
  .explore__data .section__title{
    text-align: initial;
  }
  .explore__user{
    justify-content: flex-end;
    align-self: flex-end;
    margin-bottom: 1.25rem;
  }

  .join__container{
    grid-template-columns: 460px 340px;
    column-gap: 8.5rem;
    padding: 1rem 5rem;
  }
  .join__description{
    margin-bottom: 3rem;
  }

  .footer{
    padding: 5rem 3rem;
  }
  .footer__title{
    margin-bottom: 1.5rem;
  }
  .footer__group{
    margin-top: 7rem;
  }
  .footer__social{
    column-gap: 2rem;
  }
  .footer__social-link{
    font-size: 1.5rem;
  }

}