/* Vitalment Content Manager – product listings (shop, categories, tags). Matches homepage cards. */

body.vcm-shop {
	--vm-teal: #03474b;
	--vm-teal-d: #02363a;
	--vm-mint: #d0ecde;
	--vm-mint-l: #eef6f2;
	--vm-ink: #143234;
	--vm-muted: #5f7b76;
	--vm-line: #dde8e3;
	--vm-r: 18px;
	--vm-serif: "Cormorant Infant", Georgia, serif;
	--vm-sans: Mulish, Arial, sans-serif;
}

/* Space above the page title (theme default 80px on desktop) */
@media (min-width: 768px) { body.vcm-shop .page_content { margin-top: 48px !important; } }

/* Subcategory tiles */
.vcm-subcats { margin: 8px 0 28px; font-family: var(--vm-sans); }
.vcm-subcats-back { display: inline-flex; align-items: center; gap: 8px; margin: 0 0 14px; padding: 0 0 5px; border-bottom: 2px solid var(--vm-mint); font: 800 14px/1 var(--vm-sans); color: var(--vm-teal); text-decoration: none; }
.vcm-subcats-back:hover { border-color: var(--vm-teal); color: var(--vm-teal); }
.vcm-subcats-back-ico { display: inline-flex; transform: rotate(180deg); }
.vcm-subcats-back-ico svg { width: 14px; height: 14px; }
.vcm-subcats-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.vcm-subcat { position: relative; display: flex; flex-direction: column; justify-content: space-between; min-height: 116px; padding: 20px 22px 16px; border-radius: var(--vm-r); overflow: hidden; background: linear-gradient(150deg, #03474b 0%, #0b5d5f 100%); color: #fff; text-decoration: none; transition: transform .2s, box-shadow .2s; box-shadow: 0 14px 30px -22px rgba(3,71,75,.6); }
.vcm-subcat::after { content: ""; position: absolute; right: -40px; top: -40px; width: 120px; height: 120px; border-radius: 50%; background: rgba(208,236,222,.08); pointer-events: none; }
.vcm-subcat:hover { transform: translateY(-3px); color: #fff; box-shadow: 0 20px 40px -24px rgba(3,71,75,.7); }
.vcm-subcat-name { font: 700 34px/1.05 var(--vm-serif); color: #fff; }
.vcm-subcat-meta { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 18px; }
.vcm-subcat-count { font: 700 13px/1.2 var(--vm-sans); color: var(--vm-mint); }
.vcm-subcat-arrow { display: inline-flex; align-items: center; justify-content: center; flex: 0 0 32px; width: 32px; height: 32px; border-radius: 50%; background: #fff; color: var(--vm-teal); }
.vcm-subcat-arrow svg { width: 15px; height: 15px; }
.vcm-subcat.is-current { background: var(--vm-mint); box-shadow: inset 0 0 0 2px var(--vm-teal); }
.vcm-subcat.is-current .vcm-subcat-name { color: var(--vm-teal); }
.vcm-subcat.is-current .vcm-subcat-count { color: var(--vm-teal); }
.vcm-subcat.is-current .vcm-subcat-arrow { background: var(--vm-teal); color: #fff; }

/* Category description (content stays in WooCommerce, only the presentation changes) */
body.vcm-shop .term-description { display: flex; align-items: center; gap: 20px; margin: 0 0 28px !important; padding: 20px 26px !important; background: var(--vm-mint-l) !important; border: 1px solid var(--vm-line) !important; border-radius: var(--vm-r) !important; box-shadow: none !important; text-align: left !important; }
body.vcm-shop .term-description .codevz-product-brands { flex: 0 0 72px; width: 72px; height: 72px; margin: 0 !important; padding: 0 !important; border-radius: 14px; overflow: hidden; background: #fff; }
body.vcm-shop .term-description .codevz-product-brands img { display: block; width: 72px !important; height: 72px !important; max-width: none; object-fit: cover; margin: 0 !important; }
body.vcm-shop .term-description::before, body.vcm-shop .term-description::after { display: none !important; content: none !important; }
body.vcm-shop .term-description p { margin: 0 !important; font: 400 15.5px/1.6 var(--vm-sans) !important; color: var(--vm-muted) !important; text-align: left !important; }

/* Toolbar: result count, sorting, per page */
body.vcm-shop .page_content .woocommerce-result-count { float: left; margin: 0 0 22px !important; padding: 0 !important; background: none !important; border: 0 !important; box-shadow: none !important; line-height: 46px !important; font: 600 14px/46px var(--vm-sans) !important; color: var(--vm-muted) !important; text-align: left !important; width: auto !important; }
body.vcm-shop .page_content form.woocommerce-ordering, body.vcm-shop .page_content form.codevz-products-per-page { float: right; margin: 0 0 22px 10px !important; width: auto !important; }
body.vcm-shop .page_content form.woocommerce-ordering select, body.vcm-shop .page_content form.codevz-products-per-page select { height: 46px; min-width: 190px; margin: 0 !important; padding: 0 40px 0 18px !important; border: 1px solid var(--vm-line) !important; border-radius: 999px !important; background-color: #fff !important; box-shadow: none !important; font: 600 14px/1 var(--vm-sans) !important; color: var(--vm-ink) !important; }
body.vcm-shop .page_content form.codevz-products-per-page select { min-width: 150px; }
body.vcm-shop .page_content ul.products { clear: both; }

/* Product cards */
body.vcm-shop .page_content ul.products { display: grid !important; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 22px; margin: 0 0 36px !important; padding: 0 !important; }
body.vcm-shop .page_content ul.products::before, body.vcm-shop .page_content ul.products::after { display: none !important; content: none !important; }
body.vcm-shop .page_content ul.products li.product { width: auto !important; min-width: 0; margin: 0 !important; float: none !important; clear: none !important; padding: 12px 12px 16px !important; background: #fff !important; border: 1px solid var(--vm-line) !important; border-radius: var(--vm-r) !important; box-shadow: 0 10px 30px -20px rgba(3,71,75,.28) !important; display: flex !important; flex-direction: column; text-align: left !important; position: relative; transition: transform .2s, box-shadow .2s; font-family: var(--vm-sans); }
body.vcm-shop .page_content ul.products li.product::before, body.vcm-shop .page_content ul.products li.product::after { display: none !important; }
body.vcm-shop .page_content ul.products li.product, body.vcm-shop .page_content ul.products li.product * { box-sizing: border-box !important; }
body.vcm-shop .page_content ul.products li.product:hover { transform: translateY(-3px); box-shadow: 0 18px 40px -22px rgba(3,71,75,.45) !important; }
body.vcm-shop .page_content li.product a.woocommerce-LoopProduct-link { display: flex !important; flex-direction: column; flex: 1 1 auto; color: inherit; text-decoration: none; padding: 0 !important; margin: 0 !important; background: none !important; }
body.vcm-shop .page_content li.product .xtra-product-thumbnail { position: relative !important; aspect-ratio: 1 / 1; border-radius: 12px !important; overflow: hidden; background: #f3f6f4 !important; margin: 0 0 14px !important; padding: 0 !important; top: auto !important; transform: none !important; box-shadow: none !important; width: 100% !important; }
body.vcm-shop .page_content li.product .xtra-product-thumbnail img { width: 100% !important; height: 100% !important; object-fit: cover; margin: 0 !important; border-radius: 0 !important; box-shadow: none !important; transform: none !important; }
body.vcm-shop .page_content li.product span.onsale { position: absolute !important; top: 10px !important; left: 10px !important; right: auto !important; bottom: auto !important; width: auto !important; height: auto !important; min-width: 0 !important; min-height: 0 !important; line-height: 1 !important; padding: 7px 10px !important; margin: 0 !important; border-radius: 999px !important; background: var(--vm-teal) !important; color: #fff !important; font: 800 12px/1 var(--vm-sans) !important; z-index: 3; box-shadow: none !important; }
body.vcm-shop .page_content li.product span.onsale::before { content: "−"; }
body.vcm-shop .page_content li.product .woocommerce-loop-product__title { position: relative !important; display: -webkit-box !important; -webkit-box-orient: vertical; -webkit-line-clamp: 3; overflow: hidden; font: 700 15.5px/1.4 var(--vm-sans) !important; color: var(--vm-ink) !important; margin: 0 0 12px !important; padding: 20px 0 0 !important; text-align: left !important; letter-spacing: 0 !important; text-transform: none !important; min-height: calc(2 * 1.4em + 20px); }
body.vcm-shop .page_content li.product .codevz-product-category-after-title { position: absolute !important; top: 0; left: 0; right: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; display: block !important; font: 700 10.5px/1.4 var(--vm-sans) !important; letter-spacing: .1em; text-transform: uppercase; color: #86a29b !important; margin: 0 !important; opacity: 1 !important; }
body.vcm-shop .page_content li.product .star-rating { display: none !important; }
body.vcm-shop .page_content li.product .price { position: static !important; display: flex !important; flex-wrap: wrap; align-items: baseline; gap: 4px 10px; margin: auto 0 14px !important; padding: 0 !important; background: none !important; box-shadow: none !important; border-radius: 0 !important; font: 800 19px/1.2 var(--vm-sans) !important; color: var(--vm-teal) !important; text-align: left !important; transform: none !important; width: auto !important; height: auto !important; top: auto !important; right: auto !important; left: auto !important; }
body.vcm-shop .page_content li.product .price del { order: 2; font-size: 14px !important; font-weight: 400 !important; color: #7f9792 !important; opacity: 1 !important; }
body.vcm-shop .page_content li.product .price del .amount, body.vcm-shop .page_content li.product .price del bdi { color: inherit !important; font: inherit !important; }
body.vcm-shop .page_content li.product .price ins { order: 1; text-decoration: none !important; background: none !important; color: inherit !important; font-weight: 800 !important; }
body.vcm-shop .page_content li.product .price .amount, body.vcm-shop .page_content li.product .price bdi { color: inherit !important; }
body.vcm-shop .page_content li.product a.button, body.vcm-shop .page_content li.product a.added_to_cart { position: static !important; display: flex !important; align-items: center; justify-content: center; gap: 8px; width: 100% !important; margin: 0 !important; min-height: 46px; padding: 0 12px !important; border-radius: 999px !important; background: var(--vm-teal) !important; color: #fff !important; font: 800 14px/1 var(--vm-sans) !important; opacity: 1 !important; visibility: visible !important; transform: none !important; box-shadow: none !important; border: 0 !important; text-transform: none !important; letter-spacing: 0 !important; }
body.vcm-shop .page_content li.product a.button:hover { background: var(--vm-teal-d) !important; }
body.vcm-shop .page_content li.product a.added_to_cart { margin-top: 8px !important; background: var(--vm-mint) !important; color: var(--vm-teal) !important; }
body.vcm-shop .page_content li.product .xtra-product-icons { z-index: 4; }

/* Pagination */
body.vcm-shop .woocommerce-pagination ul.page-numbers { display: flex !important; flex-wrap: wrap; justify-content: center; gap: 8px; border: 0 !important; margin: 0 0 20px !important; }
body.vcm-shop .woocommerce-pagination ul.page-numbers li { border: 0 !important; float: none !important; margin: 0 !important; }
body.vcm-shop .woocommerce-pagination .page-numbers a, body.vcm-shop .woocommerce-pagination .page-numbers span { display: inline-flex !important; align-items: center; justify-content: center; min-width: 44px; height: 44px; padding: 0 12px !important; border-radius: 999px !important; border: 1px solid var(--vm-line) !important; background: #fff !important; color: var(--vm-teal) !important; font: 800 14px/1 var(--vm-sans) !important; box-shadow: none !important; }
body.vcm-shop .woocommerce-pagination .page-numbers span.current, body.vcm-shop .woocommerce-pagination .page-numbers a:hover { background: var(--vm-teal) !important; border-color: var(--vm-teal) !important; color: #fff !important; }

/* Tablet */
@media (max-width: 1024px) {
	.vcm-subcat-name { font-size: 28px; }
}

/* Mobile */
@media (max-width: 767px) {
	.vcm-subcats { margin: 0 0 20px; }
	.vcm-subcats-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
	.vcm-subcat { min-height: 92px; padding: 14px 14px 12px; border-radius: 14px; }
	.vcm-subcat-name { font-size: 25px; }
	.vcm-subcat-meta { margin-top: 12px; }
	.vcm-subcat-count { font-size: 12px; }
	.vcm-subcat-arrow { flex-basis: 28px; width: 28px; height: 28px; }

	body.vcm-shop .term-description { padding: 16px 18px !important; gap: 14px; margin-bottom: 20px !important; }
	body.vcm-shop .term-description .codevz-product-brands { display: none; }
	body.vcm-shop .term-description p { font-size: 14.5px !important; line-height: 1.55 !important; }

	body.vcm-shop .page_content .woocommerce-result-count { float: none; width: 100% !important; line-height: 1.3 !important; margin-bottom: 12px !important; }
	body.vcm-shop .page_content form.woocommerce-ordering, body.vcm-shop .page_content form.codevz-products-per-page { float: left; width: calc(50% - 5px) !important; margin: 0 0 18px !important; }
	body.vcm-shop .page_content form.woocommerce-ordering { width: calc(58% - 5px) !important; }
	body.vcm-shop .page_content form.codevz-products-per-page { width: calc(42% - 5px) !important; margin-left: 10px !important; }
	body.vcm-shop .page_content form.woocommerce-ordering select, body.vcm-shop .page_content form.codevz-products-per-page select { width: 100% !important; min-width: 0; height: 44px; padding: 0 28px 0 14px !important; font-size: 12.5px !important; text-overflow: ellipsis; }

	body.vcm-shop .page_content ul.products { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
	body.vcm-shop .page_content ul.products li.product { padding: 8px 8px 10px !important; border-radius: 14px !important; }
	body.vcm-shop .page_content li.product .xtra-product-thumbnail { margin-bottom: 10px !important; border-radius: 10px !important; }
	body.vcm-shop .page_content li.product .woocommerce-loop-product__title { font-size: 13.5px !important; line-height: 1.38 !important; padding-top: 17px !important; margin-bottom: 8px !important; min-height: calc(2 * 1.38em + 17px); }
	body.vcm-shop .page_content li.product .codevz-product-category-after-title { font-size: 9.5px !important; }
	body.vcm-shop .page_content li.product .price { font-size: 16px !important; gap: 2px 8px; margin-bottom: 10px !important; }
	body.vcm-shop .page_content li.product .price del { font-size: 12.5px !important; }
	body.vcm-shop .page_content li.product a.button { min-height: 40px; font-size: 12.5px !important; padding: 0 8px !important; }
	body.vcm-shop .page_content li.product span.onsale { top: 7px !important; left: 7px !important; padding: 6px 8px !important; font-size: 11px !important; }
	body.vcm-shop .page_content li.product .xtra-product-icons { display: none !important; }
}

/* Sold out cards: the discount badge moves aside so it never collides with the theme label. */
body.vcm-shop .page_content li.product.outofstock span.onsale { top: auto !important; bottom: 10px !important; left: 10px !important; right: auto !important; background: #7f9792 !important; }
body.vcm-shop .page_content li.product.outofstock .xtra-product-thumbnail::after,
body.vcm-shop .page_content li.product.outofstock .xtra-product-thumbnail::before { z-index: 2; }

/* Checkout: back to cart */
body.vcm-checkout .vcm-back-to-cart { margin: 0 0 18px !important; font-family: Mulish, Arial, sans-serif; }
body.vcm-checkout .vcm-back-to-cart a { display: inline-flex; align-items: center; gap: 8px; padding: 0 0 5px; border-bottom: 2px solid #d0ecde; font: 800 14px/1 Mulish, Arial, sans-serif; color: #03474b !important; text-decoration: none; }
body.vcm-checkout .vcm-back-to-cart a:hover { border-color: #03474b; }
body.vcm-checkout .vcm-back-ico { display: inline-flex; transform: rotate(180deg); }
body.vcm-checkout .vcm-back-ico svg { width: 14px; height: 14px; }

/* ================================================================
   VISUAL DIRECTION v2 – listings match the homepage store look.
   ================================================================ */
body.vcm-shop { --vm-r: 10px; --vm-line: #e2e9e8; }
body.vcm-shop .page_content ul.products { gap: 16px; }
body.vcm-shop .page_content ul.products li.product { border-radius: 10px !important; padding: 10px 10px 14px !important; box-shadow: none !important; }
body.vcm-shop .page_content ul.products li.product:hover { box-shadow: 0 12px 26px -20px rgba(3,71,75,.5) !important; }
body.vcm-shop .page_content li.product .xtra-product-thumbnail { border-radius: 8px !important; margin-bottom: 12px !important; }
body.vcm-shop .page_content li.product span.onsale { border-radius: 6px !important; font-size: 11.5px !important; padding: 6px 9px !important; }
body.vcm-shop .page_content li.product .woocommerce-loop-product__title { font-size: 15px !important; }
body.vcm-shop .page_content li.product .price { font-size: 18px !important; }
body.vcm-shop .page_content li.product a.button, body.vcm-shop .page_content li.product a.added_to_cart { border-radius: 8px !important; min-height: 44px; font-size: 13.5px !important; }

/* Subcategory tiles: product hierarchy, not decoration. */
.vcm-subcats-grid { gap: 12px; }
.vcm-subcat { min-height: 96px; padding: 16px 18px 14px; border-radius: 10px; background: linear-gradient(140deg, #03474b 0%, #0a565a 100%); box-shadow: none; }
.vcm-subcat::after { display: none; }
.vcm-subcat:hover { transform: none; box-shadow: 0 12px 26px -20px rgba(3,71,75,.6); }
.vcm-subcat-name { font: 800 22px/1.1 var(--vm-sans); letter-spacing: -.01em; }
.vcm-subcat-meta { margin-top: 12px; }
.vcm-subcat-count { font-size: 12.5px; }
.vcm-subcat-arrow { flex: 0 0 28px; width: 28px; height: 28px; border-radius: 8px; }
.vcm-subcat.is-current { background: #eef4f3; box-shadow: inset 0 0 0 2px var(--vm-teal); }
.vcm-subcats-back { font-size: 13px; }

/* Category description and toolbar. */
body.vcm-shop .term-description { border-radius: 10px !important; background: #f5f8f8 !important; padding: 16px 20px !important; }
body.vcm-shop .term-description p { font-size: 15px !important; }
body.vcm-shop .term-description .codevz-product-brands { flex-basis: 56px; width: 56px; height: 56px; border-radius: 8px; }
body.vcm-shop .term-description .codevz-product-brands img { width: 56px !important; height: 56px !important; }
body.vcm-shop .page_content form.woocommerce-ordering select, body.vcm-shop .page_content form.codevz-products-per-page select { height: 44px; border-radius: 8px !important; font-size: 13.5px !important; }
body.vcm-shop .page_content .woocommerce-result-count { line-height: 44px !important; font-size: 13.5px !important; }
body.vcm-shop .woocommerce-pagination .page-numbers a, body.vcm-shop .woocommerce-pagination .page-numbers span { border-radius: 8px !important; min-width: 42px; height: 42px; }
body.vcm-checkout .vcm-back-to-cart a { font-size: 13.5px; }

@media (max-width: 767px) {
	.vcm-subcat { min-height: 80px; padding: 12px 12px 10px; }
	.vcm-subcat-name { font-size: 18px; }
	body.vcm-shop .page_content ul.products { gap: 10px; }
	body.vcm-shop .page_content li.product .woocommerce-loop-product__title { font-size: 13.5px !important; }
	body.vcm-shop .page_content li.product .price { font-size: 16px !important; }
}

