/* The Paving Vault – Pallet Pricing */

.tpv-buy,
.tpv-samples {
	--tpv-border: #e2e2e2;
	--tpv-ink: #111;
	--tpv-muted: #666;
	--tpv-soft: #f7f7f5;
	--tpv-green-bg: #e7f3e9;
	--tpv-green: #1f5f2e;
	--tpv-amber-bg: #fcf0e1;
	--tpv-amber: #8a4b08;
}

.tpv-buy [hidden],
.tpv-samples [hidden] {
	display: none !important;
}

/* Product page purchase box */

.tpv-buy {
	display: grid;
	gap: 14px;
	margin: 18px 0;
	color: var(--tpv-ink);
	font-size: 15px;
	line-height: 1.45;
}

.tpv-banner {
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 11px 14px;
	background: var(--tpv-ink);
	color: #fff;
	font-size: 13px;
	font-weight: 700;
	letter-spacing: 0.05em;
	text-transform: uppercase;
}

.tpv-banner svg {
	flex: none;
}

.tpv-facts {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	margin: 0;
	border: 1px solid var(--tpv-border);
}

.tpv-facts > div {
	padding: 10px 12px;
	border-left: 1px solid var(--tpv-border);
}

.tpv-facts > div:first-child {
	border-left: 0;
}

.tpv-facts dt {
	margin: 0;
	color: var(--tpv-muted);
	font-size: 12px;
	font-weight: 400;
}

.tpv-facts dd {
	margin: 2px 0 0;
	font-size: 17px;
	font-weight: 700;
}

.tpv-buy form.cart.tpv-option {
	display: grid !important;
	gap: 12px;
	margin: 0 !important;
	padding: 16px;
	border: 1px solid var(--tpv-border);
}

.tpv-option__head {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 8px;
}

.tpv-option__title {
	font-size: 16px;
	font-weight: 700;
}

.tpv-badge {
	padding: 3px 10px;
	border-radius: 999px;
	background: var(--tpv-green-bg);
	color: var(--tpv-green);
	font-size: 12px;
	font-weight: 700;
	white-space: nowrap;
}

.tpv-badge--fee {
	background: var(--tpv-amber-bg);
	color: var(--tpv-amber);
}

.tpv-field {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 10px;
	margin: 0;
}

.tpv-buy .tpv-field input[type="number"] {
	width: 120px;
	max-width: 100%;
	margin: 0;
	padding: 8px 10px;
	text-align: center;
}

.tpv-summary {
	margin: 0;
	color: var(--tpv-muted);
}

.tpv-summary strong {
	color: var(--tpv-ink);
	font-size: 17px;
}

.tpv-warning {
	margin: 0;
	padding: 8px 10px;
	background: var(--tpv-amber-bg);
	color: var(--tpv-amber);
	font-size: 13px;
}

.tpv-buy .tpv-button {
	width: 100%;
	margin: 0 !important;
}

.tpv-buy form.cart.tpv-sample {
	display: flex !important;
	flex-wrap: wrap !important;
	align-items: center;
	justify-content: space-between;
	gap: 10px;
	margin: 0 !important;
	padding: 12px 16px;
	border: 1px dashed var(--tpv-border);
	background: var(--tpv-soft);
}

.tpv-sample__text {
	flex: 1 1 220px;
	font-size: 14px;
}

.tpv-small {
	margin: 0;
	color: var(--tpv-muted);
	font-size: 12px;
}

@media (max-width: 620px) {
	.tpv-sample__text {
		flex: 1 1 100%;
	}

	.tpv-buy .tpv-sample__button {
		width: 100%;
		margin: 0 !important;
	}
}

@media (max-width: 520px) {
	.tpv-facts {
		grid-template-columns: 1fr;
	}

	.tpv-facts > div {
		display: flex;
		align-items: baseline;
		justify-content: space-between;
		gap: 10px;
		border-left: 0;
		border-top: 1px solid var(--tpv-border);
	}

	.tpv-facts > div:first-child {
		border-top: 0;
	}

	.tpv-facts dd {
		margin: 0;
	}
}

/* Prices in shop loops and product pages */

.tpv-price__inc,
.tpv-price__ex {
	display: block;
}

.tpv-price__ex {
	font-size: 0.8em;
	font-weight: 400;
	opacity: 0.75;
}

.tpv-note {
	margin: 0 0 12px;
	font-size: 14px;
}

.tpv-cart-qty-label {
	display: block;
	margin-top: 4px;
	font-size: 12px;
	opacity: 0.75;
}

/* Samples grid */

.tpv-samples {
	--tpv-cols: 4;
}

.tpv-samples__search {
	margin: 0 0 24px;
}

.tpv-samples__search input {
	width: 100%;
	max-width: 440px;
	padding: 10px 14px;
}

.tpv-samples__group + .tpv-samples__group {
	margin-top: 40px;
}

.tpv-samples__heading {
	margin: 0 0 16px;
}

.tpv-samples__grid {
	display: grid;
	grid-template-columns: repeat(var(--tpv-cols), minmax(0, 1fr));
	gap: 24px 20px;
}

.tpv-sample-card {
	display: flex;
	min-width: 0;
	flex-direction: column;
	gap: 10px;
}

.tpv-sample-card__image img {
	display: block;
	width: 100%;
	height: auto;
	aspect-ratio: 1 / 1;
	object-fit: cover;
}

.tpv-sample-card__title {
	flex: 1;
	margin: 0;
	font-size: 15px;
	line-height: 1.3;
}

.tpv-sample-card__title a {
	color: inherit;
	text-decoration: none;
}

.tpv-sample-card form {
	margin: 0;
}

.tpv-sample-card__button {
	width: 100%;
	max-width: 100%;
	/* Themes pad these buttons heavily, which overflows a narrow grid column. */
	padding-left: 12px !important;
	padding-right: 12px !important;
	white-space: normal !important;
	overflow-wrap: anywhere;
}

.tpv-sample-card__added {
	padding: 10px 0;
	color: var(--tpv-green);
	font-size: 14px;
	font-weight: 700;
}

@media (max-width: 1024px) {
	.tpv-samples__grid {
		grid-template-columns: repeat(min(var(--tpv-cols), 3), minmax(0, 1fr));
	}
}

@media (max-width: 640px) {
	.tpv-samples__grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
		gap: 20px 14px;
	}
}

.tpv-buy .tpv-button[disabled] {
	opacity: 0.5;
	/* Themes often colour :disabled buttons; grey it out whatever the colour is. */
	filter: grayscale(1);
	cursor: not-allowed;
}

.tpv-no-delivery {
	margin: 0;
	color: #8a4b08;
	font-weight: 600;
}
