@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@100;300;400;500;600&display=swap');

*{
  font-family: 'Poppins', sans-serif;
  margin:0; padding:0;
  box-sizing: border-box;
  text-decoration: none;
  outline: none; border:none;
  text-transform: capitalize;
  transition: all .2s linear;
}

$blue : #0984e3;
$black : #333;
$white : #fff;
$gold : gold;
$light-color : #666;
$light-bg : #eee;
$border : .2rem solid $black;
$box-shadow : 0 .5rem 1rem rgba(0,0,0,.2);

@mixin grid($val) {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax($val, 1fr));
  gap:2rem;
}

html{
  overflow-x: hidden;
  font-size: 62.5%;

  &::-webkit-scrollbar{
    width: 1rem;
  }

  &::-webkit-scrollbar-track{
    background: $light-bg;
  }

  &::-webkit-scrollbar-thumb{
    background: $blue;
    border-radius: 5rem;
  }
}

body{
  background: $light-bg;
}

section{
  padding:3rem 9%;
}

.heading{
  text-align: center;
  margin-bottom: 3rem;
  font-size: 3.5rem;
  color:$black;

  span{
    color:$blue;
  }
}

.btn{
  margin-top: 1rem;
  display: inline-block;
  border-radius: .5rem;
  padding:1rem 3rem;
  font-size: 1.7rem;
  color:$white;
  cursor: pointer;
  background: $blue;

  &:hover{
    background: $black;
  }
}

@keyframes fadeIn {
  0%{
    transform: scale(.5);
    opacity: 0;
  }
}

.header{
  position: sticky;
  top:0; left:0; right:0;
  z-index: 1000;
  background: $blue;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding:1rem 9%;

  .logo{
    font-size: 2.5rem;
    color:$white;
    font-weight: bolder;

    i{
      color:$gold;
    }
  }

  .search-form{
    border-radius: 5rem;
    height: 5rem;
    width: 50rem;
    padding:0 2rem;
    display: flex;
    align-items: center;
    background: $white;

    input{
      width: 100%;
      padding-right: 1rem;
      font-size: 1.7rem;
      text-transform: none;
      color:$light-color;
    }

    label{
      font-size: 2rem;
      color:$light-color;
      cursor: pointer;

      &:hover{
        color:$blue;
      }
    }
  }

  .icons a,
  .icons div{
    font-size: 2.5rem;
    margin-left: 2rem;
    color:$white;
    cursor: pointer;

    &:hover{
      color:$gold;
    }
  }
}

#search-btn{
  display: none;
}

.side-bar{
  position: fixed;
  top:0; left:-110%;
  height: 100%;
  width: 30rem;
  background: $white;
  z-index: 10000;

  &.active{
    left:0;
    box-shadow: 0 0 0 100vw rgba(0,0,0,.7);
  }

  #close-side-bar{
    position: absolute;
    top:1rem; right:2rem;
    font-size: 4rem;
    cursor: pointer;
    color:$light-color;

    &:hover{
      transform: rotate(90deg);
      color:$black;
    }
  }

  .user{
    padding:2rem;
    background: $light-bg;
    text-align: center;

    img{
      height: 17rem;
      width: 17rem;
      border-radius: 50%;
      border:1rem solid $white;
      box-shadow: $box-shadow;
      margin-bottom: .5rem;
    }

    h3{
      padding:.5rem 0;
      font-size: 1.7rem;
      color:$light-color;
    }

    a{
      font-size: 1.5rem;
      color:$blue;

      &:hover{
        color:$black;
      }
    }
  }

  .navbar{
    padding-top: 1rem;

    a{
      display: block;
      padding:1rem 2rem;
      font-size: 1.7rem;
      color:$light-color;

      &:hover{
        color:$blue;

        i{
          padding-right: 2rem;
        }
      }

      i{
        padding-right: .5rem;
      }
    }
  }
}

.home{
  background: $white;

  .slide{
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap:2rem;
    min-height: 40rem;
    padding:2rem 0;
    
    .image{
      flex:1 1 42rem;
      text-align: center;

      img{
        height: 30rem;
      }
    }

    .content{
      flex:1 1 42rem;

      span{
        font-size: 2rem;
        color:$blue;
      }

      h3{
        padding-top: .5rem;
        color:$black;
        font-size: 3rem;
      }
    }
  }
}

.swiper-button-next::after,
.swiper-button-prev::after{
  font-size: 3rem;
  color:$black;
}

.banner{

  .box-container{
    @include grid(31rem);

    .box{
      position: relative;
      height: 25rem;
      border:$border;
      border-radius: .5rem;
      overflow:hidden;
      box-shadow: $box-shadow;

      &:hover img{
        transform: scale(1.1);
      }

      img{
        height: 100%;
        width: 100%;
        object-fit: cover;
      }

      .content{
        position: absolute;
        top:50%; left:5%;
        transform: translateY(-50%) rotate(45deg);

        span{
          font-size: 1.7rem;
          color:$blue;
        }

        h3{
          font-size: 2rem;
          padding:.5rem 0;
          color:$black;
        }
      }
    }
  }
}

.arrivals{

  .box-container{
    @include grid(33rem);

    .box{
      border-radius: .5rem;
      border:$border;
      padding:2rem;
      box-shadow: $box-shadow;
      display: flex;
      align-items: center;
      gap:1rem;
      background: $white;
      
      &:hover{

        .image{

          .main-img{
            display: none;
          }

          .hover-img{
            display: inline-block;
          }
        }
      }

      .image{

        img{
          height: 15rem;
          animation: fadeIn .2s linear;
        }

        .hover-img{
          display: none;
        }
      }

      .content{

        h3{
          font-size: 2rem;
          color:$black;
        }

        .price{
          padding-top: .5erm;
          font-size: 2rem;
          color:$blue;
          padding-bottom: .7rem;

          span{
            font-size: 1.5rem;
            color:$light-color;
            text-decoration: line-through;
          }
        }

        .stars i{
          font-size: 1.5rem;
          color:$gold;
        }
      }
    }
  }
}

.about{
  display: flex;
  align-items: center;
  flex-wrap: wrap;

  .image{
    flex:1 1 42rem;

    img{
      width: 100%;
    }
  }

  .content{
    flex:1 1 42rem;
    padding:3rem;
    background: $white;

    h3{
      font-size: 3rem;
      text-transform: uppercase;
      color:$black;
    }

    p{
      font-size: 1.5rem;
      color:$light-color;
      padding:1rem 0;
      line-height: 2;
    }
  }
}

.faq{
  
  .accordion-container{
    max-width: 70rem;
    margin:0 auto;

    .accordion{
      background: $white;
      margin-bottom: 1.5rem;
      box-shadow: $box-shadow;

      &:last-child{
        margin-bottom: .5rem;
      }

      &.active{

        .accordion-heading{
          background: $blue;

          i{
            transform: rotate(180deg);
          }
        }

        .accordioin-content{
          display: block;
        }
      }

      .accordion-heading{
        padding:2rem;
        display: flex;
        align-items: center;
        gap:1rem;
        justify-content: space-between;
        background: $black;
        cursor: pointer;
        
        h3{
          font-size: 2rem;
          color:$white;
        }

        i{
          font-size: 2rem;
          color:$white;
        }
      }
    }

    .accordioin-content{
      padding:2rem;
      font-size: 1.5rem;
      line-height: 2;
      color:$light-color;
      display: none;
      animation:fadeIn .2s linear;
    }
  }
}

.review{

  .slide{
    width: 35rem;
    padding:3rem;
    text-align: center;
    border:$border;
    box-shadow: $box-shadow;
    border-radius: .5rem;
    background: $white;

    img{
      height: 10rem;
      width: 10rem;
      border-radius: 50%;
      margin-bottom: .5rem;
    }

    h3{
      font-size: 2rem;
      color:$black;
    }

    span{
      color:$blue;
      font-size: 1.7rem;
    }

    p{
      font-size: 1.5rem;
      line-height: 2;
      color:$light-color;
      padding-top: 1rem;
    }
  }
}

.category{

  .box-container{
    @include grid(15rem);

    .box{
      text-align: center;
      border-radius: .5rem;
      border:$border;
      padding:2rem;
      background: $white;
      box-shadow: $box-shadow;

      &:hover{
        background: $black;
        
        h3{
          color:$white;
        }
      }
      
      img{
        height: 8rem;
        margin-bottom: .5rem;
      }

      h3{
        font-size: 1.7rem;
        color:$black;
      }
    }
  }
}

.products{

  .box-container{
    @include grid(31rem);

    .box{
      border:$border;
      text-align: center;
      background: $white;
      box-shadow: $box-shadow;
      border-radius: .5rem;
      overflow: hidden;

      &:hover .image{

        .hover-img{
          display: inline-block;
        }

        .main-img{
          display: none;
        }

        .icons{
          left:1rem;
        }
      }

      .image{
        position: relative;

        img{
          height: 30rem;
          animation: fadeIn .2s linear;
        }

        .hover-img{
          display: none;
        }

        .icons{
          position: absolute;
          top:0; left:-7rem;

          a{
            display: block;
            margin-top: 1rem;
            height: 4.5rem;
            width: 4.5rem;
            line-height: 4.5rem;
            font-size: 1.7rem;
            border-radius: 50%;
            color:$white;
            background: $black;

            &:hover{
              background: $blue;
            }
          }
        }
      }

      .content{
        padding:2rem;

        h3{
          font-size: 2rem;
          color:$black;
        }

        .price{
          font-size: 2.2rem;
          color:$blue;
          padding-bottom: .7rem;
          padding-top: .5rem;

          span{
            color:$light-color;
            font-size: 1.5rem;
            text-decoration: line-through;
          }
        }

        .stars{

          i{
            font-size: 1.7rem;
            color:$gold;
          }
        }
      }
    }
  }
}

.product-banner{

  .box-container{
    display: flex;
    flex-wrap: wrap;
    gap:2rem;

    .box{
      flex:1 1 42rem;
      position: relative;
      box-shadow:$box-shadow;
      border-radius: .5rem;
      border:$border;
      overflow: hidden;
      height: 30rem;

      &:hover img{
        transform: scale(1.1);
      }

      img{
        height: 100%;
        width: 100%;
        object-fit: cover;
      }

      .content{
        position: absolute;
        top:50%; left:5%;
        transform: translateY(-50%);

        span{
          font-size: 1.7rem;
          color:$blue;
        }

        h3{
          padding-top: .5rem;
          font-size: 2rem;
          color:$black;
        }
      }
    }
  }
}

.info-container{

  .box-container{
    @include grid(31rem);

    .box{
      background: $white;
      border-radius: .5rem;
      text-align: center;
      padding:2rem;
      border:$border;
      box-shadow: $box-shadow;

      i{
        height: 7.5rem;
        width: 7.5rem;
        line-height: 7.5rem;
        font-size: 2.5rem;
        border-radius: 50%;
        margin-bottom: .5rem;
        background: $blue;
        color:$white;
      }

      h3{
        font-size: 2rem;
        padding:.5rem 0;
        color:$black;
      }

      p{
        font-size: 1.5rem;
        line-height: 2;
        color:$light-color;
      }
    }
  }
}

.contact{
  display: flex;
  flex-wrap: wrap;
  gap:2rem;

  form{
    flex:1 1 42rem;

    h3{
      font-size: 3rem;
      text-transform: uppercase;
      color:$black;
      padding-bottom:1rem;
    }

    p{
      font-size: 1.5rem;
      color:$light-color;
      padding:1rem 0;
      line-height: 2;
    }

    .inputBox{
      display: flex;
      justify-content: space-between;
      flex-wrap: wrap;

      input{
        width: 49%;
      }
    }

    .inputBox input, textarea{
      padding:1.2rem 1.4rem;
      border-radius: .5rem;
      box-shadow: $box-shadow;
      border:$border;
      background: $white;
      text-transform: none;
      color:$light-color;
      font-size: 1.5rem;
      margin:.7rem 0;
    }

    textarea{
      height: 15rem;
      resize: none;
      width: 100%;
    }
  }

  .map{
    flex:1 1 42rem;
    width: 100%;
  }
}

.newsletter{
  background:$blue;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap:2rem;

  .content{
    flex:1 1 42rem;

    h3{
      font-size: 6rem;
      color:$white;
      text-transform: uppercase;
    }

    p{
      font-size: 2.2rem;
      color:$white;
    }
  }

  form{
    flex:1 1 42rem;
    background: $white;
    display: flex;
    padding:.5rem;
    border-radius: .5rem;

    .email{
      width: 100%;
      padding:0 1.4rem;
      text-transform: none;
      color:$light-color;
      font-size: 1.6rem;
    }

    .btn{
      margin-top: 0;
    }
  }
}

.register,
.login{

  form{
    max-width: 40rem;
    border-radius: .5rem;
    padding:2rem;
    background: $white;
    box-shadow: $box-shadow;
    border:$border;
    margin:1rem auto;

    h3{
      font-size: 2.5rem;
      padding-bottom: 1rem;
      color:$black;
      text-transform: uppercase;
    }
    
    .box{
      width: 100%;
      padding:1.2rem 1.4rem;
      border-radius: .5rem;
      border:$border;
      font-size: 1.6rem;
      color:$light-color;
      text-transform: none;
      margin:.7rem 0;
    }

    .remember{
      display: flex;
      align-items: center;
      gap:.5rem; 
      padding-top: 1.5rem;
      padding-bottom: 1rem;

      label{
        font-size: 1.5rem;
        color:$light-color;
        cursor: pointer;
      }
    }

    .btn{
      width: 100%;
      text-align: center;

      &.link{
        background: $black;

        &:hover{
          background: $blue;
        }
      }
    }

    p{
      padding-top: 2rem;
      font-size: 1.5rem;
      color:$light-color;
      text-align: center;
      padding-bottom: 1rem;
    }
  }
}

.shopping-cart{

  .box-container{
    @include grid(31rem);

    .box{
      padding:2rem;
      border:$border;
      background: $white;
      border-radius: .5rem;
      box-shadow: $box-shadow;
      display: flex;
      align-items: center;
      gap:.5rem;
      position: relative;

      .fa-times{
        position: absolute;
        top:1rem; right:1.5rem;
        font-size: 2.5rem;
        color:$light-color;
        cursor: pointer;

        &:hover{
          color:$black;
        }
      }

      img{
        height: 12rem;
      }

      .content{

        h3{
          font-size: 1.7rem;
          color:$black;
        }

        form{
          padding:1rem 0;
          display: flex;
          gap:.5rem;
          align-items: center;

          span{
            font-size: 1.5rem;
            color:$light-color;
          }

          input{
            width: 7rem;
            padding: .5rem 1rem; 
            color:$light-color;
            border-radius: .5rem;
            background: $light-bg;
            font-size: 1.5rem;
          }
        }

        .price{
          font-size: 2rem;
          color:$blue;

          span{
            font-size: 1.5rem;
            color:$light-color;
            text-decoration: line-through;
          }
        }
      }
    }
  }

  .cart-total{
    margin-top: 2rem;
    box-shadow: $box-shadow;
    border:$border;
    border-radius: .5rem;
    background: $white;
    padding:2rem;
    padding-top: 1rem;

    h3{
      padding-top: 1rem;
      font-size: 2rem;
      color:$black;

      span{
        color:$blue;
      }
    }
  }
}















.quick-links{
  display: flex;
  align-items: center;
  gap:2rem;
  background: $black;
  justify-content: space-between;

  .logo{
    font-size: 2.5rem;
    color:$white;
    font-weight: bolder;

    i{
      color:$gold;
    }
  }

  .links{

    a{
      margin:0 1rem;
      font-size: 1.7rem;
      color:$white;

      &:hover{
        color:$gold;
      }
    }
  }

  .share{

    a{
      font-size: 2.5rem;
      color:$white;
      margin-left: 2rem;

      &:hover{
        color:$gold;
      }
    }
  }
}

.credit{
  display: flex;
  align-items: center;
  gap:2rem;
  background: $white;
  justify-content: space-between;

  p{
    font-size: 2rem;
    color:$light-color;
    
    span{
      color:$blue;
    }
  }

  img{
    height: 4rem;
    filter: drop-shadow(0 0 .1rem $black);
  }
}










// media queries 

@media (max-width:1200px){

  html{
    font-size: 55%;
  }

  .header{
    padding:2rem;
  }

  section{
    padding:3rem 2rem;
  }

}

@media (max-width:991px){

  .quick-links{
    flex-flow: column;
    text-align: center;

    .links{
      padding:1rem 0;

      a{
        display: block;
        font-size: 2rem;
        padding:1rem 0;
      }
    }

    .share{

      a{
        margin:0 1rem;
      }
    }
  }

  .credit{
    flex-flow: column;
    text-align: center;
  }

}

@media (max-width:768px){

  #search-btn{
    display: inline-block;
  }

  .header{

    .search-form{
      position: absolute;
      top:99%; left:0; right:0;
      width: 100%;
      border-radius: 0;
      box-shadow: $box-shadow;
      height: 6rem;
      clip-path: polygon(0 0, 100% 0, 100% 0, 0 0);

      &.active{
        clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%);
      }
    }
  }

  .swiper-button-next,
  .swiper-button-prev{
    display: none;
  }

  .home{

    .slide{
      text-align: center;
    }
  }

  .newsletter{
    text-align: center;

    .content{
      h3{
        font-size: 4rem;
      }
      p{
        font-size: 1.5rem;
      }
    }
  }

}

@media (max-width:450px){

  html{
    font-size: 50%;
  }

  .header{
    justify-content: center;

    .logo{
      display: none;
    }

    .icons a,
    .icons div{
      margin:0 1rem;
    }
  }

  .home{

    .slide{
      .image{

        img{
          height: auto;
          width: 100%;
        }
      }
    }
  }

  .arrivals .box-container .box{
    flex-flow: column;
    gap:2rem;
    text-align: center;
  }

  .contact form .inputBox input{
    width: 100%;
  }

 .shopping-cart .cart-total{
   text-align: center;

   .btn{
     width: 100%;
   }
 }

}