// =============================================================================
// _NATIVE.SCSS
// -----------------------------------------------------------------------------
// Site styles.
// =============================================================================

// =============================================================================
// TABLE OF CONTENTS
// -----------------------------------------------------------------------------
//   01. Base Styles
//   02. Captions and Galleries
// =============================================================================

// Base Styles
// =============================================================================

.sticky {
  margin: 0;
}

.alignright {
  float: right;
  margin: 0.35em 0 0.35em $baseMargin;
}

.alignleft {
  float: left;
  margin: 0.35em $baseMargin 0.35em 0;
}

.alignnone {
  float: none;
  margin: 0 0 $baseMargin 0;
}

.aligncenter {
  display: block;
  margin: 0 auto $baseMargin;
}



// Captions and Galleries
// =============================================================================

//
// Shared styles.
//

.wp-caption,
.gallery-item {
  max-width: 100%;
  border: 1px solid $shortcodeBorderColor;
  border: 1px solid $shortcodeBorderColorRgba;
  padding: 5px;
  text-align: center;
  background-color: $baseModBackground;
  border-radius: 3px;
  @include box-shadow(#{$baseShortcodeBoxShadow});

  img {
    border-radius: 2px;
  }

  > .wp-caption-text,
  > .wp-caption-text:last-child {
    display: block;
    margin: 9px 0 5px;
    padding: 0 5%;
    @include font-size(1.0);
    line-height: 1.2;
    text-transform: uppercase;
  }
}


//
// Galleries.
//

.gallery {
  clear: both;
  margin: -4% 0 $baseMargin;
  @include clearfix();

  .gallery-item {
    float: left;
    margin: 4% 4% 0 0;
  }
}

.gallery-columns-0 .gallery-item,
.gallery-columns-1 .gallery-item {
  width: 100%;
}

.gallery-columns-2 .gallery-item {
  width: 48%;

  &:nth-child(2n) {
    margin-right: 0;
  }
}

.gallery-columns-3 .gallery-item {
  width: 30.6666%;

  &:nth-child(3n) {
    margin-right: 0;
  }
}

.gallery-columns-4 .gallery-item {
  width: 22%;

  &:nth-child(4n) {
    margin-right: 0;
  }

  @include break(cubs) {
    width: 48%;
    &:nth-child(2n) { margin-right: 0; }
  }
}

.gallery-columns-0 .gallery-item,
.gallery-columns-1 .gallery-item,
.gallery-columns-2 .gallery-item,
.gallery-columns-3 .gallery-item,
.gallery-columns-4 .gallery-item {
  @include break(middle-bear) {
    width: 100%;
    float: none;
    margin-right: 0;
  }
}