/*
   Modified by: Paul Iacomi
   Originally based on a marked2app template
*/

/* Colors */

:root {
    --color-highlight-1: #2f80a5;
    --color-highlight-2: #0f5271;
    --color-highlight-3: #3a3a4f;
    --color-complementary-1: #b54b3a;
    --color-complementary-2: #a73f2d;
    --color-white: #FFFFFF;
    --color-off-white: #F8F5F0;
    --color-off-white-2: #ECE6DA;
    --color-grey-1: #ddd;
    --color-grey-2: #68645d;
    --color-grey-3: #57534A;
    --color-grey-4: #423F37;
    --color-black: rgb(0, 0, 0);
    --color-transparent: rgba(0, 0, 0, 0.4);
}

@font-face {
    font-family: "Ubuntu";
    font-style: normal;
    font-weight: 300;
    src: local("Ubuntu Light"), local("Ubuntu-Light"), url("http://themes.googleusercontent.com/static/fonts/ubuntu/v4/WtcvfJHWXKxx4x0kuS1kobO3LdcAZYWl9Si6vvxL-qU.woff") format("woff");
}

@font-face {
    font-family: "Ubuntu";
    font-style: normal;
    font-weight: 400;
    src: local("Ubuntu"), url("http://themes.googleusercontent.com/static/fonts/ubuntu/v4/CGXpU_uR_FUfdeyCjAWgZ-vvDin1pK8aKteLpeZ5c0A.woff") format("woff");
}

@font-face {
    font-family: "Ubuntu";
    font-style: normal;
    font-weight: 500;
    src: local("Ubuntu Medium"), local("Ubuntu-Medium"), url("http://themes.googleusercontent.com/static/fonts/ubuntu/v4/gMhvhm-nVj1086DvGgmzB7O3LdcAZYWl9Si6vvxL-qU.woff") format("woff");
}

@font-face {
    font-family: "Ubuntu";
    font-style: normal;
    font-weight: 700;
    src: local("Ubuntu Bold"), local("Ubuntu-Bold"), url("http://themes.googleusercontent.com/static/fonts/ubuntu/v4/nsLtvfQoT-rVwGTHHnkeJrO3LdcAZYWl9Si6vvxL-qU.woff") format("woff");
}

@font-face {
    font-family: "Ubuntu";
    font-style: italic;
    font-weight: 300;
    src: local("Ubuntu Light Italic"), local("Ubuntu-LightItalic"), url("http://themes.googleusercontent.com/static/fonts/ubuntu/v4/DZ_YjBPqZ88vcZCcIXm6VqfTCPadK0KLfdEfFtGWCYw.woff") format("woff");
}

/* General settings */

html {
    font-size: 100%;
    scroll-behavior: smooth;
}

html, button, input, select, textarea {
    font-family: sans-serif;
}

html, body, button, input, select, textarea {
    color: var(--color-grey-3);
    font-family: "Ubuntu Medium", "Myriad Pro", "Myriad", sans-serif;
    font-size: 18px;
    font-weight: 300;
}

body {
    margin: 0 auto;
    background-color: var(--color-white);
    height: 100%;
    min-height: 100%;
    overflow: hidden;
}

body, textarea {
    line-height: 1.4;
}

body:after {
    clear: both;
    content: "";
    display: table;
}

h1, h2, h3, dt {
    color: var(--color-grey-4);
    font-weight: 700;
}

h1 {
    font-size: 2em;
    margin: 0.67em 0;
}

h2, .article-list .article-title {
    font-size: 1.5em;
    margin: 0.83em 0;
}

h3, dt {
    font-size: 1.17em;
    margin: 1em 0;
}

h4 {
    font-size: 1em;
    margin: 1.33em 0;
}

h5 {
    font-size: 0.83em;
    margin: 1.67em 0;
}

h6 {
    font-size: 0.75em;
    margin: 2.33em 0;
}

a {
    color: var(--color-highlight-1);
    cursor: pointer;
    outline: 0 none;
    text-decoration: underline;
}

a:hover {
    outline: 0 none;
    color: var(--color-highlight-2);
}

p, pre {
    margin: 1em 0;
}

.article-body p {
    text-align: justify;
}

code, kbd, pre, samp {
    font-family: monospace, serif;
    font-size: 1em;
    margin: 0;
    padding: 0;
}

pre {
    white-space: pre-wrap;
    word-wrap: break-word;
}

pre {
    background-color: var(--color-off-white);
    font-size: 0.7rem;
    overflow-x: auto;
    padding: 1.3rem;
    position: relative;
    white-space: pre;
    word-wrap: normal;
}

pre, code, kbd, samp {
    margin: 0;
}

code, kbd, pre, samp {
    font-family: monospace, serif;
}

code {
    color: var(--color-grey-4);
}

aside {
    display: block;
    float: right;
    width: 390px;
}

b, strong {
    font-weight: bold;
    color: var(--color-grey-4);
    font-weight: 700;
}

blockquote {
    color: var(--color-grey-4);
    font-size: 1.25em;
    font-weight: 700;
    margin: 1em 40px;
}

blockquote {
    margin-bottom: 2em;
    margin-top: 2em;
}

hr {
    -moz-border-bottom-colors: none;
    -moz-border-left-colors: none;
    -moz-border-right-colors: none;
    -moz-border-top-colors: none;
    border-color: -moz-use-text-color -moz-use-text-color var(--color-off-white-2);
    border-image: none;
    border-style: none none solid;
    border-width: medium medium 1px;
    margin: 3em 6em;
}

/* buttons */

.button {
    box-shadow: inset 0px 34px 0px -15px var(--color-complementary-1);
    background-color: var(--color-complementary-2);
    border: 1px solid var(--color-grey-4);
    display: inline-block;
    cursor: pointer;
    color: var(--color-white);
    font-size: 15px;
    font-weight: bold;
    padding: 9px 23px;
    text-decoration: none;
    text-shadow: 0px -1px 0px var(--color-grey-4);
}

.button:hover {
    background-color: var(--color-complementary-1);
}

.button:active {
    position: relative;
    top: 1px;
}


/* Wrapper and Header */

.wrapper {
    flex: 1;
    display: flex;
}

.container {
    flex: 1;
    order: 1;
    height: 100vh;
    overflow-y: auto;
}

article {
    padding-left: 6rem;
    padding-right: 6rem;
    margin-left: auto;
    margin-right: auto;
    max-width: 42rem;
    display: block;
}

/* header/navbar */

header {
    flex: 0 0 25%;
    order: 0;
    background-color: var(--color-highlight-3);
    border-left: 1px solid var(--color-black);
    color: var(--color-off-white);
    -webkit-font-smoothing: antialiased;
    height: 100vh;
    overflow-y: auto;
    padding: 20px;
}

header h1 {
    font-family: Arvo, sans-serif;
    font-size: 1.3em;
    font-weight: 300;
    color: var(--color-white);
    line-height: 1.3em;
    border-bottom: none;
    margin-top: 0;
    margin-left: 10px;
}

header ul>li:before {
    background-color: var(--color-white);
}

header a {
    text-decoration: none;
    font-size: 0.9em;
    color: var(--color-off-white);
}

header a:hover {
    outline: 0 none;
    color: var(--color-highlight-1);
}

header ul {
    list-style: none;
    padding: 0;
}

.navbar-hamburger {
    display: none;
}

#navbar-check {
    display: none;
}

@media print, screen and (max-width: 960px) {
    body {
        overflow: auto;
    }
    .wrapper {
        flex-direction: column;
    }
    /* header, article, footer {
        float: none;
        position: static;
        width: auto;
    } */
    article, footer {
        float: none;
        position: static;
        width: auto;
    }
    header {
        position: static;
        flex: 0 0 0;
        padding: 20px;
    }
    article {
        padding-left: 3.5rem;
        padding-right: 3.5rem;
    }
    .navbar-items {
        background-color: var(--color-highlight-3);
        position: fixed;
        top: 0;
        bottom: 0;
        width: 70%;
        padding: 10px;
        overflow-y: auto;
        -webkit-box-orient: vertical;
        -webkit-box-direction: normal;
        -ms-flex-flow: column nowrap;
        flex-flow: column nowrap;
        -webkit-box-pack: center;
        -ms-flex-pack: center;
        justify-content: center;
    }
    .navbar-hamburger {
        display: block !important;
        float: left;
        position: fixed;
        z-index: 6;
        top: 5%;
        color: var(--color-off-white);
        background-color: var(--color-complementary-2);
        -webkit-transform: translateY(-50%);
        transform: translateY(-50%);
        transform: scale(2);
    }
    .navbar-left .navbar-items {
        left: 0;
        margin-left: -100%;
        -webkit-transition: margin-left 0.2s ease;
        transition: margin-left 0.2s ease;
    }
    .navbar-left #navbar-check:checked~.navbar-items {
        margin-left: 0;
    }
    .navbar-left #navbar-check:checked~.navbar-hamburger {
        margin-left: 72%;
    }
    div.navbar-item:not(:last-of-type) {
        margin-bottom: 8px;
    }
}

/* images and figures */

figure {
    margin-bottom: 2em;
    margin-top: 2em;
}

figure>figcaption {
    margin-top: 0.5em;
}

img {
    max-width: 100%;
    max-height: 100vh;
    display: block;
    border: 0 none;
    margin: auto;
}

.img-modal {
    z-index: 3;
    display: none;
    position: fixed;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: var(--color-black);
    background-color: var(--color-transparent);
}

.img-modal-content {
    margin: auto;
    background-color: var(--color-white);
    position: relative;
    padding: 0;
    outline: 0;
    max-width: 60%;
    animation: animatezoom 0.6s;
}

.img-modal-content img {
    max-width: 100%;
    max-height: 100%;
}

@keyframes animatezoom {
    from {
        transform: scale(0)
    }
    to {
        transform: scale(1)
    }
}

/* Lists and tables */

ol>li:before {
    color: var(--color-grey-4);
    content: counter(ol, decimal) ".";
    counter-increment: ol;
    font-weight: 700;
    margin-right: 0.333em;
    position: absolute;
    right: 100%;
}

ul>li:before {
    background-color: var(--color-grey-4);
    border-radius: 14px 14px 14px 14px;
    content: "";
    height: 6px;
    margin-right: 0.333em;
    margin-top: 0.55em;
    position: absolute;
    right: 100%;
    width: 6px;
}

ol, ul, dl {
    margin-left: 2rem;
    padding: 0;
}

ol {
    counter-reset: ol;
}

li+li, dd+dt {
    margin-top: 0.5em;
}

ul>li {
    position: relative;
}

ol>li {
    position: relative;
}

li {
    list-style: none outside none;
}

small, dd, figcaption {
    color: var(--color-grey-2);
    display: block;
    font-size: 0.8rem;
    font-style: italic;
    line-height: 1.2;
}

/* Tables */

tbody {
    display: table-row-group
}

tfoot {
    display: table-footer-group
}

table {
    margin-bottom: 2em;
    font-size: 0.8em;
    padding: 0;
    border-collapse: collapse;
    box-shadow: 1px 1px 2px var(--color-transparent);
    -webkit-box-shadow: 1px 1px 2px var(--color-transparent);
    width: 80%;
    margin: 0 auto 2em auto
}

table th, table td {
    padding: 10px 10px 9px;
    line-height: 18px;
    text-align: left
}

table th {
    padding-top: 9px;
    vertical-align: middle
}

table td {
    vertical-align: top;
    border-top: 1px solid var(--color-grey-1);
}

table tbody th {
    border-top: 1px solid var(--color-grey-1);
    vertical-align: top
}

table {
    border: 1px solid var(--color-grey-1);
    border-collapse: separate;
    *border-collapse: collapse;
    -webkit-border-radius: 4px;
    -moz-border-radius: 4px;
    border-radius: 4px
}

table th+th, table td+td, table th+td {
    border-left: 1px solid var(--color-grey-1)
}

table thead tr:first-child th:first-child, table tbody tr:first-child td:first-child {
    -webkit-border-radius: 4px 0 0 0;
    -moz-border-radius: 4px 0 0 0;
    border-radius: 4px 0 0 0
}

table thead tr:first-child th:last-child, table tbody tr:first-child td:last-child {
    -webkit-border-radius: 0 4px 0 0;
    -moz-border-radius: 0 4px 0 0;
    border-radius: 0 4px 0 0
}

table tbody tr:last-child td:first-child {
    -webkit-border-radius: 0 0 0 4px;
    -moz-border-radius: 0 0 0 4px;
    border-radius: 0 0 0 4px
}

table tbody tr:last-child td:last-child {
    -webkit-border-radius: 0 0 4px 0;
    -moz-border-radius: 0 0 4px 0;
    border-radius: 0 0 4px 0
}

tbody tr:nth-child(odd) {
    background-color: rgba(0, 0, 0, 0.03)
}

caption {
    display: table-caption;
    font-weight: 300;
    font-size: 1.1em;
    background: var(--color-transparent);
    padding: 5px;
    border-radius: 4px;
    -webkit-border-radius: 4px;
    margin: 4px 0;
    box-shadow: 2px 2px 2px var(--color-transparent);
    -webkit-box-shadow: 2px 2px 2px var(--color-transparent);
}

/* grey out placeholders */

:-moz-placeholder {
    color: var(--color-off-white-2);
}

::-webkit-input-placeholder {
    color: var(--color-off-white-2);
}

.article-date {
    color: var(--color-off-white-2);
    display: block;
    font-size: 0.8rem;
}

/* Title, author, institution, abstract */

.author-list {
    margin: 0 0 0px;
    font-weight: 700;
}

.author-affiliations {
    margin: 0 0 0px;
    font-style: italic;
    font-size: smaller;
}

.author-correspondence {
    line-height: 2rem;
    font-weight: 700;
    font-size: smaller;
}

.abstract {
    margin: 0% 1% 2%;
    font-weight: 700;
}

/* References */

.references {
    line-height: 1.1;
    font-size: 15px;
}

div.csl-entry {
    clear: both;
    margin-bottom: 0.5em;
}

.hanging div.csl-entry {
    margin-left: 2em;
    text-indent: -2em;
}

div.csl-left-margin {
    min-width: 2em;
    float: left;
}

div.csl-right-inline {
    margin-left: 2em;
    padding-left: 1em;
}

div.csl-indent {
    margin-left: 2em;
}

/* Other pandoc settings */

q {
    quotes: "ÔÇ£" "ÔÇØ" "ÔÇÿ" "ÔÇÖ";
}

.display.math {
    display: block;
    text-align: center;
    margin: 0.5rem auto;
}