/******************************************************************************
 * Global layout styles
 *****************************************************************************/
html {
    background: white url(/graphics/body_back.gif) repeat-x top;
    font-family: 'Lucida Grande', Verdana, Geneva, Lucida, Arial, Helvetica, sans-serif;
    font-size: 80%;
}

body {
    margin: 20px auto 0 auto;
    width: min(70em, 100vw);
}

/******************************************************************************
 * Season styles
 *****************************************************************************/

/* Default is early spring */
header { background: #5E97CC url(/graphics/head-earlyspring.jpg) no-repeat right center; }
/* ensures logo is readable even if screen is squished */
header h1 { background-color: #5E97CC; }
nav { background-color: #F6F4EC; }

body.spring header { background: #4f7ea8 url(/graphics/head-spring.jpg) no-repeat right center; }
body.spring header h1 { background-color: #4f7ea8; }
body.spring nav { background-color: #F6F4EC; }

/* TODO: summer */

/* TODO: fall */

body.winter header { background: #faf7e6 url(/graphics/head-winter.jpg) no-repeat right center; }
body.winter header h1 { background-color: #faf7e6; }
body.winter nav { background-color: #EBEFF5; }

/******************************************************************************
 * Heading styles
 *****************************************************************************/
header {
    border: 1px solid #333;
    padding: 25px;
}

header h1 {
    /* default font size will make the h1 too tall and push the h2 quote away */
    font-size: 0%;
    /* but we do want at least a small gap to the h2 quote */
    margin-bottom: 5px;
    /* ensures background doesn't go beyond logo - image sizes are fixed so this can be fixed */
    width: 230px;
}

/* push the icon up to align more with the logo test baseline */
header h1 img#icon { margin-bottom: 5px; }

/* space logo away from icon */
header h1 img#logo { margin-left: 10px; }

header h1 span {
    /* this mess hides the text without removing it from the document, so hopefully it is there for text and readers */
    height: 1px;
    width: 1px;

    margin: -1px;
    overflow: hidden;
    padding: 0;
    position: absolute;
    white-space: nowrap;
}

header h2 {
    color: black;
    font-size: medium;
    font-weight: normal;
    margin: 0;
    width: fit-content;
}

/* only used for mobile */
button#menuToggle { display: none; }

div#line {
    background: #FFC700;
    border-color: #333;
    border-style: solid;
    border-width: 0 1px 1px 1px;
    height: 10px;
}

/******************************************************************************
 * Sidebar styles
 *****************************************************************************/
nav {
    border-color: #333;
    border-style: solid;
    border-width: 0 1px 1px 1px;
    float: right;
    margin-bottom: 1em;
    padding: 10px;
    width: 20em;
}

nav h3 {
    border-top: 1px dotted #333;
    margin: 15px 5px 5px 5px;
    padding-top: 10px;
}

nav ul#mainmenu { font-size: 120%; }

nav ul {
    list-style: none;
    margin: 0;
    padding-left: 5px;
}

nav ul ul {
    border-left: 1px solid gray;
    margin-left: 8px;
    padding-left: 8px;
}

nav a.currentpage { font-weight: bold; }

/* Fix buttons so they just look like buttons */
nav ul#buttons { margin-top: 10px; }
nav ul#buttons li { display: inline; }
nav ul#buttons a img { border: 0; }
nav ul#buttons a {
    /* undo external decorations */
    background: none;
    padding-left: 0;
}

/******************************************************************************
 * Content styles
 *****************************************************************************/
main {
    clear: left;
    float: left;
    line-height: 150%;
    margin-bottom: 1em;
    width: 47em;
}

main h1 { line-height: 110%; }
main h2 + h3 { padding-top: 3px; }

b.big {
    font-size: large;
    font-weight: bold;
}

ul#duringnav {
    border-top: 1px solid black;
    list-style: none;
    padding: 3px 0 0 0;
    text-align: center;
}
ul#duringnav li {
    border-left: 1px solid black;
    display: inline;
    padding: 0 1px 0 4px;
}
ul#duringnav li:first-child {
    border-left: 0;
    padding-left: 0;
}

figure {
    margin-left: 0;
    text-align: center;
}

figure img {
    border: 1px solid #A9A9A9;
    box-shadow: 5px 5px 5px #999;
}
figure.clean img {
    border: 0 !important;
    box-shadow: 0 0 0;
}

/* additional spacing between pictures helps clarify which one the caption belongs to */
figure + figure { margin-top: 25px; }

figure a:link img { border: 2px solid #1C298C; }
figure a:visited img { border: 2px solid #8D1B20; }
figure a:hover img { border: 2px solid #A9A9A9; }

aside {
    border-top: 1px solid #555555;
    color: #555555;
}

figure.aside-left {
    float: left;
    margin: auto 20px 15px 0;
}

main h1[id] a.heading-anchor,
main h2[id] a.heading-anchor,
main h3[id] a.heading-anchor,
main h4[id] a.heading-anchor,
main h5[id] a.heading-anchor,
main h6[id] a.heading-anchor {
    font-size: 70%;
    margin-left: 5px;
    text-decoration: none;
    vertical-align: top;
    visibility: hidden;
}

main h1[id]:hover a.heading-anchor,
main h2[id]:hover a.heading-anchor,
main h3[id]:hover a.heading-anchor,
main h4[id]:hover a.heading-anchor,
main h5[id]:hover a.heading-anchor,
main h6[id]:hover a.heading-anchor {
    visibility: visible;
}

/******************************************************************************
 * Footer styles
 *****************************************************************************/
footer {
    clear: both;
    color: #666;
    margin: 0;
    padding: 10px;
    text-align: center;
}

/******************************************************************************
 * Global appearance styles
 *****************************************************************************/
h1, h2, h3, h4, h5, h6 { font-family: 'Palatino Linotype', 'Times New Roman', Times, serif; }
h1 { font-size: 200%; }
h2 {
    font-size: 150%;
    margin-bottom: 5px;
    margin-top: 1em;
}
h3 {
    font-size: 120%;
    margin-top: 0;
}

a { text-decoration: underline; }
a:link {
    background-color: transparent;
    color: #1C298C;
}
a:visited {
    background-color: transparent;
    color: #8D1B20;
}
a:hover { text-decoration: none; }

a[id] { text-decoration: none; } /* remove text decoration from link anchors */

a[rel~="external"] {
    background-image: url(/graphics/extern.gif);
    background-position: left center;
    background-repeat: no-repeat;
    padding-left: 9px;
}
a[rel~="external"]:hover {
    background-image: url(/graphics/extern-over.gif);
    background-position: left center;
    background-repeat: no-repeat;
}

a.noex {
    background: none;
    padding-left: 0;
}
a.noex:hover { background: none; }

blockquote {
    border-left: 5px solid #ddd;
    margin-left: 0;
    padding-left: 10px;
}

code {
    background-color: #f0f0f0;
    font-family: Consolas, courier, monospace;
    font-size: 120%;
}

q { quotes: '\201C' '\201D' '\2018' '\2019'; }
q:before { content: open-quote; }
q:after { content: close-quote; }

.center { text-align: center; }

table {
    border-collapse: collapse;
    border: 1px solid gray;
}

thead {
    border-bottom: 1px solid gray;
}

th, td {
    padding: 5px;
    border-right: 1px solid gray;
}

tbody tr:nth-child(odd) {
    background-color: #f0f0f0;
  }