// =============================================================================
// _FLEXSLIDER.SCSS
// -----------------------------------------------------------------------------
// Site styles.
// =============================================================================

// =============================================================================
// TABLE OF CONTENTS
// -----------------------------------------------------------------------------
//   01. Browser Resets
//   02. Necessary Styles
//   03. Slider Theme
// =============================================================================

// Browser Resets
// =============================================================================

.flex-container a:active,
.x-flexslider a:active {
  outline: none;
}

.x-slides,
.flex-control-nav,
.flex-direction-nav {
  margin: 0;
  padding: 0;
  list-style: none;
}



// Necessary Styles
// =============================================================================

.x-flexslider {
  margin: 0;
  padding: 0;
}

.x-flexslider .x-slides {
  .x-slide {
    display: none;
    position: relative;
  }

  img {
    width: 100%;
    display: block;
  }
}

.flex-pauseplay span {
  text-transform: capitalize;
}


//
// Clearfix for the .x-slides element.
//

.x-slides {
  @include cf();
}


//
// No JavaScript fallback.
//

.no-js .x-slides > li:first-child {
  display: block;
}



// Slider Theme
// =============================================================================

.x-flexslider {
  width: 100%;
  margin: 0 0 $baseMargin;
  position: relative;
}

.x-flexslider-featured-gallery {
  background: $baseModBackground;
}

.flex-viewport {
  max-height: 2000px;
  transition: all 1s ease;
}

.loading .flex-viewport {
  max-height: 300px;
}


//
// Direction nav.
//

.flex-direction-nav a {
  display: block;
  cursor: pointer;
  position: absolute;
  top: 50%;
  width: 30px;
  height: 30px;
  margin-top: -17px;
  font-size: 30px;
  line-height: 30px;
  text-align: center;
  text-shadow: 0 2px 2px rgba(0, 0, 0, 0.325);
  color: $white;
  opacity: 0.5;
  transition: opacity 0.3s ease;
  z-index: 10;

  [class*="#{$fa-css-prefix}-"] {
    width: auto;
  }

  &:hover {
    text-decoration: none;
    color: $white;
    opacity: 1;
  }

  &.flex-prev {
    left: 14px;
  }

  &.flex-next {
    right: 14px;
  }
}


//
// Control nav.
//

.flex-control-nav {
  position: absolute;
  line-height: 1;
  text-align: center;
  z-index: 10;

  &:not(.flex-control-thumbs) {
    left: 14px;
    right: 14px;
    bottom: 14px;
    padding: 0 4px;
    background-color: $baseModBackground;

    li {
      margin: 7px 4px 6px;
      text-indent: -9999px;
    }
  }

  &.flex-control-thumbs {
    top: 0;
    right: 0;
    padding: 1em;

    li {
      background-color: $black;
      box-shadow: 0 0.15em 0.625em rgba(0, 0, 0, 0.215);

      &:not(:first-child) {
        margin-left: 0.5em;
      }
    }

    img {
      width: auto;
      height: 1.5em;
      vertical-align: top;
      transition: opacity 0.3s ease;
      cursor: pointer;

      &:not(:hover):not(.flex-active) {
        opacity: 0.65;
      }
    }
  }

  li {
    display: inline-block;
  }

  a {
    display: block;
    width: 14px;
    height: 14px;
    background-color: $baseModBackground;
    border-radius: 100em;
    opacity: 0.5;
    transition: opacity 0.3s ease;

    &:hover {
      cursor: pointer;
      opacity: 1;
    }

    &.flex-active {
      opacity: 1;
    }
  }
}