@font-face {
    font-family: 'EB Garamond';
    src: url('fonts/EBGaramond-VariableFont_wght.ttf') format('truetype');
    font-weight: 400 800;
    font-style: normal;
}

@font-face {
    font-family: 'EB Garamond';
    src: url('fonts/EBGaramond-Italic-VariableFont_wght.ttf') format('truetype');
    font-weight: 400 800;
    font-style: italic;
}

html,
body {
    margin: 0;
    padding: 0;
    width: 100vw;
    height: 100vh;
    overflow-x: hidden;
}

body {
    font-family: "EB Garamond", serif;
    margin: 0;
    padding: 0;
}

ul,
li {
    list-style: none;
    margin: 0;
    padding: 0;
    font-size: .875rem;
}

li {
    margin-bottom: .125rem;
}

p {
    font-size: 1.5rem;
}

h2,
h3 {
    font-family: "EB Garamond", serif;
    font-optical-sizing: auto;
    font-weight: 400;
    font-style: normal;
    font-size: 3rem;
    line-height: 1.1;
}

h3 {
    font-size: 2.5rem;
    margin: 0 0 1rem 0;
}

#scrolly {
    display: flex;
    max-width: 100%;
    margin: 0 auto;
}

.metadata {
    color: #666;
    font-family: monospace;
    font-size: 1rem;
}

article {
    flex: 1;
    width: 50%;
    max-width: 1024px;
}

.step {
    margin: 0 0 50vh 0;
    padding: 4rem 2rem;
}

figure {
    position: sticky;
    top: 0;
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: start;
    background: white;
    color: #333;
    font-size: 1.5rem;
    padding: 0 2rem;
    margin: 0;
    width: 50%;
    box-sizing: border-box;
}

.chapter-number {
    font-size: 1.25rem;
    font-style: italic;
    color: #666;
    font-weight: 100;
    margin-bottom: 0.5rem;
}

.chapter-title {
    font-family: "EB Garamond", serif;
    font-optical-sizing: auto;
    font-weight: 400;
    font-style: normal;
    font-size: 3rem;
    line-height: 1.1;
    color: #333;
    margin: 0;
    max-width: 100%;
    white-space: normal;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

#graphic {
    display: block;
    white-space: normal;
}

@media only screen and (max-width: 768px) {
    #scrolly {
        flex-direction: column;
    }

    figure {
        position: absolute;
        top: 0;
        z-index: 2;
        height: auto;
        right: 0;
        padding: 1rem 2rem;
        left: 0;
        width: 100%;
        align-items: center;
        justify-items: center;
        min-height: 75px;
    }

    h2.chapter-title {
        font-size: 1.25rem;
    }

    article {
        padding-top: 5rem;
    }

    .chapter-number {
        font-size: 1rem;
        margin-bottom: 0;

    }
    
    article {
        width: 100%;
    }

}
