html, body, #main {
    height: 100%;
}

/*   --------------   POPUPS   ----------- */

#notSupportedBrowser {
    display: block;
    position: fixed;
    left: 50%; top: 50%;
    transform: translate(-50%, -50%);
    width: 800px;
    border: 1px solid rgb(150, 150, 150);
    z-index: 1000;
    background-color: white;
    max-width: 100%;
}
#notSupportedBrowser h1, #notSupportedBrowser h3 {
    text-align: center;
}
#popupBackground {
    display: block;
    background-color: rgb(88, 88, 88);
    position: fixed;
    top: 0; left: 0;
    width: 100vw; height: 100vh;
    z-index: 100;
}

@supports (display: grid) {
    #notSupportedBrowser {
        display: none;
    }
    #popupBackground {
        display: none;
        background-color: rgba(0, 0, 0, 0.05);
        position: fixed;
        top: 0; left: 0;
        width: 100vw; height: 100vh;
        z-index: 9;
    }
}

#internetFeedbackBoks {
    text-align: center;
    display: none;
    width: calc(100% - 8em);
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: white;
    padding: 1em;
    z-index: 10;
    box-shadow: 0 6px 8px -6px black;
    border-radius: 5px;
    font-size: 1em;
    width: 70%;
}
#internetFeedbackBoks h3 {
    color: #fd593c;
}
#lukkInternettFeedback {
    border: 1px solid black;
    padding: 1em 1.2em;
    background-color: white;
    margin: 0.5em;
    border-radius: 4px;
    cursor: pointer;
}
#lukkInternettFeedback:hover {
    background-color: rgb(190, 190, 190);
}
#internetFeedbackPermanent {
    display: none;
    text-align: center;
    position: absolute;
    bottom: 0em;
    background-color: white;
    padding: 1em;
    z-index: 10;
    box-shadow: 0 0px 3px 0px black;
    border-radius: 16px 16px 0 0;
    box-sizing: border-box;
    width: 100%;
}
#internetFeedbackPermanent h3 {
    margin-top: 0;
    font-size: 1em;
    color: #fd593c;
}
#internetFeedbackPermanent p {
    margin-bottom: 0;
}

@keyframes loadingSpin {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

#internetLoadingBoks {
    text-align: center;
    display: none;
    width: calc(100% - 8em);
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: white;
    padding: 1em;
    z-index: 10;
    box-shadow: 0 6px 8px -6px black;
    border-radius: 5px;
    font-size: 1em;
    z-index: 200;
}
#loadingIcon {
    width: 50px;
    transform: rotate(0deg);
    animation-duration: 1.3s;
    animation-iteration-count: infinite;
    animation-name: loadingSpin;
    animation-timing-function: steps(12, end);
}

#errorlogDiv {
    display: none;
    width: calc(100% - 8em);
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: white;
    padding: 1em;
    z-index: 10;
    box-shadow: 0 6px 8px -6px black;
    border-radius: 5px;
    max-height: 60%;
    width: 70%;
    overflow-y: auto;
}
#errorlogDiv h3 {
    text-align: center;
    margin-right: 1em;
}
#errorlogUL {
    list-style-type: none;
    font-size: 0.5em;
}
#errorlogUL li {
    margin: 0.5em 0;
}
#lukkErrorlog {
    border: 1px solid black;
    padding: 0.8em 1em;
    background: transparent;
    cursor: pointer;
    position: absolute;
    top: 4em;
    right: 3em;
}
#lukkErrorlog:hover {
    border: 1px solid transparent;
    background: #dedede91;
}

/*   --------------   GENERELT   ----------- */

body {
    font-size: 2em;
    margin: 0; padding: 0;
    font-family: 'Barlow', sans-serif;
    /* background-color: rgba(0, 0, 0, 0.041); */
    /* background-color: #ff97151a; */
    background-color: #ff971514;
}

#main {
    display: grid;
    grid-template-columns: 1fr 3fr;
}

.hoved {
    padding: 0.5em;
}

* {
    -webkit-touch-callout: none;
    -webkit-user-select: none;
    -khtml-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
}
input, input:before, input:after, textarea {
    -webkit-touch-callout: initial;
    -webkit-user-select: initial;
    -khtml-user-select: initial;
    -moz-user-select: initial;
    -ms-user-select: initial;
    user-select: initial;
}

#creds {
    position: absolute;
    bottom: 1em;
    right: 1em;
    text-align: right;
    font-size: 0.35em;
}
#creds a {
    text-decoration-color: gray;
    color: gray;
}


/*   --------------   TOOLBAR   ----------- */
#toolbar {
    position: absolute;
    left: 1em;
}
#toolbar img {
    display: inline-block;
    height: 0.7em;
    cursor: pointer;
}

#beskjedBoks {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: white;
    padding: 1em;
    display: none;
    z-index: 10;
    box-shadow: 0 6px 8px -6px black;
    border-radius: 5px;
    width: 70%;
}
#beskjedBoks p {
    text-align: center;
    font-size: 0.6em;

    -webkit-touch-callout: unset;
    -webkit-user-select: unset;
    -khtml-user-select: unset;
    -moz-user-select: unset;
    -ms-user-select: unset;
    user-select: text;
}
#beskjedInput {
    border: 1px solid black;
    padding: 1em;
    background-color: white;
    width: 80%;
    position: relative;
    left: 50%;
    transform: translateX(-50%);
    box-sizing: border-box;
}
.knappDiv {
    display: flex;
    justify-content: center;
}
#bekreftBeskjed, #avbryt, #hintJa, #hintNei {
    border: 1px solid black;
    padding: 1em;
    background-color: white;
    margin: 0.5em;
    cursor: pointer;
    transition: background-color 200ms;
}
#avbryt {
    color: red;
}
#bekreftBeskjed:hover, #avbryt:hover, #hintJa:hover, #hintNei:hover {
    background-color: rgba(61, 61, 61, 0.349);
}

#hintBoks {
    position: fixed;
    display: none;
    bottom: 0;
    left: 50%;
    transform: translate(-50%, 100%);
    transition: transform 0.5s;
    padding: 1em;
    background-color: white;
    box-shadow: 0 6px 8px -6px black;
    border-radius: 25px 25px 0 0;
    z-index: 1;
    width: 50%;
}
#hintBoks p, #hintBoks h5 {
    margin: 0;
    text-align: center;
}
#hintJa, #hintNei {
    margin: 0.5em 0.5em 0;
}

#errorImg {
    display: inline-block;
    width: 0.75em;
    height: 0.7em;
    cursor: pointer;
    opacity: 0.5;
    position: fixed;
    bottom: 0.5em;
    left: 0.5em;
}

/*   --------------   BESTILLINGER GENERELT   ----------- */
@keyframes hover {
    0% {
        background-color: rgba(255, 255, 255);
    }
    10% {
        background-color: rgba(0, 0, 0, 0.219)
    }
    80% {
        background-color: rgba(0, 0, 0, 0.219)
    }
    100% {
        background-color: rgba(255, 255, 255);
    }
}
.bestillingsdiv {
    border: 1px solid rgba(0, 0, 0, 0.219);
    border-radius: 2px;
    width: 100%;
    min-height: 3em;
    box-sizing: border-box;
    background-color: rgba(255, 255, 255, 0.192);
}
.bestillingsdiv div {
    cursor: pointer;
}
.bestillingsdiv div:hover {
    animation: hover 3s forwards ease;
}

h3 {
    margin: 0.5em
}

p {
    font-size: 0.5em;
}

/*   --------------   NY BESTILLING   ----------- */
#nyBestilling {
    border-right: 1px solid black;
    display: flex;
    justify-content: center;
    flex-direction: column;
}
#nyBestilling h3, #nyBestilling p, #generertTall  {
    transform: translateY(-60px);
}
#nyBestilling p {
    margin: 0 0 2em 0;
    text-align: center;
}

#generertTall {
    width: 4em;
    height: 3em;
    border-radius: 5px;
    background-color: white;
    box-shadow: 0 6px 8px -6px black;
    margin: 0 auto 10px;
    text-align: center;
    cursor: pointer;
    box-sizing: border-box;
    background-color: white;
}
#generertTall div {
    font-size: 2.5em;
    position: relative;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -53%);
}
#generertTall:hover {
    animation: hover 3s forwards ease;
}

/*   --------------   BESTILLINGER PÅ KJØKKENET   ----------- */
#bestillingKjokken {
    margin-bottom: 0.5em;
}
.bestilling{
    display: inline-block;
    padding: 0.2em;
    margin: 0.5em;
    min-width: 1em;
    text-align: center;
    border-radius: 5px;
    background-color: white;
    box-shadow: 0 6px 8px -6px black;
}
@keyframes spin {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(-180deg);
    }
}
#refresh {
    position: absolute;
    right: 0.8em;
    top: 0.5em;
    cursor: pointer;
    animation-duration: 0.8s;
    animation-fill-mode: none;
}

/*   --------------   FERDIGE BESTILLINGER   ----------- */
#ferdigeBestillinger {
    margin-top: 0.5em;
    border-top: 1px solid black;
}

#statistikk {
    width: 48%;
    display: none;
    border: 1px solid rgba(0, 0, 0, 0.219);
    border-radius: 2px;
    min-height: 3em;
    box-sizing: border-box;
    background-color: rgba(255, 255, 255, 0.192);
    margin-left: 1em;
    float: right;
    font-size: 0.5em;
    padding: 1em;
}
#ferdigBestillingDiv {
    float: left; 
    width: 100%;
}
#statistikk h4 {
    margin-top: 0;
}
#ventetid {
    list-style-type: none;
}
#gjennomsnittVentetid {
    list-style-type: none;
}
#resetAvg {
    float: right;
    border: 1px solid black;
    padding: 0.5em;
    transform: translateY(-0.5em);
    background-color: white;
}
#resetAvg:hover {
    background-color: rgba(61, 61, 61, 0.349);
    cursor: pointer;
}

@media only screen and (max-width: 650px){
    #lukkErrorlog {
        position: relative;
        top: 0;
        left: 50%;
        right: 0;
        transform: translateX(-50%);
    }
}

@media only screen and (max-width: 670px){
    #ferdigBestillingDiv {
        float: none!important;
        width: 100%!important;
    }
    #statistikk {
        float: none;
        width: 100%;
        margin: 1em 0;
    }
}