/* Cus Tabelle Prodotti (Sabianlab) */

.cus-tab {
	--cus-testo: #174372;
	--cus-blu: #0066af;
	--cus-rosso: #b40923;
	--cus-grigio: #f6f6f6;
	--cus-bordo: #dfe5ec;
	--cus-evid: #eaf2fa;
	--cus-alt: #fafbfc;
	--cus-hover: #fdf0f2;
	--cus-etichetta: #5b7594;
	font-family: Arial, Helvetica, sans-serif;
	color: var(--cus-testo);
	font-size: 13px;
	line-height: 1.4;
	margin: 24px 0 40px;
	text-align: left;
}

.cus-tab *,
.cus-tab *::before,
.cus-tab *::after {
	box-sizing: border-box;
}

.cus-tab .sr {
	position: absolute;
	width: 1px;
	height: 1px;
	overflow: hidden;
	clip: rect(0 0 0 0);
	white-space: nowrap;
}

/* Filtri */

.cus-tab__filtri {
	display: flex;
	flex-wrap: wrap;
	align-items: flex-end;
	gap: 12px 16px;
	padding: 16px;
	margin: 0 0 12px;
	background: var(--cus-grigio);
	border-top: 3px solid var(--cus-blu);
}

.cus-tab__filtro {
	display: flex;
	flex-direction: column;
	gap: 5px;
	min-width: 160px;
	margin: 0;
	font-size: 12px;
	font-weight: bold;
	letter-spacing: .03em;
	text-transform: uppercase;
	color: var(--cus-testo);
}

.cus-tab__filtro select {
	height: 38px;
	width: 100%;
	margin: 0;
	padding: 0 34px 0 10px;
	border: 1px solid var(--cus-blu);
	border-radius: 0;
	background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%230066af' stroke-width='2'/%3E%3C/svg%3E") no-repeat right 12px center;
	color: var(--cus-testo);
	font: normal 15px Arial, Helvetica, sans-serif;
	letter-spacing: 0;
	text-transform: none;
	-webkit-appearance: none;
	appearance: none;
	cursor: pointer;
}

.cus-tab__filtro select:focus-visible,
.cus-tab__azzera:focus-visible,
.cus-tab__scorri:focus-visible,
.cus-tab .c-apri button:focus-visible {
	outline: 2px solid var(--cus-rosso);
	outline-offset: 2px;
}

.cus-tab__info {
	display: flex;
	align-items: center;
	gap: 16px;
	margin-left: auto;
	min-height: 38px;
}

.cus-tab__conteggio {
	margin: 0;
	padding: 0;
	font-family: "Roboto Slab", Arial, Helvetica, sans-serif;
	font-size: 15px;
}

.cus-tab__azzera {
	padding: 0;
	border: 0;
	background: none;
	color: var(--cus-rosso);
	font: inherit;
	font-size: 14px;
	text-decoration: underline;
	cursor: pointer;
}

.cus-tab__vuoto {
	margin: 0;
	padding: 24px 16px;
	border: 1px solid var(--cus-bordo);
	text-align: center;
	font-size: 15px;
}

/* Tabella (computer) */

.cus-tab__scorri {
	max-height: 75vh;
	overflow: auto;
	border: 1px solid var(--cus-bordo);
	-webkit-overflow-scrolling: touch;
}

.cus-tab--accessori .cus-tab__scorri {
	max-height: none;
}

.cus-tab--semplice {
	max-width: 760px;
}

.cus-tab table {
	width: 100%;
	margin: 0;
	border: 0;
	border-collapse: separate;
	border-spacing: 0;
	font-variant-numeric: tabular-nums;
}

.cus-tab table th,
.cus-tab table td {
	padding: 6px 5px;
	border: 0;
	border-right: 1px solid var(--cus-bordo);
	border-bottom: 1px solid var(--cus-bordo);
	background: #fff;
	color: var(--cus-testo);
	font-family: Arial, Helvetica, sans-serif;
	font-size: 13px;
	font-weight: normal;
	letter-spacing: 0;
	line-height: 1.35;
	text-align: center;
	text-transform: none;
	vertical-align: middle;
	white-space: nowrap;
}

.cus-tab--cilindri table th,
.cus-tab--cilindri table td {
	padding-left: 4px;
	padding-right: 4px;
}

.cus-tab--accessori table th,
.cus-tab--accessori table td {
	padding: 8px 10px;
	font-size: 14px;
}

.cus-tab thead {
	position: sticky;
	top: 0;
	z-index: 3;
}

.cus-tab table thead th {
	background: #174372;
	color: #fff;
	font-size: 12px;
	border-right-color: rgba(255, 255, 255, .18);
	border-bottom-color: rgba(255, 255, 255, .18);
}

.cus-tab--accessori table thead th {
	font-size: 13px;
}

.cus-tab table thead tr.cus-tab__sotto th {
	background: #e3ecf6;
	color: var(--cus-testo);
	font-weight: bold;
	border-right-color: var(--cus-bordo);
	border-bottom-color: #c9d6e4;
}

.cus-tab table thead th.a-capo {
	white-space: normal;
	min-width: 56px;
	max-width: 76px;
}

.cus-tab table tbody th {
	font-weight: bold;
	text-align: left;
	padding-left: 8px;
	padding-right: 8px;
}

.cus-tab table .c-des {
	text-align: left;
}

.cus-tab--cilindri table .c-des {
	text-align: center;
}

/* codice sempre visibile scorrendo in orizzontale */
.cus-tab table .c-cod {
	position: sticky;
	left: 0;
	z-index: 1;
	border-right: 0;
	box-shadow: 1px 0 0 var(--cus-bordo);
}

.cus-tab table thead .c-cod {
	z-index: 4;
	text-align: left;
}

.cus-tab tbody tr.alt > *,
.cus-tab--accessori tbody tr:nth-child(even) > * {
	background: var(--cus-alt);
}

.cus-tab tbody .evid,
.cus-tab tbody tr.alt > .evid {
	background: var(--cus-evid);
}

.cus-tab tbody tr:hover > * {
	background: var(--cus-hover);
}

.cus-tab .pallino {
	display: inline-block;
	width: 9px;
	height: 9px;
	border-radius: 50%;
	background: var(--cus-blu);
	vertical-align: middle;
}

.cus-tab table .c-diam {
	min-width: 27px;
	padding-left: 3px;
	padding-right: 3px;
}

.cus-tab .solo-mobile {
	display: none;
}

.cus-tab tbody tr[hidden] {
	display: none !important;
}

/* Cellulare */

@media (max-width: 760px) {

	.cus-tab__filtri {
		display: grid;
		grid-template-columns: 1fr 1fr;
		padding: 12px;
	}

	.cus-tab__filtro {
		min-width: 0;
	}

	.cus-tab__filtro:first-child {
		grid-column: 1 / -1;
	}

	.cus-tab__info {
		grid-column: 1 / -1;
		justify-content: space-between;
		margin: 0;
		min-height: 0;
	}

	.cus-tab--semplice table th,
	.cus-tab--semplice table td {
		white-space: normal;
	}

	/* schede: una per riga */

	.cus-tab--schede .cus-tab__scorri {
		max-height: none;
		overflow: visible;
		border: 0;
	}

	.cus-tab--schede table,
	.cus-tab--schede tbody {
		display: block;
		width: 100%;
	}

	.cus-tab--schede thead {
		display: none;
	}

	.cus-tab--schede tbody tr {
		display: grid;
		grid-template-columns: repeat(12, 1fr);
		gap: 10px 8px;
		margin: 0 0 10px;
		padding: 14px 14px 12px;
		border: 1px solid var(--cus-bordo);
		border-left: 4px solid var(--cus-blu);
		background: #fff;
	}

	.cus-tab--schede table tbody tr > * {
		display: block;
		position: static;
		padding: 0;
		border: 0;
		box-shadow: none;
		background: none;
		text-align: left;
		white-space: normal;
		font-size: 15px;
	}

	.cus-tab--schede table tbody tr.alt > *,
	.cus-tab--schede table tbody tr:hover > *,
	.cus-tab--schede table tbody tr:nth-child(even) > *,
	.cus-tab--schede table tbody tr > .evid,
	.cus-tab--schede table tbody tr.alt > .evid {
		background: none;
	}

	.cus-tab--schede tbody td[data-label]::before {
		content: attr(data-label);
		display: block;
		margin-bottom: 2px;
		font-size: 11px;
		font-weight: bold;
		letter-spacing: .03em;
		text-transform: uppercase;
		color: var(--cus-etichetta);
	}

	.cus-tab--schede table tbody .c-cod {
		position: static;
		grid-column: span 7;
		order: 1;
		font-size: 17px;
		font-weight: bold;
		box-shadow: none;
	}

	.cus-tab--schede tbody .c-des {
		grid-column: span 5;
		order: 2;
		text-align: right;
		color: var(--cus-etichetta);
	}

	.cus-tab--cilindri tbody .c-des::before {
		display: none;
	}

	/* accessori: codice, poi descrizione, poi le misure tre per riga */

	.cus-tab--accessori.cus-tab--schede table tbody .c-cod {
		grid-column: 1 / -1;
	}

	.cus-tab--accessori.cus-tab--schede tbody .c-des {
		grid-column: 1 / -1;
		text-align: left;
		color: var(--cus-testo);
	}

	.cus-tab--accessori.cus-tab--schede tbody .c-val {
		grid-column: span 4;
		order: 3;
	}

	/* cilindri */

	.cus-tab--cilindri tbody .c-corsa,
	.cus-tab--cilindri tbody .c-sfil,
	.cus-tab--cilindri tbody .c-port {
		display: flex;
		flex-direction: column;
		justify-content: space-between;
		grid-column: span 4;
		order: 3;
		font-weight: bold;
	}

	.cus-tab--cilindri tbody .c-diam {
		display: none;
	}

	.cus-tab--cilindri tbody .c-diamlista {
		display: block;
		grid-column: 1 / -1;
		order: 6;
	}

	.cus-tab--cilindri tbody .c-apri {
		display: block;
		grid-column: 1 / -1;
		order: 7;
	}

	.cus-tab .c-apri button {
		width: 100%;
		margin: 2px 0 0;
		padding: 9px 12px;
		border: 1px solid var(--cus-blu);
		border-radius: 0;
		background: #fff;
		color: var(--cus-blu);
		font: bold 14px Arial, Helvetica, sans-serif;
		text-align: left;
		text-transform: none;
		cursor: pointer;
	}

	.cus-tab .c-apri button::after {
		content: "+";
		float: right;
		font-size: 18px;
		line-height: 1;
	}

	.cus-tab tr.aperta .c-apri button::after {
		content: "\2212";
	}

	.cus-tab--cilindri tbody .c-dim,
	.cus-tab--cilindri tbody .c-peso,
	.cus-tab--cilindri tbody .c-olio {
		display: none;
		grid-column: span 3;
		order: 8;
	}

	.cus-tab--cilindri tbody tr.aperta .c-dim,
	.cus-tab--cilindri tbody tr.aperta .c-peso,
	.cus-tab--cilindri tbody tr.aperta .c-olio {
		display: block;
	}

	.cus-tab--cilindri tbody tr.aperta .c-peso,
	.cus-tab--cilindri tbody tr.aperta .c-olio {
		grid-column: span 6;
		order: 9;
	}
}
