

@import "../tfl-lib";

/* ---------------------------------- Posts Carousel ---------------------------------- */

.tfl-posts-carousel {
  clear: both;
  max-width: none;
  @include respond-to-min(1024) {
    max-width: 96%;
  }

  &.tfl-classic-skin .tfl-posts-carousel-item {
    .hentry {
      background: #fff;
      border-radius: 6px;
      border: none;
      padding: 0;
      margin: 0;
      transition: box-shadow .25s ease 0s;
      box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
      overflow: hidden;

      &:hover {
        box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
      }
    }

    .tfl-project-image {
      position: relative;
      overflow: hidden;

      img {
        width: 100%;
        display: block;
        transition: all .4s ease-in-out 0s;
        max-width: 100%;
      }

      &:hover {
        img {
          filter: brightness(50%);
        }
      }

      .tfl-image-info {
        display: block;
        text-align: center;

        .tfl-entry-info {
          text-align: center;
          display: block;
          position: absolute;
          top: 50%;
          left: 0;
          right: 0;
          margin: auto;
          max-width: 100%;
          transform: translateY(-50%);
        }

        .tfl-post-title {
          padding: 10px;
          margin: 0;
          font-size: 22px;
          line-height: 34px;
          font-weight: 400;
          color: #fff;
          opacity: 0;
          transition: opacity .4s ease-in-out 0s;
          @include respond-to-max(1024) {
            font-size: 18px;
            line-height: 26px;
          }

          a {
            display: inline;
            color: #fff;
            transition: all .3s ease-in-out 0s;
            border-bottom: 1px solid transparent;

            &:hover {
              border-bottom: 2px solid #ccc;
            }
          }
        }

        .tfl-terms {
          display: block;
          color: #f9f9f9;
          font-size: 14px;
          line-height: 22px;
          opacity: 0;
          transition: opacity .4s ease-in-out 0s;

          a {
            color: #ddd;
            position: relative;
            display: inline;
            zoom: 1;
            font-size: 14px;
            line-height: 22px;
            font-style: italic;
            transition: all .4s ease-in-out 0s;

            &:hover {
              color: #fff;
            }
          }
        }
      }

      &:hover {
        .tfl-image-info {
          .tfl-post-title, .tfl-terms {
            opacity: 1;
          }
        }
      }
    }

    .tfl-entry-text-wrap {
      text-align: center;
      max-width: 650px;
      margin: 0 auto;
      padding: 25px 15px;

      .entry-title {
        @include tfl-heading-style();
        font-size: 16px;
        line-height: 24px;
        margin-bottom: 10px;

        &:after, &:before {
          display: none;
        }

        a {
          color: #333333;
          transition: all .4s ease-in-out 0s;

          &:hover {
            color: #888;
          }
        }
      }

      .tfl-entry-meta {
        span {
          display: inline-block;
          padding: 0;
          margin: 0;
          font-style: italic;
          color: #999;

          a {
            @include transition(all 0.3s ease-in-out 0s);
            font-style: normal;
          }

          &:after {
            content: '//';
            padding-left: 6px;
            padding-right: 6px;
          }

          &:first-child {
            border: none;
            padding-left: 0;
          }

          &:last-child:after {
            display: none;
          }
        }
      }

      .entry-summary {
        padding: 0;
        margin: 10px auto 0;

        &:before {
          width: 35px;
          height: 1px;
          background: #aaa;
          display: block;
          content: "";
          text-align: center;
          margin: 0 auto 15px;
        }
      }

      .tfl-category-list {

        @include bottom-line(35, 1, #aaa);
        transition: all .4s ease-in-out 0s;

        &:after {
          text-align: center;
          margin: 10px auto 10px;
        }
      }

      .tfl-category-list a {
        font-style: italic;
        transition: all .4s ease-in-out 0s;
      }
    }

    .type-post .tfl-entry-text-wrap .entry-summary:before {
      display: none;
    }
  }
}

.tfl-posts-carousel .tfl-posts-carousel-item {

  .tfl-read-more {
    margin: 25px 0 0 0;
  }

  .tfl-read-more a:not(.tfl-button) {
    color: #333;
    font-size: 12px;
    line-height: 1;
    font-weight: 600;
    text-transform: uppercase;
    display: block;
    padding: 0;
    transition: color 0.3s ease-in-out 0s;

    &:hover {
      color: #666;
    }

    &:after {
      content: '›';
      display: inline-block;
      margin-left: 7px;
    }

    .rtl & {
      &:after {
        margin: 0 7px 0 0;
      }
    }
  }
}