body {
    background-color: black;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    align-items: center;
    height: 100vmin;
    width: 100vw;
    font-family: "Oxanium";
    color: white;
    margin: 0;
}

body.hideKMH #kmhlabel {
    /* display: none; */
    opacity: 0;
    height: 0;
}

body.hideKMH.speedVertical #speed {
}

body.flip #textWrapper,
body.flip canvas {
    transform: scaleX(-1);
}

body.speedVertical #textWrapper,
body.speedVertical #speed,
body.speedVertical #kmhlabel {
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    width: auto;
    margin-bottom: 0 !important;
    top: 0;
    left: 0;
}

body.speedVertical.circular #speed {
    height: 20vmin;
    font-size: 15vmin;
}

body.speedVertical #textWrapper {
    height: 100vmin;
}

body.circular #speed {
    margin-bottom: 40vmin;
    font-size: 20vmin;
}

body.circular #kmhlabel {
    font-size: 5vmin;
    margin-bottom: 40vmin;
}

body.style5 #speed {
    transition: none;
    font-family: "DSEG7 Modern";
    text-shadow: 0 0 3vmin;
    position: relative;
    width: 2.5em;
    text-align: right;
    /* line-height: 0vmin; */
}

body.style5:not(.circular) #speed {
    margin-bottom: 0;
}

body.style5 #speed::before {
    position: absolute;
    top: 0;
    right: 0;
    content: "88.8";
    text-align: right;
    opacity: 0.2;
    text-shadow: 0 0 21vmin black;
}
body.style5 #speed::after {
    position: absolute;
    top: 0;
    right: 0;
    content: "88.8";
    opacity: 0.45;
    color: transparent;
    text-shadow: 0 0 1.5vmin black;
}

body.style5 #speed,
body.style5 #kmhlabel {
    color: rgb(227 215 160) !important;
}

body.style5.showNumberBG #speed,
body.style5.showNumberBG #kmhlabel {
    color: var(--userColor) !important;
}

body.circular.hideKMH.style5 #speed {
    font-size: 15vmin;
    line-height: 24vmin;
}

body.circular:not(.hideKMH).style5 #speed {
    font-size: 18vmin;
    line-height: 24vmin;
}

body.style5:not(.circular) #kmhlabel {
    margin-bottom: 15vmin !important;
}

body.style5.circular #kmhlabel {
    margin-bottom: 30vmin !important;
}

#requestLocation {
    position: fixed;
    background: white;
    color: black;
    font-size: 5vmin;
    padding: 30px;
    border-radius: 16px;
    z-index: 100000000000;
    opacity: 1;
}
#requestLocation:hover {
    background-color: red;
}
#requestLocation.hidden {
    display: none;
}

canvas {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    transition: all 0.3s;
}

canvas#canBG {
    z-index: 1;
}

canvas#canOverlay {
    z-index: 99;
}

canvas#canSpeed {
    z-index: 2;
    /* filter: blur(3px); */
}

#textWrapper {
    display: flex;
    flex-direction: row;
    align-items: baseline;
    transition: all 0.3s;
    user-select: none;
}

#speed {
    z-index: 10000;
    font-size: 30vmin;
    font-variation-settings: "wght" 400;
    transition: all 0.3s;
    margin-bottom: 20vmin;
    user-select: none;
}

#kmhlabel {
    font-variation-settings: "wght" 400;
    box-sizing: content-box;
    width: 0px;
    position: relative;
    left: 1vw;
    top: -10px;
    content: "km/h";
    font-size: 10vmin;
    height: 10vmin;
    font-style: italic;
    opacity: 0.5;
    transition: all 0.3s;
}

body.showGridded .gridded {
    width: fit-content;
    background-image: url(grid.png);
    color: transparent !important;
    background-size: 10px;
    -webkit-background-clip: text;
}

#realspeed {
    opacity: 0.3;
    position: fixed;
    bottom: 0px;
    left: 0px;
    padding: 20px;
    transition: all 0.2s;
}

#realspeed.highlight {
    opacity: 0.5;
    color: red;
}

body.showButtons #flipper,
body.showButtons #settings {
    opacity: 1;
}

#flipper,
#settings {
    z-index: 100000;
    font-size: 10vmin;
    position: fixed;
    bottom: 0px;
    right: 5vw;
    padding: 2vw;
    opacity: 0.05;
    transition: all 0.5s;
}

body.topButtons #flipper,
body.topButtons #settings {
    bottom: 80vmin;
}

#settings {
    left: 0;
    right: auto;
}

.icon {
    font-family: "Material Icons";
}

#installButton {
    display: none;
    position: fixed;
    bottom: 0px;
    left: 0px;
    right: 0px;
    font-size: 5vmin;
    z-index: 100000000;
    background-color: white;
    color: black;
    padding: 20px;
    text-align: center;
}

#installButton.show {
    display: block;
}

#settingsBackdrop {
    display: none;
    z-index: 10000000;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
}

#settingsBackdrop.show {
    display: flex;
}

#settingsDialog {
    display: flex;
    flex-direction: column;
    background-color: rgba(255, 255, 255, 0.3);
    backdrop-filter: blur(2px);
    border-radius: 2vmin;
    padding: 5vmin;
    margin-left: 10vmin;
}

.hflex {
    display: flex;
    flex-direction: row;
    align-items: center;
    margin: 1vmin 0;
    justify-content: space-between;
}

h1 {
    font-size: 6vmin;
    margin: 0;
}

h2 {
    font-size: 4vmin;
    padding: 3vmin;
}

h3 {
    font-size: 3vmin;
    margin-right: 3vmin;
    margin-left: 0;
}

#roundnessSlider {
    width: 300px;
}

#stylesetting img {
    transition: all 0.3s;
    margin-left: 3vmin;
    border-radius: 3vmin;
    width: 50px;
}

body.showNumberBG #stylesetting img.styleImage_noblue,
body:not(.showNumberBG) #stylesetting img.styleImage {
    display: none;
}

body.style1 .setting1,
body.style2 .setting2,
body.style3 .setting3,
body.style4 .setting4,
body.style5 .setting5,
body.style6 .setting6,
body.style7 .setting7,
body.style8 .setting8,
body.style9 .setting9,
body.style10 .setting10 {
    /* text-align: center;
    background-color: #0099ff;
    border-radius: 100px;
    color: white; */
    box-shadow: 0 0 10px white;
}

#colorpicker {
    margin-left: 5vmin;
    align-self: flex-end;
    display: flex;
    flex-direction: column;
}

#huefield {
    width: 40vmin;
    height: 10vmin;
    margin-bottom: 10vmin;
    background-image: linear-gradient(to right, #f00, #ff0, #0f0, #0ff, #00f, #f0f, #f00);
}

#huefield #huemarker {
    width: 1vmin;
    height: 10vmin;
    border: solid 0.5vmin white;
    border-radius: 0.5vmin;
    box-sizing: border-box;
    transform: translateX(-50%);
}

#colorfield {
    width: 40vmin;
    height: 40vmin;
    background-image: linear-gradient(to bottom, transparent, black), linear-gradient(to right, white, transparent);
    background-color: red;
    position: relative;
}

#colorfield #marker {
    display: block;
    width: 1vmin;
    height: 1vmin;
    border-radius: 1000vmin;
    border: solid 0.5vmin white;
    position: absolute;
    box-shadow: 0 0 1vmin black;
    transform: translate(-50%, -50%);
}
