.itemgridfilterwrapper {
	display: flex;
}

.itemgridfilterwrapper > .filtercontainer {
	min-width: 20%;
	min-height: calc(100% - 250px);
	display: block;
	background-color: var(--main-elements-background-color);
	box-shadow: var(--box-shadow);
	padding: 1em;
	margin-right: 1em;
}

.itemgridfilterwrapper .filterswiper {
	display: none;
	float: left;
	margin-right: 2em;
}

.itemgridfilterwrapper .productgrid {
	width: 100%;
}

.productgrid > .listhead {
	color: var(--main-body-text-color);
	margin-bottom: .5em;
	display: flex;
}

.productgrid > .listhead > .sortby > * {
	margin-right: .5em;
}

.productgrid > .listhead > .pagination {
	flex-grow: 2;
	text-align: right;
	justify-content: end;
}

/*#region Item*/
.itemgrid .itemwrapper {
	height: 100%;
	display: flex;
	flex-direction: column;
	background-color: var(--main-elements-background-color);
	box-shadow: var(--box-shadow);
}

.itemgrid .itemwrapper:hover {
	outline: 1px solid var(--main-link-color);
}

.itemgrid .itemwrapper > .image {
	order: 2
}


.itemgrid .itemwrapper > .info {
	order: 3;
	position: static;
	display: flex;
	flex-direction: column;
	flex: 1;
	padding: .5em;
}

.itemgrid .itemwrapper > .info:hover {
	cursor: pointer;
}

.itemgrid .itemwrapper > .info > *:not(:empty):not(:last-child) {
	margin-bottom: .3em;
	overflow-wrap: break-word;
}

.itemgrid .itemwrapper > .info :is(a:hover,a:focus) {
	color: var(--secondary-text-color);
	background-color: var(--main-link-color);
}

.itemgrid .itemwrapper > .info :is(a:hover,a:focus) svg.icon {
	fill: var(--secondary-text-color);
}

.itemgrid .itemwrapper > .info a {
	color: var(--main-text-color);
	fill: var(--main-text-color);
	background-color: var(--main-elements-background-color);
}

.itemgrid .itemwrapper > .info .stock-text {
	display: none;
}

.itemgrid .itemwrapper > .info .name {
	flex: 1;
	border: none;
	order: 0;
}

.itemgrid .itemwrapper > .info table.specs {
	/* order: 1; */
	width: calc(100% - .5em);
}

.itemgrid .itemwrapper > .info > .priceblock > .quantity-picker {
	display: flex;
	justify-content: end;
	margin: .5rem 0 0 0;
	padding: 0;
	order: -1;
	flex-basis: 100%;
	width: 100%;
}

.itemgrid .itemwrapper > .info > .priceblock > .quantity-picker > label.qNumber {
	width: 50%;
	max-width: -moz-available;
}

@media screen and (max-width: 768px) {
	.itemgrid .itemwrapper > .info > .priceblock > .quantity-picker > label.qNumber {
		width: 80%;
	}
}

.itemgrid .itemwrapper > .info > .priceblock > .quantity-picker > label.qNumber > button {
	/* background-color: gray; */
}

.itemgrid .itemwrapper > .info > .priceblock > .quantity-picker > label.qNumber > input.quantity {
	width: 100%;
	max-width: unset;
}

.itemgrid .itemwrapper > .info table.specs tbody,
.itemgrid .itemwrapper > .info table.specs tbody > tr {
	display: block;
}

.itemgrid .itemwrapper > .info table.specs tbody > tr :is(th,td) {
	display: contents;
	background-color: inherit;
	padding: 0;
	line-height: inherit;
}

.itemgrid .itemwrapper > .info table.specs tbody > tr > th {
	display: inline;
	font-weight: bold;
	padding-right: .5em;
}

.itemgrid .itemwrapper > .info div.itemcode > span {
	color: var(--table-header-background-color);
	background-color: var(--table-header-text-color);
	font-size: .8em;
	padding: .2em .5em;
	display: inline-block;
	border-radius: .3em;
	margin-bottom: .5em;
}

.itemgrid .itemwrapper > .info div.priceblock {
	display: flex;
	align-items: center;
	order: 2;
	flex-flow: wrap;
	justify-content: end;
}

.itemgrid .itemwrapper > .info div.priceblock > * {
	vertical-align: middle;
}

.itemgrid .itemwrapper > .info div.priceblock i {
	font-size: 1.75rem;
}

.itemgrid .itemwrapper > .info div.priceblock div.price {
	display: flex;
	overflow: hidden;
	flex-wrap: wrap;
	flex-direction: column;
	flex-grow: 1;
	margin-right: .5em;
}

@media screen and (max-width: 768px) {
	.itemgrid .itemwrapper > .info div.priceblock div.price {
		width: 100%;
	}
}

.itemgrid .itemwrapper > .info div.priceblock a .modelspecquantity {
	width: 1.2em;
	height: 1.2em;
	color: var(--main-elements-background-color);
	background-color: var(--main-text-color);
	text-align: center;
	line-height: .9em;
	border-radius: 50%;
	position: absolute;
	float: left;
	margin-left: 2em;
	margin-top: -1.5em;
	padding: .1em;
}

.itemgrid .itemwrapper > .info div.priceblock .itemrecomendedquantity {
	display: none;
}

.itemgrid .itemwrapper > .info div.priceblock a.primary {
	padding: 1.1em .5em;
	margin-left: .5em;
	border: 0;
	width: 40px;
}

.itemgrid .itemwrapper > .info div.priceblock .message {
	width: 100%;
}

.itemgrid .itemwrapper > .info div.priceblock a.primary span:first-of-type {
	display: none;
}

.itemgrid .itemwrapper > .info div.priceblock a:hover .modelspecquantity {
	color: var(--main-link-color);
	background-color: var(--secondary-text-color);
}

.itemgrid .itemwrapper > .info div.priceblock .itemrecomendedquantity {
	display: none;
}

/* Never show click to collect in itemgrid */
.itemgrid .itemwrapper > .info div.priceblock a.clickCollect {
	display: none;
}


/*#endregion*/

/*#region Entity layout*/
.itemgrid.entitylayout .itemwrapper > .info div.priceblock {
	text-align: right;
}

/*#endregion*/

/*#region focusitemgrid*/
.focusitemgrid.componentwrapper {
	margin-bottom: 0;
}

.focusitemgrid .productgrid .listfoot {
	display: none;
}

/*#endregion*/

/*#region Filter column */
.filtercontainer .modellfilter .modelSearchHistory > ol > li:nth-of-type(n+6),
.filtercontainer .modellfilter .modelSearchHistory.removefirst > ol > li:first-of-type {
	display: none;
}

.filtercontainer label.qRange {
	margin-left: -.5em;
	width: calc(100% - 0em);
	height: 4em;
}

.filtercontainer .filtergroup {
	margin-bottom: 20px;
	max-width: 300px;
}

.filtercontainer li.filtergroup span {
	color: var(--main-body-text-color);
}

.itemgridfilterwrapper .filtercontainer :is(a.toggleFilters,a.applyfilter) {
	display: none;
}

/*#endregion*/


@media screen and (max-width: 768px) {
	/* Adjust the grid so big names get cut */
	.productgrid .qGrid1 > * {
		max-width: calc(100% - 1em);
	}
	
	.productgrid .qGrid2 > * {
		max-width: calc(50% - 1em);
	}
	
	.productgrid .qGrid3 > * {
		max-width: calc(33.3% - 1em);
	}
	
	.productgrid .qGrid4 > * {
		max-width: calc(25% - 1em);
	}
	
	.productgrid .qGrid5 > * {
		max-width: calc(20% - 1em);
	}
	
	
}


@media screen and (max-width: 480px) {
	.productgrid {
		margin: 0;
	}
	
	.productgrid .listhead {
		flex-wrap: wrap;
	}
	
	.productgrid .listhead,
	.productgrid .listfoot {
		padding: .5em;
		margin: 0;
	}
	
	.productgrid .listhead > * {
		vertical-align: middle;
		flex-grow: 1;
	}
	
	.productgrid .listhead > *:not(:first-of-type) {
		text-align: right;
	}
	
	.itemgrid.qGridMobile1 > li {
		flex-basis: calc(100% - 1em);
		max-width: calc(100% - 1em);
	}
	
	.itemgrid.qGridMobile2 > li {
		flex-basis: calc(50% - 1em);
		max-width: calc(50% - 1em);
	}
	
	.itemgridfilterwrapper .filterswiper,
	.itemgridfilterwrapper .filtercontainer a.applyfilter {
		display: block;
	}
	
	.itemgridfilterwrapper .filtercontainer {
		padding: .5em;
		display: block;
		position: fixed;
		overflow: auto;
		height: 100%;
		width: 60%;
		top: 0;
		left: -65%;
		z-index: 9999;
		background-color: var(--main-elements-background-color);
		border-right: 1px solid var(--detaillist-list-border-color);
	}
	
	.itemgridfilterwrapper .filtercontainer > a.toggleFilters {
		display: block;
		position: absolute;
		right: .5em;
		top: .5em;
		font-size: 1.5em;
		z-index: 1;
	}
	
	.productgrid > .listhead > .pagination {
		position: relative;
		top: -1.4em;
		justify-content: end;
	}
	
	.productgrid > .listhead > .pagination b.count {
		margin: 0 .3em;
	}
	
	div.listhead.filter.fixed {
		position: fixed;
		top: 0;
		z-index: 8;
		background-color: var(--main-elements-background-color);
		box-shadow: var(--box-shadow);
		height: 3em;
	}
	
}

body:not(.designPlus) .productgrid .itemBuyButton:has(.purchaseQuantityPerSale) {
	position: relative;
}
body:not(.designPlus) .productgrid .itemBuyButton .purchaseQuantityPerSale {
	position: absolute;
	left: 0;
	background: var(--header-icons-text-color);
	padding: 0 .5em;
	color: var(--header-icons-text-hover-color);
	top: 0;
	border-radius: 1em;
	font-size: x-small;
}

body:not(.designPlus) a.toggleFilters {
	position: relative;
	z-index: 1000;
}
