/**
 * Global front-end fixes.
 *
 * The slide-out mini-cart is rendered inside the header markup, so its product
 * names inherit the transparent header's white text at the top of the page and
 * are unreadable. Force them dark regardless of the header state.
 *
 * @package blomify
 */

.right-header .mini-cart .dropdown-menu-mini-cart .product_name a,
.dropdown-menu-mini-cart .woocommerce-mini-cart-item .product_name a,
.cart-slider .product_name a {
	color: #2b2b2b !important;
}

.right-header .mini-cart .dropdown-menu-mini-cart .product_name a:hover,
.cart-slider .product_name a:hover {
	opacity: 0.7;
}

/**
 * Remove the grey placeholder background behind product-card images.
 * The theme paints `background: var(--background-color)` on every catalog
 * thumbnail (custom.css: `.product .thumbnail-wrap a.thumbnail-img`), which
 * shows through around images that don't fill their square. Make it transparent
 * on all product cards (including the out-of-stock variant).
 */
.product .thumbnail-wrap a.thumbnail-img,
.product.outofstock .thumbnail-wrap a.thumbnail-img {
	background: transparent !important;
}

/**
 * "Dostawa i odbiór" (Delivery & Pickup) single-product block.
 * Matches Figma node 127-150: Nunito 14/21, #2B2B2B, UPPERCASE,
 * truck + shopping-bag Font Awesome icons on the two highlight lines.
 */
.blomify-delivery-pickup {
	font-family: 'Nunito', sans-serif;
	color: #2B2B2B;
	padding-top: 20px;
}
.blomify-delivery-pickup .dp-title {
	font-size: 14px;
	line-height: 21px;
	font-weight: 700;
	text-transform: uppercase;
	margin: 0 0 12px;
	color: #2B2B2B;
}
.blomify-delivery-pickup .dp-content {
	font-size: 14px;
	line-height: 21px;
	text-transform: uppercase;
}
.blomify-delivery-pickup .dp-highlights {
	list-style: none;
	margin: 0 0 15px;
	padding: 0;
	display: flex;
	flex-direction: column;
	gap: 10px;
}
.blomify-delivery-pickup .dp-highlights li {
	position: relative;
	padding-left: 25px;
	margin: 0;
}
.blomify-delivery-pickup .dp-highlights li::before {
	position: absolute;
	left: 0;
	top: 0;
	font-family: 'Font Awesome 5 Free';
	font-weight: 900;
	font-size: 14px;
	line-height: 21px;
	color: var(--secondary-color, #2B2B2B);
}
.blomify-delivery-pickup .dp-highlights li.dp-ship::before   { content: '\f0d1'; }
.blomify-delivery-pickup .dp-highlights li.dp-pickup::before { content: '\f290'; }
.blomify-delivery-pickup .dp-highlights strong { font-weight: 700; }
.blomify-delivery-pickup .dp-content h4 {
	font-size: 14px;
	line-height: 21px;
	font-weight: 700;
	text-transform: uppercase;
	margin: 15px 0 5px;
	color: #2B2B2B;
}
.blomify-delivery-pickup .dp-content p {
	margin: 0 0 5px;
	font-size: 14px;
	line-height: 21px;
}

/* Force bold on the block title and section headers (override theme heading rules). */
.single-product .entry-summary .blomify-delivery-pickup .dp-title,
.single-product .entry-summary .blomify-delivery-pickup .dp-content h4,
.blomify-delivery-pickup .dp-title,
.blomify-delivery-pickup .dp-content h4 {
	font-family: 'Nunito', sans-serif !important;
	font-weight: 700 !important;
}

/* ------------------------------------------------------------------ *
 * Shop toolbar (product-top-sorting) — mobile / tablet layout (<=991px)
 * ------------------------------------------------------------------
 * The theme leaves the sorting bar as one cramped row that overflows the
 * viewport on small screens. Rebuild it to match the design: the
 * "Domyślne sortowanie" select fills the left side, the "Filtr" button sits
 * on the right, and the result count drops to its own line below. The grid/
 * list view switcher and the per-page selector are hidden on mobile.
 * Loaded before the theme's responsive.css, hence the !important guards.     */
@media (max-width: 991px) {
	.product-top-sorting {
		display: flex !important;
		flex-wrap: wrap !important;
		align-items: center !important;
	}
	.product-top-sorting .product-sort-view,
	.product-top-sorting .woocommerce-perpage {
		display: none !important;
	}
	/* Sorting select — left, grows to fill the row.
	 * flex-basis 0 + min-width 0 so it shrinks instead of pushing the
	 * Filtr button off-screen on narrow phones. */
	.product-top-sorting .woocommerce-ordering {
		order: 1 !important;
		flex: 1 1 0 !important;
		min-width: 0 !important;
		float: none !important;
		margin: 0 15px 0 0 !important;
	}
	.product-top-sorting .woocommerce-ordering .select-wrap {
		width: 100%;
		min-width: 0;
		margin: 0;
	}
	.product-top-sorting .woocommerce-ordering .select-wrap select.orderby {
		width: 100% !important;
		padding: 14px 40px 14px 15px !important;
		font-size: 14px !important;
	}
	.product-top-sorting .woocommerce-ordering .select-wrap::after {
		right: 15px !important;
		font-size: 11px !important;
	}
	/* Filtr button — right */
	.product-top-sorting .toggle-filter {
		order: 2 !important;
		flex: 0 0 auto !important;
		margin: 0 0 0 auto !important;
		justify-content: flex-end !important;
	}
	.product-top-sorting .filter {
		padding: 14px 18px !important;
		font-size: 14px !important;
		margin: 0 !important;
	}
	.product-top-sorting .filter .fa-align-right {
		font-size: 14px !important;
		margin: 0 0 0 10px !important;
	}
	/* Result count — full-width row underneath */
	.product-top-sorting .woocommerce-result-count {
		order: 3 !important;
		flex: 1 1 100% !important;
		width: 100% !important;
		float: none !important;
		margin: 15px 0 0 !important;
		line-height: 1.4 !important;
	}
}
