/* Crate builder: beer rows with − / + pills, then a bar that stays at the bottom of the screen (slots, total, button). */
.retorto-crate__list {
	list-style: none;
	margin: 0;
	padding: 0;
}

.retorto-crate__item {
	display: grid;
	grid-template-columns: 3.5rem minmax(0, 1fr) auto auto;
	align-items: center;
	gap: 1rem;
	padding: .65rem 0;
	border-bottom: 1px solid rgba(29, 29, 27, .1);
}

.retorto-crate__item:first-child {
	border-top: 1px solid rgba(29, 29, 27, .1);
}

.retorto-crate__thumb img {
	display: block;
	width: 3.5rem;
	height: 3.5rem;
	object-fit: cover;
}

.retorto-crate__name {
	display: flex;
	flex-direction: column;
	gap: .1rem;
	font-weight: 600;
	line-height: 1.3;
}

.retorto-crate__name small {
	font-size: .8125rem;
	font-weight: 400;
	opacity: .7;
}

.retorto-crate__price {
	display: flex;
	flex-direction: column;
	align-items: flex-end;
	line-height: 1.25;
	white-space: nowrap;
}

.retorto-crate__price del {
	font-size: .8125rem;
	opacity: .55;
}

.retorto-crate__price ins {
	text-decoration: none;
	font-weight: 700;
}

.retorto-crate__qty {
	display: inline-flex;
	align-items: center;
	height: 2.5rem;
	padding: 0 .25rem;
	background: #fff;
	border-radius: 999px;
}

.retorto-crate__item.is-picked .retorto-crate__qty {
	box-shadow: inset 0 0 0 1.5px #1D1D1B;
}

/* Specific enough to beat the kit's global button styles (.elementor-kit-N button). */
form.retorto-crate button.retorto-crate__step {
	width: 2rem;
	height: 2rem;
	min-width: 0;
	padding: 0;
	font-size: 1.1rem;
	line-height: 1;
	letter-spacing: 0;
	color: #1D1D1B;
	background: transparent;
	border: 0;
	border-radius: 50%;
	cursor: pointer;
}

form.retorto-crate button.retorto-crate__step:hover:not(:disabled) {
	background: rgba(29, 29, 27, .07);
}

form.retorto-crate button.retorto-crate__step:disabled {
	opacity: .25;
	cursor: not-allowed;
}

.woocommerce form.retorto-crate .retorto-crate__qty input[type="number"] {
	width: 2rem;
	min-height: 0;
	margin: 0;
	padding: 0;
	font-weight: 700;
	text-align: center;
	color: #1D1D1B;
	background: transparent;
	border: 0;
	box-shadow: none;
	-moz-appearance: textfield;
}

.retorto-crate__qty input::-webkit-outer-spin-button,
.retorto-crate__qty input::-webkit-inner-spin-button {
	-webkit-appearance: none;
	margin: 0;
}

.retorto-crate__barra {
	position: sticky;
	bottom: 0;
	z-index: 5;
	display: flex;
	flex-direction: column;
	gap: .75rem;
	padding: 1.25rem 0 1.5rem;
	background: var(--retorto-colore, #F5F4F1);
}

.retorto-crate__slot {
	display: flex;
	gap: 4px;
}

.retorto-crate__slot span {
	flex: 1;
	height: 6px;
	border-radius: 3px;
	background: rgba(29, 29, 27, .14);
	transition: background .2s;
}

.retorto-crate__slot span.is-piena {
	background: #1D1D1B;
}

.retorto-crate__summary {
	display: flex;
	justify-content: space-between;
	align-items: baseline;
	gap: 1rem;
}

.retorto-crate__count {
	font-size: .9375rem;
}

.retorto-crate__mancano {
	opacity: .7;
}

.retorto-crate__total {
	font-size: 1.5rem;
	font-weight: 700;
}

.woocommerce div.product form.retorto-crate .single_add_to_cart_button {
	width: 100%;
	height: 3.25rem;
	float: none;
}

/* WooCommerce paints disabled .alt buttons purple: keep ours black, just faded. */
.woocommerce div.product form.retorto-crate .single_add_to_cart_button:disabled,
.woocommerce div.product form.retorto-crate .single_add_to_cart_button:disabled:hover {
	color: #fff;
	background: #1D1D1B;
	opacity: .35;
	cursor: not-allowed;
}

@media (max-width: 480px) {
	.retorto-crate__item {
		grid-template-columns: 3rem minmax(0, 1fr) auto;
		grid-template-areas: "thumb name name" "thumb price qty";
		row-gap: .4rem;
	}
	.retorto-crate__thumb { grid-area: thumb; align-self: start; }
	.retorto-crate__name { grid-area: name; }
	.retorto-crate__price { grid-area: price; flex-direction: row; gap: .5rem; align-items: baseline; justify-self: start; }
	.retorto-crate__qty { grid-area: qty; }
	.retorto-crate__thumb img { width: 3rem; height: 3rem; }
}
