/* Animationen -------------------------------------------------------------------------- */
@keyframes buttonAusblenden {
    0% {
        opacity: 1;
    }
    99% {
        transform: scale(0);
        opacity: 0;
        position: relative;
    }
    100% {
        visibility: hidden;
        position: fixed;
        top: -100%;
    }
}

@keyframes overview-animation-tablet {
    0%{
        transform: scale(0.1);
        opacity: 0;
    }
    20%{
        transform: scale(0.9) rotate(-90deg);
        opacity: 1;
    }
    50%{
        transform: scale(0.9) rotate(0deg);
        opacity: 1;
    }
    80%{
        transform: scale(0.9) rotate(0deg);
        opacity: 1;
    }
    100%{
        transform: scale(0.1) rotate(0deg);
        opacity: 0;
    }
}

@keyframes overview-animation-pfeile{
    0%{
        opacity: 0;
        transform: rotate(0deg);
    }
    20%{
        opacity: 1;
        transform: rotate(0deg);
    }
    80%{
        opacity: 1;
        transform: rotate(180deg);
    }
    100%{
        opacity: 0;
        transform: rotate(180deg);
    }
}

/* Bootstrap Nano ----------------------------------------------------------------------- */
*,
*::before,
*::after {
    font-family: Arial, Helvetica, sans-serif;
    box-sizing: border-box;
    color: white;

    user-select: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
}

html,
body {
    margin: 0;
    padding: 0;
    width: 100%;
    height: 100%;
    background-position: center;
    background-size: cover;
}

body::before{
    content: '';
    position: absolute;
    top: 0; left: 0;
    width: 100%;
    height: 100%;
    background-color: rgb(19, 19, 83);
    background: linear-gradient(180deg, rgba(51, 51, 51, 0.85) 0%, rgba(34, 34, 34, 0.85) 100%);
}

[data-component]{
    position: relative;
    z-index: 1;
    padding: 1rem;
    padding-top: 5.5rem;
    width: 100%;
}

h1{
    font-weight: 400;
    margin: 0;
    font-size: 1.5rem;
}

template {
    display: none;
}

.button {
    background-color: #e9b213;
    border: none;
    border-radius: 0.5rem;
    color: black;
    padding: 0.625rem 1.25rem;
    text-align: center;
    text-decoration: none;
    display: inline-block;
    font-size: 1rem;
    margin: 0.25rem 0.125rem;
    cursor: pointer;
    transition-duration: 0.4s;
}

.button:hover {
    background-color: #aa830e;
}

.button:active {
    background-color: #86670a;
}

.d-flex {
    display: flex !important;
}

.d-inline-flex {
    display: inline-flex !important;
}

.d-none {
    display: none !important;
}

.justify-content-center {
    justify-content: center !important;
}

.justify-content-between {
    justify-content: space-between !important;
}

.align-items-center {
    align-items: center !important;
}

.table-dark {
    color: #f8f9fa;
    background-color: #343a40;
    border-color: #495057;
    width: 100%;
    margin-bottom: 1rem;
    vertical-align: top;
    border: 1px solid #495057;
}

table {
    caption-side: bottom;
    border-collapse: collapse;
    width: 100%;
    margin-bottom: 1rem;
    vertical-align: top;
    border-color: #4d5153;
    color: #ffffff;
    margin: 1rem 0;
}

.table>tbody {
    vertical-align: inherit;
}

.table>thead {
    vertical-align: bottom;
}

th {
    text-align: inherit;
    text-align: -webkit-match-parent;
}

thead,
tbody,
tfoot,
tr,
td,
th {
    border-color: inherit;
    border-style: solid;
    border-width: 0;
}

.table > tbody > tr{
    border-bottom-width: 1px;
}

.table td, .table th {
    padding: 0.5rem 0.5rem;
    background-color:#212529;
    border-bottom-width: 1px;
    box-shadow: inset 0 0 0 9999px initial;
}

.table>tbody>tr:nth-of-type(odd)>* {
    background-color: #2c3034;
}

.table > tbody > tr:hover > * {
    background-color: #323539;
}

.mb-1{
    margin-bottom: 0.25rem;
}

.mb-2{
    margin-bottom: 0.5rem;
}

.mb-3{
    margin-bottom: 1rem;
}

.scroll-container{
    overflow-y: auto;
    margin: auto;
    max-width: 60rem;
    padding-right: 0.5rem;
}

.h-100{
    height: 100%;
}

.min-h-100{
    min-height: 100%;
}

.text-center{
    text-align: center;
}

/** Startseite -------------------------------------------------------------------------- */
[data-component=startseite]{
    flex-direction: column;
    width: 100%;
}

.startseite-buttons{
    background-color: rgba(35, 35, 35, 0.9);
    padding: 0.5rem;
    border-radius: 0.5rem;
    position: relative;
}

.startseite-button{
    flex-direction: column;
    text-decoration: none;
    width: 6rem;
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 0.5rem;
}

.startseite-button:hover,
.startseite-button.aktiv{
    background-color: rgba(250,250,250,0.1);
}

.startseite-button.aktiv span{
    color: #e9b213;
}

.startseite-button.scannen{
    position: absolute;
    width: 4rem;
    height: 4rem;
    top: -2rem;
    left: calc(50% - 2rem);
    background-color: #e9b213;
    border-radius: 50%;
    box-shadow: 0 0 1rem #aa830e;
    transition: 0.5s transform;
}

.startseite-button.scannen:hover{
    transform: scale(1.1);
}

.startseite-button img{
    margin-bottom: 0.5rem;
    width: 1.5rem;
    height: 1.5rem;
}

.startseite-button.scannen img{
    margin-bottom: 0;
    width: 3rem;
    height: 3rem;
}

.historien-wrapper{
    height: calc(100% - 6rem);
}

.historie{
    max-height: calc(100% - 2rem);
    overflow-y: auto;
    margin-right: -0.5rem;
    padding-right: 0.5rem;
}

.historie-leer{
    padding: 1rem;
    flex-direction: column;
    background-color: rgba(35, 35, 35, 0.2);
    text-align: center;
    border-radius: 1rem;
    cursor: pointer;
    transition: 0.5s background-color;
}

.historie-leer:hover{
    background-color: rgba(20,20,20,0.2);
}

.historie-leer img{
    width: 80%;
    max-width: 20rem;
    margin-bottom: 2rem;
}

.historien-element{
    background-color: rgba(35, 35, 35, 0.5);
    padding: 0.5rem;
    border-radius: 1rem;
    margin-bottom: 1rem;
}

.historien-element .links{
    cursor: pointer;
}

.historien-element .links img{
    width: 2.6rem;
    height: 2.6rem;
    margin-right: 0.5rem;
}

.historien-element .links .wert{
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    width: calc(40vw - 2rem);
}

.historien-element .links .typ{
    color: grey;
}

.historien-element .links .typ::first-letter {
    text-transform: uppercase;
}

.historien-element .rechts{
    text-align: right;
}

.historien-element .rechts a{
    cursor: pointer;
}

.historien-element .rechts img{
    width: 1.5rem;
    height: 1.5rem;
    opacity: 0.7;
    transition: 0.5s opacity;
}

.historien-element .rechts:hover img{
    opacity: 1;
}

.historien-element .rechts div{
    font-size: 0.8rem;
    color: grey;
}

/** Scannerbereich ---------------------------------------------------------------------- */
#video-container {
    width: 100%;
    height: calc(100% - 1rem);
    overflow: hidden;
    position: relative;
    line-height: 0;
}

#qr-video {
    min-width: 100%;
    clip-path: inset(0.5rem 0.5rem round 20px);
    overflow: hidden;
    background-color: #232323;
}

.scanner-button-wrapper {
    position: fixed;
    bottom: 2rem;
    border-radius: 2rem;
    padding: 0.25rem;

    background-color: rgba(35, 35, 35, 0.6);
    backdrop-filter: blur(0.5rem);
}

.scanner-button {
    border-radius: 50%;
    background-color: #e9b213;
    box-shadow: 0 0 0.5rem #7a5e0a;

    display: inline-flex;
    justify-content: center;
    align-items: center;
    padding: 0.5rem;
    margin: 0.25rem;

    transition: 0.5s transform;
    cursor: pointer;
}

.scanner-button:hover {
    transform: scale(1.1);
}

.scanner-button[disabled='true'] {
    animation: 0.5s buttonAusblenden forwards;
}

.scanner-button img {
    height: 1.8rem;
    width: 1.8rem;
}

.active-symbols-wrapper {
    position: fixed;
    top: 5rem;
}

.active-symbol {
    padding: 0.25rem;
}

.active-symbol[disabled='true'] {
    display: none;
}

.topleiste{
    position: fixed;
    background-color: rgba(35, 35, 35, 0.9);
    width: 100%;
    padding: 1rem;
    top: 0;
    left: 0;
}

.zurueck-gehen-icon{
    text-decoration: none;
    cursor: pointer;
}

.zurueck-gehen-icon * {
    color: #e9b213;
}

/** Hochladen --------------------------------------------------------------------------- */
#file-selector{
    display: none;
}

.hochladen-button{
    background-color: rgba(35, 35, 35, 0.85);
    flex-direction: column;
    padding: 1rem;
    border-radius: 1rem;
    cursor: pointer;
    transition: 0.5s background-color;
}

.hochladen-button:hover{
    background-color: rgba(51, 51, 51, 0.85);
}

.hochladen-button img{
    margin-bottom: 1rem;
}

/** Overview zu klein ------------------------------------------------------------------- */
.overview-zu-klein {
    display: none;
    position: fixed;
    top: 0; left: 0; z-index: 19;
    width: 100%;
    padding: 1rem;
    background-color: rgba(10, 10, 10, 0.98);
    background-image: url(/assets/web/bilder/pexels-shottrotter-2249959.jpg);
}

.overview-zu-klein::before{
    content: '';
    position: absolute;
    top: 0; left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(35, 35, 35, 0.7);
}

.overview-zu-klein .overview-fenster {
    max-width: 20rem;
    clip-path: inset(0 0 0 0 round 15px);
    text-align: center;
}

.overview-zu-klein .overview-animation{
    display: flex;
    justify-content: center;
    align-items: center;
    height: 7rem;
    position: relative;
    margin-bottom: 1rem;
}

.overview-zu-klein .overview-animation img{
    position: absolute;
}

.overview-zu-klein .overview-animation img:nth-child(1){
    animation: overview-animation-pfeile 3s infinite;
}


.overview-zu-klein .overview-animation img:nth-child(2){
    animation: overview-animation-tablet 3s infinite;
}

#zwischenablage-input{
    opacity: 0;
    position: fixed;
    top: -100%;
}

/* Media-Queries ------------------------------------------------------------------------ */
@media screen and (max-height: 800px){
    html, body{
        font-size: 14px;
    }
}

@media screen and (max-height: 48rem) and (orientation: landscape) {
    .overview-zu-klein{
        display: flex;
    }
}

@media (pointer: fine) {
    ::-webkit-scrollbar-track {
        background: rgba(20, 20, 20, 0.5);
        border-radius: 0.25rem;
    }
    
    ::-webkit-scrollbar-thumb {
        background: rgba(40, 40, 40, 0.95);
        -webkit-transition: 0.5s background-color;
        transition: 0.5s background-color;
        border-radius: 0.25rem;
        cursor: pointer;
        margin: -0.5rem 0;
    }
    
    ::-webkit-scrollbar {
        width: 0.75rem;
    }
}

@media screen and (min-width: 48rem) {
    .historien-element .links .wert{
        width: calc(80vw - 2rem);
    }
}

.dialog-container{
    display: flex;
    justify-content: center;
    align-items: center;
    position: fixed;
    z-index: 5;
    top: 0; left: 0;

    width: 100%;
    background-color: rgba(30,30,30,0.7);
    padding: 1rem;
}

.dialog{
    width: 100%;
    max-width: 20rem;

    padding: 1.5rem 1.5rem 0 1.5rem;
    border-radius: 1rem;

    background-color: #222222;
    text-align: center;

    overflow: hidden;
}

.dialog-header{
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
    font-weight: 700;
}

.dialog-inhalt{
    line-height: 1.5;
}

.dialog-buttons{
    border-top: 1px solid #656567;
    margin: 1rem -1.5rem 0 -1.5rem;

    display: flex;
}

.dialog-button{
    padding: 1rem;
    text-decoration: none;
    color: #e9b213;
    font-weight: 700;
    text-align: center;
    width: 100%;
}

.dialog-button:nth-child(n+2){
    border-left: 1px solid #656567;
}

.dialog-button:hover{
    background-color: rgba(250,250,250,0.3);
}

.dialog-ergebnis{
    overflow-wrap: break-word;
}

.dialog-inhalt table{
    border: 1px solid rgba(250,250,250,0.3);
    margin: 0.5rem 0;
    width: 18rem;
}

.dialog-inhalt td{
    text-align: left;
    border: 1px solid rgba(250,250,250,0.3);
    padding: 0.25rem;
    font-size: 0.8rem;
}

.dialog-inhalt td:nth-child(2){
    overflow-wrap: break-word;
    word-break: break-all;
}

@keyframes modal-einblenden {
    100%{
        transform: translateY(0);
    }
}

@keyframes modal-ausblenden {
    0%{
        transform: translateY(0);
    }
    100%{
        transform: translateY(100%);
    }
}

.modal-container{
    position: fixed;
    top: 0; left: 0; z-index: 3;
    width: 100%;
    backdrop-filter: blur(0.5rem);

    display: flex;
    justify-content: center;
    align-items: end;
}

.modal{
    width: 100%;
    max-width: 40rem;

    border-radius: 1rem 1rem 0 0;
    background-color: #262626;

    padding: 1rem;
    transform: translateY(100%);
    animation: modal-einblenden 1s forwards;
}

.modal[disabled=true]{
    animation: modal-ausblenden 1s forwards;
}

.modal-header{
    font-size: 1.25rem;
    margin-bottom: 2rem;
    text-align: center;
}

.modal-inhalt{
    line-height: 1.5rem;
}

.modal-actions{
    margin: 2rem 0;
}

.modal-action{
    background: rgb(41,42,43);
    background: linear-gradient(137deg, rgb(51,52,53) 0%, rgb(41,42,43) 80%);
    text-decoration: none;

    padding: 1rem;
    margin-bottom: 1rem;
    border-radius: 1rem;
    transition: 0.5s;

    cursor: pointer;
}

.modal-action:hover{
    background: linear-gradient(137deg, rgb(61,62,63) 0%, rgb(51,52,53) 80%);
}

.modal-action img{
    width: 3rem;
    height: 3rem;
    margin-right: 1rem;
}

.modal-action-titel{
    display: block;
    margin-bottom: 0.4rem;
    color: #e9b213
}

.modal-action-text{
    color: #b3b3b3;
    font-size: 0.9rem;
}

.modal .button{
    width: 100%;
}

@keyframes toast-einblenden{
    0%{
        opacity: 0;
        transform: scale(0);
    }
    20%{
        opacity: 1;
        transform: scale(1);
    }
    80%{
        opacity: 1;
        transform: scale(1);
    }
    100%{
        opacity: 0;
        transform: scale(0);
    }
}

.toast-wrapper{
    text-align: center;
    animation: 3s toast-einblenden forwards;
    position: fixed;
    bottom: 8rem;
    width: 100%;
    z-index: 6;
}

.toast{
    background-color: #4C4C4C;
    border-radius: 0.25rem;
    padding: 0.5rem;
}

/* ------------------------------ Kontextmenü -------------------------------*/

.kontextmenue-komponente{
    display: none;
    position: fixed;
    z-index: 8;
    top: 0;
    left: 0;
    width: 100%;
}

#kontextmenue-checkbox:checked ~ .kontextmenue-komponente{
    display: block;
}

.kontextmenue-wrapper{
    min-width: 15rem;
    display: inherit;
    position: absolute;
    top: 4rem;
    right: 1rem;
    background-color: #262626;
    z-index: 9;
    border-radius: 0.75rem;
}

.kontextmenu-schliessen{
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    background-color: rgba(20,20,20,0.8);
    backdrop-filter: blur(10px);
}

.kontextmenu-schliessen img{
    position: absolute;
    top: 1rem;
    right: 1rem;
}

.kontextmenue-item{
    padding: 1rem;
    text-decoration: none;
}

.kontextmenue-item:nth-child(n+2){
    border-top: 1px solid #838383
}

/* -------------------- Media Queries ------------------ */

@supports (-webkit-fill-available: 100%) {
    html, body {
        height: -webkit-fill-available;
    }
}

@supports (-webkit-touch-callout: none) {
    @media (display-mode: standalone) {
        html, body, body::before {
            height: 100dvh;
        }
    }
}
