/* @group book reader */

body.template-book_reader_view {

  $reader-bg: $body-background;
  $reader-border: #555;

  background: $lightgray2;

  /* Hide unused elements */
  #header,
  #portal-topactions,
  #portal-breadcrumbs,
  #bottom-actions,
  div#viewlet-below-content,
  #banner-image,
  div.row.belowContent,
  #ftw-footer {
    display: none;
  }

  /* remove max width */
  .fixedWidth {
    width: auto;
  }

  #page-wrapper {
    margin-top: 1.25em;
    background: transparent;
    @include boxshadow(none);
    border: none;
  }

  .book-reader {
    max-width: 1000px;
    width: 94%;
    margin: 0 auto;
    padding: 1em 2%;
    /* padding-left: 0; */
    background: $reader-bg;
    border: 1px solid $reader-border;
    @include boxshadow(0 0 1em #aaa);
    font-size: 125%;
    line-height: 1.5em;
    position: relative;
  }
  .book-reader-navigation {
    width: 15em;
    a {
      color: #000;
      font-size: 90%;
    }
  }

  .book-reader-content {
    background: $page-background;
    padding: 1em;
    @include boxshadow(0 0 0.25em $reader-border);
  }

  #content .book-reader-navigation a:hover {
    text-decoration: underline;
  }
  #content .book-reader-navigation a.active {
    color: #000;
    text-decoration: underline;
  }
  #content .book-reader-navigation ul {
    margin-left: 1.25em;
    &.book-reader-navigation-0 {
      margin-left: 0;
    }
  }

  #content #close-book-reader {
    display: block;
    position: absolute;
    top: -1em;
    right: -1em;
    text-indent: -1000em;
    background: url(%THEME_URL%/images/pb_close.png) no-repeat center center;
    width: 2em;
    height: 2em;
  }

}

/* @end */

/* @group responsive book reader */

@media screen and (max-width: 769px) {
  body.template-book_reader_view {
    #page-wrapper {
      margin-top: 0.5em;
    }
    .book-reader {
      background: none;
      border: none;
      @include boxshadow(none);
      padding: 0;
      margin: 0;
      width: 100%;
    }
    .book-reader-navigation {
      display: none;
    }
    #content #close-book-reader {
      right: 0;
      top: 0;
      background: none;
      text-indent: 0;
      width: auto;
      height: auto;
      position: relative;
      text-align: center;
    }
  }
}


/* @end */