html {
	height:100%;
}
body {
	height:100%;
	margin:0;
	font-family: sans-serif;
    min-width: 400px;
    display: flex;
    flex-direction: column;
    align-items: center;
}
div.buttongroup {
    display: flex;
    flex-direction: column;
    max-width: 500px;
    margin: 0 auto;
    padding-top: 50px;
}
div#locationbuttons {
    padding-top:0;
    width:100%;
}
span.shortloc {
    font-weight: bold;
}
button.location {
    margin: 5px;
    height: 70px;
    font-size:x-large;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding-left: revert;
}
button.category {
    margin: 5px;
    height: 54px;
    font-size:x-large;
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: flex-start;
    padding-left:0;
}
button > span.longloc {
	font-size:small;
    text-wrap-mode: nowrap;
}
content {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding-top: 50px;
}
table {
    margin-bottom: 20px;
}
table#bestand, table#andere {
	width: 99%;
}
table, tr, td {
	border-collapse:collapse;
	border-top: 1px solid grey;
	border-bottom: 1px solid grey;
}
td.plusbutton, td.minusbutton, td.count, td.center {
	text-align:center;
}
tr.textfiltered {
    display: none;
}
span.count {
	font-size:x-large;
	font-weight:bold;
}
button.plusbutton, button.minusbutton {
    font-size: xx-large;
    width: 1.5em;
    margin: 4px;
}
button.backbutton {
    display: flex;
    align-items: center;
    height: 35px;
}
.empty {
	color:red;
}
.low {
	color:orange;
}
div#fulltablecontainer {
	display: none;
    justify-content: center;
}
table#fulltable td.low { background-color:orange; color:black;}
table#fulltable td.empty { background-color:red; color:black;}

.small {
	font-size:small;
}
.navi {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size:x-large;
    font-weight: bold;
    padding: 5px;
    border-bottom:3px solid black;
    /* make it sticky */
    position: fixed;
    left: 0;
    right: 0;
}
span[class^="type-"] {
    border: 1px solid black;
    border-radius: 4px;
    padding: 2px 4px;
    font-family: monospace;
    font-weight:bold;
    color:black;
    }
span.type-singlemode	{ background-color: yellow;		}
span.type-multimode	{ background-color: aqua;		}
span.type-upc		{ background-color: #2c5a92db; color:white; }
span.type-apc		{ background-color: #29a71b;		}
span.type-sc		{ background-color: #ccc;		}
span.type-ACU		{ background-color: lightskyblue;		}
span.type-DAC		{ background-color: black; color:white;		}
span.type-05m 		{ background-color: hsl(  0 100% 75%);	}
span.type-1m 		{ background-color: hsl( 40 100% 75%);	}
span.type-2m 		{ background-color: hsl( 80 100% 75%);	}
span.type-3m 		{ background-color: hsl(120 100% 75%);	}
span.type-5m 		{ background-color: hsl(160 100% 75%);	}
span.type-7m 		{ background-color: hsl(200 100% 75%);	}
span.type-10m 		{ background-color: hsl(240 100% 75%);	}
span.type-15m 		{ background-color: hsl(280 100% 75%);	}
span.type-20m 		{ background-color: hsl(320 100% 75%);	}
span.type-300m 		{ background-color: hsl(  0 100% 75%);	}
span.type-10km 		{ background-color: hsl( 50 100% 75%);	}
span.type-10-20km 		{ background-color: hsl( 50 100% 75%);	}
span.type-20km 		{ background-color: hsl(100 100% 75%);	}
span.type-30km 		{ background-color: hsl(150 100% 75%);	}
span.type-40km 		{ background-color: hsl(200 100% 75%);	}
span.type-80km 		{ background-color: hsl(250 100% 75%);	}
span.type-120km 	{ background-color: hsl(300 100% 75%);	}

table#fulltable tr, table#fulltable th, table#fulltable td {
	border: 1px solid black;
}
table#fulltable tr:hover > td{
	background-color:dodgerblue !important;
}
table#fulltable th {
  position: sticky;
  top: -1px;  /* to hide blank border-top */
  background: black;
  color:white;
  border:1px solid white;
  height:30px;
}
table#fulltable td.heading {
  position: sticky;
  top: 31px;  /* 0px if you don't have a navbar, but something is required */
}
table#fulltable td.subheading {
  position: sticky;
  top: 51px;  /* 0px if you don't have a navbar, but something is required */
  background:#333;
  color:white;
}
input.num-ist, input.num-soll { text-align:right; }
td.odd {
	background-color:#ccc;
}
td.counts, td.count {
    padding: 0 5px;
}
img.catimg {
    height: 50px;
    width: 50px;
    margin-right:10px;
    background: white;
}
button.category:hover {
    text-decoration: underline;
    cursor: pointer;
}

/* changes for desktop layout */

@media (min-width: 900px) {
	div#locationbuttons {
 	   display: flex;
    	flex-direction: row;
	justify-content: center;

	}
	div#fulltablecontainer {
		display:flex;
		align-items:center;
		flex-direction:column;
	}
	table#bestand, table#andere {
		width: auto;
        min-width: 500px;
	}
    div.buttongroup {
        flex-direction: row;
        flex-wrap: wrap;
        justify-content: center;
        max-width: unset;
    }
    button.category {
        height: 340px;
        width: 300px;
        overflow: hidden;
        justify-content: space-evenly;
        flex-direction: column;
        padding-left: revert;
    }
    img.catimg {
        display:block;
        width: 250px;
        height: 250px;
        background-color: white;
        box-shadow: 0 0 5px black;
        margin-right: 0;
    }
}

@-moz-document url-prefix() {

    div.lastaction-loc {
        padding-top: 4px;
    }
    span.lastaction.desc {
        padding: 2px 4px 0px 4px !important;
    }
}


td.heading {
	font-weight:bold;
}
#showmissing {
	margin-bottom:15px;
}
td.count > select {
    height: 40px;
    width: 150px;
    margin: 5px 0;
    font-size: x-large;
}
.type-cwdm1270 {
background-color: plum;
}

.type-cwdm1290 {
background-color: lightskyblue;
}

.type-cwdm1310 {
background-color: palegreen;
}

.type-cwdm1330 {
background-color: yellowgreen;
}

.type-cwdm1350 {
background-color: fuchsia;
}

.type-cwdm1370 {
background-color: khaki;
}

.type-cwdm1390 {
background-color: white;
}

.type-cwdm1410 {
background-color: gainsboro;
}

.type-cwdm1430 {
background-color: black;
color: white !important;
}

.type-cwdm1450 {
background-color: yellow;
}

.type-cwdm1470 {
background-color: gray;
}

.type-cwdm1490 {
background-color: blueviolet;
}

.type-cwdm1510 {
background-color: dodgerblue;
}

.type-cwdm1530 {
background-color: limegreen;
}

.type-cwdm1550 {
background-color: lemonchiffon;
}

.type-cwdm1570 {
background-color: darkorange;
}

.type-cwdm1590 {
background-color: red;
}

.type-cwdm1610 {
background-color: sienna;
}

td.itemimage {
    text-align: center;
}
img.itemimage {
    max-height: 50px;
    max-width: 50px;
    cursor:pointer;
}
img.itemimage.enlarged {
    height:256px;
    width:256px;
}
/* popup when hovering over items in overview table */
#imgpopup {
    position: fixed;
    z-index: 5;
    background:white;
    border: 2px solid black;
    display:none;
    height:256px;
}
/* popup when clicking image in inventory list */
div#imgcenterbox {
    background-image: url("");
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-position: center;
    background-repeat: no-repeat;
    backdrop-filter: brightness(0.5) blur(3px);
    display: none;
}

/* subcategory headers */
.header {
    background: #555;
    color: #ddd;
    border-top: 20px solid white;
    text-align: center;
    width:100%;
    height: 2.4em;
}
.item {
    background: linear-gradient(90deg, #fff 0%, #bbb 100%);
}
h3 {
    font-size: x-large;
    margin: 15px 0 0 0;
}

td.itemname {
    font-weight: bold;
    line-height: 1.4em;
    padding-left: 6px;
}
span.itemdesc {
    font-size: 0.9em;
    font-weight: normal;
}

/* DIV LAYOUT */
div.header {
    background: #555;
    color: white;
    border-top: 20px solid white;
    width: 100%;
    padding: 4px 0;
    display: flex;
    justify-content: center;
    font-weight: bold;
}
div.itemname {
    flex-grow: 1;
}
div#bestand {
    display: flex;
    flex-direction: column;
}
div.item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-top: 1px solid #666;
}
#image_enlarged {

    background-color: white;
    border: 2px solid black;
    max-width: 90%;
    min-width: 400px;
    max-height: 90%; 
    /* top: 0; */
    /* left: 0; */
    /* right: 0; */
    /* bottom: 0; */
    /* margin: auto; */
    backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    justify-content: center;
}
div#popupcontainer {
    top: 0;
    bottom: 0;
    left: 0;
    right: 0;
    position: fixed;
    backdrop-filter: blur(2px) brightness(0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    max-height: 100vh;
    display: none;
}
#main_heading {
    text-align: center;
    display: flex;
    align-items: center;
}
#header-img {
    height: 60px;
}
div#lastactionscontainer {
    display: flex;
    flex-direction: column;
    width: fit-content;
    margin: 0 auto;
    align-items: flex-start;
}
div.lastaction {
    display: flex;
    margin: 2px;
    flex-direction: row;
    border-radius: 6px;
    padding: 4px;
    width: 100%;
    overflow: hidden;
}
div.lastaction-rowcontainer {
    display: flex;
    flex-direction: column;
}
div.lastaction.action-ADD {
    background-color: #00800060;
}
div.lastaction.action-REMOVE {
    background-color: #80000060;
}
div.lastaction.action-SETCOUNT {
    background-color: #00178060;
}
div.lastaction-time {
    color:hsl(0, 0%, 40%);
    font-size: 0.7em;
    margin-top: 2px;
}
div.lastaction-loc {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 76px;
    font-weight: bold;
    font-size: 1.4em;
    color: #ffffffaa;
    backdrop-filter: brightness(0.5);
    margin: -5px 4px -5px -5px;
}
span.lastaction.desc, span.lastaction.loc {
    background-color: #333;
    color:white;
    padding: 2px 4px;
    border-radius: 4px;
    font-size: smaller;
}
span.lastaction.amount {
    font-weight: bold;
}