/*
 * Theme colors:
 * light blue: #79b6e5
 * medium blue: #1c5a88
 * darker blue: #0e2c44
 */

 * {
    box-sizing: border-box;
}

body {
    font: 100%/1.3 sans-serif;
    padding: 4rem 0 0;
    margin: 0;
    background-color: #eee;
}

ol,
ul {
    margin: 0;
    padding: 0 0 0 1rem;
}

ol li,
ul li {
    padding: .25rem 0;
}

ul {
    list-style: square;
}

table {
    margin: 1rem 0;
}

table,
tr,
th,
td {
    border: none;
}

th,
td {
    padding: .5rem;
}

th {
    background-color: #eee;
    text-align: left;
    font-weight: normal;
}

td {
    border-bottom: solid 1px #eee;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    padding: 0;
    margin: 2rem 0 1rem;
}


/* Layout */

.wrapper {
    display: flex;
    flex-flow: column nowrap;
}

.contentwrapper {
    order: 1;
    box-shadow: -.25rem 0 1rem .5rem rgba(0,0,0,0.1);
    background-color: #fff;
}

.navigationwrapper {
    order: 2;
}


/* Main */

.document {
    padding: 1rem 1rem 1.5rem;
}

.document a,
.document a:link,
.document a:visited {
    color: #5899CC;
    text-decoration: none;
    border-bottom: solid 1px #79b6e5;
}

.document a:hover,
.document a:active {
    color: #000;
    border-color: #000;
}

.document img {
    max-width: 100%;
    height: auto;
}


/* Navigation */

.navigationwrapper {
    padding: 0 0 2rem;
    background-color: #ddd;
    font-size: smaller;
}

.navigationwrapper ul {
    list-style: none;
}

.navigationwrapper li {
    padding: 0;
}

.navbar-toc > ul {
    margin-bottom: 1rem;
    padding: 0;
    font-size: medium;
}

.navbar-toc ul > li > ul {
    font-size: smaller;
    padding: 0;
    background-color: rgba(255,255,255,.5);
}

.navbar-toc li > ul > li {
    border-top: solid 1px #ddd;
}

.navigationwrapper h3,
.navigationwrapper h4 {
    color: #999;
    padding: .5rem 1rem 0;
    font-weight: normal;
    margin: 0;
}

.navigationwrapper a,
.navigationwrapper a:link,
.navigationwrapper a:visited {
    display: block;
    text-decoration: none;
    color: #1c5a88;
    font-weight: normal;
    padding: .5rem 1rem;
}

.navigationwrapper a:hover,
.navigationwrapper a:active {
    color: #000;
}

.navbar-toc a,
.navbar-toc a:link,
.navbar-toc a:visited {
    display: block;
    text-decoration: none;
    color: #1c5a88;
    font-weight: normal;
    padding: .5rem 1rem;
}

.navbar-toc a:hover,
.navbar-toc a:active {
    background-color: #1c5a88;
    color: #fff;
    border: none;
}

.navigationwrapper a[href="#"] {
    position: relative;
    margin-top: 1rem;
}

.navigationwrapper a[href="#"]::before {
    content: '';
    position: absolute;
    display: block;
    height: 1rem;
    width: 1rem;
    background-color: #0e2c44;
    transform: rotate(45deg);
    top: .5rem;
    left: -.75rem;
}

.navigationwrapper li > ul > li > ul > li > a {
    padding-left: 2rem !important;
}

.relationswrapper {
    margin: 1rem 0;
}

.nexttopic,
.prevtopic {
    background-color: rgba(255,255,255,.25);
    margin: .25rem 0;
}

.nexttopic {
    text-align: right;
}

.nexttopic::after {
    content: '▶';
    font-size: smaller;
}

.prevtopic::before {
    content: '◀';
    font-size: smaller;
}


/* Related bar */

.related {
    padding: .5rem 1rem;
    background-color: #1c5a88;
    color: #fff;
    display: flex;
    flex-flow: row nowrap;
    align-items: center;
    justify-content: space-between;
}

.breadcrumb a,
.breadcrumb a:link,
.breadcrumb a:visited
.footer a,
.footer a:link,
.footer a:visited {
    color: #79b6e5;
    text-decoration: none;
}

.breadcrumb a:hover,
.breadcrumb a:active,
.footer a:hover,
.footer a:active {
    color: #fff;
}

.related h3 {
    display: none;
}

.breadcrumb,
.pager {
    display: block;
    list-style: none;
    margin: 0;
    padding: 0;
    overflow: hidden;
}

.breadcrumb {
    flex: 1 0 calc(100vw-6rem);
    display: flex;
    flex-flow: row wrap;
    align-items: center;
    order: 1;
}

.breadcrumb li {
    background: url('../img/arrow-right2_white.svg') no-repeat center left transparent;
    background-size: auto .75rem;
    padding: 0 .25rem 0 1.25rem;
    font-size: smaller;
}

.breadcrumb li:first-child {
    background-image: none;
    padding: 0 .25rem .25rem 0;
}

.breadcrumb li:first-child a {
    background: url('../img/home_white.svg') no-repeat center center transparent;
    background-size: 66.66% auto;
    text-indent: -1000em;
    display: block;
    width: 2rem;
    height: 2rem;
    border-radius: .25rem;
}

.pager {
    flex: 0 0 6rem;
    order: 2;
    display: flex;
    flex-flow: row nowrap;
    justify-content: flex-end;
    align-items: center;
}

.pager a {
    background: url('../img/list2_white.svg') no-repeat center center transparent;
    background-size: 66.66% auto;
    text-indent: -1000em;
    display: block;
    width: 2rem;
    height: 2rem;
    border-radius: .25rem;
}

.pager li:nth-child(1) {
    order: 3;
}

.pager li:nth-child(2) {
    order: 2;
}

.pager li:nth-child(3) {
    order: 1;
}

.pager li:nth-child(1) a {
    background-size: 50% auto;
}

.pager li:nth-child(2) a {
    background-image: url('../img/forward3_white.svg');
}

.pager li:nth-child(3) a {
    background-image: url('../img/backward2_white.svg');
}

.breadcrumb li:first-child a:hover,
.breadcrumb li:first-child a:active,
.pager a:hover,
.pager a:active {
    background-color: #17496E;
}


/* Header */

.header {
    padding: .5rem 1rem;
    background-color: #0e2c44;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: auto;
    z-index: 1000;
}

.logo-link {
    display: inline-block !important;
    padding: 0 !important;
}

.logo-link:hover,
.logo-link:active {
    background-color: transparent !important;
}

.logo-img {
    height: auto;
    width: 10rem;
}


/* Footer */

.footer {
    padding: 1rem;
    background-color: #0e2c44;
    color: #fff;
    font-size: smaller;
}


/* Search */

#searchbox {
    margin: .5rem 0;
}

#searchbox .search {
    display: flex;
    flex-flow: row nowrap;
    align-items: stretch;
    padding: 0.5rem 1rem;
}

#searchbox .search > div:first-child {
    flex: 1 0 auto;
}

#searchbox input[type="text"] {
    padding: .5rem;
    border: none;
    border-radius: .25rem;
    width: 100%;
}

#searchbox input[type="submit"] {
    border: none;
    background-color: #1c5a88;
    border-radius: .25rem;
    padding: .5rem;
    color: #fff;
    font-size: smaller;
    cursor: pointer;
    margin: 0 0 0 .25rem;
}

#searchbox input[type="submit"]:hover,
#searchbox input[type="submit"]:active {
    background-color: #0e2c44;
}

.searchresultpage #searchbox {
    display: flex;
    flex-flow: row nowrap;
    align-items: stretch;
    max-width: 30rem;
}

.searchresultpage #searchbox input[type="text"] {
    background-color: #ddd;
    flex: 1 0 auto;
    width: auto;
}

ul.search {
    list-style: none;
}

ul.search > li {
    margin: 0 0 1rem;
}


/* Index */

.genindex-jumpbox {
    color: #ddd;
    display: flex;
    flex-flow: row nowrap;
    justify-content: space-around;
}

.indextable > ul {
    list-style: none;
}

.document .indextable a,
.document .genindex-jumpbox a {
    border: none;
}

.document .indextable a:hover,
.document .indextable a:active,
.document .genindex-jumpbox a:hover,
.document .genindex-jumpbox a:active {
    border-bottom: solid 1px #79b6e5;
}


/* Misc. classes */

a.headerlink {
    padding: .5rem;
    opacity: .33;
    font-size: medium;
    border: none !important;
}

.pre {
    font-size: larger;
    opacity: .75;
}

.highlight {
    background-color: #eee !important;
    padding: .5rem 1rem;
    margin: 1rem 0;
}

.document .toctree-wrapper {
    border-top: dashed 1px #ddd;
    border-bottom: dashed 1px #ddd;
    padding: 1rem 0;
    margin-bottom: 2rem;
}

.document .toctree-wrapper .caption {
    font-weight: bold;
    margin: 0 0 .5rem;
}

.document .toctree-wrapper ul {
    list-style: none;
}

.document .toctree-wrapper a {
    border: none;
}

.document .toctree-wrapper a:hover,
.document .toctree-wrapper a:active {
    border-bottom: solid 1px #79b6e5;
}

.topless {
    margin: 0;
    padding: 0;
}

.langselect {
    padding: .5rem 1rem;
    display: flex;
    flex-flow: row nowrap;
    justify-content: flex-start;
    align-items: center;
}

.langselect li {
    display: inline-block;
    padding: 0 .25rem 0 0;
}

.lang {
    background: url('../img/gl.png') no-repeat center center rgba(255,255,255,.25);
    display: block;
    width: 2rem;
    height: 2rem;
    text-indent: -1000em;
    padding: 0 !important;
    border-radius: .25rem;
}

.lang:hover,
.lang:active,
.lang.active {
    background-color: #fff;
}

.lang-da {
    background-image: url('../img/dk.png');
}

.lang-en {
    background-image: url('../img/us.png');
}

.frontpage-image {
    display: none;
}


@media screen and (min-width: 60rem) {

    body {
        padding: 0;
    }

    .wrapper {
        flex-flow: row nowrap;
        min-height: 100vh;
    }
    
    .contentwrapper {
        order: 2;
        width: 60%;
        min-width: 45rem;
        display: flex;
        flex-flow: column nowrap;
    }

    .navigationwrapper {
        order: 1;
        width: 20%;
        min-width: 15rem;
    }

    .header {
        position: static;
        padding: 3rem 2rem;
        display: flex;
        flex-flow: column nowrap;
        justify-content: center;
        align-items: center;
    }

    .logo-link {
        display: block !important;
        width: 100%;
        max-width: 15rem;
    }

    .logo-img {
        width: 100%;
        height: auto;
    }

    ol,
    ul {
        padding: 0;
    }
    
    li > ol,
    li > ul {
        padding: 0 0 0 1rem;
    }

    .document {
        padding: 2rem 3rem 3rem;
    }

    .related {
        padding: .5rem 3rem;
    }

    .footer {
        padding: 2rem 3rem 3rem;
        flex: 1 0 auto;
        display: flex;
        flex-flow: row nowrap;
        justify-content: space-between;
    }

    .indextable > ul {
        columns: auto 2;
        overflow: hidden;
    }


    /* Make layout a little different on front page */

    .frontpage-image {
        display: block;
        background: url('../img/img-by-frank-thomsen-renard.jpg') no-repeat center top transparent;
        background-size: cover;
        padding: 8rem 10rem;
        margin-right: -3rem;
        margin-left: -3rem;
        margin-top: -2rem;
        margin-bottom: 3rem;
        text-align: center;
    }

    .document .frontpage-logo {
        max-width: 30rem;
        padding: 1rem;
        background: radial-gradient(rgba(0,0,0,.5), rgba(0,0,0,.1), rgba(0,0,0,0)); 
    }

}
