/*!
 * DokuWiki Bootstrap3 Template: TOC
 *
 * Home     http://dokuwiki.org/template:bootstrap3
 * Author   Giuseppe Di Terlizzi <giuseppe.diterlizzi@gmail.com>
 * License  GPL 2 (http://www.gnu.org/licenses/gpl.html)
 */
#dw__toc {

  &.affix                            { z-index: 999; }
  .toc-title                         { cursor: pointer; margin-top: 0; }
  .toc-body > ul                     { overflow-y: auto !important; padding-left: 10px; }

  .nav > li > a                      { /*color: #666;*/ padding: 4px 20px; font-weight: 500; display: block; word-break: keep-all; }
  .nav > li > a:hover                { background-color: transparent; color: initial; }
  .nav > li > a:hover                { border-left: 1px solid #428bca; }

  .nav .nav                          { padding-bottom: 10px; }
  .nav .nav .nav > li > a            { padding-top: 1px; padding-bottom: 1px }
  .nav .nav .nav > .active > a       { font-weight: 500;   }

  /* .nav .nav .nav                    { display: none;  } */
  .nav > .active > ul                { display: block !important; }

  .nav > li > a                      { padding-left: 20px; }
  .nav .nav > li > a                 { padding-left: 30px; }
  .nav .nav .nav > li > a            { padding-left: 40px; }
  .nav .nav .nav .nav > li > a       { padding-left: 50px; }


  .nav > li > a:hover                { padding-left: 19px; }
  .nav .nav > li > a:hover           { padding-left: 29px; }
  .nav .nav .nav > li > a:hover      { padding-left: 39px; }
  .nav .nav .nav .nav > li > a:hover { padding-left: 49px; }

  .nav > .active > a,
  .nav > .active > a:hover                { padding-left: 18px; }

  .nav .nav > .active > a,
  .nav .nav > .active > a:hover           { padding-left: 28px; }

  .nav .nav .nav > .active > a,
  .nav .nav .nav > .active > a:hover      { padding-left: 38px; }

  .nav .nav .nav .nav > .active > a,
  .nav .nav .nav .nav > .active > a:hover { padding-left: 48px; }

  .nav > .active > a,
  .nav > .active > a:hover,
  .nav > .active > a:focus {
    font-weight: bold;
    background-color: transparent;
    border-left: 2px solid #428bca;
  }

}

.dw-toc {
  width: 16em;
  float: right;
  height: auto;
  margin: 0 0 1.5em 1.5em;
}

.dw-toc-closed {
  .toc-title span,
  .toc-body         { display: none; }
  .dw-toc {
    position: absolute;
    width: 50px;
    right: 30px;
  }
}

.toc-panel .panel-body {
  padding: 0;
}

.toc-panel .panel-heading {
  margin-bottom: 0;
  padding: 5px;
}

.toc-panel {
  &.dw-toc-left  { 
    float: left;
    margin: 0 1.5em 1.5em 0;

    .dw-toc-closed {
      right: auto;
    }
  }
}
