* {
    box-sizing: border-box;
}

/* *, *:before, *:after {
    box-sizing: border-box;
} */

@font-face {
    font-family: "Font Awesome";
    font-style: normal;
    font-weight: 900;
    font-display: block;
    src: url("fa-solid-900.woff2") format("woff2"), url("fa-solid-900.ttf") format("truetype");
}

/* Italic variant is currently not used, so we're not loading it */
@font-face {
    font-family: "Rubik";
    font-style: normal;
    font-weight: 300 900;
    font-display: swap;
    src: url("Rubik-VariableFont_wght.ttf") format("truetype");
}

html {
    margin: 0px;
    padding: 0px;
}

body {
    font-family: "rubik", "futura", "museo sans", arial, sans-serif;
    font-size: 13pt;
    color: #666666;
    background-color: #ffffff;
    padding: 0px;
    margin: 0px;
    line-height: 1.5;
    position: relative;
}

p {
    hyphens: auto;
    -webkit-hyphens: auto;
    -ms-hyphens: auto;
}

a {
    color: #fa9919;
    text-decoration: underline;
}

a:hover {
    text-decoration: none;
}

a.image::after {
    content: '';
}

a::after {
    font-family: "Font Awesome";
    font-size: 0.8em;
    content: "\a0\f08e";
}

div#container {
    max-width: 960px;
    margin: 0px auto;
    display: flex;
    flex-flow: column nowrap;
    position: relative;
}

div#line {
    border-left: 4px solid #00303c;
    height: 100%;
    position: absolute;
    left: 50%;
    margin-left: -2px;
    top: 0px;
    z-index: 1;
}

.navcell {
    padding: 20px;
    position: relative;
    background-color: #ffffff;
    height: 360px;
    align-content: center;
    left: 0px;
    width: 50%;
}

.navcell:nth-of-type(2) {
    left: 50%;
    margin-top: -360px;
}

.cell {
    padding: 12px 40px;
    position: relative;
    background-color: #ffffff;
    width: 50%;
}

.cell img {
    max-width: 100%;
}

/* The circles on the timeline (trick from https://www.w3schools.com/howto/howto_css_timeline.asp) */
.cell::after {
    content: '';
    position: absolute;
    width: 25px;
    height: 25px;
    right: -16px;
    background-color: white;
    border: 4px solid #00303c;
    top: 40px;
    border-radius: 50%;
    z-index: 1;
}

.left {
    left: 0px;
    text-align: right;
}

.right {
    left: 50%;
    text-align: left;
}

/* Shift the circles for blocks on the right side */
.right::after {
    left: -17px;
}

.sidebyside {
    padding-top: 50px;
}

.sidebyside::after {
    border: none;
    z-index: -1;
}

.caption {
    font-size: 0.8em;
}

img#portrait {
    position: absolute;
    top: 30px;
    left: calc((100% - 300px) / 2);
    width: 300px;
    z-index: 1;
}

nav {
    font-size: 1.2em;
    color: #444444;
    min-height: 3em;
    line-height: 2em;
    text-align: center;
}

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

nav a {
    margin: 0px 10px;
    color: #444444;
    text-decoration: none;
}

nav a:hover {
    color: #fa9919;
}

nav a::after {
    content: '';
}

nav .highlight {
    color: #fa9919;
}

h2 {
    margin-top: 30px;
    margin-bottom: 15px;
    text-transform: uppercase;
    font-size: 15pt;
    color: #00303c;
    letter-spacing: 1px;
}

footer {
    position: relative;
    top: 0px;
    left: 0px;
    padding-bottom: 30px;
    font-size: 10pt;
    margin: 0px;
    width: 100%;
    color: #cccccc;
    background-color: #00303c;
    z-index: 2;
}

div#static-container {
    max-width: 520px;
    margin: 0px auto;
    padding: 0px 20px;
    text-align: justify;
}

/* Small screen adaptations */
@media (max-width: 960px) {
    div#line {
        left: 50px;
    }
    
    /* Image needs to be inline, not overlapping the navigation blocks */
    img#portrait {
        position: relative;
    }
    
    .navcell {
        height: auto;
        width: calc((100% - 50px) / 2);
        left: 50px;
    }
    
    /* The top margin is adjusted in JS to equal the height of the other block */
    .navcell:nth-of-type(2) {
        left: calc(40% + 50px);
        margin-top: 0px;
    }
    
    /* Cells take up most of the screen width, and are always to the right of the timeline */
    .cell {
        width: 90%;
    }
    
    .left {
        left: 50px;
        text-align: left;
    }
    
    .right {
        left: 50px;
        text-align: left;
    }
    
    .left::after {
        left: -17px;
    }
}

@media (max-width: 500px) {
    img#portrait {
        left: 20%;
        width: 60%;
    }
}
