@import "components/header";
@import "mixins";
@import "variables";

:host {
  display: block;
}

.slate {
  background-color: #759398;
  padding-bottom: 4em;
}

.recommendations {
  max-width: 620px;
  display: flex;
  flex-direction: column;
  margin: 0 auto ;
  position: relative;
  height: 100%;
  min-height: 520px;
  opacity: 0;
  transform: translateY(100px);
  transition: .3s cubic-bezier(.25,.1,.25,1);

  &.show {
    opacity: 1;
    transform: translateY(0px);
  }

  .header {
    color: white;
  }

  .header__title {
    border-color: white;
    font-size: 2.3em;
  }
}

.recommendations__content {
    position: relative;
}

.recommendations__container {
  position: absolute;
  left: 0;
  top: 0;
  width: calc(100% + 16px);
  height: 100%;
  border-radius: 25px 25px 0 0;
  overflow: hidden;
  box-sizing: content-box;
  padding-top: 80px;
  min-height: 620px;
}

.recommendations__ad {
  text-align: center;
  background-color: #759398;
  padding-bottom: 2em;
  border: 1px solid #759398;
}

.filter-btn {
  background-color: #2d3436;
  border: none;
  height: 29px;
  width: 44px;
  border-radius: 19px;
  color: white;
  font-size: 17px;
  padding-top: 1px;
  top: 20px;
  left: 10px;
  position: absolute;
  z-index: 3;
}

.add-playlist-btn {
  background-color: transparent;
  border: none;
  height: 29px;
  border-radius: 19px;
  color: #2d3436;
  font-size: 17px;
  padding-top: 1px;
  top: 20px;
  right: 10px;
  position: absolute;
  z-index: 1;
  display: inline-block;
  cursor: pointer;

  span {
    /* Create Playlist: */
    font-size: 14px;
    font-weight: bold;
    color: #fffbfa;
    letter-spacing: 1.35px;
    text-align: center;
    margin-right: 6px;
    z-index: 1;
  }
}

.refresh-btn {
  @extend .add-playlist-btn;
  right: auto;
}

.content {
  position: relative;
}

.track-container {
  overflow-x: auto;
  width: 100%;
  height: 100%;
  -ms-overflow-style: none;  // IE 10+
  overflow: -moz-scrollbars-none;  // Firefox
  overflow-y: hidden;
  -ms-overflow-style: none;  /* IE and Edge */
  scrollbar-width: none;
  &::-webkit-scrollbar {
    display: none;
  }

}


.card-track {
  display: flex;
  overflow-y: hidden;
  overflow-x: scroll;
  width: 2700px;
  z-index: 1;
  padding-left: 1.5em;
  flex-wrap: wrap;
  height: 470px;
  align-items: flex-start;
  align-content: baseline;
  -webkit-box-align: start;
  -ms-overflow-style: none;  /* IE and Edge */
  scrollbar-width: none;
  /* Firefox */

  &::-webkit-scrollbar {
    display: none;
  }

  .card {
    background: none;
    width: 252px;
    height: 200px;
    margin-right: 70px;
    position: relative;
    img {
      object-fit: cover;
      width: 100%;
      max-height: 100%;
    }

    .card-info {
      background: #2d3436;
      box-shadow: -12px 5px 4px 0 rgba(0, 0, 0, 0.5);
      width: 252px;
      height: 142px;
      position: absolute;
      left: -16px;
      top: 70px;
      display: flex;
      flex-wrap: wrap;
      align-content: flex-end;
      justify-content: flex-start;
      padding: 16px 16px;
      transition: .3s cubic-bezier(.25,.1,.25,1);
      box-sizing: border-box;

      h3 {
        font-size: 1em;
        margin: 0 0 5px;
        width: 100%;
        color: #fff;
      }

      p {
        color: #fff;
        font-size: 1em;
        margin: 0;
        font-family: $secondary-font;
      }
    }
    .card-content {
      background: #fffbfa;
      width: 252px;
      height: 142px;
      margin-right: 70px;
      position: relative;
    }

    &:nth-child(9) {
      margin-left: 40px;
    }

    &:nth-child(1n + 9) {
      margin-top: 50px;
    }
  }
}

  @include desktop {
    .recommendations {
      max-width: 1024px;
      margin: 0 auto;

      .header__title {
        border-color: white;
        font-size: 3em;
      }

      &__container {
        position: relative;
      }

      .track-container {
        overflow: hidden;
      }

      .card-track {
        height: 100%;
        width: 100%;
        overflow: hidden;

        .card {
          min-height: 240px;
          &:nth-child(9) {
            margin-left: 0;
          }

          &:nth-child(1n + 9) {
            margin-top: 0;
          }
        }

      }
    }

  }
