@font-face {
    font-family: "Gotham";
    src: url("../fonts/GothamBold.ttf") format("truetype");
    font-weight: bold;
}
@font-face {
    font-family: "Gotham";
    src: url("../fonts/GothamBoldItalic.ttf") format("truetype");
    font-weight: bold;
    font-style: italic;
}
@font-face {
    font-family: "Gotham";
    src: url("../fonts/GothamBook.ttf") format("truetype");
    font-weight: normal;
}
@font-face {
    font-family: "Gotham";
    src: url("../fonts/GothamBookItalic.ttf") format("truetype");
    font-weight: normal;
    font-style: italic;
}

:root{
    --tesla-white: #eeeeee;
    --tesla-white-active: #f6f6f6;
    --tesla-blue: #006cfd;
    --tesla-grey-button: #d8d8d8;
    --tesla-black:#131313;
    --tesla-icon:#373737;
    --tesla-intermediate: #bbbbbb ;
    --tesla-grey-font: #808080;
    --tesla-red: #ff371f;
}

body{
    font-family: 'Gotham';
    background-color: var(--tesla-white);
    color: var(--tesla-grey-font);
    width: 820px;
    max-width: 100%;
    margin: auto;
    margin-top: 25px;
}

body.fullscreen {
    font-size: 0.8em;
}

.debug > span {
    font-weight: bold;
    color: var(--tesla-grey-font);
    font-size: 1.3em;
}
.debug > h1 {
    
    font-size: 1.2em;
    font-weight: normal;
}

.debug-group {
    margin-bottom: 75px;
}

.separator {
    border: solid 1px var(--tesla-grey-button);
    width: 100%;
    display: inline-block;
    margin-bottom: 20px;
}


.button {
    font-weight: bold;
    font-family: 'Gotham';
    text-transform: uppercase;
    border: none;
    font-size: 1.2em;

    padding: 20px 39px 20px 39px; /* 10 30 10 30 */
    min-width: 195px; /*150*/
    border-radius: 39px; /* 30 */
    margin: 13px; /* 10 */
}

.button.fullscreen{
    padding: 14px 27px 14px 27px;
    min-width: 137px;
    border-radius: 28px;
    margin: 9px;
}

a.button{
    text-decoration: none;
    display: inline-block;
}

.button.blue {
    background-color: var(--tesla-blue);
    color: var(--tesla-white-active);
}

.button.blue:hover {
    background-color: var(--tesla-blue);
    color: var(--tesla-white-active);
}

.button.grey{
    background-color: var(--tesla-grey-button);
    color: var(--tesla-icon);
}

.button.grey:hover{
    background-color: var(--tesla-grey-font);
    color: var(--tesla-white);
}

.button.white{
    background-color: var(--tesla-white);
    color: var(--tesla-icon);
    border: solid 3px var(--tesla-grey-button);
}

.button.white:hover{
    background-color: var(--tesla-intermediate);
    color: var(--tesla-white);
    border: solid 3px var(--tesla-grey-font);
}

.autopilot{
    padding: 20px 39px 20px 39px; /* 10 30 10 30 */
    min-width: 260px; /*200*/
    border-radius: 9px; /*6*/
    min-height: 58px; /*45*/
}

.tabs {
    position: fixed;
    top: 0;
    width: 100%;
    height: 75px;
    background-color: var(--tesla-white-active);
    left: 0;
    text-align: center;
    align-items: center;
    display: flex;
    justify-content: space-around;
    font-weight: bold;
    z-index: 8;
}

.tabs.fullscreen{
    height: 52px;
}

.tabs > .active {
    color: var(--tesla-icon);
}

.tabs > input {
    width: 150px;
    height: 100%;
    line-height: 75px;
    border: none;
    background: none;
    font-family: 'Gotham';
    font-weight: bold;
    color: var(--tesla-grey-font);
    font-size: 1em;
}

.tabs.fullscreen > input {
    line-height: 52px;
}


#media, #tools, #games {
    display: flex;
    flex-flow: row wrap;
}

#contents > div {
    padding-top: 60px;
    padding-bottom: 60px;
}

.element {
    width: 250px;
    height: 250px;
    transition: 0.2s;
    margin: 10px;
}

.element.fullscreen{
    width: 175px;
    height: 175px;
}

.element:hover{
    transform: scale(0.9);
}

.element > img {
    width: 100%;
    height: 200px;
    border-radius: 20px;
    object-fit: cover;
}

.element.fullscreen > img{
    height: 140px;
    border-radius: 14px;
}

.element > span {
    text-align: center;
    width: 100%;
    display: block;
    padding-top: 10px;
}

.element.fullscreen > span{

}

.element:nth-child(3n){
    page-break-after: always;
}

#lateralPanel {
    animation: fadein 0.5s;
    background-color: rgba(0, 0, 0, 0.30);
    position: fixed;
    top: 0;
    left: 0;
    display: flex;
    flex-direction: row-reverse;
    height: 100vh;
    width: 100%;
    z-index: 10;
}

#lateralPanel > div.details{
    height: 100%;
    width: 800px;
    text-align: center;
    background-color: var(--tesla-white-active);
    animation: slidein 0.5s;
    overflow: auto;
    z-index: 11;
    pointer-events: all;
}

div.details.fullscreen{
    width: 500px !important;
}

#lateralPanel > div.details > input.close {
    position: relative;
    top: 10px;
    font-size: 27px;
    width: 720px;
    text-align: left;
    height: 40px;
    background: none;
    border: none;
    color: var(--tesla-grey-font);
    left: -20px;
}
#lateralPanel > div.details.fullscreen > input.close {
    left: 20px;
    font-size: 19px;
}


#lateralPanel > div.details > .button {
    position: fixed;
    bottom: 20px;
    right: 400px;
    transform: translate(50%);
}

#lateralPanel > div.details.fullscreen > .button {
    right: 240px;
}

#lateralPanel > div.details > .text > img {
    margin-top: 60px;
    border-radius: 20px;
    max-width: 90%;
    object-fit: cover;
    max-height: 50%;
}

#lateralPanel > div.details.fullscreen > .text > img {
    margin-top: 20px;
    max-height: 35vh;
}

#lateralPanel > div.details > .text > span {
    margin-top: 20px;
    display: block;
    width: 90%;
    margin-left: auto;
    margin-right: auto;
}
#lateralPanel > div.details > .text {
    max-height: calc(100vh - 150px);
    overflow-y: auto;
}

#fullscreen-button{
    position: fixed;
    left: 0;
    bottom: 0;
}

#backgroundClick{
    position: fixed;
    width: 100vw;
    height: 100vh;
}

.popup{
    width: 100vw;
    height: 100vh;
    z-index: 998;
    background-color: #00000091;
    position: fixed;
    top: 0;
    left: 0;
}

.popup > div > div.content{
    background-color: var(--tesla-white);
    border-radius: 0px 0px 20px 20px;
    padding: 20px;
    text-align: center;
}

.popup > div.content {
    display: flex;
    flex-direction: column;
    width: 80%;
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%,-50%);
    pointer-events: all;
    z-index: 999;
    animation: fadein 0.3s;
}

.popup > div > div.title {
    text-align: center;
    background-color: var(--tesla-white-active);
    border-radius: 20px 20px 0px 0px;
    color: var(--tesla-black);
    height: 65px;
    line-height: 39px;
}

.popup > div > div.title > h1{
    font-size: 1.3em;
    vertical-align: middle;
    display: inline-block;
}

div.checkbox{
    line-height: 20px;
    margin-bottom: 30px;
}

div.checkbox > label > input {
    width: 20px;
    height: 20px;
    position: relative;
    top: 4px;
}

#app-version{
    
}

@keyframes fadein {
    from {
        opacity: 0%;
    }

    to {
        opacity: 100%;
    }
}

@keyframes slidein {
    from {
        transform: translate(100%);
    }

    to {
        transform: translate(0%);
    }
}