/* MedCare Mobility — LIVE product-archive card redesign 2026-10-16 (Tab). Ported from staging v2, archive part only. Enqueued on shop / product category / tag / attribute / product search pages only (body.mcm-archive-v2). */
:root{--mcm-blue:#013365;--mcm-blue-2:#0a4a8a;--mcm-blue-soft:#edf3fa;--mcm-ink:#182a3d;--mcm-muted:#5f7186;--mcm-line:#e1e8f0;--mcm-bg:#f6f8fb;--mcm-ok:#1f8a4c;--mcm-star:#f5a623;--mcm-r:14px;--mcm-shadow:0 10px 30px rgba(1,51,101,.08)}

/* ---------- shared pieces ---------- */
.mcm-btn{display:inline-flex;align-items:center;justify-content:center;gap:8px;min-height:48px;padding:10px 22px;border-radius:10px;font:600 15px/1.2 inherit;text-decoration:none!important;border:2px solid var(--mcm-blue);transition:background .15s,color .15s;cursor:pointer;white-space:nowrap}
.mcm-btn--primary{background:var(--mcm-blue);color:#fff!important}
.mcm-btn--primary:hover{background:var(--mcm-blue-2);color:#fff}
.mcm-btn--outline{background:#fff;color:var(--mcm-blue)!important}
.mcm-btn--outline:hover{background:var(--mcm-blue-soft)}
.mcm-btn--card{width:100%;min-height:46px;background:var(--mcm-blue);color:#fff!important;font-size:14px;border-color:var(--mcm-blue)}
.mcm-btn--card:hover{background:var(--mcm-blue-2)}
.mcm-bullets{list-style:none;margin:0;padding:0;font-size:13.5px;line-height:1.4;color:var(--mcm-ink)}
.mcm-bullets li{position:relative;padding-left:22px;margin:0 0 6px;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
.mcm-bullets li::before{content:"";position:absolute;left:0;top:3px;width:14px;height:14px;border-radius:50%;background:var(--mcm-ok);-webkit-mask:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><path fill='none' stroke='white' stroke-width='4' stroke-linecap='round' stroke-linejoin='round' d='M5 12l5 5L20 7'/></svg>") center/9px no-repeat,linear-gradient(#000 0 0);-webkit-mask-composite:xor;mask:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><path fill='none' stroke='white' stroke-width='4' stroke-linecap='round' stroke-linejoin='round' d='M5 12l5 5L20 7'/></svg>") center/9px no-repeat,linear-gradient(#000 0 0);mask-composite:exclude}
.mcm-wrap{width:min(100% - 32px,1320px);margin:0 auto}
.mcm-link{color:var(--mcm-blue);font-weight:600;text-decoration:none;white-space:nowrap}
.mcm-link:hover{text-decoration:underline}
/* star rating line: stars + 4.9 + (12 reviews) */
.mcm-rating{display:inline-flex;align-items:center;gap:6px;text-decoration:none!important;color:var(--mcm-muted);font-size:13px;line-height:1.2;min-height:20px}
.mcm-rating .star-rating{margin:0!important;color:var(--mcm-star);font-size:13px;flex:0 0 auto;float:none}
.mcm-rating .star-rating::before{color:#d7dee7}
.mcm-rating__num{font-weight:700;color:var(--mcm-ink)}
.mcm-rating:hover .mcm-rating__count{text-decoration:underline}
/* Affirm's own "As low as $xx/mo" line (filled in by Affirm's script; hidden until it has text) */
.mcm-affirm{margin:0!important;font-size:12.5px;line-height:1.3;color:var(--mcm-muted);min-height:0}
.mcm-affirm:empty{display:none}
.mcm-affirm a{color:var(--mcm-blue)}

/* ============================================================
   PRODUCT ARCHIVE (category / shop) — Porto product grid items
   ============================================================ */
.mcm-archive-v2 .archive-products .porto-tb-item.product{display:flex;flex-direction:column;background:#fff;border:1px solid var(--mcm-line);border-radius:var(--mcm-r);padding:12px;margin-bottom:16px;box-shadow:none;transition:box-shadow .15s;position:relative}
.mcm-archive-v2 .archive-products .porto-tb-item.product:hover{box-shadow:var(--mcm-shadow)}
.mcm-archive-v2 .archive-products .porto-tb-item .product-type-bio,.mcm-archive-v2 .archive-products .porto-tb-item .product-type-advanced{display:flex;flex-direction:column;flex:1 1 auto;position:relative}
.mcm-archive-v2 .archive-products .porto-tb-featured-image{border-radius:10px;overflow:hidden;background:#fff;margin:0;border:1px solid var(--mcm-line)!important}
.mcm-archive-v2 .archive-products .porto-tb-featured-image img{aspect-ratio:1/1;object-fit:contain;width:100%;height:auto}
/* no quick view / add to cart on the archive (Pinny, Sep 4): the short description replaces them; wishlist stays */
.mcm-archive-v2 .archive-products .porto-tb-item .porto-tb-woo-link:not(.porto-tb-wishlist),.mcm-archive-v2 .archive-products .porto-tb-item .porto-tb-woo-buttons:not(.porto-tb-wishlist),.mcm-archive-v2 .archive-products .porto-tb-item .quickview,.mcm-archive-v2 .archive-products .porto-tb-item .add_to_cart_button,.mcm-archive-v2 .archive-products .porto-tb-item .add-links,.mcm-archive-v2 .archive-products .porto-tb-item .porto-tb-addcart,.mcm-archive-v2 .archive-products .porto-tb-item .screen-reader-text{display:none!important}
.mcm-archive-v2 .archive-products .porto-tb-item .product-content{padding-top:12px!important;text-align:left;display:flex;flex-direction:column;flex:1 1 auto;position:static}
.mcm-archive-v2 .archive-products .porto-tb-item .tb-meta-product_cat{display:none!important}
.mcm-archive-v2 .archive-products .porto-tb-item .post-title{font-size:15px!important;line-height:1.35!important;font-weight:600!important;letter-spacing:0!important;text-align:left!important;margin:0 0 6px!important;display:-webkit-box;-webkit-line-clamp:3;-webkit-box-orient:vertical;overflow:hidden;min-height:calc(15px*1.35*3)}
.mcm-archive-v2 .archive-products .porto-tb-item .post-title a{color:var(--mcm-ink)}
.mcm-archive-v2 .archive-products .porto-tb-item .post-title a:hover{color:var(--mcm-blue)}
.mcm-archive-v2 .archive-products .porto-tb-item .tb-woo-rating{text-align:left;margin:0 0 6px!important;min-height:20px;display:block}
.mcm-archive-v2 .archive-products .porto-tb-item .tb-woo-rating .rating-wrap,.mcm-archive-v2 .archive-products .porto-tb-item .tb-woo-rating .rating-content{display:inline-flex;align-items:center}
.mcm-archive-v2 .archive-products .porto-tb-item .tb-woo-price{text-align:left;margin:0 0 2px!important;font-size:20px!important;font-weight:700;color:var(--mcm-blue);letter-spacing:0!important}
.mcm-archive-v2 .archive-products .porto-tb-item .tb-woo-price .price{color:var(--mcm-blue)}
.mcm-archive-v2 .archive-products .porto-tb-item .tb-woo-price del{font-size:14px;font-weight:400;color:var(--mcm-muted);margin-right:6px}
.mcm-archive-v2 .archive-products .porto-tb-item .tb-woo-price ins{text-decoration:none}
/* wishlist heart: a small white circle in the image's top-right corner, nothing else in the action row */
.mcm-archive-v2 .archive-products .porto-tb-item .custom-action{position:absolute!important;top:0;left:0;right:0;height:0;margin:0!important;padding:0!important;min-height:0;display:block;overflow:visible;z-index:3;border:0;background:none}
.mcm-archive-v2 .archive-products .porto-tb-item .porto-tb-wishlist{display:block!important;position:absolute!important;top:8px;right:8px;left:auto;width:40px!important;height:40px!important;margin:0!important;padding:0!important;border:0!important;background:none!important;border-radius:0!important;opacity:1!important;visibility:visible!important;transform:none!important}
.mcm-archive-v2 .archive-products .porto-tb-item .porto-tb-wishlist .yith-wcwl-add-to-wishlist{margin:0!important;padding:0!important;background:transparent!important;border:0!important;width:40px;height:40px;font-size:0;line-height:0}
.mcm-archive-v2 .archive-products .porto-tb-item .porto-tb-wishlist .yith-wcwl-add-to-wishlist>div,.mcm-archive-v2 .archive-products .porto-tb-item .porto-tb-wishlist .yith-wcwl-add-button,.mcm-archive-v2 .archive-products .porto-tb-item .porto-tb-wishlist .yith-wcwl-wishlistexistsbrowse,.mcm-archive-v2 .archive-products .porto-tb-item .porto-tb-wishlist .yith-wcwl-wishlistaddedbrowse{margin:0!important;padding:0!important;background:none!important;width:40px;height:40px;display:block}
.mcm-archive-v2 .archive-products .porto-tb-item .porto-tb-wishlist a{display:flex!important;align-items:center;justify-content:center;width:40px!important;height:40px!important;padding:0!important;margin:0!important;border-radius:50%!important;background:#fff!important;border:1px solid var(--mcm-line)!important;box-shadow:0 2px 8px rgba(1,51,101,.12);color:var(--mcm-blue)!important;font-size:0!important;line-height:0!important;text-indent:0}
.mcm-archive-v2 .archive-products .porto-tb-item .porto-tb-wishlist a:hover{background:var(--mcm-blue-soft)!important}
.mcm-archive-v2 .archive-products .porto-tb-item .porto-tb-wishlist a::before,.mcm-archive-v2 .archive-products .porto-tb-item .porto-tb-wishlist a::after{display:none!important;content:none!important}
.mcm-archive-v2 .archive-products .porto-tb-item .porto-tb-wishlist svg{width:20px!important;height:20px!important;display:block;margin:0;stroke-width:1.8;fill:none;color:var(--mcm-blue)!important;stroke:currentColor}
.mcm-archive-v2 .archive-products .porto-tb-item .porto-tb-wishlist .yith-wcwl-wishlistexistsbrowse svg,.mcm-archive-v2 .archive-products .porto-tb-item .porto-tb-wishlist .yith-wcwl-wishlistaddedbrowse svg{fill:var(--mcm-blue)}
.mcm-archive-v2 .archive-products .porto-tb-item .porto-tb-wishlist .feedback,.mcm-archive-v2 .archive-products .porto-tb-item .porto-tb-wishlist .yith-wcwl-add-to-wishlist span:not(.yith-wcwl-icon-svg){display:none!important}
/* card body order */
.mcm-archive-v2 .archive-products .mcm-card-extra{display:contents}
.mcm-archive-v2 .archive-products .porto-tb-item .product-content>.tb-meta-product_cat{order:1}
.mcm-archive-v2 .archive-products .porto-tb-item .product-content>.post-title{order:2}
.mcm-archive-v2 .archive-products .porto-tb-item .product-content>.tb-woo-rating{order:3}
.mcm-archive-v2 .archive-products .porto-tb-item .product-content>.tb-woo-price{order:4}
.mcm-archive-v2 .archive-products .porto-tb-item .product-content .mcm-card-extra .mcm-affirm{order:5;margin:0 0 10px!important}
.mcm-archive-v2 .archive-products .porto-tb-item .product-content .mcm-card-extra .mcm-bullets{order:6;margin:0 0 12px;padding-top:10px;border-top:1px solid var(--mcm-line)}
.mcm-archive-v2 .archive-products .porto-tb-item .product-content .mcm-card-extra .mcm-btn--card{order:8;margin-top:auto}
.mcm-archive-v2 .archive-products .porto-tb-item .labels .onsale{background:var(--mcm-ok);color:#fff;font-weight:700;border-radius:8px;padding:4px 8px;font-size:12px}
.mcm-archive-v2 .archive-products .porto-tb-item .labels{z-index:2}
/* mobile: one product per row, image left, name + stars + price + Affirm right, 6 bullets full width, button */
@media (max-width:575.98px){
	.mcm-archive-v2 .archive-products .has-ccols>.porto-tb-item.product{--porto-cw:100%;width:100%!important;max-width:100%!important;flex:0 0 100%!important;margin:0 0 14px!important;padding:12px}
	.mcm-archive-v2 .archive-products .porto-tb-item .product-type-bio,.mcm-archive-v2 .archive-products .porto-tb-item .product-type-advanced{display:grid;grid-template-columns:42% 1fr;grid-template-rows:auto auto auto auto 1fr;column-gap:12px;row-gap:0}
	.mcm-archive-v2 .archive-products .porto-tb-item .product-content{display:contents}
	.mcm-archive-v2 .archive-products .porto-tb-item .porto-tb-featured-image{grid-column:1;grid-row:1/span 5;align-self:start}
	.mcm-archive-v2 .archive-products .porto-tb-item .post-title{grid-column:2;grid-row:1;font-size:15px!important;min-height:0;margin:0 0 4px!important}
	.mcm-archive-v2 .archive-products .porto-tb-item .tb-woo-rating{grid-column:2;grid-row:2;margin:0 0 4px!important;min-height:0}
	.mcm-archive-v2 .archive-products .porto-tb-item .tb-woo-price{grid-column:2;grid-row:3;font-size:19px!important;margin:0!important}
	.mcm-archive-v2 .archive-products .porto-tb-item .product-content .mcm-card-extra .mcm-affirm{grid-column:2;grid-row:4;margin:2px 0 0!important}
	.mcm-archive-v2 .archive-products .porto-tb-item .product-content .mcm-card-extra .mcm-bullets{grid-column:1/-1;grid-row:6;margin:12px 0 12px;padding-top:12px}
	.mcm-archive-v2 .archive-products .porto-tb-item .product-content .mcm-card-extra .mcm-btn--card{grid-column:1/-1;grid-row:7;margin-top:0}
	.mcm-archive-v2 .archive-products .porto-tb-item .hover-image{display:none}
	/* heart sits on the image's top-right: image column is 42% of the card body */
	.mcm-archive-v2 .archive-products .porto-tb-item .porto-tb-wishlist{right:auto;left:calc(42% - 44px);top:4px;width:36px!important;height:36px!important}
	.mcm-archive-v2 .archive-products .porto-tb-item .porto-tb-wishlist .yith-wcwl-add-to-wishlist,.mcm-archive-v2 .archive-products .porto-tb-item .porto-tb-wishlist .yith-wcwl-add-to-wishlist>div,.mcm-archive-v2 .archive-products .porto-tb-item .porto-tb-wishlist a{width:36px!important;height:36px!important}
	.mcm-archive-v2 .archive-products .porto-tb-item .porto-tb-wishlist svg{width:18px!important;height:18px!important}
}
@media (min-width:576px) and (max-width:991.98px){
	.mcm-archive-v2 .archive-products .has-ccols>.porto-tb-item.product{--porto-cw:50%;width:50%!important}
}
/* the custom fixed header (mu-plugin) is 166 px tall on phones / 170 px on tablets on product archives (it carries the
   search row there), but its CSS fallback is 138 px until its script measures it — that 28 px jump was the whole CLS on
   category pages. Pre-set the same value so nothing moves; the script still overrides it with the measured height. */
/* LIVE (measured Oct 16 at 360/390/414/768 px): the header is 146 px on product archives, so pre-set 146 px */
@media (max-width:991.98px){ html:has(body.mcm-archive-v2){--mcm-body-offset:146px} }
/* list view (desktop toggle): all bullets, one per line */
.mcm-archive-v2 .archive-products.list .porto-tb-item .mcm-bullets li,.mcm-archive-v2 .products.list .mcm-bullets li{-webkit-line-clamp:unset}
/* tap targets ≥44px for sorting / filters / pagination on touch */
@media (max-width:991.98px){
	.mcm-archive-v2 .woocommerce-ordering select,.mcm-archive-v2 .woocommerce-pagination a,.mcm-archive-v2 .woocommerce-pagination span,.mcm-archive-v2 .porto-tb-pagination a{min-height:44px;min-width:44px}
}

/* ---------- mobile Filter off-canvas (Pinny Oct 16 6:22 PM: panel went behind the fixed header, no close button) ---------- */
.mcm-filter-head{display:none}
@media (max-width:991.98px){
	html.sidebar-opened body.mcm-archive-v2 #mcm-custom-header-wrap{visibility:hidden!important}
	/* the panel lives inside .column2 (z-index:1), so it can never stack above the fixed header (z 9999): hide the header while the panel is open */
	html.sidebar-opened body.mcm-archive-v2 .mobile-sidebar{top:0!important;height:100%!important;height:100dvh!important;box-shadow:0 0 30px rgba(0,0,0,.25)}
	html.sidebar-opened body.mcm-archive-v2 .mobile-sidebar .sidebar-content{padding-top:0!important;height:100%;overflow-y:auto!important;overscroll-behavior:contain;-webkit-overflow-scrolling:touch}
	body.mcm-archive-v2 .mobile-sidebar .mcm-filter-head{display:flex;position:sticky;top:0;z-index:5;align-items:center;justify-content:space-between;gap:12px;margin:0 -15px 12px;padding:10px 12px 10px 16px;background:#fff;border-bottom:1px solid var(--mcm-line)}
	body.mcm-archive-v2 .mcm-filter-head__title{font:700 17px/1.2 inherit;color:var(--mcm-blue);margin:0}
	body.mcm-archive-v2 .mcm-filter-close{display:inline-flex;align-items:center;justify-content:center;width:44px;height:44px;flex:0 0 44px;border:1px solid var(--mcm-line);border-radius:50%;background:#fff;color:var(--mcm-ink);font-size:22px;line-height:1;cursor:pointer;padding:0}
	body.mcm-archive-v2 .mcm-filter-close:hover,body.mcm-archive-v2 .mcm-filter-close:focus-visible{background:var(--mcm-blue-soft);outline:2px solid var(--mcm-blue);outline-offset:1px}
}

/* ---------- desktop Filter off-canvas (Pinny Oct 20 10:03 AM: on desktop the panel still sat behind the header with no close button) ----------
 * Porto's "Filters" toggle is on at every width on this store, so the sidebar is the same off-canvas panel on desktop
 * (.mobile-sidebar, fixed, inside .column2 z-index:1 -> can never stack above the fixed header). The Oct 16 rules above
 * were limited to max-width 991.98px; this block applies the same treatment at 992px and up. Rollback: delete this block. */
@media (min-width:992px){
	html.sidebar-opened body.mcm-archive-v2 #mcm-custom-header-wrap{visibility:hidden!important}
	html.sidebar-opened body.mcm-archive-v2 .mobile-sidebar{top:0!important;height:100%!important;height:100dvh!important;box-shadow:0 0 30px rgba(0,0,0,.25)}
	html.sidebar-opened body.mcm-archive-v2 .mobile-sidebar .sidebar-content{padding-top:0!important;height:100%;overflow-y:auto!important;overscroll-behavior:contain}
	body.mcm-archive-v2 .mobile-sidebar .mcm-filter-head{display:flex;position:sticky;top:0;z-index:5;align-items:center;justify-content:space-between;gap:12px;margin:0 -12px 12px;padding:10px 12px 10px 16px;background:#fff;border-bottom:1px solid var(--mcm-line)}
	body.mcm-archive-v2 .mcm-filter-head__title{font:700 17px/1.2 inherit;color:var(--mcm-blue);margin:0}
	body.mcm-archive-v2 .mcm-filter-close{display:inline-flex;align-items:center;justify-content:center;width:44px;height:44px;flex:0 0 44px;border:1px solid var(--mcm-line);border-radius:50%;background:#fff;color:var(--mcm-ink);font-size:22px;line-height:1;cursor:pointer;padding:0}
	body.mcm-archive-v2 .mcm-filter-close:hover,body.mcm-archive-v2 .mcm-filter-close:focus-visible{background:var(--mcm-blue-soft);outline:2px solid var(--mcm-blue);outline-offset:1px}
}

/* ===== Mobile/tablet (<992px): ACF category tabs "Read More" toggle left-aligned (Pinny, Oct 20 10:37 AM). Alignment only. Tab 2026-10-20 ===== */
@media (max-width:991.98px){body.mcm-archive-v2 #product-category-tabs a.read-more{text-align:left!important}}
