.cpc-product-archive,
.cpc-single-product {
	max-width: 1180px;
	margin: 0 auto;
	padding: 2rem 1rem 3rem;
}

.cpc-archive-header,
.cpc-product-header {
	margin-bottom: 1.75rem;
}

.cpc-archive-header h1,
.cpc-product-header h1 {
	margin: 0;
	line-height: 1.15;
}

.cpc-catalogue-filters {
	display: flex;
	flex-wrap: wrap;
	gap: .75rem;
	align-items: center;
	margin: 0 0 1.5rem;
}

.cpc-catalogue-filters input,
.cpc-catalogue-filters select,
.cpc-quote-form input,
.cpc-quote-form textarea {
	box-sizing: border-box;
	min-height: 2.7rem;
	padding: .55rem .7rem;
	border: 1px solid #cbd5e1;
	border-radius: .4rem;
	background: #fff;
	color: inherit;
}

/* Base Universal Product Grid */
.cpc-products-grid {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 1.5rem;
	margin: 1.5rem 0;
}

/* Dynamic Desktop Breakpoints */
.cpc-products-grid[data-columns="1"] { grid-template-columns: repeat(1, minmax(0, 1fr)); }
.cpc-products-grid[data-columns="2"] { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.cpc-products-grid[data-columns="3"] { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.cpc-products-grid[data-columns="4"] { grid-template-columns: repeat(4, minmax(0, 1fr)); }

/* Dynamic Tablet Breakpoints */
@media (max-width: 1024px) {
	.cpc-products-grid[data-columns-tablet="1"] { grid-template-columns: repeat(1, minmax(0, 1fr)); }
	.cpc-products-grid[data-columns-tablet="2"] { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.cpc-products-grid[data-columns-tablet="3"] { grid-template-columns: repeat(3, minmax(0, 1fr)); }
	.cpc-products-grid[data-columns-tablet="4"] { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

/* Dynamic Mobile Breakpoints */
@media (max-width: 767px) {
	.cpc-products-grid[data-columns-mobile="1"] { grid-template-columns: repeat(1, minmax(0, 1fr)); }
	.cpc-products-grid[data-columns-mobile="2"] { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.cpc-products-grid[data-columns-mobile="3"] { grid-template-columns: repeat(3, minmax(0, 1fr)); }
	.cpc-products-grid[data-columns-mobile="4"] { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

/* Universal Product Card */
.cpc-product-card {
	display: flex;
	flex-direction: column;
	overflow: hidden;
	border: 1px solid #e2e8f0;
	border-radius: 12px;
	background: #fff;
	box-shadow: 0 5px 20px rgba(15, 23, 42, .06);
}

.cpc-product-image {
	display: block;
	aspect-ratio: 4 / 3;
	background: #f8fafc;
	border-bottom: 1px solid #e2e8f0;
}

/* Enforced Contain Presentation to prevent cropping globally */
.cpc-product-image img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: contain;
	padding: 12px;
	box-sizing: border-box;
}

.cpc-product-card__content { display: flex; flex: 1; flex-direction: column; padding: 1.15rem; }
.cpc-product-card__title { margin: .15rem 0 .65rem; font-size: 1.2rem; line-height: 1.3; }
.cpc-product-card__title a { color: inherit; text-decoration: none; }
.cpc-product-categories { margin: 0 0 .4rem; font-size: .86rem; color: #64748b; }
.cpc-product-categories a { color: inherit; }
.cpc-product-excerpt { margin: .6rem 0; color: #475569; }
.cpc-product-badges { display: flex; flex-wrap: wrap; gap: .35rem; margin: .5rem 0; }
.cpc-product-badge { display: inline-flex; align-items: center; padding: .25rem .5rem; border-radius: 999px; background: #dbeafe; color: #1e3a8a; font-size: .8rem; font-weight: 700; }
.cpc-product-packaging { margin: .5rem 0; color: #475569; font-size: .9rem; }

.cpc-product-actions {
	display: flex;
	flex-wrap: nowrap;
	align-items: center;
	gap: .6rem;
	margin-top: 1rem;
}
.cpc-product-actions > .cpc-button { flex: 1 1 auto; width: auto; min-width: 0; }
.cpc-product-card .cpc-product-actions { margin-top: auto; }

.cpc-button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 2.5rem;
	box-sizing: border-box;
	padding: .55rem .85rem;
	border: 1px solid transparent;
	border-radius: .45rem;
	font: inherit;
	font-weight: 600;
	line-height: 1.2;
	text-align: center;
	text-decoration: none;
	cursor: pointer;
}

.cpc-button-primary { background: #1d4ed8; color: #fff; }
.cpc-button-secondary { background: #fff; color: #1e3a8a; border-color: #93c5fd; }
.cpc-button-whatsapp { background: #128c4a; color: #fff; }
.cpc-button-outline { background: transparent; color: #334155; border-color: #cbd5e1; }
.cpc-button.is-added { background: #dcfce7; color: #166534; border-color: #86efac; cursor: default; }
.cpc-button:hover, .cpc-button:focus { filter: brightness(.95); }

.cpc-product-detail { max-width: 900px; }
.cpc-product-gallery {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
	gap: .8rem;
	margin: 1.25rem 0 2rem;
}

.cpc-product-gallery a { display: block; overflow: hidden; border-radius: .6rem; background: #f8fafc; }
.cpc-product-gallery img { display: block; width: 100%; aspect-ratio: 1 / 1; object-fit: cover; }
.cpc-product-content { margin: 1.5rem 0; }
.cpc-product-section { margin: 2.5rem 0; }
.cpc-product-section h2 { margin-bottom: 1rem; }
.cpc-product-options ul { display: flex; flex-wrap: wrap; gap: .5rem; padding: 0; list-style: none; }
.cpc-product-options li { padding: .45rem .7rem; border: 1px solid #cbd5e1; border-radius: .4rem; background: #f8fafc; }
.cpc-specifications table { width: 100%; border-collapse: collapse; }
.cpc-specifications th, .cpc-specifications td { padding: .75rem; border-bottom: 1px solid #e2e8f0; text-align: left; vertical-align: top; }
.cpc-specifications th { width: 35%; color: #334155; }
.cpc-product-video iframe { max-width: 100%; }
.cpc-native-video { display: block; width: 100%; max-width: 900px; height: auto; }
.cpc-responsive-video { position: relative; height: 0; overflow: hidden; padding-bottom: 56.25%; }
.cpc-responsive-video iframe { position: absolute; inset: 0; width: 100%; height: 100%; }
.cpc-panorama img { display: block; max-width: 100%; border-radius: .6rem; }
.cpc-quote-items { padding-left: 1.25rem; }
.cpc-empty { padding: 1rem; border-radius: .5rem; background: #f8fafc; }
.cpc-quote-form { max-width: 620px; }
.cpc-quote-form label { display: grid; gap: .35rem; font-weight: 600; }
.cpc-quote-form input, .cpc-quote-form textarea { width: 100%; font-weight: 400; }
.cpc-quote-honeypot { position: absolute; left: -9999px; }
.cpc-notice { padding: .75rem 1rem; border-radius: .4rem; }
.cpc-notice-success { background: #dcfce7; color: #166534; }
.cpc-notice-error { background: #fee2e2; color: #991b1b; }
.cpc-quote-items li { margin: .5rem 0; }
.cpc-quote-whatsapp { margin: .75rem 0; }
.cpc-quote-remove { margin-left: .5rem; border: 0; background: transparent; color: #b91c1c; text-decoration: underline; cursor: pointer; }
.cpc-quote-fab { position: fixed; right: 1.25rem; bottom: 1.25rem; z-index: 9990; min-height: 3.25rem; padding: .75rem 1rem; border: 0; border-radius: 999px; background: #1d4ed8; color: #fff; font: inherit; font-weight: 700; box-shadow: 0 10px 28px rgba(30, 64, 175, .35); cursor: pointer; }
.cpc-quote-fab span { display: inline-grid; min-width: 1.45rem; height: 1.45rem; margin-left: .3rem; place-items: center; border-radius: 50%; background: #fff; color: #1d4ed8; font-size: .8rem; }
.cpc-quote-drawer { position: fixed; top: 0; right: 0; z-index: 9999; width: min(420px, 100vw); height: 100vh; box-sizing: border-box; overflow-y: auto; padding: 1.25rem; background: #fff; box-shadow: -12px 0 32px rgba(15, 23, 42, .2); transform: translateX(105%); transition: transform .2s ease; }
.cpc-quote-drawer.is-open { transform: translateX(0); }
.cpc-quote-drawer__header { display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid #e2e8f0; }
.cpc-quote-drawer .cpc-quote-drawer__header > button { display: flex !important; flex: 0 0 40px; align-items: center; justify-content: center; width: 40px; height: 40px; box-sizing: border-box; padding: 0; border: 0; background: transparent; color: #000 !important; font-family: Arial, sans-serif; font-size: 32px !important; font-weight: 700 !important; line-height: 1 !important; text-indent: 0 !important; opacity: 1 !important; overflow: visible; cursor: pointer; }
.cpc-quote-drawer .cpc-quote-drawer__header > button::before,
.cpc-quote-drawer .cpc-quote-drawer__header > button::after { display: none !important; content: none !important; }
.cpc-quote-toast { position: fixed; right: 1.25rem; bottom: 5.25rem; z-index: 10000; max-width: 290px; padding: .8rem 1rem; border-radius: .5rem; background: #0f172a; color: #fff; box-shadow: 0 8px 24px rgba(15, 23, 42, .25); }
.cpc-quote-toast__link { margin-left: .5rem; border: 0; background: transparent; color: #bfdbfe; font: inherit; font-weight: 700; text-decoration: underline; cursor: pointer; }
.cpc-product-detail .cpc-product-actions { position: sticky; bottom: .75rem; z-index: 20; padding: .65rem; border: 1px solid #e2e8f0; border-radius: .6rem; background: rgba(255, 255, 255, .95); box-shadow: 0 5px 20px rgba(15, 23, 42, .12); }
.cpc-breadcrumbs { margin: 0 0 1rem; font-size: .9rem; color: #64748b; }
.nav-links { display: flex; flex-wrap: wrap; gap: .45rem; margin: 1.5rem 0; }
.nav-links .page-numbers { display: inline-flex; min-width: 2.4rem; min-height: 2.4rem; align-items: center; justify-content: center; padding: 0 .6rem; border: 1px solid #cbd5e1; border-radius: .4rem; text-decoration: none; }

.cpc-lightbox {
	position: fixed;
	inset: 0;
	z-index: 99999;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 1rem;
	background: rgba(2, 6, 23, .9);
}

.cpc-lightbox img { max-width: 96vw; max-height: 92vh; object-fit: contain; }
.cpc-lightbox button { position: absolute; top: 1rem; right: 1rem; border: 0; background: transparent; color: #fff; font-size: 2rem; cursor: pointer; }

@media (max-width: 420px) {
	.cpc-product-actions { flex-wrap: wrap; }
	.cpc-product-actions > .cpc-button { flex: 1 1 calc(50% - .3rem); }
}

@media (max-width: 560px) {
	.cpc-catalogue-filters > * { width: 100%; }
	.cpc-specifications th { width: 42%; }
}

/* ==========================================================================
   v4.1.0 - Homepage Showcase Extensions
   ========================================================================== */

.cpc-showcase-section {
    margin: 40px 0;
}

.cpc-section-title {
    text-align: center;
    margin-bottom: 30px;
}

.cpc-section-title h2 {
    font-size: 1.75em;
    margin: 0;
}

.cpc-view-all-container {
    text-align: center;
    margin-top: 30px;
}

/* Mobile UX: Native App-like Horizontal Swipe Layout (Applied via .is-showcase modifier class) */
@media (max-width: 767px) {
    .cpc-products-grid.is-showcase {
        display: flex;
        flex-wrap: nowrap;
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        scroll-behavior: smooth;
        -webkit-overflow-scrolling: touch;
        padding-bottom: 16px;
        gap: 16px;
        grid-template-columns: none;
        scroll-padding-left: 16px;
        overscroll-behavior-x: contain;
    }
    
    .cpc-products-grid.is-showcase > * {
        flex: 0 0 85%;
        scroll-snap-align: center;
    }
    
    .cpc-products-grid.is-showcase::-webkit-scrollbar {
        display: none;
    }
    .cpc-products-grid.is-showcase {
        -ms-overflow-style: none;
        scrollbar-width: none;
    }
}