// -----------------------------------------------------------------------------
// This file contains all styles related to the product component.
// -----------------------------------------------------------------------------

/* Product Component */

// Product Original

.product-o {
    padding: 20px;
    background-color: $g-white;
  }

.product-o--hover-off {
  box-shadow: 0 0 21px 0 rgba(0, 0, 0, 0.1);
}

.product-o--radius {
  border-radius: 14px;
}

.product-o--hover-on {
  transition: all 0.4s ease-in-out;
  &:hover {
    box-shadow: 0 0 21px 0 rgba(0, 0, 0, 0.1);
  }
}

.product-o:hover {
  .product-o__wrap:before {
    opacity: 1;
  }

  .product-o__action-wrap {
    opacity: 1;
    transform: translateY(-50%) scale(1);
  }

  .product-o__action-list {
    > li {
      opacity: 1;
      transform: translateY(0);
    }
  }
}

.product-o__wrap {
      // border: 1px solid red;
      position: relative;
      &:before {
        content: "";
        background: rgba(0,0,0,0.6);
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        z-index: 1;
        opacity: 0;
        transition: all 400ms cubic-bezier(0.175, 0.885, 0.32, 1.275);
      }
    }





.product-o__action-wrap {
      width: 100%;
      position: absolute;
      top: 50%;
      left: 0;
      opacity: 0;
      z-index: 2;
      transform: translateY(-50%) scale(0.8);
      transition: all 0.2s ease 0s;

    }




    // Component 2 flex
.product-o__action-list {
      display: flex;
      justify-content: center;
      flex-wrap: wrap;
      margin: 0;
      padding: 0;
      list-style: none;
    // by default all children would be inline because of flex
      > li {
        margin: 0 4px 6px;
        opacity: 0;// shrink
        transform: translateY(50%);
        transition: all 0.3s ease 0.1s;
        > a {
          display: block;
          width: 35px;
          text-align: center;
          border-radius: 50%;
          height: 35px;
          line-height: 35px;
          background-color: hsla(0,0%,100%,.25);
          color: $g-white;
          font-size: 12px;
          transition: all 0.3s ease 0s;
          &:hover {
            background-color: $g-brand-secondary-color;
            color: $g-white;
          }
        }
      }
    }


.product-o__category {
    display: block;
    margin-top: 4px;
    > a {
      color: #a0a0a0;
      transition: color 0.5s;
      font-size: 12px;
      &:hover {
        color: $g-brand-color;
      }
    }
  }
// div
.product-o__name {
    > a {
      color: $g-brand-secondary-color;
      font-size: 14px;
      font-weight: 600;
      transition: color 0.5s;
      &:hover {
        color: $g-brand-color;
      }
    }
  }

.product-o__rating {
    margin-bottom: 4px;
     i {
      font-size: 12px;
      }
  }

.product-o__review {
     margin-left: 4px;
     font-size: 12px;
     color: #a0a0a0;
   }

.product-o__price {
      display: block;
      color: $g-brand-secondary-color;
      font-size: 14px;
      font-weight: 600;

    }

.product-o__discount {
      font-weight: 600;
      margin-left: 30px;
      color: $g-brand-secondary-color;
      font-size: 14px;
      text-decoration: line-through;
    }

.product-o__countdown-wrap {
  margin-top: 16px;
}


.product-o__special-count-wrap {
  position: absolute;
  width: 100%;
  bottom: 20px;
  // background: rgba(0,0,0,0.6);
}


// x-product
.x-product {
  padding: 20px;
  border-radius: 6px;
  transition: transform .3s cubic-bezier(.68,-.55,.265,1.55);
  box-shadow: 0 0 8px 0 rgba(0, 0, 0, 0.06);
  .row {
    align-items: center;
  }

  // ul
  &__feature-list {
    margin: 0;
    padding: 0;
    list-style: none;
  }

  &:hover {
    transform: translateY(-6px);
  }
}



.feature {
  margin-bottom: 20px;
  &__name {
    color: $g-brand-secondary-color;
    font-size: 13px;
    font-weight: 600;
    display: block;
  }

  &__value {
    color: $g-text-color;
    font-size: 12px;
    display: block;
  }
}













// Product-l
.product-l {
  display: flex;

  &__img-wrap {
    margin-right: 20px;
  }

  &__rating {
     i {
      font-size: 12px;
    }
  }


  &__link {
    width: 110px;
    height: 110px;
  }


  &__category {
    display: block;
    > a {
      color: #a0a0a0;
      transition: color 0.5s;
      font-size: 12px;
      &:hover {
        color: $g-brand-color;
      }
    }
  }

  &__name {
    display: block;
    margin-bottom: 4px;
    > a {
      color: $g-brand-secondary-color;
      font-size: 14px;
      font-weight: 600;
      transition: color 0.5s;
      &:hover {
        color: $g-brand-color;
      }
    }
  }



  &__price {
    display: block;
    color: $g-brand-secondary-color;
    font-size: 14px;
    font-weight: 600;
  }

  &__discount {
    font-weight: 600;
    margin-left: 15px;
    color: $g-brand-color;
    font-size: 14px;
    text-decoration: line-through;
  }
}





// product-o2
.product-o2 {
  background-color: $g-white;
  box-shadow: 0 0 8px 0 rgba(0, 0, 0, 0.06);

&__wrap {
  position: relative;
  overflow: hidden;
}

&__action-wrap {
  position: absolute;
  z-index: 2;
  opacity: 0;
  transition: all 0.6s linear;
  left: 20px;
  top: 20px;
}

  &__action-list {
    margin: 0;
    padding: 0;
    text-align: center;
    list-style: none;
    // by default all children would be inline because of flex
    > li {
      margin-bottom: 6px;
      > a {
        display: inline-block;
        width: 35px;
        text-align: center;
        border-radius: 50%;
        height: 35px;
        line-height: 35px;
        background-color: $g-brand-color;
        color: $g-white;
        font-size: 12px;
        transition: all 0.3s ease 0.1s;
        &:hover {
          background-color: $g-white;
          color: $g-brand-color;
        }
      }
      &:last-child {
        margin-bottom: 0;
      }
    }
  }

&__countdown-wrap {
  position: absolute;
  right: 0;
  top: 0;
  background-color: rgba(0, 0, 0, 0.6);
  width: 60px;
  height: 100%;
}

  &__img {
    transition: all 0.6s ease-in-out;
    transform: scale(1);
  }



&__content {
  padding: 10px;
}



  &__category {
    display: block;
    margin-top: 4px;
    > a {
      color: #a0a0a0;
      transition: color 0.5s;
      font-size: 12px;
      &:hover {
        color: $g-brand-color;
      }
    }
  }

  &__name {
    display: block;
    > a {
      color: $g-brand-secondary-color;
      font-size: 14px;
      font-weight: 600;
      transition: color 0.5s;
      &:hover {
        color: $g-brand-color;
      }
    }
  }

  &__rating {
    margin-bottom: 4px;
     i {
      font-size: 12px;
    }
  }

  &__review {
    margin-left: 4px;
    font-size: 12px;
    color: #a0a0a0;
  }

  &__price {
    display: block;
    color: $g-brand-secondary-color;
    font-size: 14px;
    font-weight: 600;

  }

  &__discount {
    font-weight: 600;
    margin-left: 30px;
    color: $g-brand-secondary-color;
    font-size: 14px;
    text-decoration: line-through;
  }

}

.product-o2:hover {
  .product-o2__img {
    transform: scale(1.1);
  }


  .product-o2__action-wrap {
    opacity: 1;
  }
}


// Product-r

.product-r {
  border-radius: 15px;
  overflow: hidden;
  background-color: $g-white;
  transition: transform .3s cubic-bezier(.68,-.55,.265,1.55);
  box-shadow: 2px 2px 8px 3px rgba(36, 37, 38, 0.08);

  &__container {
    position: relative;
  }

  &__ribbon-wrap {
    position: absolute;
    top:0;
    right: 25px;
  }




  &__action-wrap {
    width: 100%;
    position: absolute;
    top: 50%;
    left: 0;
    opacity: 0;
    z-index: 2;
    transform: translateY(-50%) scale(0.8);
    transition: all 0.2s ease 0s;
  }



  &__action-list {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;// multi-line
    margin: 0;
    padding: 0;
    list-style: none;
    // by default all children would be inline because of flex
    > li {
      margin: 0 4px 6px;
      opacity: 0;// shrink
      transform: translateY(50%);
      transition: all 0.3s ease 0.1s;
      > a {
        display: block;
        width: 35px;
        text-align: center;
        border-radius: 50%;
        height: 35px;
        line-height: 35px;
        background-color: $g-white;
        color: $g-brand-color;
        box-shadow: 0 0 8px 0 rgba(0, 0, 0, 0.06);
        font-size: 12px;
        transition: all 0.3s ease 0s;
        &:hover {
          background-color: $g-white;
          color: $g-brand-color;
        }
      }
    }
  }








  &__info-wrap {
    padding: 14px;
  }

  &__category {
    display: block;
    margin-bottom: 2px;
    > a {
      color: #a0a0a0;
      transition: color 0.5s;
      font-size: 12px;
      &:hover {
        color: $g-brand-color;
      }
    }
  }




  &__n-p-wrap {
    display: flex;
    justify-content: space-between;
    margin-bottom: 6px;
  }


  &__name,&__price {
    -ms-flex: 0 1 auto;// IE10+ fix
  }

  &__name {
    display: block;
    > a {
      color: $g-brand-secondary-color;
      font-size: 14px;
      font-weight: 600;
      transition: color 0.5s;
      &:hover {
        color: $g-brand-color;
      }
    }
  }



  &__price {
    display: block;
    font-weight: 600;
    color: $g-brand-color;
    font-size: 16px;
  }


  &__description {
    margin-bottom: 6px;
    display: block;
    color: $g-text-color;
    font-size: 12px;
  }


  &:hover {
    transform: translateY(-6px);
      .product-r__action-wrap {
        opacity: 1;
        transform: translateY(-50%) scale(1);
      }

      .product-r__action-list {
        > li {
          opacity: 1;
          transform: translateY(0);
        }
      }
    }
}

// Product-best seller 2
.product-bs {
  background-color: $g-white;
 // border-radius: 20px;
  box-shadow: 0 0 8px 0 rgba(0, 0, 0, 0.06);
  transition: transform 0.7s ease-in-out;

  &__container {
      padding: 20px;
  }

  &__wrap {
    position: relative;
    margin-bottom: 4px;
  }

  &__action-wrap {
    width: 100%;
    position: absolute;
    top: 50%;
    left: 0;
    opacity: 0;
    z-index: 2;
    transform: translateY(-50%) scale(0.8);
    transition: all 0.2s ease 0s;
  }

  &__action-list {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    margin: 0;
    padding: 0;
    list-style: none;
    // by default all children would be inline because of flex
    > li {
      margin: 0 4px 6px;
      opacity: 0;// shrink
      transform: translateY(50%);
      transition: all 0.3s ease 0.1s;
      > a {
        display: block;
        width: 35px;
        text-align: center;
        border-radius: 50%;
        height: 35px;
        line-height: 35px;
        background-color: $g-brand-color;
        color: $g-white;
        font-size: 12px;
        transition: all 0.3s ease 0s;
        &:hover {
          box-shadow: 0 0 8px 0 rgba(0, 0, 0, 0.06);
          background-color: $g-white;
          color: $g-brand-color;
        }
      }
    }
  }


  &__category {
    display: block;
    > a {
      color: #a0a0a0;
      transition: color 0.5s;
      font-size: 12px;
      &:hover {
        color: $g-brand-color;
      }
    }
  }

  &__name {
    display: block;
    > a {
      color: $g-brand-secondary-color;
      font-size: 14px;
      font-weight: 600;
      transition: color 0.5s;
      &:hover {
        color: $g-brand-color;
      }
    }
  }

  &__rating {
    margin-bottom: 4px;
     i {
      font-size: 12px;
    }

  }

  &__review {
    margin-left: 4px;
    font-size: 12px;
    color: #a0a0a0;
  }

  &__price {
    display: block;
    color: $g-brand-secondary-color;
    font-size: 14px;
    font-weight: 600;

  }

  &__discount {
    font-weight: 600;
    margin-left: 30px;
    color: $g-brand-secondary-color;
    font-size: 14px;
    text-decoration: line-through;
  }

}

.product-bs:hover {
    transform: translateY(-8px);

  .product-bs__action-wrap {
    opacity: 1;
    transform: translateY(-50%) scale(1);
  }

  .product-bs__action-list {
    > li {
      opacity: 1;
      transform: translateY(0);
    }
  }


}



// Product short


.product-short {
  background-color: #fbfbfb;
  transition: transform 0.7s ease-in-out;

  &:hover {
    transform: translateY(-8px);
  }

  &__container {
    padding: 30px;
  }


  &__info {
    margin-top: 14px;
  }

  &__price {
    display: block;
    font-size: 12px;
    font-weight: 600;
    color: $g-brand-color;
  }

  &__name {
    display: block;
    > a {
      font-size: 14px;
      font-weight: 600;
      color: $g-brand-secondary-color;
      transition: color 0.5s;
      &:hover {
        color: $g-brand-color;
      }
    }
  }

  &__category {
    display: block;
    > a {
      font-size: 11px;
      color: #a0a0a0;
      transition: color 0.5s;
      &:hover {
        color: $g-brand-color;
      }
    }
  }
}
