//   licensed under the Affero General Public License version 3 or later.  See
//   the COPYRIGHT file.

@import '_mixins.css.scss';

#lightbox{
  z-index: 1003;
  position: fixed;
  top: 0;
  right: 0;
  display: none;
  overflow-y: auto;
  width: 100%;
  text-align: center;
  padding-top: 80px;
  padding-bottom: 20px;

  color: #666;
  text-shadow: none;
  font-size: 12px;

  &.show{
    position: absolute;
    display: block;
  }

  #lightbox-image{
    @include box-shadow(0, 10px, 20px, black);
    top: 0;
    display: block;
    margin-bottom: 120px;
  }

  #lightbox-content{
    text-align: left;
    display: inline-block;
  }

  #lightbox-links{
    margin-top: 12px;

    .attribution{
      float: right;
    }

    #lightbox-attribution-link{
      color: #999;
      font-weight: bold;
      &:hover{
        color: #eee;
      }
    }
  }

  #lightbox-close-link,
  #lightbox-attribution-link,
  #lightbox-short-link{
    display: inline-block;
    color: #333;
    text-decoration: none;
    line-height: 14px;

    &:hover{
      color: #eee;
    }
  }

  #lightbox-close-link{
    color: #666;
    margin-bottom: 12px;
  }
}

#lightbox-backdrop{
  -moz-box-shadow:inset 0 0 50px #000000;
  -webkit-box-shadow:inset 0 0 50px #000000;
  box-shadow:inset 0 0 50px #000000;

  z-index: 1002;
  position: fixed;
  height: 100%;
  width: 100%;
  top: 0;
  left: 0;
  background-color: rgba(0,0,0,0.9);
  display: none;
}

#lightbox-imageset{
  z-index: 1004;
  position: fixed;
  width: 100%;
  left: 0;
  bottom: 0;
  display: none;
  text-align: center;
  background-color: rgba(0,0,0,0.4);
  padding: 5px 0;

  img{
    @include transition(opacity, 0.2s);
    @include opacity(0.2);
    height: 70px;
    width: 70px;
    margin-right: 5px;
    cursor: pointer;

    &:last-child{
      margin-right: 0;
    }

    &.selected{
      @include opacity(1);
    }
  }
}

body.lightboxed{
  overflow: hidden;
  #lightbox-backdrop,
  #lightbox-imageset{
    display: block;
  }
}

