/* Charcoal Cream - A Free Design by Bryant Smith (bryantsmith.com)
   A holy-grail page: a charcoal header and footer frame two slim rails
   around a cream reading column. Every colour and space is gathered here;
   look for the section headings to find what you want to change. */


/* ---- BODY: the dark "desk" behind the page ---- */

body {
    background: #202020;
    color: #2f2d29;
    font-family: Georgia, "Times New Roman", Times, serif;
    font-size: 17px;
    line-height: 1.7;
    padding: 0;
}

* {
    margin: 0;
    padding: 0;
}

#page {
    margin: 0 auto;
    max-width: 980px;
}


/* ---- HEADER: the charcoal band across the top ---- */

#masthead {
    background: #202020;
    border-bottom: 3px solid #3a3a3a;
    padding: 44px 48px 34px 48px;
}

#masthead .site-mark {
    color: #f4eede;
    display: block;
    font-size: 34px;
    letter-spacing: 1px;
    line-height: 1.1;
    text-decoration: none;
}

#masthead .tagline {
    color: #a49c8c;
    font-family: Verdana, Arial, Helvetica, sans-serif;
    font-size: 11px;
    letter-spacing: 3px;
    margin-top: 14px;
    text-transform: uppercase;
}


/* ---- MENU: simple text links under the title ---- */

#menu {
    font-family: Verdana, Arial, Helvetica, sans-serif;
    font-size: 12px;
    letter-spacing: 1.5px;
    margin-top: 26px;
    text-transform: uppercase;
}

#menu a,
#menu a:visited {
    border-bottom: 2px solid transparent;
    color: #cfc7b6;
    margin-right: 24px;
    padding-bottom: 3px;
    text-decoration: none;
    transition: color 0.15s ease, border-color 0.15s ease;
}

#menu a:hover,
#menu a:focus {
    border-bottom-color: #f4eede;
    color: #ffffff;
}


/* ---- LAYOUT: the holy grail grid - two rails, one reading column ---- */

#layout {
    background: #f7f2e8;
    display: grid;
    grid-template-columns: 200px 1fr 200px;
}

#left-rail,
#right-rail {
    background: #efe7d7;
    padding: 44px 22px;
}

#left-rail {
    border-right: 1px solid #e3d8c2;
}

#right-rail {
    border-left: 1px solid #e3d8c2;
}

#left-rail h3,
#right-rail h3 {
    color: #8a7f6a;
    font-family: Verdana, Arial, Helvetica, sans-serif;
    font-size: 10px;
    letter-spacing: 2px;
    margin-bottom: 16px;
    text-transform: uppercase;
}


/* ---- RAIL LINKS: a plain list of text links ---- */

.link-list {
    list-style: none;
}

.link-list li {
    border-bottom: 1px solid #e3d8c2;
    padding: 9px 0;
}

.link-list a,
.link-list a:visited {
    border-bottom: 1px solid transparent;
    color: #4a463e;
    text-decoration: none;
    transition: color 0.15s ease, border-color 0.15s ease;
}

.link-list a:hover,
.link-list a:focus {
    border-bottom-color: #202020;
    color: #202020;
}

.rail-note {
    border-top: 1px solid #ddd2bc;
    color: #5f5a51;
    font-size: 14px;
    line-height: 1.55;
    margin-top: 24px;
    padding-top: 18px;
}


/* ---- READING COLUMN: the cream centre of the page ---- */

#content {
    background: #f7f2e8;
    padding: 48px 54px 56px 54px;
}

#content p {
    margin-bottom: 20px;
}

#content a,
#content a:visited {
    border-bottom: 1px solid #b8ad95;
    color: #202020;
    text-decoration: none;
    transition: color 0.15s ease, border-color 0.15s ease;
}

#content a:hover,
#content a:focus {
    border-bottom-color: #8a7f6a;
    color: #5f584a;
}

.lead {
    color: #3a372f;
    font-size: 20px;
    line-height: 1.62;
}

.lead::first-letter {
    color: #202020;
    float: left;
    font-size: 3.2em;
    line-height: 0.82;
    padding: 5px 10px 0 0;
}

#content h2 {
    border-top: 2px solid #202020;
    color: #202020;
    font-family: Verdana, Arial, Helvetica, sans-serif;
    font-size: 12px;
    font-weight: bold;
    letter-spacing: 2.5px;
    margin: 46px 0 18px 0;
    padding-top: 12px;
    text-transform: uppercase;
}

code {
    background: #efe7d7;
    border-radius: 3px;
    color: #202020;
    font-size: 15px;
    padding: 1px 6px;
}


/* ---- QUOTE: the indented passage with a charcoal bar ---- */

blockquote {
    border-left: 3px solid #202020;
    color: #4a463e;
    font-size: 19px;
    font-style: italic;
    margin: 34px 0;
    padding: 4px 0 4px 24px;
}

blockquote p {
    margin: 0;
}

blockquote cite {
    color: #7a7466;
    display: block;
    font-family: Verdana, Arial, Helvetica, sans-serif;
    font-size: 11px;
    font-style: normal;
    letter-spacing: 1px;
    margin-top: 10px;
    text-transform: uppercase;
}


/* ---- ENTRIES: the dated list of writing ---- */

.entries {
    list-style: none;
}

.entries li {
    border-bottom: 1px solid #e6dcc9;
    padding: 15px 0;
}

.entries li:last-child {
    border-bottom: none;
}

.entries .date {
    color: #766f60;
    display: inline-block;
    font-family: Verdana, Arial, Helvetica, sans-serif;
    font-size: 11px;
    letter-spacing: 1px;
    text-transform: uppercase;
    width: 135px;
}

.entries a {
    color: #202020;
    font-size: 18px;
    text-decoration: none;
}

.entries a:hover,
.entries a:focus {
    border-bottom: 1px solid #8a7f6a;
    color: #5f584a;
}


/* ---- FOOTER: the charcoal band and the required credit link ---- */

#footer {
    background: #202020;
    border-top: 3px solid #3a3a3a;
    color: #a49c8c;
    font-family: Verdana, Arial, Helvetica, sans-serif;
    font-size: 10px;
    letter-spacing: 1px;
    padding: 26px 48px;
    text-align: center;
    text-transform: uppercase;
}

#footer a,
#footer a:visited {
    border-bottom: 1px solid #4a4a4a;
    color: #cfc7b6;
    text-decoration: none;
    transition: color 0.15s ease, border-color 0.15s ease;
}

#footer a:hover,
#footer a:focus {
    border-bottom-color: #f4eede;
    color: #ffffff;
}


/* ---- FOCUS: a clear ring for keyboard users ---- */

a:focus {
    outline: 2px solid #8a7f6a;
    outline-offset: 2px;
}


/* ---- TABLETS: drop the right rail first ---- */

@media (max-width: 820px) {
    #layout {
        grid-template-columns: 190px 1fr;
    }

    #right-rail {
        border-left: none;
        border-top: 1px solid #e3d8c2;
        grid-column: 1 / -1;
    }
}


/* ---- SMALL SCREENS: stack everything into one column ---- */

@media (max-width: 640px) {
    #masthead {
        padding: 34px 24px 26px 24px;
    }

    #masthead .site-mark {
        font-size: 27px;
    }

    #menu a {
        display: inline-block;
        margin: 6px 16px 0 0;
    }

    #layout {
        grid-template-columns: 1fr;
    }

    #left-rail {
        border-right: none;
        border-bottom: 1px solid #e3d8c2;
        padding: 28px 24px;
    }

    #right-rail {
        padding: 28px 24px;
    }

    #content {
        padding: 34px 24px 42px 24px;
    }

    .lead {
        font-size: 18px;
    }

    #content h2 {
        margin-top: 36px;
    }

    .entries .date {
        display: block;
        margin-bottom: 4px;
        width: auto;
    }

    #footer {
        padding: 22px 24px;
    }
}


/* ---- PRINT: lose the dark bands and the rails ---- */

@media print {
    body {
        background: #ffffff;
    }

    #masthead,
    #footer {
        background: #ffffff;
        border-color: #cccccc;
        color: #333333;
    }

    #masthead .site-mark,
    #masthead .tagline,
    #menu a,
    #footer a {
        color: #000000;
    }

    #layout {
        display: block;
        background: #ffffff;
    }

    #left-rail,
    #right-rail {
        display: none;
    }

    #content {
        background: #ffffff;
        padding: 0;
    }
}
