$component: 'videos';
$template: 'template-4';
$item: 'widget-item';

$color-black-1: #1B1E25;
$color-black-2:#404040;
$color-gray-1: #808080;
$color-gray-2: #B0B0B0;
$color-gray-3: #E8E8E8;
$color-gray-4: #F2F2F2;

@mixin webkit-box ($lines, $line-height) {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: $lines;
  overflow: hidden;
  max-height: #{$lines * $line-height}px;
}
@mixin border-radius ($radius) {
  -webkit-border-radius: $radius;
  -moz-border-radius: $radius;
  border-radius: $radius;
}
@mixin transition ($property, $duration) {
  -webkit-transition-property: $property;
  -moz-transition-property: $property;
  -ms-transition-property: $property;
  -o-transition-property: $property;
  transition-property: $property;
  -webkit-transition-duration: $duration;
  -moz-transition-duration: $duration;
  -ms-transition-duration: $duration;
  -o-transition-duration: $duration;
  transition-duration: $duration;
}

.widget.c-#{$component}.c-#{$component}-#{$template} {
  .#{$item}-body {
    position: relative;

    &[data-role="big.elements"] {
      .#{$item}-name {
        position: absolute;
        left: 24px;
        right: 24px;
        bottom: 24px;

        color: #fff;
      }

      .#{$item}-picture {
        &:after {
          content: '';
          position: absolute;
          width: 100%;
          height: 100%;
          background: #000;
          top: 0;
          left: 0;
          opacity: 0.5;
        }

        svg {
          max-width: 80px;
          max-height: 80px;
          z-index: 1;
        }
      }
    }
  }
  .#{$item}-picture {
    position: relative;
    padding-top: #{100% / 16 * 9};
    background-size: cover;
    background-color: #E7F1FF;
    background-repeat: no-repeat;
    background-position: center;
    cursor: pointer;
    @include border-radius(2px);

    svg {
      max-width: 48px;
      max-height: 48px;
      position: absolute;
      top: 50%;
      left: 50%;
      pointer-events: none;
      -webkit-transform: translate(-50%, -50%);
      -moz-transform: translate(-50%, -50%);
      -ms-transform: translate(-50%, -50%);
      -o-transform: translate(-50%, -50%);
      transform: translate(-50%, -50%);
      @include transition(transform, 0.4s);
    }
    &:hover {
      svg {
        -webkit-transform: translate(-50%, -50%) scale(1.1);
        -moz-transform: translate(-50%, -50%) scale(1.1);
        -ms-transform: translate(-50%, -50%) scale(1.1);
        -o-transform: translate(-50%, -50%) scale(1.1);
        transform: translate(-50%, -50%) scale(1.1);
      }
    }

    > img {
      display: none;
    }
  }
  .#{$item}-name {
    font-style: normal;
    font-weight: normal;
    font-size: 14px;
    line-height: 24px;
    color: $color-black-2;
    margin-top: 16px;

    @include webkit-box(2, 24);
  }

  .widget-header {
    overflow: hidden;
  }
  .widget-all-container {
    display: none;
  }
  .widget-all-button {
    font-size: 14px;
    font-weight: 500;
    line-height: 1;
    color: #808080;
    text-decoration: none;
    text-transform: uppercase;
    letter-spacing: 0.1em;

    i {
      display: none;
      font-size: 18px;
    }
  }

  @media all and (max-width: 550px) {
    .widget-all-container {
      display: block;
    }
    .widget-title.align-center.widget-title-margin {
      margin-left: 25px;
    }
    .widget-all-container.mobile {
      text-align: right;
      width: 25px;
      max-height: 36px;
    }
    .widget-all-container i {
      display: inline-block;
    }
    .widget-footer.mobile,
    .widget-footer-button.mobile{
      display: none;
    }
    .widget-all-container {
      width: 25px;
    }
  }

  @media all and (max-width: 768px) {
    .#{$item}-body {
      &[data-role="big.elements"] {
        .#{$item}-name {
          position: relative;
          left: initial;
          right: initial;
          bottom: initial;
          color: $color-black-2;
        }

        .#{$item}-picture {
          &:after {
            display: none;
          }

          svg {
            max-width: 48px;
            max-height: 48px;
            z-index: 1;
          }
        }
      }
    }
  }
}