.preview-container {
  position: relative;
  width: 100%;
  max-height: 110px;
  height: 110px;
  white-space: nowrap;
  overflow: auto;
  .preview-div {
    display: inline-block;
    width: 120px;
    height: 100px;
    margin: 7px 10px 0 0;
    vertical-align: top;
    position: relative;
    border: 1px solid #DDD;
    @include clearfix;
    &:hover .remove-preview:after {
      @include opacity(1);
    }
    .spinner {
      position:absolute;
      top:50%;
      left:50%;
      margin-left: -16px;
      margin-top: -16px;
      width:32px;
      height:32px;
    }
  }
  .preview-img {
      display: block;
      height: auto;
      max-width: 100%;
  }
  .remove-preview {
    position: absolute;
    width: 100%;
    height: 100%;
    left: 0;
    top: 0;
    &:after {
      background: rgba(0, 0, 0, 0.4);
      content: '';
      height: 100%;
      left: 0;
      opacity: 0;
      position: absolute;
      top: 0;
      width: 100%;
      @include opacity(0);
    }
    i {
      top: 5px;
      right: 5px;
      position: absolute;
      color: #fff;
      cursor: pointer;
      z-index: 5;
      opacity: inherit;
    }
  }
}

.image-comment {
  background-position:left top;
  background-repeat:no-repeat;
  width:300px;
  height:300px;
}

@mixin file-icon($path) {
  background: #fff url($path);
  background-position: center;
  background-repeat: no-repeat;
  @include background-size(60px auto);
}
.file-icon {
  width: 100%;
  height: 100%;
  &.audio {
    @include file-icon("../images/icons/audio.png");
  }
  &.video {
    @include file-icon("../images/icons/video.png");
  }
  &.ppt {
    @include file-icon("../images/icons/ppt.png");
  }
  &.generic {
    @include file-icon("../images/icons/generic.png");
  }
  &.code {
    @include file-icon("../images/icons/code.png");
  }
  &.excel {
    @include file-icon("../images/icons/excel.png");
  }
  &.word {
    @include file-icon("../images/icons/word.png");
  }
  &.pdf {
    @include file-icon("../images/icons/pdf.png");
  }
  &.patch {
    @include file-icon("../images/icons/patch.png");
  }
  &.image {
    @include file-icon("../images/icons/image.png");
  }
}
.post-image__column {
  position: relative;
  width: 240px;
  height: 100px;
  float: left;
  margin: 5px 10px 5px 0;
  display: table;
  border: 1px solid lightgrey;
  .post__load {
    height: 100%;
    width: 100%;
    background-size: 20px 20px;
    background-repeat: no-repeat;
    background-position: center;
  }
  .post__image {
    width: 100%;
    height: 100%;
    background-color: #FFF;
    background-repeat: no-repeat;
    &.small {
        background-position: center;
    }
    &.normal {
        background-position: top left;
    }
  }
  .post-image__thumbnail {
    display: table-cell;
    vertical-align: top;
    width: 50%;
    height: 100%;
  }
  .post-image__details {
    display: table-cell;
    vertical-align: top;
    width: 50%;
    height: 100%;
    background: white;
    border-left: 1px solid #ddd;
    font-size: 13px;
    padding: 7px;
    .post-image__name {
      margin-bottom: 3px;
    }
    .post-image__type {
      color: grey;
    }
    .post-image__size {
      margin-left: 4px;
      color: grey;
    }
  }
  a {
    text-decoration: none;
    color: grey;
  }
}

.file-details__container {
    @include display-flex;
    display: -ms-flexbox;

    .file-details {
        width: 320px;
        height: 270px;
        padding: 14px;
        text-align: left;
        vertical-align: top;

        .file-details__name {
            font-size: 16px;
        }
        .file-details__info {
            color: grey;
        }
    }
    .file-details__preview {
        width: 320px;
        height: 270px;
        border-right: 1px solid #ddd;
        vertical-align: center;

        // helper to center the image icon in the preview window
        .file-details__preview-helper {
            height: 100%;
            display: inline-block;
            vertical-align: middle;
        }
    }
}
