/* ==========================================================================
   Shop: category pages, product grid, single product
   WooCommerce's own CSS is switched off – everything here is the full styling.
   ========================================================================== */

.wk-shop { padding-top: var(--wk-s8); }
.woocommerce-products-header { margin-bottom: var(--wk-s6); }
.woocommerce-products-header__title { margin: 0 0 12px; font-size: clamp(40px, 5vw, 56px); line-height: 1; }
/* The page title is hidden on screen but stays in the page for search engines and screen readers. */
.woocommerce-products-header__title { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; border: 0; }
.woocommerce-products-header { margin-bottom: 0; }
.term-description, .page-description { max-width: 680px; font-size: var(--wk-fs-l); color: var(--wk-ink-3); }
.term-description p:last-child { margin-bottom: 0; }

/* Layout: filters left, products right */
.wk-shop-layout { display: flex; flex-wrap: wrap; gap: var(--wk-s12); align-items: flex-start; }
.wk-shop-main { flex: 999 1 560px; min-width: 0; }
.wk-filters { flex: 0 0 260px; }
.wk-filters__toggle { display: none; }
.wk-filters--plugin { display: contents; } /* the plugin's filter column is the flex item itself */
.wk-filters__body { display: flex; flex-direction: column; }
.wk-filter { padding: 20px 0; border-bottom: 1px solid var(--wk-line-mid); }
.wk-filter:first-child { padding-top: 0; }
.wk-filter:last-child { border-bottom: 0; }
.wk-filter__title { margin: 0 0 12px; font-family: var(--wk-font); font-size: var(--wk-fs); font-weight: 600; }
.wk-filter ul { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 6px; }
.wk-filter li a { display: flex; align-items: center; min-height: 32px; color: var(--wk-ink); text-decoration: none; font-size: var(--wk-fs); }
.wk-filter li a:hover { color: var(--wk-orange-text); }
.wk-filter .count { margin-left: auto; color: var(--wk-muted); font-size: var(--wk-fs-sm); }

.wk-toolbar { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: var(--wk-s4); margin-bottom: var(--wk-s6); }
.wk-toolbar__r { display: flex; align-items: center; gap: var(--wk-s3); }
.woocommerce-result-count { margin: 0; font-size: var(--wk-fs); color: var(--wk-ink-3); }
.woocommerce-ordering { margin: 0; }
.woocommerce-ordering select { width: auto; min-width: 220px; min-height: var(--wk-btn-h-sm); font-size: var(--wk-fs); font-weight: 500; }

/* Product grid */
ul.products { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 32px 24px; margin: 0; padding: 0; list-style: none; }
ul.products.columns-4, .wk-grid.products { grid-template-columns: repeat(4, minmax(0, 1fr)); }
ul.products li.product { margin: 0; padding: 0; width: auto; }
.wk-shop-layout--full ul.products { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.woocommerce-info.woocommerce-no-products-found { margin-top: var(--wk-s4); }

@media (max-width: 1000px) {
	.wk-shop-layout { gap: var(--wk-s4); }
	.wk-filters { flex: 1 1 100%; min-width: 0; }
	.wk-filters--plugin { display: contents; }
	.wk-toolbar__r { width: 100%; }
	.wk-toolbar__r .woocommerce-ordering { flex: 1 1 auto; min-width: 0; }
	.wk-toolbar__r .woocommerce-ordering select { width: 100%; min-width: 0; }
	.wk-filters__toggle {
		display: inline-flex; align-items: center; gap: 8px;
		min-height: var(--wk-btn-h-sm); padding: 0 16px;
		border: 1px solid var(--wk-field-line); border-radius: var(--wk-r);
		background: var(--wk-surface); font-weight: 600; font-size: var(--wk-fs); cursor: pointer; list-style: none;
	}
	.wk-filters__toggle::-webkit-details-marker { display: none; }
	.wk-filters[open] .wk-filters__toggle { border-color: var(--wk-ink); }
	.wk-filters__body { margin-top: var(--wk-s4); padding: 0 var(--wk-box-pad); background: var(--wk-surface); border: 1px solid var(--wk-line); border-radius: var(--wk-r-lg); }
	.wk-filter:first-child { padding-top: 20px; }
	ul.products, ul.products.columns-4, .wk-grid.products, .wk-shop-layout--full ul.products { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px 16px; }
}
@media (max-width: 600px) {
	.woocommerce-ordering, .woocommerce-ordering select { width: 100%; }
	.wk-pcard__body { padding: 14px; gap: 6px; }
	.wk-pcard__name { font-size: var(--wk-fs-s); }
	.wk-pcard__meta { display: none; }
	.wk-pcard__foot { flex-direction: column; gap: 2px; }
}

/* Single product ----------------------------------------------------------- */
.single-product div.product { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 56px; align-items: start; }
.single-product div.product > .woocommerce-product-gallery,
.single-product div.product > .images { grid-column: 1; position: sticky; top: 150px; margin: 0; }
.single-product div.product > .summary { grid-column: 2; margin: 0; }
.single-product div.product > .woocommerce-tabs,
.single-product div.product > .related,
.single-product div.product > .upsells,
.single-product div.product > section { grid-column: 1 / -1; }
.single-product .onsale { position: absolute; top: 16px; left: 16px; z-index: 2; padding: 6px 10px; border-radius: var(--wk-r-pill); background: var(--wk-ink); color: var(--wk-on-dark); font-size: var(--wk-fs-xs); font-weight: 600; }

.woocommerce-product-gallery { position: relative; }
.woocommerce-product-gallery__wrapper { margin: 0; }
.woocommerce-product-gallery__image { border-radius: var(--wk-r-xl); background: var(--wk-tile); box-shadow: var(--wk-shadow-1); overflow: hidden; }
.woocommerce-product-gallery__image img { width: 100%; height: auto; mix-blend-mode: multiply; }
.woocommerce-product-gallery .flex-control-thumbs { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 10px; margin: 12px 0 0; padding: 0; list-style: none; }
.woocommerce-product-gallery .flex-control-thumbs li { border-radius: var(--wk-r-md); background: var(--wk-tile); overflow: hidden; cursor: pointer; }
.woocommerce-product-gallery .flex-control-thumbs img { mix-blend-mode: multiply; opacity: .7; transition: opacity var(--wk-d-fast) ease; }
.woocommerce-product-gallery .flex-control-thumbs img.flex-active, .woocommerce-product-gallery .flex-control-thumbs img:hover { opacity: 1; }
.woocommerce-product-gallery__trigger { position: absolute; top: 16px; right: 16px; z-index: 3; display: flex; align-items: center; justify-content: center; width: 44px; height: 44px; border-radius: 50%; background: var(--wk-surface); box-shadow: var(--wk-shadow-1); font-size: 0; text-decoration: none; }
.woocommerce-product-gallery__trigger::before { content: ""; width: 20px; height: 20px; background: var(--wk-ink); -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.75' stroke-linecap='round'%3E%3Cpath d='M3 10a7 7 0 1 0 14 0a7 7 0 1 0 -14 0M21 21l-6 -6M7 10h6M10 7v6'/%3E%3C/svg%3E") center / contain no-repeat; mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.75' stroke-linecap='round'%3E%3Cpath d='M3 10a7 7 0 1 0 14 0a7 7 0 1 0 -14 0M21 21l-6 -6M7 10h6M10 7v6'/%3E%3C/svg%3E") center / contain no-repeat; }

.product_title { margin: 0 0 12px; font-size: 48px; line-height: 1; }
.summary .price { margin: 0 0 var(--wk-s5); font-size: 22px; font-weight: 600; color: var(--wk-ink); }
.price del { color: var(--wk-muted); font-weight: 400; margin-right: 6px; }
.price ins { text-decoration: none; }
.woocommerce-product-details__short-description { color: var(--wk-ink-3); }
.summary .stock { font-weight: 500; font-size: var(--wk-fs); }
.summary .stock.in-stock { color: var(--wk-green); }
.summary .stock.out-of-stock { color: var(--wk-muted); }

form.cart { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin: var(--wk-s6) 0; padding-top: var(--wk-s6); border-top: 1px solid var(--wk-line-mid); }
form.cart .quantity input { width: 88px; text-align: center; font-weight: 600; }
form.cart .single_add_to_cart_button { flex: 1 1 220px; min-height: 52px; }
table.variations { margin: 0 0 var(--wk-s4); }
table.variations th, table.variations td { padding: 8px 0; border: 0; vertical-align: middle; }
table.variations th { width: 120px; color: var(--wk-ink); font-size: var(--wk-fs); }
.reset_variations { display: inline-block; margin-top: 8px; font-size: var(--wk-fs-s); }
.single_variation_wrap { width: 100%; }
.woocommerce-variation-price { margin-bottom: 12px; }

.product_meta { display: flex; flex-direction: column; gap: 4px; padding-top: var(--wk-s4); border-top: 1px solid var(--wk-line-mid); font-size: var(--wk-fs-s); color: var(--wk-muted); }
.product_meta a { color: var(--wk-ink-2); }

/* Tabs: underline like the menus */
.woocommerce-tabs { margin-top: var(--wk-s10); }
.woocommerce-tabs ul.tabs { display: flex; gap: var(--wk-s8); margin: 0 0 var(--wk-s6); padding: 0 0 1px; list-style: none; border-bottom: 1px solid var(--wk-line); overflow-x: auto; overflow-y: hidden; }
.woocommerce-tabs ul.tabs li a { position: relative; display: inline-block; padding: 12px 0; color: var(--wk-ink); font-weight: 500; text-decoration: none; white-space: nowrap; }
.woocommerce-tabs ul.tabs li a::after { content: ""; position: absolute; left: 50%; right: 50%; bottom: -1px; height: 2px; background: var(--wk-orange); transition: left var(--wk-d) ease, right var(--wk-d) ease; }
.woocommerce-tabs ul.tabs li a:hover::after { left: 0; right: 0; }
.woocommerce-tabs ul.tabs li.active a { color: var(--wk-orange); font-weight: 600; }
.woocommerce-Tabs-panel { max-width: 820px; }
.woocommerce-Tabs-panel > h2:first-child { display: none; }
.woocommerce-product-attributes th { width: 200px; color: var(--wk-ink); }

.related > h2, .upsells > h2 { margin: var(--wk-s16) 0 var(--wk-s6); }

@media (max-width: 1000px) {
	.single-product div.product { grid-template-columns: minmax(0, 1fr); gap: var(--wk-s6); }
	.single-product div.product > .woocommerce-product-gallery,
	.single-product div.product > .images,
	.single-product div.product > .summary { grid-column: 1; position: static; }
	.product_title { font-size: 36px; }
}

/* Category pages: short text and questions below the products */
.wk-cat-intro { max-width: 68ch; margin: var(--wk-s12, 48px) 0 0; color: var(--wk-muted, #5A5F63); }
.wk-cat-intro p { margin: 0; }
.wk-cat-intro + .wk-cat-faq { margin-top: var(--wk-s8, 32px); }
.wk-cat-faq { max-width: 820px; margin: var(--wk-s12, 48px) 0 0; }
.wk-cat-faq h2 { margin: 0 0 var(--wk-s4, 16px); }
