#main-grid > main {
    grid-area: content;
    color: #222;
}

#main-grid > header {
    grid-area: header;
    padding: 10px;
    margin-bottom: 1em;
    border-bottom: 1px solid #ddd;
    font-size: 1.4em;
}

#main-grid > footer {
    grid-area: footer;
    color: #eee;
    font-size: small;
    text-align: right;
}

#toc {
    grid-area: sidebar;
    border-bottom: 2px dashed #ccc;
    margin-bottom: 1.5em;
    padding-bottom: 1.8em;
}

#toc ul {
    margin: 0 0 0 1.2em;
    padding: 0.1em;
}


#main-grid {
    display: grid;
    grid-row-gap: 10px;
    grid-template-areas:
        "header"
        "sidebar"
        "content"
        "footer";
    width: 100%;
    max-width: 1080px;
    margin: 0 auto;
}

@media only screen and (min-width: 1000px) and (min-device-width: 700px) {
    #main-grid {
        grid-template-areas:
            "header  header"
            "sidebar content"
            "footer  footer";
        grid-column-gap: 2em;
        grid-row-gap: 20px;
        grid-row-gap: 1em;
        grid-template-columns: 1fr 4fr;
    }

    #toc {
        border-bottom: none;
        font-size: 0.9em;
    }

    #main-grid > main > h2:first-child {
        margin-top: 0;
    }
}
html, body {
    font: 16px/1.6 Helvetica, arial, sans-serif;
}

body {
    margin: 1em;
}

a {
    color: #4183C4;
    text-decoration: none;
    transition: color 250ms ease-out;
}

a:hover {
    color: darkblue;
}

h1, h2, h3, h4, h5, h6 {
    margin: 1.35em 0 0.8em;
    padding: 0;
    font-weight: bold;
}

h1 {font-size: 2.25em;}
h2 {font-size: 1.75em; border-bottom: 1px solid #eee;}
h3 {font-size: 1.5em;}
h4 {font-size: 1.25em;}
h5 {font-size: 1em;}
h6 {font-size: 1em;}

p, blockquote, ul, ol, dl, table, pre {
    margin: 1em 0;
}

dl {
    padding: 0;
}

dl dt {
    font-weight: bold;
    padding: 0;
    margin: 1em 0 0.35em;
}

dd {
    margin: 1em 0 1em 1.8em;
}

li {
    margin: 0.15em 0;
}

hr {
    margin: 1.75em 0 0.8em 0;
    border: none;
    border-bottom: 1px solid #ccc;
}

h1 p, h2 p, h3 p, h4 p, h5 p, h6 p {
    margin-top: 0;
}

li p.first {
    display: inline-block;
}

ul, ol {
    padding-left: 1.5em;
}

blockquote {
    border-left: 4px solid #dddddd;
    padding: 0 15px;
    color: #777777;
}

table {
    border-collapse: collapse;
    margin: 1em 0;
    padding: 0;
}

table tr {
    border-top: 1px solid #cccccc;
    background-color: white;
    margin: 0;
    padding: 0;
}

table tr:nth-child(2n) {
    background-color: #f8f8f8;
}

table tr th, table tr td {
    border: 1px solid #ccc;
    text-align: left;
    margin: 0;
    padding: 6px 13px !important;
}

table thead th {
    text-align: center;
}

img {
    max-width: 100%;
}

main code {
    margin: 0 2px;
    padding: 0 5px;
    white-space: nowrap;
    border: 1px solid #eaeaea;
    background-color: #f8f8f8;
    border-radius: 3px;
    font-size: 0.95em;
}

pre code {
    margin: 0;
    padding: 0;
    white-space: pre-wrap;
    background: transparent;
}

pre {
    background-color: #f8f8f8;
    border: 1px solid #cccccc;
    overflow: auto;
    padding: 6px 10px;
    border-radius: 3px;
}

pre code {
    background-color: transparent;
    border: none;
}

.sourceLine {color: black}
.sourceCode span.kw {font-weight: bold}
.sourceCode span.st {color: goldenrod}
.sourceCode span.co {color: gray}
.sourceCode span.do {color: gray}
.sourceCode span.dv {color: blue}
.sourceCode span.bn {color: blue}
.sourceCode span.fl {color: purple}
.sourceCode span.dt {color: purple}
.sourceCode span.al {color: green; font-weight: bold}
.sourceCode span.er {color: red; font-weight: bold}
