* {
    margin: 0;
    padding: 0;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
    box-sizing: border-box;
}

body {
    background: #BDFFBD;
    width: 100%;
    height:100%;
    overflow: hidden;
}

canvas {
    position: fixed;
    top: 50%;
    left: 50%;
    max-width: 100%;
    max-height: 100%;
    transform: translate(-50%, -50%)
}

#gameover {
    position: fixed;
    top: 0;
    left: 0;
    width:100%;
    height: 100%;
    background: rgb(211, 32, 32);
    animation: fade 1s;
    z-index: 99;
    display: none;
}

#gameover > div {
    position: fixed;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    z-index: 100;
    animation: slide 1s;
    text-align: center;
}

#score {
    margin: 1em;
    font-size: 3em;
}

#score2 {
    position: fixed;
    top: 0;
    left: 0;
    margin: .5em;
    font-size: 4em;
}

#restart {
    border: black solid 2px;
    background: rgba(0, 0, 0, 0);
    padding: .5em;
    font-size: 1.5em;
    cursor: pointer;
    transition: all .5s
}

#restart:hover {
    background: rgba(0, 0, 0, 1);
    color: white;
}

@keyframes fade {
    from {opacity: 0}
    to {opacity: 1}
}

@keyframes slide {
    from {transform: translate(-100%, -50%)}
    to {transform: translate(-50%, -50%)}
}