html {
    height: 100%;
    overflow-y: scroll;
}

body {
    -webkit-hyphens: auto;
        -ms-hyphens: auto;
            hyphens: auto;

    -webkit-hyphenate-limit-before: 3;
    -webkit-hyphenate-limit-after: 3;
    -webkit-hyphenate-limit-chars: 6 3 3;
    -webkit-hyphenate-limit-lines: 2;
    -webkit-hyphenate-limit-last: always;

    hyphenate-limit-chars: 6 3 3;
    hyphenate-limit-lines: 2;
    hyphenate-limit-last: always;

    min-height: 100%;
}

#propic {
    border-radius: 5px;
    border-style: solid;
    width: 30%;
    aspect-ratio: 1 / 1;
}

#name {
    font-size: 2em;
    margin: 0;
}

header {
    width: 100%;
    padding-top: 0.7em;
}

header > div {
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-orient: horizontal;
    -webkit-box-direction: normal;
        -ms-flex-direction: row;
            flex-direction: row;
    -webkit-box-pack: space-between;
        -ms-flex-pack: space-between;
            justify-content: space-between;
}

header hr {
    border-style: solid;
    color: var(--header-border-color);
    margin: 1em 0 1.5em 0;
}

#kerb {
    color: inherit;
    font-size: 1.3em;
    text-decoration: none;
}

header nav {
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-orient: horizontal;
    -webkit-box-direction: normal;
        -ms-flex-direction: row;
            flex-direction: row;
    -webkit-box-flex: 0;
        -ms-flex-positive: 0;
            flex-grow: 0;
    -webkit-box-pack: space-between;
        -ms-flex-pack: space-between;
            justify-content: space-between;
}

nav a {
    border-radius: 5px;
    border-style: none;
    height: -webkit-min-content;
    height: -moz-min-content;
    height: min-content;
    text-decoration: none;
}

header > div, div.content, main {
    width: 85%;
    margin: 0 auto;
}

/* two widths: phone/small tablet & tablet held sideways/laptop/monitor */

@media only screen and (max-width: 700px) {
    body {
        font-size: 1em;
        padding: 1em;
    }

    #propic {
        border-width: 2px;
        margin: 0.5em 0 0.5em 1.5em;
        max-width: 170px;
    }

    #name {
        margin-bottom: 0.5em;
    }

    header nav {
        max-width: 18em;
        width: 93%;
    }

    nav a {
        padding: 0.2em 0.65em;
    }
}

@media only screen and (min-width: 700px) {
    body {
        font-size: 1.1em;
        margin: 0 auto;
        max-width: 55em;
        padding: 1em 2em;
    }

    #propic {
        border-width: 3px;
        margin: 0.5em 0 1em 2em;
        max-width: 200px;
    }

    #name {
        margin-bottom: 0.5em;
    }

    header nav {
        width: 55%;
    }

    nav a {
        padding: 0.2em 0.8em;
    }
}

/* profile picture stops floating to right when <600px */

@media only screen and (max-width: 600px) {
    #propic {
        float: none;
        margin: 0 0 0.5em 0;
        width: 60%;
    }

    div:has(#propic) {
        text-align: center;
    }

    #name {
        margin-bottom: 0.7em;
        text-align: center;
    }

    #kerb {
        margin-bottom: 0.6em;
    }

    header > div {
        -webkit-box-align: center;
           -ms-flex-align: center;
              align-items: center;
           -webkit-box-orient: vertical;
        -webkit-box-direction: normal;
           -ms-flex-direction: column;
               flex-direction: column;
    }

    header > div, div.content, main {
        width: 93%;
    }
}

@media only screen and (min-width: 600px) {
    #propic {
        float: right;
    }
}

:is(div.content, main) a {
    text-decoration: none;
}

:is(div.content, main) a::after {
    content: "+";
    font-size: 0.8em;
    line-height: 65%;
    vertical-align: super;
}

/* a.footnote-ref::after is less specific than div.content a::after */
:is(div.content, main) a:is(.no-after, .footnote-ref, .footnote-back, :has(> img))::after {
    content: unset;
}

:is(div.content, main) a:hover {
    text-decoration: underline;
}

:is(div.content, main) {
    -webkit-box-flex: 1;
        -ms-flex-positive: 1;
            flex-grow: 1;
    line-height: 1.45;
}

div.contentDesc {
    margin-bottom: 1em;
}

section.info {
    margin: 0 0 1.5em 2em;
}

.infoGroup section.info:not(:last-child) {
    margin-bottom: 0;
}

section.info h2 {
    display: inline;
    font-style: italic;
    font-weight: inherit;
    font-size: inherit;
    margin: 0 0.5em 0 -2em;
}

section.info h2::after{
    content: ':';
}

span.noHyphen {
    -webkit-hyphens: manual;
        -ms-hyphens: manual;
            hyphens: manual;
}

nav a:hover {
    cursor: pointer;
}

footer {
    -webkit-box-align: end;
        -ms-flex-align: end;
            align-items: flex-end;
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-orient: horizontal;
    -webkit-box-direction: normal;
        -ms-flex-direction: row;
            flex-direction: row;
    -webkit-box-flex: 0;
        -ms-flex-positive: 0;
            flex-grow: 0;
    font-size: 0.85em;
    -webkit-box-pack: justify;
        -ms-flex-pack: justify;
            justify-content: space-between;
    margin-top: 2.5em;
    width: 100%;
}

footer p {
    margin: 0;
}

a.hiddenLink {
    color: inherit;
    text-decoration: none;
}

@media only screen and (min-width: 921px) {
    div.twocols {
        display: -webkit-box;
        display: -ms-flexbox;
        display: flex;
        -webkit-box-orient: horizontal;
        -webkit-box-direction: normal;
            -ms-flex-direction: row;
                flex-direction: row;
        -webkit-box-pack: justify;
            -ms-flex-pack: justify;
                justify-content: space-between;
    }

    div.twocols > div.col {
        width: 47%;
    }
}

div.subject {
    margin-bottom: 0.5em;
}

div.subject div {
    margin-top: 0.3em;
    margin-bottom: 1em;
}

div.course {
    margin-bottom: 2em;
}

#links > ul {
    margin-top: -0.7em;
}

#links ul > li {
    margin-bottom: 0.15em;
}

div.surveyQuestion {
    margin-bottom: 1.6em;
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-orient: vertical;
    -webkit-box-direction: normal;
        -ms-flex-direction: column;
            flex-direction: column;
    -webkit-box-pack: start;
        -ms-flex-pack: start;
            justify-content: flex-start;
    -webkit-box-align: start;
        -ms-flex-align: start;
            align-items: flex-start;
}

div.sliderWithNums {
    width: 12em;
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-pack: justify;
        -ms-flex-pack: justify;
            justify-content: space-between;
    -webkit-box-align: center;
        -ms-flex-align: center;
            align-items: center;
    margin-top: 0.5em;
}

span.sliderDesc {
    font-style: italic;
    font-size: 0.8em;
}

input.surveyTextbox, textarea.surveyTextbox {
    font-family: 'Open Sans', 'Helvetica', sans-serif;
    font-size: 0.8em;
    border-style: ridge;
    border-radius: 6px;
    padding: 0.2em 0.5em;
}

input.surveyTextbox {
    margin-left: 0.5em;
}

textarea.surveyTextbox {
    width: 100%;
    height: 5em;
    -webkit-box-sizing: border-box;
            box-sizing: border-box;
    margin-top: 1em;
    margin-bottom: 0.2em;
}

#surveySubmitQuestion {
    margin-top: 2.5em;
    -webkit-box-align: end;
        -ms-flex-align: end;
            align-items: flex-end;
    -webkit-box-pack: justify;
        -ms-flex-pack: justify;
            justify-content: space-between;
    height: 4em;
}

div.checkboxItem {
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    font-size: 0.8em;
    -webkit-box-align: center;
        -ms-flex-align: center;
            align-items: center;
}

div.checkboxItem > input {
    margin: 0.4em 0.5em 0.2em 0.5em;
}

div.checkboxItems {
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-orient: vertical;
    -webkit-box-direction: normal;
        -ms-flex-direction: column;
            flex-direction: column;
    -webkit-box-pack: start;
        -ms-flex-pack: start;
            justify-content: flex-start;
    -webkit-box-align: start;
        -ms-flex-align: start;
            align-items: flex-start;
    margin-top: 0.3em;
}

div.project {
    margin: 0.7em 0;
}

summary span.parens {
    margin-left: 1em;
}

summary {
    cursor: pointer;
}

div.projectDesc {
    margin-bottom: 1.5em;
    margin-top: 0.3em;
}

div.projectDesc p {
    margin: 0.6em auto;
}

div#work #seeAlsoPersonal {
    margin-top: 3em;
}

div#work h3 {
    margin-bottom: 0.8em;
    margin-top: 1.5em;
}

div#writing p:first-child {
    margin-bottom: 2em;
    font-style: italic;
}
