/* Layout */
* {
    margin: 0;
}
html {
    overflow-y: scroll;
}
html, body {
    height: 100%;
}
body {
    padding-top: 70px;
}
.container {
    width: auto;
    max-width: 1600px;
}
.wrapper {
    min-height: 100%;
    height: auto !important;
    margin: 0 auto -61px; /* the bottom margin is the negative value of the footer's height */
    padding-bottom: 30px;
}
.navbar-brand {
    padding: 12px 15px 8px;
}
.footer, .push {
    height: 60px; /* .push must be the same height as .footer */
}
.footer {
    background-color: #f5f5f5;
    border-top: 1px solid #d0d0d0;
}
footer p {
    margin: 20px 0;
}
#navbar_search {
    padding: 0 8px;
}

/* Hide the username in the navigation menu on displays less than 1400px wide */
@media (max-width: 1399px) {
    #navbar_user {
        display: none;
    }
}

/* Hide the search bar in the navigation menu on displays less than 1250px wide */
@media (max-width: 1249px) {
    #navbar_search {
        display: none;
    }
}

/* Printer friendly CSS class and various fixes for printing. */
@media print {
    body {
        padding-top: 0px;
    }
    a[href]:after {
        content: none !important;
    }
    .noprint {
        display: none !important;
    }
}

/* Scroll the drop-down menus at or above 768px wide to match bootstrap's behavior for hiding dropdown menus */
@media (min-width: 768px) {
    .navbar-nav > li > ul {
        max-height: calc(80vh - 50px);
        overflow-y: auto;
    }
}

/* Collapse the nav menu on displays less than 980px wide */
@media (max-width: 979px) {
    #navbar {
        max-height: calc(80vh - 50px);
        overflow-y: auto;
    }
    .navbar-header {
        float: none;
    }
    .navbar-left,.navbar-right {
        float: none !important;
    }
    .navbar-toggle {
        display: block;
    }
    .navbar-collapse {
        border-top: 1px solid transparent;
        box-shadow: inset 0 1px 0 rgba(255,255,255,0.1);
    }
    .navbar-fixed-top {
        top: 0;
        border-width: 0 0 1px;
    }
    .navbar-collapse.collapse {
        display: none!important;
        max-height: none;
    }
    .navbar-nav {
        float: none !important;
        margin-top: 7.5px;
    }
    .navbar-nav>li {
        float: none;
    }
    .navbar-nav>li>a {
        padding-top: 10px;
        padding-bottom: 10px;
    }
    .collapse.in {
        display:block !important;
    }
    #navbar_user {
        display: inline;
    }
}

/* Navigation menu */
li.subnav > a {
    padding-left: 30px;
}
ul.dropdown-menu {
    width: 250px;
}
ul.dropdown-menu div.buttons {
    padding-right: 10px;
    padding-top: 2px;
}
ul.dropdown-menu div.buttons a {
    width: 26px;
}
ul.dropdown-menu > li > a {
    clear: left;
}
.nav > li > a.dropdown-toggle {
    padding: 15px 12px;
}

/* Forms */
label {
    font-weight: normal;
}
label.required {
    font-weight: bold;
}
input[name="pk"] {
    margin-top: 0;
}


/* Tables */
th.pk, td.pk {
    padding-bottom: 6px;
    padding-top: 10px;
    width: 30px;
}
tfoot td {
    font-weight: bold;
}
table.attr-table td:nth-child(1) {
    width: 25%;
}
.table-headings th {
    background-color: #f5f5f5;
}
td.min-width {
    width: 1%;
}

/* Paginator */
div.paginator {
    margin-bottom: 20px;
}
div.paginator form {
    margin-bottom: 6px;
}
nav ul.pagination {
    margin-top: 0;
    margin-bottom: 8px !important;
}

/* Racks */
div.rack_header {
    margin-left: 32px;
    text-align: center;
    width: 220px;
}

/* Devices */
table.component-list td.subtable {
    padding: 0;
    padding-left: 16px;
}
table.component-list td.subtable td {
    border: none;
    padding-bottom: 6px;
    padding-top: 6px;
}
table.interface-ips th {
    font-size: 80%;
    font-weight: normal;
}

/* Reports */
table.reports td.method {
    font-family: monospace;
    padding-left: 30px;
}
td.report-stats label {
    display: inline-block;
    line-height: 14px;
    margin-bottom: 0;
    min-width: 40px;
}
table.report th {
    position: relative;
}
table.report th a {
    position: absolute;
    top: -51px;
}

/* Rendered Markdown */
.rendered-markdown table {
    width: 100%;
}
.rendered-markdown th {
    border-bottom: 2px solid #dddddd;
    padding: 8px;
}
.rendered-markdown td {
    border-top: 1px solid #dddddd;
    padding: 8px;
}
.rendered-markdown :last-child {
    margin-bottom: 0;
}

/* Admonition (docs) */
.admonition {
    margin-bottom: 10px;
    padding-bottom: 2px;
}
.admonition p {
    padding: 0 12px;
}
.admonition pre {
    margin: 0 12px 10px;
}
.admonition p.admonition-title {
    color: rgb(255, 255, 255);
    font-weight: bold;
    padding: 4px 12px;
}
.admonition p.admonition-title::before {
    content: "\f06a";
    font-family: "FontAwesome";
    margin-right: 4px;
}
/* Admonition - Note */
.admonition.note {
    background-color: rgb(231, 242, 250);
}
.admonition.note .admonition-title {
    background-color: rgb(106, 176, 222);
}
.admonition.note .admonition-title::before {
    content: "\f05a";
}
/* Admonition - Warning */
.admonition.warning {
    background-color: rgb(255, 237, 204);
}
.admonition.warning .admonition-title {
    background-color: rgb(240, 179, 126);
}
.admonition.warning .admonition-title::before {
    content: "\f06a";
}
/* Admonition - Danger */
.admonition.danger {
    background-color: rgb(253, 243, 242);
}
.admonition.danger .admonition-title {
    background-color: rgb(242, 159, 151);
}
.admonition.danger .admonition-title::before {
    content: "\f071";
}

/* AJAX loader */
.loading {
    position: fixed;
    display: none;
    z-index: 999;
    height: 2em;
    width: 2em;
    overflow: show;
    margin: auto;
    top: 0;
    left: 0;
    bottom: 0;
    right: 0;
}
.loading:before {
    content: '';
    display: block;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.3);
}

/* Misc */
.color-block {
    display: block;
    width: 80px;
    border: 1px solid grey;
}
.inline-color-block {
    display: inline-block;
    width: 1.5em;
    height: 1.5em;
    border: 1px solid grey;
    border-radius: .25em;
    vertical-align: middle;
}
.text-nowrap {
    white-space: nowrap;
}
.banner-bottom {
    margin-bottom: 50px;
}
.panel table {
    margin-bottom: 0;
}
.panel .table th {
    border-bottom-width: 1px;
}
.panel table tr.even:first-child td {
    border-top: 0;
}
.panel .list-group {
    max-height: 400px;
    overflow: auto;
}
ul.nav-tabs, ul.nav-pills {
    margin-bottom: 20px;
}
/* Fix progress bar margin inside table cells */
td .progress {
    margin-bottom: 0;
    min-width: 100px;
}
textarea {
    font-family: Consolas, Lucida Console, monospace;
}
