@font-face {
  font-family: 'Atkinson Hyperlegible';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  size-adjust: 110%;
  src: local('Atkinson Hyperlegible'),
       url('fonts/atkinson-hyperlegible-v10-latin-regular.ttf') format('truetype');
}

@font-face {
  font-family: 'Atkinson Hyperlegible';
  font-style: italic;
  font-weight: 400;
  font-display: swap;
  size-adjust: 110%;
  src: local('Atkinson Hyperlegible'),
       url('fonts/atkinson-hyperlegible-v10-latin-italic.ttf') format('truetype');
}

@font-face {
  font-family: 'Atkinson Hyperlegible';
  font-style: normal;
  font-weight: bold;
  font-display: swap;
  size-adjust: 110%;
  src: local('Atkinson Hyperlegible'),
       url('fonts/atkinson-hyperlegible-v10-latin-700.ttf') format('truetype');
}

:root {
    --color:#002034;
    --background:#d4ecfd;
    
    --link:#003d84;
    --linkhover:#009c5d;
    
    --accentbg:#b0dffd;
    --hr: #6bbdf0;
}

@media (prefers-color-scheme: dark) {
    :root {
        --color:#c5d7f0;
        --background:#002046;
        
        --link:#e5b023;
        --linkhover:#ffde46;
        
        --accentbg:#011832;
        --hr: #003d84;
    }
}

* { margin: 0; padding: 0; transition: color 0.5s ease, opacity 0.5s ease;}
img { margin:5px; max-width:100%; }

body { 
    color:var(--color);
    background:var(--background) url(kale/wavecut.png) fixed;
    font: 1rem 'Atkinson Hyperlegible', sans-serif; 
    letter-spacing:.35px;
}

#cover {
    text-align:center;
    padding:10px 30px 10px 30px;
    width:calc(100% - 60px);
}

main {
    padding:10px 30px 10px 30px;
    width:calc(100% - 60px);
    margin:auto;
}

a {
    color:var(--link);
}

a:hover, a:focus {
    color: var(--linkhover);
}

p {
    margin:10px 0px 10px 0px;
    line-height:1.5;
}

main h1 {
    font-size:2em;
    margin:5px 0 5px 0;
}

main h2 {
    margin:20px 0 10px 0;
    font-size:1.8em;
    font-weight:normal;
}

main h2::first-letter {
    color:var(--link);
    font-size:1.2em;
}

main ol#contents {
    list-style:outside upper-roman;
    margin: 10px 0 10px 40px;
    font-size:1.3em;
}

main ol#contents li {
    margin: 10px 0 10px 0;
}

main ol#contents .meta {
    font-size:0.75em;
}

main hr {
    border:0.5px solid var(--hr);
    margin:20px auto 20px auto;
}

main .box {
    background:var(--accentbg);
    margin: 10px;
    padding: 10px;
    border-radius:5px;
}

summary {
    cursor:pointer;
    margin: 5px 0px 5px 0px;
}

details {
    padding:10px;
    background:var(--accentbg);
    margin:5px 0 5px 0;
    border-radius:5px;
}

main footer {
    text-align:center;
    border-top: 0.5px solid var(--hr);
    margin-top:10px;
    padding:10px;
}

@media screen and (min-width:800px) {
    #container {
        display:flex;
        align-items:flex-start;
    }

    #cover {
        flex: 1 1 calc(40% - 20px);
        padding:10px;
    }

    main {
        flex: 1 1 calc(60% - 60px);
        padding-top:10px;
    }
}

@media (prefers-color-scheme: dark) {

    img {
        opacity:0.6;
    }
    
    img:hover {
        opacity:1;
    }
}