/* =====================================================================
   We Blink – pagina prodotto WooCommerce (stile marketplace)
   Colonne: [titolo + foto + correlati] [prezzo + descrizione] [acquisto] [carrello + cross-sell]
   ===================================================================== */

.wb-shop--product { max-width: 1560px; margin: 0 auto; padding: 18px 24px 64px; }
.wbp-product { --wbp-line: #e3e6e6; --wbp-ink: #0f1111; --wbp-muted: #565959; --wbp-link: #007185; color: var(--wbp-ink); }
.wbp-product *, .wbp-product *::before, .wbp-product *::after { box-sizing: border-box; }

.wbp-crumbs { font-size: 13px; color: var(--wbp-muted); margin: 0 0 14px; }
.wbp-crumbs a { color: var(--wbp-link); text-decoration: none; }
.wbp-crumbs a:hover { text-decoration: underline; }

/* ---------- Griglia ---------- */
.wbp-grid { display: grid; grid-template-columns: minmax(0, 4.6fr) minmax(0, 2.8fr) minmax(220px, 1.8fr) minmax(170px, 1fr); gap: 28px; align-items: start; }
.wbp-col { min-width: 0; }

/* ---------- 1. Titolo e breve descrizione (rosso) ---------- */
.wbp-head { margin-bottom: 16px; }
.woocommerce .wbp-product .woocommerce-product-rating { margin: 0 0 6px; font-size: 14px; display: flex; align-items: center; gap: 8px; }
.wbp-head .woocommerce-review-link { color: var(--wbp-link); }
.woocommerce .wbp-product .wbp-title { font-size: clamp(1.35rem, 2vw, 1.75rem); line-height: 1.25; font-weight: 600; margin: 0 0 8px; color: var(--wbp-ink); clear: none; }
.wbp-short { color: var(--wbp-muted); font-size: 15.5px; line-height: 1.5; }
.wbp-short p { margin: 0 0 6px; }
.wbp-short ul { margin: 6px 0 0 18px; padding: 0; }

/* ---------- 1. Foto e gallery (giallo) ---------- */
.wbp-gallery { position: relative; }
.woocommerce div.product.wbp-product div.images { width: 100% !important; float: none !important; margin: 0 !important; }
.woocommerce div.product.wbp-product div.images img { border-radius: 6px; }
.woocommerce div.product.wbp-product div.images .flex-control-thumbs { display: grid !important; grid-template-columns: repeat(auto-fill, minmax(70px, 1fr)); gap: 8px; margin: 10px 0 0 !important; padding: 0 !important; list-style: none !important; }
.woocommerce div.product.wbp-product div.images .flex-control-thumbs li { width: auto !important; float: none !important; margin: 0 !important; }
.woocommerce div.product.wbp-product div.images .flex-control-thumbs li img { border: 2px solid var(--wbp-line); border-radius: 6px; opacity: 1; aspect-ratio: 1; object-fit: cover; }
.woocommerce div.product.wbp-product div.images .flex-control-thumbs li img.flex-active,
.woocommerce div.product.wbp-product div.images .flex-control-thumbs li img:hover { border-color: #007185; }
.woocommerce .wbp-product span.onsale { top: 10px; left: 10px; right: auto; z-index: 9; min-height: 0; min-width: 0; padding: 4px 10px; border-radius: 4px; line-height: 1.4; background: #cc0c39; }

/* ---------- 1. Correlati (sotto le foto) ---------- */
.wbp-related { margin-top: 34px; }
.woocommerce .wbp-related section.related { width: 100%; float: none; clear: both; }
.wbp-related h2, .wbp-more .up-sells h2 { font-size: 1.2rem; margin: 0 0 14px; }
.woocommerce .wbp-product ul.products { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; margin: 0; padding: 0; list-style: none; }
.woocommerce .wbp-product ul.products::before, .woocommerce .wbp-product ul.products::after { display: none; }
.woocommerce .wbp-product ul.products li.product { width: auto !important; margin: 0 !important; float: none !important; padding: 10px; border: 1px solid var(--wbp-line); border-radius: 8px; display: flex; flex-direction: column; }
.woocommerce .wbp-product ul.products li.product a img { margin-bottom: 8px; border-radius: 4px; aspect-ratio: 1; object-fit: contain; background: #fff; }
.woocommerce .wbp-product ul.products li.product .woocommerce-loop-product__title { font-size: 14px; line-height: 1.35; padding: 0; margin: 0 0 6px; color: var(--wbp-ink); display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.woocommerce .wbp-product ul.products li.product .price { color: var(--wbp-ink); font-size: 15px; font-weight: 700; margin-bottom: 8px; }
.woocommerce .wbp-product ul.products li.product .button { margin-top: auto; text-align: center; }

/* ---------- 2. Prezzo e descrizione (verde) ---------- */
.woocommerce .wbp-product .wbp-pricebox .price { font-size: 30px; line-height: 1.1; color: var(--wbp-price, #0f1111); font-weight: 500; margin: 0 0 14px; }
.woocommerce .wbp-product .wbp-pricebox .price del { font-size: 15px; color: var(--wbp-muted); opacity: 1; display: block; }
.woocommerce .wbp-product .wbp-pricebox .price ins { text-decoration: none; color: #b12704; }
.wbp-pricebox { padding-bottom: 14px; border-bottom: 1px solid var(--wbp-line); margin-bottom: 16px; }
.wbp-desc__title { font-size: 1.05rem; margin: 0 0 8px; }
.wbp-desc__body { font-size: 15px; line-height: 1.6; }
.wbp-desc__body > *:first-child { margin-top: 0; }
.wbp-desc__body ul { padding-left: 18px; }
.wbp-desc__body img { max-width: 100%; height: auto; }
.woocommerce .wbp-product .product_meta { margin-top: 18px; padding-top: 12px; border-top: 1px solid var(--wbp-line); font-size: 13px; color: var(--wbp-muted); display: flex; flex-direction: column; gap: 4px; }
.wbp-product .product_meta a { color: var(--wbp-link); }

/* ---------- 3. Acquisto (blu) ---------- */
.wbp-grid--static .wbp-buy { position: static !important; }
.wbp-buy { position: sticky; top: 110px; border: 1px solid #d5d9d9; border-radius: 10px; padding: 18px; background: #fff; }
.admin-bar .wbp-buy { top: 142px; }
.woocommerce .wbp-product .wbp-buy .stock { font-size: 17px; font-weight: 600; margin: 0 0 12px; }
.woocommerce .wbp-product .wbp-buy .stock.in-stock { color: #007600; }
.woocommerce .wbp-product .wbp-buy .stock.out-of-stock { color: #b12704; }
.woocommerce .wbp-product .wbp-buy form.cart { margin: 0 !important; display: flex; flex-direction: column; gap: 10px; }
.woocommerce .wbp-product .wbp-buy form.cart::before, .woocommerce .wbp-product .wbp-buy form.cart::after { display: none; }
.woocommerce .wbp-product .wbp-buy form.cart div.quantity { float: none !important; margin: 0 !important; display: flex; align-items: center; gap: 10px; border: 1px solid #d5d9d9; border-radius: 8px; padding: 6px 10px; background: #f0f2f2; box-shadow: 0 2px 5px rgba(15, 17, 17, .08); }
.woocommerce .wbp-product .wbp-buy form.cart div.quantity::before { content: "Quantità:"; font-size: 14px; }
.woocommerce .wbp-product .wbp-buy form.cart div.quantity .qty { width: 100%; flex: 1; border: 0; background: transparent; font-size: 15px; text-align: left; padding: 4px 0; }
.woocommerce .wbp-product .wbp-buy form.cart .button,
.woocommerce .wbp-product .wbp-buy .wbp-buynow { float: none !important; width: 100%; margin: 0 !important; padding: 12px 16px; border-radius: 999px; font-size: 15px; font-weight: 500; line-height: 1.2; text-align: center; border: 0; cursor: pointer; transition: filter .15s; }
.woocommerce .wbp-product .wbp-buy form.cart .single_add_to_cart_button { background: var(--wbp-cart); color: var(--wbp-cart-fg); }
.woocommerce .wbp-product .wbp-buy .wbp-buynow { background: var(--wbp-buy); color: var(--wbp-buy-fg); }
.woocommerce .wbp-product .wbp-buy form.cart .button:hover, .woocommerce .wbp-product .wbp-buy .wbp-buynow:hover { filter: brightness(.94); }
.woocommerce .wbp-product .wbp-buy form.cart .button.disabled, .woocommerce .wbp-product .wbp-buy form.cart .button:disabled { opacity: .55; }
/* prodotti variabili: scelte una sotto l'altra */
.woocommerce .wbp-product .wbp-buy table.variations { margin: 0 0 4px; }
.woocommerce .wbp-product .wbp-buy table.variations th, .woocommerce .wbp-product .wbp-buy table.variations td { display: block; padding: 0 0 4px; text-align: left; }
.woocommerce .wbp-product .wbp-buy table.variations select { width: 100%; min-width: 0; padding: 8px; border-radius: 8px; border: 1px solid #d5d9d9; }
.woocommerce .wbp-product .wbp-buy .woocommerce-variation-add-to-cart { display: flex; flex-direction: column; gap: 10px; }
.woocommerce .wbp-product .wbp-buy .woocommerce-variation-price .price { font-size: 22px; color: var(--wbp-ink); }
/* prodotti raggruppati */
.woocommerce .wbp-product .wbp-buy table.group_table { font-size: 14px; }

/* ---------- 4. Carrello e cross-sell (grigio) ---------- */
.wbp-col--side { border-left: 1px solid var(--wbp-line); padding-left: 16px; }
.wbp-cartbox { text-align: center; padding-bottom: 14px; border-bottom: 1px solid var(--wbp-line); margin-bottom: 14px; }
.wbp-cartbox__sum { display: flex; flex-direction: column; gap: 2px; font-size: 13px; color: var(--wbp-muted); margin-bottom: 8px; }
.wbp-cartbox__tot { font-size: 17px; font-weight: 700; color: #b12704; }
.wbp-product .wbp-cartbox__btn { display: block; padding: 8px 10px; border: 1px solid #d5d9d9; border-radius: 999px; color: var(--wbp-ink); text-decoration: none; font-size: 14px; background: #fff; box-shadow: 0 2px 5px rgba(15, 17, 17, .08); }
.wbp-product .wbp-cartbox__btn:hover { background: #f7fafa; }
.wbp-side__title { font-size: 14px; margin: 0 0 10px; text-align: center; }
.wbp-mini { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 6px; padding: 12px 0; border-bottom: 1px solid var(--wbp-line); }
.wbp-mini__img img { width: 110px; height: 110px; object-fit: contain; display: block; }
.wbp-product .wbp-mini__name { font-size: 13px; line-height: 1.3; color: var(--wbp-ink); text-decoration: none; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.wbp-product .wbp-mini__name:hover { color: #c7511f; }
.wbp-mini__price { font-weight: 700; font-size: 15px; }
.wbp-mini__price del { font-weight: 400; font-size: 12px; color: var(--wbp-muted); }
.wbp-mini__price ins { text-decoration: none; }
.woocommerce .wbp-product a.button.wbp-mini__add { padding: 6px 16px; border-radius: 999px; border: 2px solid var(--wbp-cart); background: #fff; color: var(--wbp-ink); font-size: 13px; font-weight: 600; }
.woocommerce .wbp-product a.button.wbp-mini__add:hover { background: var(--wbp-cart); color: var(--wbp-cart-fg); }
.woocommerce .wbp-product a.added_to_cart { font-size: 12px; color: var(--wbp-link); }

/* ---------- Sotto: schede, recensioni, up-sell ---------- */
.wbp-more { margin-top: 48px; padding-top: 24px; border-top: 1px solid var(--wbp-line); }
.woocommerce .wbp-product .woocommerce-tabs { clear: both; }
.woocommerce .wbp-product .woocommerce-tabs ul.tabs { padding: 0; margin: 0 0 18px; }
.woocommerce .wbp-product .wbp-more .up-sells { margin-top: 36px; }

/* ---------- Tablet: acquisto sotto il prezzo, carrello e cross-sell in fondo ---------- */
@media (max-width: 1280px) {
	.wbp-grid { grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); grid-template-rows: auto 1fr auto; grid-template-areas: "main info" "main buy" "side side"; }
	.wbp-col--main { grid-area: main; }
	.wbp-col--info { grid-area: info; }
	.wbp-col--buy { grid-area: buy; }
	.wbp-col--side { grid-area: side; border-left: 0; padding-left: 0; border-top: 1px solid var(--wbp-line); padding-top: 18px; }
	.wbp-buy { position: static; }
	.wbp-cartbox { display: flex; align-items: center; justify-content: space-between; gap: 16px; text-align: left; }
	.wbp-cartbox__sum { margin: 0; }
	.wbp-side__list { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 0 16px; }
	.wbp-side__title { grid-column: 1 / -1; text-align: left; }
}

/* ---------- Smartphone: titolo, foto, prezzo, acquisto, descrizione, correlati, carrello ---------- */
@media (max-width: 760px) {
	.wb-shop--product { padding: 12px 16px 48px; }
	.wbp-grid { display: flex; flex-direction: column; gap: 18px; }
	.wbp-col--main, .wbp-col--info { display: contents; }
	.wbp-head { order: 1; margin: 0; }
	.wbp-gallery { order: 2; }
	.wbp-pricebox { order: 3; margin: 0; }
	.wbp-attrs { order: 3; margin: 0; }
	.wbp-col--buy { order: 4; }
	.wbp-desc { order: 5; }
	.wbp-related { order: 6; margin-top: 8px; }
	.wbp-col--side { order: 7; }
	.woocommerce .wbp-product ul.products { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
	.wbp-side__list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* =====================================================================
   Attributi a riquadri (colonna centrale)
   ===================================================================== */
.wbp-attrs { margin: 0 0 18px; padding-bottom: 14px; border-bottom: 1px solid var(--wbp-line); display: flex; flex-direction: column; gap: 12px; }
.wbp-attr__label { margin: 0 0 8px; font-size: 14.5px; color: var(--wbp-muted); }
.wbp-attr__label strong { color: var(--wbp-ink); }
.wbp-attr--info .wbp-attr__label { margin: 0; }
.wbp-attr__opts { display: flex; flex-wrap: wrap; gap: 8px; }
.wbp-product .wbp-sw { all: unset; box-sizing: border-box; cursor: pointer; display: flex; flex-direction: column; align-items: flex-start; gap: 2px; min-width: 92px; padding: 8px 10px; border: 1px solid #c4c8c8; border-radius: 8px; background: #fff; font-size: 13px; line-height: 1.25; color: var(--wbp-ink); transition: border-color .15s, box-shadow .15s; }
.wbp-product .wbp-sw:hover { border-color: #8d9191; }
.wbp-product .wbp-sw:focus-visible { outline: 3px solid #007185; outline-offset: 2px; }
.wbp-product .wbp-sw.is-on { border: 2px solid #007185; padding: 7px 9px; box-shadow: 0 0 0 3px rgba(0, 113, 133, .12); background: #f0f8fa; }
.wbp-product .wbp-sw.is-off { opacity: .45; border-style: dashed; }
.wbp-product .wbp-sw--img { width: 104px; padding: 0 0 8px; overflow: hidden; }
.wbp-product .wbp-sw--img.is-on { padding: 0 0 7px; }
.wbp-sw__img { display: block; width: 100%; height: 86px; object-fit: contain; background: #fff; margin-bottom: 6px; border-bottom: 1px solid var(--wbp-line); }
.wbp-sw__img--none { background: #f3f4f6; }
.wbp-sw--img .wbp-sw__name, .wbp-sw--img .wbp-sw__price, .wbp-sw--img .wbp-sw__stock { padding: 0 8px; }
.wbp-sw__name { font-weight: 600; }
.wbp-sw__price { font-weight: 700; }
.wbp-sw__stock { font-size: 12px; color: #007600; }
.wbp-sw.is-out .wbp-sw__stock { color: #b12704; }
/* con i riquadri, i menu a tendina delle varianti non servono più nel riquadro di acquisto */
.woocommerce .wbp-product .wbp-has-swatches table.variations { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

/* =====================================================================
   Carrello
   ===================================================================== */
.wb-shop--page { padding-top: 28px; }
.wb-shop__title { font-size: clamp(1.8rem, 3vw, 2.4rem); margin: 0 0 20px; }
.wbc-cart { --wbp-line: #e3e6e6; --wbp-ink: #0f1111; --wbp-muted: #565959; --wbp-link: #007185; color: var(--wbp-ink); }
.wbc-cart *, .wbc-cart *::before, .wbc-cart *::after { box-sizing: border-box; }
.wbc-grid { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 24px; align-items: start; }
.wbc-main, .wbc-box { background: #fff; border: 1px solid var(--wbp-line); border-radius: 10px; }
.wbc-main { padding: 22px 26px 8px; }
.wbc-head { display: flex; align-items: flex-end; justify-content: space-between; border-bottom: 1px solid var(--wbp-line); padding-bottom: 10px; }
.woocommerce .wbc-cart .wbc-title { font-size: clamp(1.6rem, 2.6vw, 2.1rem); margin: 0; }
.wbc-head__price { font-size: 14px; color: var(--wbp-muted); }

.wbc-item { display: grid; grid-template-columns: 170px minmax(0, 1fr) auto; gap: 20px; padding: 20px 0; border-bottom: 1px solid var(--wbp-line); }
.wbc-item__img img { width: 170px; height: 170px; object-fit: contain; display: block; }
.woocommerce .wbc-cart .wbc-item__name { font-size: 17px; line-height: 1.35; font-weight: 500; margin: 0 0 6px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.wbc-item__name a { color: var(--wbp-ink); text-decoration: none; }
.wbc-item__name a:hover { color: #c7511f; text-decoration: underline; }
.wbc-item__stock { margin: 0 0 6px; font-size: 13.5px; color: #007600; }
.wbc-item__stock.is-backorder { color: #c45500; }
.wbc-cart dl.variation { margin: 0 0 10px; font-size: 13.5px; display: grid; grid-template-columns: auto 1fr; gap: 2px 6px; }
.wbc-cart dl.variation dt { font-weight: 700; margin: 0; float: none; }
.wbc-cart dl.variation dd { margin: 0; float: none; }
.wbc-cart dl.variation dd p { margin: 0; }
.wbc-item__actions { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; margin-top: 10px; }
.wbc-qty { display: inline-flex; align-items: center; height: 38px; border: 3px solid var(--wbp-cart); border-radius: 999px; overflow: hidden; background: #fff; }
.wbc-cart .wbc-qty button { all: unset; box-sizing: border-box; width: 38px; height: 100%; display: inline-flex; align-items: center; justify-content: center; cursor: pointer; color: var(--wbp-ink); }
.wbc-cart .wbc-qty button:hover { background: #f7f7f7; }
.wbc-cart .wbc-qty button:disabled { opacity: .35; cursor: default; }
.wbc-cart .wbc-qty button:focus-visible { outline: 2px solid #007185; outline-offset: -2px; }
.wbc-qty svg { width: 18px; height: 18px; }
.woocommerce .wbc-cart .wbc-qty input.qty { width: 44px; height: 100%; border: 0; padding: 0; text-align: center; font-size: 16px; font-weight: 700; background: transparent; -moz-appearance: textfield; }
.wbc-qty input.qty::-webkit-outer-spin-button, .wbc-qty input.qty::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.wbc-qty--single { border-color: var(--wbp-line); padding: 0 14px; font-size: 14px; }
.woocommerce .wbc-cart a.wbc-link, .woocommerce .wbc-cart a.remove { width: auto; height: auto; font-size: 14px; font-weight: 400; line-height: 1.4; color: var(--wbp-link) !important; background: none !important; border-left: 1px solid var(--wbp-line); padding-left: 14px; border-radius: 0; text-decoration: none; display: inline; }
.woocommerce .wbc-cart a.remove:hover { text-decoration: underline; }
.wbc-item__price { text-align: right; white-space: nowrap; }
.wbc-item__price strong { font-size: 19px; font-weight: 700; display: block; }
.wbc-item__price small { font-size: 12.5px; color: var(--wbp-muted); }

.wbc-foot { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; padding: 16px 0 14px; }
.wbc-coupon { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; font-size: 14px; }
.woocommerce .wbc-cart .wbc-coupon input { width: 160px; padding: 9px 12px; border: 1px solid #c4c8c8; border-radius: 8px; font-size: 14px; }
.wbc-foot__sub { margin: 0 0 0 auto; font-size: 18px; }
.wbc-cart .wbc-update { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.wbc-cart .wbc-form.is-loading { opacity: .55; pointer-events: none; transition: opacity .2s; }

.wbc-side { display: flex; flex-direction: column; gap: 18px; position: sticky; top: 110px; }
.admin-bar .wbc-side { top: 142px; }
.wbc-box { padding: 20px; }
.wbc-sum { margin: 0 0 14px; font-size: 18px; line-height: 1.4; }
.wbc-cart .wbc-btn { display: block; width: 100%; padding: 11px 16px; border-radius: 999px; text-align: center; text-decoration: none; font-size: 15px; font-weight: 500; border: 0; cursor: pointer; }
.wbc-cart .wbc-btn--go { background: var(--wbp-cart); color: var(--wbp-cart-fg); }
.wbc-cart .wbc-btn--go:hover { filter: brightness(.94); }
.woocommerce .wbc-cart .wbc-btn--ghost { width: auto; display: inline-block; padding: 9px 16px; background: #fff; color: var(--wbp-ink); border: 1px solid #c4c8c8; }
.wbc-details { margin-top: 14px; font-size: 14px; }
.wbc-details summary { cursor: pointer; color: var(--wbp-link); }
.woocommerce .wbc-cart .cart_totals { width: 100%; float: none; margin-top: 8px; }
.woocommerce .wbc-cart .cart_totals h2 { display: none; }
.woocommerce .wbc-cart .cart_totals table { font-size: 14px; border: 0; margin: 0; }
.woocommerce .wbc-cart .cart_totals table th, .woocommerce .wbc-cart .cart_totals table td { padding: 6px 0; border-top: 1px solid var(--wbp-line); background: none; text-align: left; }
.woocommerce .wbc-cart .cart_totals table td { text-align: right; }
.woocommerce .wbc-cart .cart_totals .wc-proceed-to-checkout { display: none; } /* c'è già "Procedi all'ordine" in alto */
.wbc-side .wbp-side__list { background: #fff; border: 1px solid var(--wbp-line); border-radius: 10px; padding: 18px 18px 6px; }
.wbc-side .wbp-side__title { text-align: left; font-size: 17px; }
.wbc-side .wbp-mini { flex-direction: row; align-items: flex-start; text-align: left; gap: 12px; }
.wbc-side .wbp-mini__img img { width: 84px; height: 84px; }
.wbc-side .wbp-mini__body { display: flex; flex-direction: column; gap: 4px; align-items: flex-start; }
.wbp-mini__rating { display: flex; align-items: center; gap: 4px; font-size: 12px; color: var(--wbp-link); }
.woocommerce .wbp-mini__rating .star-rating { font-size: 12px; margin: 0; }
.woocommerce .wbc-cart a.button.wbp-mini__add { padding: 6px 14px; border-radius: 999px; border: 0; background: var(--wbp-cart); color: var(--wbp-cart-fg); font-size: 13px; font-weight: 600; }

@media (max-width: 980px) {
	.wbc-grid { grid-template-columns: 1fr; }
	/* riepilogo in alto, articoli, poi i consigliati */
	.wbc-side { display: contents; }
	.wbc-box--sum { order: -1; }
	.wbc-side .wbp-side__list { order: 2; }
}
@media (max-width: 640px) {
	.wbc-main { padding: 16px 14px 4px; }
	.wbc-item { grid-template-columns: 96px minmax(0, 1fr); gap: 12px; }
	.wbc-item__img img { width: 96px; height: 96px; }
	.wbc-item__price { grid-column: 2; grid-row: 2; text-align: left; }
	.wbc-item__actions { grid-column: 1 / -1; }
	.wbc-foot__sub { margin: 0; }
}

.wbc-cart .wbp-mini__name { color: var(--wbp-ink); text-decoration: none; font-size: 14px; line-height: 1.3; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.wbc-cart .wbp-mini__name:hover { color: #c7511f; text-decoration: underline; }
.wbc-cart .wbp-mini__price { font-weight: 700; }
.woocommerce .wbc-cart a.button.wbp-mini__add, .woocommerce .wbp-product a.button.wbp-mini__add { text-decoration: none; }
.wbc-side .wbp-side__list { display: block; } /* nel carrello i consigliati sono sempre in colonna */

/* =====================================================================
   Sotto-header del negozio: ricerca prodotti, "Chiama ora", carrello
   ===================================================================== */
.wbs-sub { background: var(--wbs-sub-bg, #1e2023); color: var(--wbs-sub-fg, #fff); font-family: var(--wb-font, system-ui, sans-serif); position: relative; z-index: 9989; }
.wbs-sub *, .wbs-sub *::before, .wbs-sub *::after { box-sizing: border-box; }
.wbs-sub__in { max-width: 1560px; margin: 0 auto; padding: 10px 24px; display: flex; align-items: center; gap: 14px; }
.wbs-search { flex: 1; display: flex; height: 44px; border-radius: 8px; overflow: hidden; background: #fff; min-width: 0; }
.wbs-search:focus-within { box-shadow: 0 0 0 3px var(--wbs-search-bg, #FFA41C); }
.wbs-sub .wbs-search__cat { all: unset; box-sizing: border-box; max-width: 210px; padding: 0 28px 0 12px; background: #f1f2f4 url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23555' stroke-width='2.5'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") right 8px center/14px no-repeat; color: #0f1111; font-size: 13.5px; cursor: pointer; border-right: 1px solid #d5d9d9; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.wbs-sub .wbs-search__q { all: unset; box-sizing: border-box; flex: 1; min-width: 0; padding: 0 14px; color: #0f1111; font-size: 15px; background: #fff; }
.wbs-sub .wbs-search__q::placeholder { color: #6b7280; }
.wbs-sub .wbs-search__go { all: unset; box-sizing: border-box; width: 52px; display: flex; align-items: center; justify-content: center; background: var(--wbs-search-bg, #FFA41C); color: var(--wbs-search-bg-fg, #0f1111); cursor: pointer; }
.wbs-sub .wbs-search__go:hover { filter: brightness(.94); }
.wbs-search__go svg { width: 22px; height: 22px; }
.wbs-sub .wbs-call { flex: none; display: inline-flex; align-items: center; gap: 8px; height: 44px; padding: 0 18px; border-radius: 8px; background: var(--wbs-call-bg, #B9471A); color: var(--wbs-call-bg-fg, #fff); text-decoration: none; font-weight: 700; font-size: 14px; letter-spacing: .03em; }
.wbs-sub .wbs-call:hover { filter: brightness(.9); }
.wbs-call svg { width: 18px; height: 18px; }
.wbs-sub .wbs-cartlink { flex: none; position: relative; display: inline-flex; align-items: flex-end; gap: 4px; height: 44px; padding: 0 6px; color: var(--wbs-sub-fg, #fff); text-decoration: none; font-weight: 700; font-size: 14px; }
.wbs-cartlink svg { width: 32px; height: 32px; }
.wbs-cartlink__count { position: absolute; top: -2px; left: 18px; min-width: 20px; height: 20px; padding: 0 5px; border-radius: 10px; background: var(--wbs-search-bg, #FFA41C); color: var(--wbs-search-bg-fg, #0f1111); font-size: 12px; line-height: 20px; text-align: center; }
.wbs-cartlink__txt { padding-bottom: 6px; }
.wbs-sub a:focus-visible, .wbs-sub button:focus-visible, .wbs-sub select:focus-visible { outline: 3px solid var(--wbs-search-bg, #FFA41C); outline-offset: 2px; }
@media (max-width: 760px) {
	.wbs-sub__in { padding: 8px 12px; gap: 8px; flex-wrap: wrap; }
	.wbs-search { order: 3; flex: 1 1 100%; }
	.wbs-sub .wbs-search__cat { display: none; }
	.wbs-sub .wbs-call { flex: 1; justify-content: center; }
	.wbs-cartlink__txt { display: none; }
}

/* =====================================================================
   Negozio e categorie
   ===================================================================== */
.wbs-shop { --wbp-line: #e3e6e6; --wbp-ink: #0f1111; --wbp-muted: #565959; --wbp-link: #007185; max-width: 1560px; margin: 0 auto; padding: 18px 24px 64px; color: var(--wbp-ink); }
.wbs-shop *, .wbs-shop *::before, .wbs-shop *::after { box-sizing: border-box; }
.wbs-grid { display: grid; grid-template-columns: 250px minmax(0, 1fr); gap: 28px; align-items: start; }

/* Filtri */
.wbs-filters { padding-right: 6px; font-size: 14px; }
.wbs-filters.is-sticky { position: sticky; top: 110px; max-height: calc(100vh - 130px); overflow: auto; }
.admin-bar .wbs-filters.is-sticky { top: 142px; }
.wbs-grid--right { grid-template-columns: minmax(0, 1fr) 250px; }
.wbs-grid--right .wbs-filters { order: 2; padding: 0 0 0 6px; }
.wbs-grid--nofilters { grid-template-columns: minmax(0, 1fr); }
.wbs-f__n { color: var(--wbp-muted); }
.wbs-f { padding: 0 0 16px; margin: 0 0 16px; border-bottom: 1px solid var(--wbp-line); }
.wbs-f__t { font-size: 14.5px; font-weight: 700; margin: 0 0 8px; color: var(--wbp-ink); }
.wbs-f__list { list-style: none; margin: 0; padding: 0; }
.wbs-f__list li { margin: 0 0 6px; color: var(--wbp-muted); }
.wbs-f__list li.is-sub { padding-left: 12px; }
.wbs-f__list a { color: var(--wbp-ink); text-decoration: none; }
.wbs-f__list a:hover { color: #c7511f; text-decoration: underline; }
.wbs-f__list li.is-on > a { font-weight: 700; }
.wbs-stars { color: #de7921; letter-spacing: 1px; }
.wbs-check { display: inline-flex; align-items: center; gap: 8px; }
.wbs-check__box { width: 16px; height: 16px; border: 1.5px solid #8d9191; border-radius: 3px; flex: none; background: #fff; }
.is-on .wbs-check__box { background: #007185 url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3.5'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5'/%3E%3C/svg%3E") center/12px no-repeat; border-color: #007185; }
.wbs-price { display: flex; gap: 6px; align-items: center; }
.wbs-price label { flex: 1; min-width: 0; }
.wbs-shop .wbs-price input { width: 100%; padding: 7px 8px; border: 1px solid #c4c8c8; border-radius: 6px; font-size: 13.5px; }
.wbs-shop .wbs-price button { padding: 7px 12px; border: 1px solid #c4c8c8; border-radius: 6px; background: #fff; cursor: pointer; font-size: 13.5px; }
.wbs-f__reset { margin: 0 0 14px; }
.wbs-f__reset a { color: var(--wbp-link); font-weight: 600; text-decoration: none; }
.wbs-filters__close, .wbs-filters__open { display: none; }

/* Risultati */
.wbs-head { margin-bottom: 10px; }
.woocommerce .wbs-shop .wbs-title { font-size: clamp(1.5rem, 2.4vw, 2rem); margin: 0 0 6px; }
.wbs-head .term-description, .wbs-head .page-description { color: var(--wbp-muted); font-size: 15px; max-width: 900px; }
.wbs-head .term-description p { margin: 0 0 8px; }
.wbs-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; padding: 10px 0; margin-bottom: 16px; border-top: 1px solid var(--wbp-line); border-bottom: 1px solid var(--wbp-line); }
.woocommerce .wbs-shop .woocommerce-result-count { margin: 0; float: none; font-size: 14px; color: var(--wbp-muted); }
.woocommerce .wbs-shop .woocommerce-ordering { margin: 0 0 0 auto; float: none; }
.woocommerce .wbs-shop .woocommerce-ordering select { padding: 7px 30px 7px 10px; border: 1px solid #d5d9d9; border-radius: 8px; background-color: #f0f2f2; font-size: 13.5px; box-shadow: 0 2px 5px rgba(15, 17, 17, .08); }

/* Griglia di schede */
.woocommerce .wbs-shop ul.products { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 18px; margin: 0 0 28px; padding: 0; list-style: none; }
@media (min-width: 1200px) { .woocommerce .wbs-shop ul.products { grid-template-columns: repeat(var(--wbs-cols, 4), minmax(0, 1fr)); } }
.woocommerce .wbs-shop ul.products::before, .woocommerce .wbs-shop ul.products::after { display: none; }
.woocommerce ul.products li.wbs-card { width: auto !important; margin: 0 !important; float: none !important; padding: 0; display: flex; flex-direction: column; background: var(--wbs-card-bg, #fff); border: 1px solid var(--wbp-line, #e3e6e6); border-radius: 10px; overflow: hidden; transition: box-shadow .2s; }
.woocommerce ul.products li.wbs-card:hover { box-shadow: 0 6px 22px rgba(15, 17, 17, .1); }
.wbs-card__img { position: relative; display: block; background: #f7f8f8; padding: 14px; }
.woocommerce ul.products li.wbs-card .wbs-card__img img { width: 100%; aspect-ratio: 1; object-fit: contain; margin: 0; mix-blend-mode: multiply; }
.woocommerce ul.products li.wbs-card .onsale { top: 10px; left: 10px; right: auto; margin: 0; min-width: 0; min-height: 0; padding: 3px 9px; border-radius: 4px; font-size: 12px; line-height: 1.5; background: var(--wbs-sale-bg, #cc0c39); }
.wbs-card__body { padding: 12px 14px 14px; display: flex; flex-direction: column; gap: 5px; flex: 1; }
.woocommerce ul.products li.wbs-card .wbs-card__title { font-size: 15px; line-height: 1.35; font-weight: 500; margin: 0; padding: 0; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.wbs-card__title a { color: var(--wbp-ink, #0f1111); text-decoration: none; }
.wbs-card__title a:hover { color: #c7511f; }
.wbs-card__rating { display: flex; align-items: center; gap: 6px; font-size: 13px; }
.woocommerce .wbs-card__rating .star-rating { margin: 0; font-size: 13px; color: #de7921; }
.wbs-card__rating a { color: var(--wbp-link, #007185); text-decoration: none; }
.woocommerce ul.products li.wbs-card .price { margin: 2px 0 0; font-size: 20px; color: var(--wbs-price, #0f1111); font-weight: 600; }
.woocommerce ul.products li.wbs-card .price del { font-size: 13px; font-weight: 400; color: var(--wbp-muted, #565959); opacity: 1; }
.woocommerce ul.products li.wbs-card .price ins { text-decoration: none; color: #b12704; }
.wbs-card__stock { margin: 0; font-size: 13px; color: #007600; }
.wbs-card__stock.is-low { color: #c45500; }
.wbs-card__stock.is-out { color: #b12704; }
.wbs-card__cta { margin-top: auto; padding-top: 8px; }
.woocommerce ul.products li.wbs-card .button { display: block; width: 100%; margin: 0; padding: 9px 12px; border-radius: 999px; text-align: center; font-size: 14px; font-weight: 500; line-height: 1.3; background: var(--wbp-cart, #FFD814); color: var(--wbp-cart-fg, #0f1111); border: 0; }
.woocommerce ul.products li.wbs-card .button:hover { filter: brightness(.94); }
.woocommerce ul.products li.wbs-card .button.product_type_variable, .woocommerce ul.products li.wbs-card .button.product_type_grouped, .woocommerce ul.products li.wbs-card .button.product_type_external { background: #fff; color: var(--wbp-ink, #0f1111); box-shadow: inset 0 0 0 1px #d5d9d9; }
.woocommerce ul.products li.wbs-card .added_to_cart { display: block; text-align: center; font-size: 13px; padding-top: 6px; color: var(--wbp-link, #007185); }
/* sottocategorie mostrate da WooCommerce nella griglia */
.woocommerce .wbs-shop ul.products li.product-category { width: auto !important; margin: 0 !important; float: none !important; border: 1px solid var(--wbp-line); border-radius: 10px; padding: 12px; text-align: center; }
.woocommerce .wbs-shop ul.products li.product-category h2 { font-size: 15px; }

/* Numeri di pagina */
.woocommerce .wbs-shop nav.woocommerce-pagination ul { border: 0; display: inline-flex; gap: 6px; }
.woocommerce .wbs-shop nav.woocommerce-pagination ul li { border: 0; }
.woocommerce .wbs-shop nav.woocommerce-pagination ul li a, .woocommerce .wbs-shop nav.woocommerce-pagination ul li span { min-width: 38px; padding: 9px 12px; border: 1px solid #d5d9d9; border-radius: 8px; color: var(--wbp-ink); }
.woocommerce .wbs-shop nav.woocommerce-pagination ul li span.current { background: var(--wbp-ink); color: #fff; border-color: var(--wbp-ink); }
.wbs-empty { padding: 40px 0; }
.wbs-empty__link { color: var(--wbp-link); font-weight: 600; }

/* Correlati nella pagina prodotto: schede più compatte */
.wbp-related ul.products li.wbs-card .wbs-card__title { font-size: 13.5px; }
.wbp-related ul.products li.wbs-card .price { font-size: 16px; }
.wbp-related ul.products li.wbs-card .wbs-card__img { padding: 8px; }
.woocommerce .wbp-product ul.products li.wbs-card { padding: 0; }

/* Filtri su tablet e smartphone: pannello che si apre */
@media (max-width: 900px) {
	.wbs-grid { grid-template-columns: 1fr; }
	.wbs-filters { position: fixed; z-index: 99995; top: 0 !important; left: 0; bottom: 0; width: min(340px, 88vw); max-height: none; padding: 56px 20px 24px; background: #fff; box-shadow: 0 0 40px rgba(0, 0, 0, .3); transform: translateX(-105%); transition: transform .25s; }
	.wbs-filters.is-open { transform: none; }
	.wbs-filters.is-sticky { position: fixed; max-height: none; overflow: auto; }
	.wbs-grid--right .wbs-filters { order: 0; }
	.wbs-shop .wbs-filters__close { all: unset; display: block; position: absolute; top: 10px; right: 12px; width: 40px; height: 40px; font-size: 28px; line-height: 40px; text-align: center; cursor: pointer; }
	.wbs-shop .wbs-filters__open { display: inline-flex; align-items: center; gap: 6px; padding: 8px 14px; border: 1px solid #d5d9d9; border-radius: 8px; background: #fff; font-size: 14px; font-weight: 600; cursor: pointer; }
	.wbs-filters__open svg { width: 18px; height: 18px; }
	.woocommerce .wbs-shop ul.products { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
	.woocommerce ul.products li.wbs-card .wbs-card__title { font-size: 14px; }
	.woocommerce ul.products li.wbs-card .price { font-size: 17px; }
}
@media (max-width: 760px) {
	.wbs-shop { padding: 12px 12px 48px; }
	.woocommerce .wbs-shop .woocommerce-ordering { flex: 1 1 100%; }
	.woocommerce .wbs-shop .woocommerce-ordering select { width: 100%; }
}
@media (prefers-reduced-motion: reduce) { .wbs-filters { transition: none; } }
/* ritocchi */
.woocommerce ul.products li.wbs-card .onsale { color: var(--wbs-sale-bg-fg, #fff); font-weight: 700; }
.wbs-sub .wbs-search__cat { height: 100%; line-height: 44px; }
.woocommerce ul.products li.wbs-card .button, .wbs-sub a, .wbs-card__title a { text-decoration: none; }
@media (max-width: 900px) { .wbs-filters.is-open { box-shadow: 0 0 0 100vmax rgba(0, 0, 0, .45); } }

/* =====================================================================
   Blocchi aggiunti da We Blink Design (testo, HTML, shortcode)
   ===================================================================== */
.wbp-slot { margin: 14px 0; font-size: 15px; line-height: 1.55; }
.wbp-slot > *:first-child { margin-top: 0; }
.wbp-slot > *:last-child { margin-bottom: 0; }
.wbp-slot img { max-width: 100%; height: auto; }
.wbp-slot--buy_before { margin-top: 0; }
.wbp-slot--buy_after { margin-bottom: 0; font-size: 14px; }
.wbp-slot--side_after { font-size: 13.5px; }
@media (max-width: 760px) {
	.wbp-slot--gallery_after { order: 2; }
	.wbp-slot--price_after { order: 3; }
}
