@font-face {
    font-family: FZERO_SNES;
    src: url('Fonts/rexlia rg.otf') format('opentype');
  }
canvas{
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);               
}
#startRaceButton {
    position: absolute;
    bottom: 5%;
    right: 5%;
    border-style: groove;
}
#creditsButton {
    position: relative;
}
.backButton {
    position: absolute;
    bottom: 5%;
    left: 5%;
    border-style: groove;
}
.infoDiv {
    background: rgb(112,5,90);
background: linear-gradient(90deg, rgba(112,5,90,0.5634628851540616) 0%, rgba(112,5,80,0.47942927170868344) 100%);
    font-family: FZERO_SNES;
    border: 5px solid white;
    width: 95%;
    height: 90%;
    border-radius: 30px;
    position: relative;
    top: 5%;
    left: 2%;
    display: flex;
    color: white;
}
.bmDiv, .acDiv {
    margin-top: 2.5%;
    height: 90%;
    width: 50%;
}
.bmDiv {
    border-right: 5px solid white;
    font-size: 16px;
}
h2 {
    font-size: 20px;
}
h3 {
    font-size: 16px;
}
.menuDiv {
    position: absolute;
    justify-content: center;
    top: 50%;
    left: 50%;
    width: 1024px;
    height: 522px;
    transform: translate(-50%, -50%);
    background-image: url("./Sprites/straightaway menu night.gif");
    background-size: cover;
    border-color: white;
    border: 4px solid white;
    border-radius: .5%;
    text-align: center;
}
.menuButton {
    background: rgb(80,5,112);
    background: linear-gradient(90deg, rgba(80,5,112,1) 0%, rgba(255,0,134,1) 100%);
    font-family: FZERO_SNES;
    font-size: 12pt;
    font-weight:lighter;
    /* -webkit-text-stroke-width: .05px;
  -webkit-text-stroke-color: black; */
    border-color: white;
    border-radius: 10px;
    border-width: 4px;
    color: white;
}
.buttonText {
    margin: 0;
}
.leftArrow {
    display: inline-block;
  -moz-transform: scale(-1, 1);
  -webkit-transform: scale(-1, 1);
  -o-transform: scale(-1, 1);
  -ms-transform: scale(-1, 1);
  transform: scale(-1, 1);
}
#menuButtons {
    position: absolute;
    top:62%;
    left:50%;
    transform: translate(-50%, -50%);
}
#lastRaceStats{
    background: rgb(112,5,90);
    background: linear-gradient(90deg, rgba(112,5,90,0.5634628851540616) 0%, rgba(112,5,80,0.47942927170868344) 100%);
    position: absolute;
    bottom:1%;
    right:1%;
    font-family: FZERO_SNES;
    font-size: 12pt;
    font-weight:lighter;
    /* -webkit-text-stroke-width: .05px;
  -webkit-text-stroke-color: black; */
    border-color: white;
    border-radius: 10px;
    border-width: 4px;
    color: white;
    text-align: left;
}
#titleImg {
    position: absolute;
    top:25%;
    left:50%;
    transform: translate(-50%, -50%);
    width: 40%;
    height: 40%;
}
/* tabindex="0" style="background: violet; border: 1px solid;" */
#hud{
    pointer-events: none;
    position: absolute;
    transform: translate(-50%, -50%);
    width: 980px;
    height: 370px;
    left: 50%;
    top: 50%;
    display: none;
    justify-content: end;
    align-items: start;   
    font-size: 24px;
    color: white;
    text-shadow: 2px 2px #000000;
}

.lapTime {
    display: flex;
    justify-content: center;
    padding-left: 10px;
    margin-bottom: 5px;
}

#bestLapDiv {
    margin-top: 30px;
    margin-left: 10px;
    position: absolute;
    top: 0;
    right: 0;
}

/* The animation code */
@keyframes countdownAnimation {
    0%   {font-size: 1px;}
    100% {}
  }
@keyframes next {
    0% {content: "3"; font-size: 1px;}
    12% {content: "3"; font-size: 120pt;}
    37% {content: "2"; font-size: 120pt;}
    62% {content: "1"; font-size: 120pt;}
    87% {content: "GO"; font-size: 120pt;}
    92% {content: "GO"; font-size: 120pt;}
    100% {content:"GO"; font-size: 1px;}
}
/* #6A2963 */
#countdown {
    position: absolute;
    justify-content: center;
    text-align: center;
    width: 1024px;
    font-family: FZERO_SNES;
    font-size: 120pt;
    background-image: linear-gradient(180deg, #FF2B7C, #6A2963);
    background-clip: text;
    -webkit-text-fill-color: transparent;
}
#countdown::after {
    content:"";
    animation: next 4s;
}
#countdown_div {
    position: absolute;
    justify-content: center;
    top: 50%;
    left: 50%;
    width: 1024px;
    height: 522px;
    transform: translate(-50%, -50%);
    font-family: FZERO_SNES;
    font-size: 60pt
}

/* The animation code */
@keyframes finishAnimation {
    0%   {font-size: 1px;}
    100% {left:0px; top:0px;}
  }
/* #6A2963 */
#finish {
    position: absolute;
    justify-content: center;
    text-align: center;
    width: 1024px;
    font-family: FZERO_SNES;
    font-size: 120pt;
    background-image: linear-gradient(180deg, #FF2B7C, #6A2963);
    background-clip: text;
    -webkit-text-fill-color: transparent;
    animation-name: finishAnimation;
    animation-duration: 1s;
}
#finish_div {
    position: absolute;
    justify-content: center;
    top: 50%;
    left: 50%;
    width: 1024px;
    height: 522px;
    transform: translate(-50%, -50%);
    font-family: FZERO_SNES;
    font-size: 60pt
}
#transitionContainer {
    position: absolute;
    justify-content: center;
    top: 50%;
    left: 50%;
    width: 1024px;
    height: 522px;
    transform: translate(-50%, -50%);
    font-family: FZERO_SNES;
    font-size: 60pt
}

#audioControl {
    justify-content: center;
    color: white;
}
#audioControlsfx {
    justify-content: center;
    color: white;
}