/* This stylesheet is used for styling the dynamic sticky table of contents (toc) on applicable pages. */
/* The following code was taken from https://github.com/afeld/bootstrap-toc/blob/gh-pages/bootstrap-toc.css with minor changes */

/*!
 * Bootstrap Table of Contents v<%= version %> (http://afeld.github.io/bootstrap-toc/)
 * Copyright 2015 Aidan Feldman
 * Licensed under MIT (https://github.com/afeld/bootstrap-toc/blob/gh-pages/LICENSE.md) */

/* modified from https://github.com/twbs/bootstrap/blob/94b4076dd2efba9af71f0b18d4ee4b163aa9e0dd/docs/assets/css/src/docs.css#L548-L601 */

/* All levels of nav */
nav[data-toggle="toc"] .nav > li > a {
  display: block;
  padding: 4px 0px 4px 20px;
  font-size: 15px;
  font-weight: 500;
  color: #767676;
}
nav[data-toggle="toc"] .nav > li > a:hover,
nav[data-toggle="toc"] .nav > li > a:focus {
  padding-left: 19px;
  color: #0085a1;
  text-decoration: none;
  background-color: transparent;
  border-left: 1px solid #0085a1;
}
nav[data-toggle="toc"] .nav-link.active,
nav[data-toggle="toc"] .nav-link.active:hover,
nav[data-toggle="toc"] .nav-link.active:focus {
  padding-left: 18px;
  font-weight: bold;
  color: #0085a1;
  background-color: transparent;
  border-left: 2px solid #0085a1;
}

/* Nav: second level (shown on .active) */
nav[data-toggle="toc"] .nav-link + ul {
  display: none; /* Hide by default, but at >768px, show it */
  padding-bottom: 10px;
}

nav[data-toggle="toc"] .nav .nav > li > a {
  padding-top: 1px;
  padding-bottom: 1px;
  padding-left: 30px;
  font-size: 13px;
  font-weight: normal;
}
nav[data-toggle="toc"] .nav .nav > li > a:hover,
nav[data-toggle="toc"] .nav .nav > li > a:focus {
  padding-left: 29px;
}
nav[data-toggle="toc"] .nav .nav > li > .active,
nav[data-toggle="toc"] .nav .nav > li > .active:hover,
nav[data-toggle="toc"] .nav .nav > li > .active:focus {
  padding-left: 28px;
  font-weight: 500;
}

nav[data-toggle="toc"] .nav-link.active + ul {
  display: block;
}


/* Original styling by Jennifer Jin (j.jennifer@wustl.edu) ******************************/
#toc_sidebar {
    padding-left: 0px;
    overflow-wrap: anywhere;
}

#toc_sidebar nav {
    top: 5rem;
}

/* This container is only used for pages where there seems to be too much white space on the sides */
#main_content_container {
    /* Reduces default side margins (from ~7.36%) to fit more content on page */
    margin-left: 5%;
    margin-right: 5%;
    max-width: fit-content;
}

@media (max-width: 992px) {
    #main_content_container {
        margin-left: 5.79%;
        margin-right: 5.79%;
    }
    nav[data-toggle="toc"] .nav > li > a {
        /* Reduce font size */
        font-size: 13px;
    }
    nav[data-toggle="toc"] .nav .nav > li > a {
        /* Reduce font size for only nested headings */
        font-size: 12px;
    }
}

/* 768px is the width where the TOC stops being sticky (and is on top of the main content) */
@media (max-width: 768px) {
    #toc_sidebar {
        margin-bottom: 40px;
    }
    #main_content_container {
        margin-left: 6.57%;
        margin-right: 6.57%;
    }
    nav[data-toggle="toc"] .nav > li > a {
        /* Re-adjust font size */
        font-size: 15px;
    }
    nav[data-toggle="toc"] .nav .nav > li > a {
        /* Reduce font size for only nested headings */
        font-size: 13px;
    }
}

@media (max-width: 576px) {
    #main_content_container {
        margin-left: 7.36%;
        margin-right: 7.36%;
    }
}




