/**
 * Template: Clients
 */

/* Utils */

/**
 * Variables
 */

.clients-list {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-gap: 80px;
}

.client-single {
  display: -webkit-box;
  display: -webkit-flex;
  display: -moz-box;
  display: -ms-flexbox;
  display: flex;
  -webkit-box-align: center;
  -webkit-align-items: center;
     -moz-box-align: center;
      -ms-flex-align: center;
          align-items: center;
  -webkit-box-pack: center;
  -webkit-justify-content: center;
     -moz-box-pack: center;
      -ms-flex-pack: center;
          justify-content: center;
  position: relative;
  cursor: url(../images/templates/home/mouse-hover.svg) 20 40, auto;
}

.client-single img {
  -webkit-transition: .3s ease;
  -o-transition: .3s ease;
  transition: .3s ease;
  -webkit-filter: grayscale(1);
          filter: grayscale(1);
}

.client-single:hover img,
.client-single.open img {
  -webkit-filter: grayscale(0);
          filter: grayscale(0);
}

.client-single__popup {
  background: #f0f0f1;
  font-size: 17px;
  font-weight: 100;
  color: #231f20;
  padding: 7px 16px;
  position: absolute;
  line-height: 1.2;
  top: 12px;
  -webkit-transform: translateX(145px);
      -ms-transform: translateX(145px);
          transform: translateX(145px);
  -webkit-transition: .3s ease;
  -o-transition: .3s ease;
  transition: .3s ease;
  opacity: 0;
  pointer-events: none;
}

.client-single__popup:before {
  content: '';
  position: absolute;
  left: -18px;
  top: 0;
  width: 0;
  height: 0;
  border-top: 0 solid transparent;
  border-bottom: 24px solid transparent;
  border-right: 19px solid #f0f0f1;
}

.client-single__popup-close {
  position: absolute;
  left: 4px;
  top: 4px;
}

.client-single ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.client-single li:last-child {
  margin-bottom: 0 !important;
}

.client-single li:not(:last-child) {
  margin-bottom: 4px !important;
  padding-bottom: 4px;
  border-bottom: 1px solid #231f20;
}

@media (min-width: 992px) {
  .client-single:hover .client-single__popup {
    -webkit-transform: translateX(150px);
        -ms-transform: translateX(150px);
            transform: translateX(150px);
    opacity: 1;
    pointer-events: all;
  }

  .client-single__popup-close {
    display: none;
  }
}

@media (max-width: 1600px) {
  .clients-list {
    grid-gap: 70px;
  }
}

@media (max-width: 1400px) {
  .clients-list {
    grid-gap: 60px;
  }

  .client-single__popup {
    -webkit-transform: translateX(245px);
        -ms-transform: translateX(245px);
            transform: translateX(245px);
    top: 0;
  }
}

@media (max-width: 1250px) {
  .client-single__popup {
    -webkit-transform: translateX(175px);
        -ms-transform: translateX(175px);
            transform: translateX(175px);
    top: 20px;
  }
}

@media (max-width: 991px) {
  .clients-list {
    grid-template-columns: repeat(2, 1fr);
  }

  .client-single__popup {
    -webkit-transform: translateY(-5px);
        -ms-transform: translateY(-5px);
            transform: translateY(-5px);
    top: auto;
    font-size: 21px;
    padding: 25px 16px 15px 16px;
    min-width: 205px;
    -webkit-box-shadow: 0 1px 6px 0 rgba(0, 0, 0, 0.24);
            box-shadow: 0 1px 6px 0 rgba(0, 0, 0, 0.24);
    bottom: -95%;
    z-index: 10;
  }

  .client-single__popup.open {
    opacity: 1;
    pointer-events: all;
    -webkit-transform: none;
        -ms-transform: none;
            transform: none;
  }

  .client-single__popup:before {
    border-top: none;
    border-left: 19px solid transparent;
    border-right: 19px solid transparent;
    border-bottom: 24px solid #f0f0f1;
    left: 50%;
    -webkit-transform: translateX(-50%);
        -ms-transform: translateX(-50%);
            transform: translateX(-50%);
    top: -22px;
  }
}

@media (max-width: 500px) {
  .clients-list {
    grid-gap: 30px;
  }
}

@media (max-width: 400px) {
  .client-single__popup {
    min-width: 150px;
    font-size: 17px;
    bottom: -100%;
  }
}

@media (max-width: 360px) {
  .clients-list {
    grid-gap: 25px;
  }
}

@media (min-width: 992px) and (max-width: 1400px) {
  .client-single:hover .client-single__popup {
    -webkit-transform: translateX(250px);
        -ms-transform: translateX(250px);
            transform: translateX(250px);
  }
}

@media (min-width: 992px) and (max-width: 1250px) {
  .client-single:hover .client-single__popup {
    -webkit-transform: translateX(180px);
        -ms-transform: translateX(180px);
            transform: translateX(180px);
  }
}

@media (min-width: 992px) and (max-width: 991px) {
  .client-single:hover .client-single__popup {
    -webkit-transform: none;
        -ms-transform: none;
            transform: none;
  }
}