.spf-box:empty { display: none; }
.spf-box { margin: 0 0 1.5em; }
.spf-notice {
	border-left: 4px solid #2e7d32;
	background: #f3f8f3;
	color: #1d2327;
	padding: 12px 16px;
	border-radius: 4px;
	line-height: 1.5;
}
.spf-notice__row {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 8px 16px;
}
.spf-notice__text { flex: 1 1 260px; }
.spf-notice__button.button { margin: 0; white-space: nowrap; }
.spf-notice__progress {
	display: flex;
	align-items: center;
	gap: 10px;
	margin-top: 10px;
	font-size: 0.875em;
}
.spf-notice__bar {
	flex: 1;
	height: 8px;
	background: #dfe8df;
	border-radius: 999px;
	overflow: hidden;
}
.spf-notice__bar > span {
	display: block;
	height: 100%;
	background: #2e7d32;
	border-radius: 999px;
	transition: width .3s ease;
}
.spf-notice--warn { border-left-color: #b26200; background: #fff7ed; }
.spf-compare { border-left-color: #2271b1; background: #f0f6fc; margin-bottom: 10px; }
.spf-compare.is-diff { border-left-color: #d63638; background: #fcf0f1; }
.spf-compare > div { margin: 2px 0; }

/* ===== Barra spedizione gratuita (stile Spare4truck) ===== */
.spf-box { display: block; width: 100%; max-width: 100%; clear: both; box-sizing: border-box; grid-column: 1 / -1; }
.woocommerce-cart .spf-box:not(:empty) { margin: 0 0 25px 0; }
.s4t-fs-wrap {
	font-family: inherit;
	width: 100%;
	max-width: 100%;
	background: #ffffff;
	border: 1px solid #ebebeb;
	border-radius: 16px;
	padding: 20px 24px 24px;
	position: relative;
	overflow: hidden;
	box-sizing: border-box;
	margin-bottom: 10px;
}
.s4t-fs-wrap::before {
	content: '';
	position: absolute;
	top: 0; left: 0; right: 0;
	height: 3px;
	background: var(--s4t-accent);
	border-radius: 16px 16px 0 0;
}
.s4t-fs-header { display: flex; align-items: center; justify-content: center; gap: 12px; margin-bottom: 14px; flex-wrap: wrap; }
.s4t-fs-wrap:not(:has(.s4t-fs-track)) .s4t-fs-header { margin-bottom: 0; }
.s4t-fs-icon { font-size: 18px; line-height: 1; flex-shrink: 0; }
.s4t-fs-msg { font-size: 18px; font-weight: 500; color: #1a1a1a; line-height: 1.4; text-align: center; }
.s4t-fs-msg strong { font-weight: 600; }
.s4t-fs-shop {
	display: inline-flex;
	align-items: center;
	background: var(--s4t-accent);
	color: #ffffff !important;
	text-decoration: none !important;
	padding: 6px 14px;
	border-radius: 8px;
	font-size: 14px;
	font-weight: 600;
	white-space: nowrap;
	transition: opacity .2s;
}
.s4t-fs-shop:hover { opacity: .85; color: #ffffff !important; }
.s4t-fs-track { width: 100%; height: 6px; background: #f0f0f0; border-radius: 99px; overflow: hidden; }
.s4t-fs-fill { height: 100%; background: var(--s4t-accent); border-radius: 99px; transition: width .35s ease, background .35s ease; position: relative; }
.s4t-fs-fill::after { content: ''; position: absolute; right: 0; top: 0; width: 12px; height: 100%; background: rgba(255,255,255,.35); border-radius: 99px; }
@media (max-width: 767px) {
	.woocommerce-cart .spf-box:not(:empty) { margin-bottom: 18px; }
	.s4t-fs-wrap { padding: 18px 14px 20px; }
	.s4t-fs-header { gap: 8px; }
	.s4t-fs-msg { width: 100%; font-size: 15px; }
	.s4t-fs-icon { font-size: 17px; }
}

/* ---- Organizzo io la spedizione (checkout) ---- */
.woocommerce-checkout .s4t-spedizione-autonoma-row th,
.woocommerce-checkout .s4t-spedizione-autonoma-row td { border-top: 0 !important; border-bottom: 0 !important; }
.woocommerce-checkout .s4t-spedizione-autonoma-vuoto { color: transparent !important; }
.woocommerce-checkout .s4t-spedizione-autonoma-row td { text-align: right !important; vertical-align: middle !important; }
.woocommerce-checkout .s4t-spedizione-autonoma-label { display: inline-flex !important; align-items: center !important; justify-content: flex-end !important; gap: 8px !important; margin: 0 !important; color: #000 !important; cursor: pointer !important; }
.woocommerce-checkout #s4t_spedizione_autonoma { width: 17px !important; height: 17px !important; margin: 0 !important; flex: 0 0 auto !important; cursor: pointer !important; accent-color: #22d000; }
.woocommerce-checkout .s4t-spedizione-autonoma-titolo { font-size: 16px !important; font-weight: 600 !important; line-height: 1.35 !important; color: #000 !important; }
.woocommerce-checkout .s4t-spedizione-autonoma-descrizione-row td { width: 100% !important; padding-top: 5px !important; padding-bottom: 14px !important; text-align: center !important; border-top: 0 !important; border-bottom: 0 !important; }
.woocommerce-checkout .s4t-spedizione-autonoma-descrizione { display: block !important; width: 100% !important; max-width: 100% !important; margin: 0 auto !important; text-align: center !important; font-size: 13.5px !important; font-weight: 400 !important; line-height: 1.45 !important; color: #666 !important; }
