/* RESET */
html, body, div, span, h1, h2, h3, h4, h5, h6, p, ul, ol, li, dl, dt, dd, img, fieldset, form, label, legend, table, caption, tbody, tfoot, thead, tr, th, td, a, article, aside, details, figcaption, figure, footer, header, hgroup, menu, nav, section {
    margin: 0;
    padding: 0;
    border: 0;
}

* {
    box-sizing: border-box;
}

/* TYPOGRAPHY */
body {
    font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
    line-height: 1.5;
}

h1, h2, h3 {
    font-weight: 500;
}

a {
    text-decoration: none;
}

#site-title {
    text-align: center;
}

a:hover {
    text-decoration: underline;
}

#quote {
    font-style: italic;
}

.quote-mark {
    font-size: 1.25em;
}

/* COLOR SCHEME */
header {
    /*background-color: #0077CC;*/
    background-color: #0077CC;
    color: white;
}

nav, footer {
    /*background-color: #004475;*/
    background-color: #00538f;
}

nav a, footer p {
    color: white;
}

/* LAYOUT */
header img {
    max-width: 10rem;
    display: block;
    margin-left: auto;
    margin-right: auto;
}

nav {
    padding: 0.5em;
}

footer {
    padding: 1em;
    text-align: center;
}

main {
    padding: 1em;
}

main h1, main p {
    margin-bottom: 1em;
}

ul form button {
    color: white;
    font-size: 1em;
}

#details p {
    margin-bottom: 0em;
}

#details {
    margin: 1em 0;
}

/* TABLES */
table {
    width: 100%;
    border-collapse: collapse;
    table-layout: fixed; /* Ensures even column widths */
}

th, td {
    border: 1px solid #ccc;
    padding: 0.75em;
    text-align: left;
    word-wrap: break-word; /* Prevents overflow */
}

th {
    background-color: #f5f5f5;
    font-weight: bold;
}

tr:nth-child(even) {
    background-color: #fafafa;
}

/*.edit-field {
    background-color: white;
    border: 0;
}*/

/* MISC */ 
nav ul, footer ul {
    list-style-type: none;
}

img {
    width: 100%;
}

/* RESPONSIVENESS */
@media screen and (min-width: 42em) {
    header img {
        max-width: 15rem;
    }

    nav ul {
        display: flex;
        flex-direction: row;
        align-items: center;
        justify-content: center;
    }

    nav li {
        margin: 0 2em;
    }

    nav a {
        margin: 0.5em 0;
    }
    
    footer p {
        font-size: 0.9em;
    }
}

@media screen and (min-width: 52em) {
    body {
        display: grid;
        grid-template-columns: 1fr 50rem 1fr;
    }

    header, nav, footer {
        grid-column: 1 / 4;
    }

    main {
        grid-column: 2;
    }

    nav li {
        margin: 0 3em;
    }
}