@font-face {
font-family: 'chakrapetch';
src: url('../resources/chakrapetch.woff') format('woff');
font-weight: normal;
font-style: normal;
font-display: swap;
}


*{
box-sizing: border-box;
margin:0; padding:0; 
outline: none;
font-family: Arial;
overflow: auto;
}

html,body{
width: 100%;
min-height: 100vh;
max-width: 100%;
overflow-x: hidden;
overflow-y: auto;
}

body{
background: rgb(0,0,0) url("../resources/background.jpg");
background-size: cover;
position: relative;
display: flex;
flex-direction: column;
align-items: center;
justify-content: flex-start;
overflow-y: visible;
font-size: 14px;
}


/*-------------TOP--------------*/

#topbar{
height: 30px;
margin: 5px 0 30px 0;
display: flex;
justify-content: space-between;
}


.fixed{
cursor: pointer;
height: 100%;
min-width: 30px;
}


#hide{
border:1px solid pink;
width: 5ch;
padding:2px;
color: pink;
text-align: center;
display:inline-flex;
align-items: center;
justify-content: center;
}

#genre{
height: 100%;
display: flex;
background-color: transparent;
}


.genre,.left,.right{
height: 100%;
padding: 2px;
display: flex;
align-items: center;
justify-content: center;
color: yellow;
text-transform: lowercase;
font-variant: small-caps;
-webkit-tap-highlight-color: rgba(255,255,255,.5);
}

.genre{
border-bottom: 1px solid yellow;
}

.left,.right{
width: 30px;
cursor: pointer;
}

.dir{
width: 100%;
height: 100%;
cursor: pointer;
}

.dir *{
fill: rgba(0,0,0,.5);
stroke: yellow;
stroke-width: 1;
}

/*-------------MIDDLE--------------*/

#container{
position: relative;
height: auto;
margin-bottom: 10px;
display: grid;
grid-gap: 20px;
grid-template-columns: 1fr 1fr;
grid-auto-rows: 40px;
}

.span{
width: 100%; height: 100%; 
display: flex;
justify-content: center;
align-items: center;
cursor: pointer;
background: rgb(0,0,0,0.4);
border-radius: 3px;
font-size: 13px;
font-family: chakrapetch, Arial;
position: relative;
}

.idle{
color:white;
border:1px solid darkgray;
}

.clicked,.playing{
color:#39ff14;
border:1px solid #39ff14;
}

.offline,.paused{
color: red;
border:1px solid red;
}

.playing::after{
content:"";
background: url("../resources/playing.svg") no-repeat;
height:1em; width:1em;
background-size:80%;
position: absolute; right: 0;
}


/*
.span:last-child:nth-child(2n-1){
left:50%;
}*/

.hidden{
display: none;
}


/*-------------BOTTOM--------------*/

#bottombar{
margin: 30px 0;
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
}

#controls{
width: 100%; height: 2em;
display: flex;
justify-content: center;
}

.prev, #pause, .next,#timer{
display: inline-flex;
justify-content: center;
align-items: center;
cursor: pointer;
color: black;
background: darkgray;
border: 1px solid black;
border-radius: 3px;
font: bold 14px chakrapetch, Arial;
overflow: hidden;
}

.prev,.next{
width: 7ch; height: 100%;
text-transform: uppercase;
}

#pause{
width: 15ch; height: 100%;
margin: 0 20px;
text-transform: uppercase;
}


#timer{
cursor: auto;
max-width: 80%;
padding: 5px;
margin: 20px 0 40px 0;
color: purple;
font: 12px Arial;
font-variant: all-small-caps;
text-align: center;
}

#footer{
width: 100%; height: 30px;
line-height: 30px;
text-align: center;
font-variant: all-small-caps;
padding: 0 2px;
color: lightgray;
background: rgb(0,0,50);
background: rgba(0,0,50,.5);
border-top: 1px solid darkgray;
position: absolute;
bottom: 5px;
overflow: hidden;
}

.settings,.about{
cursor: pointer;
color: yellow;
}

.logo{
opacity: 1;
animation: changeColors 2s linear infinite alternate;
}

@keyframes changeColors{
0%{opacity: 0.9}
100%{opacity: 0}
}



/*-------------SETTINGS--------------*/

.normalflex{
display: flex;
align-items: flex-start;
justify-content: flex-start;
}

.centerflex{
display: flex;
align-items: center;
justify-content: center;
}

#overlay{
flex-direction: column;
position: absolute;
overflow: hidden;
top: 0; bottom:0;
right: 0; left:0;
background: rgb(0,0,0,.7);
font-variant: all-small-caps;
}

.modal{
z-index: 2;
height: 200px;
padding: 10px;
position: fixed;
bottom: calc(50vh - 100px);
flex-direction: column;
background: linear-gradient(to bottom, white, darkgray);
border: 5px outset blue;
transition: .5s ease-in;
transform: scale(0,0);
}

.popin{
transform: scale(1,1);
}

.popout{
transform: scale(0,0);
}


@keyframes popin{
from{transform: scale(0,0)}
to{transform: scale(1,1)}
}

@keyframes popout{
from{transform: scale(1,1)}
to{transform: scale(0,0)}
}


.modal .select, .modal .input,
.modal .save, .modal .sleep{
width: 200px; height: 30px;
padding: 2px;
background: lightgray;
border: 1px solid black;
}

.modal .save,
.modal .sleep{
width: 50px;
margin: 0 0 0 2px;
}

.modal .save:hover{
color: white;
background: black;
}

.msg{
margin: 10px 0 20px 0;
}

.nr{
color: green;
font-weight: bold;
}

.close{
width: 30px; height: 30px;
overflow: hidden;
position: absolute;
top:0; right: 0;
color: white;
background: linear-gradient(to bottom right, red, pink);
border: 2px solid black;
font: bold 30px Arial;
cursor: pointer;
}

.lastmod{
position: absolute;
right: 5px; bottom: 2px;
color: purple;
font: bold 10px "Courier New";
letter-spacing: -0.5px;
}



/*-------------GENERAL--------------*/

/*
body::-webkit-scrollbar{
width: 3px;
height: 3px;
}

body::-webkit-scrollbar-track{
background: white;
}

body::-webkit-scrollbar-thumb{
background: yellow;
border-radius: 50px;
}
*/


@media(orientation:portrait){
#container,#topbar,#bottombar{
width: 90%;
}

.modal{
width: 90%;
left: 5%;
}

}	

@media(orientation:landscape){
#container,#topbar,#bottombar{
width: 50%;
}

.modal{
width: 50%;
left: 25%;
}

}
