/* Fresh Drops marketplace — aligned with the investor-demo catalogue. */
:root {
	--cdpx-gold: #d2a728;
	--cdpx-gold-text: #916b0a;
	--cdpx-ink: #202020;
	--cdpx-muted: #747474;
	--cdpx-dim: #9a9895;
	--cdpx-border: #e7e2dc;
	--cdpx-border-strong: #dcd5cc;
}

.cdpx-marketplace,
.cdpx-marketplace * {
	box-sizing: border-box;
}

.cdpx-marketplace {
	display: grid;
	grid-template-columns: 250px minmax(0, 1fr);
	gap: 36px;
	width: 100%;
	padding: 6px 0 72px;
	font-family: "DM Sans", Arial, sans-serif;
	color: var(--cdpx-ink);
}

.cdpx-category-marketplace {
	width: 100%;
	padding: 0 0 72px;
}

.cdpx-filter-panel {
	position: sticky;
	top: 112px;
	align-self: start;
}

.cdpx-filter-form,
.cdpx-filter-group {
	margin: 0;
}

.cdpx-filter-group {
	padding: 0 0 22px;
	margin-bottom: 22px;
	border: 0;
	border-bottom: 1px solid var(--cdpx-border);
}

.cdpx-filter-group label:first-child,
.cdpx-filter-group legend {
	display: block;
	width: 100%;
	padding: 0;
	margin: 0 0 12px;
	font-size: 13px;
	font-weight: 700;
	line-height: 1.3;
	color: var(--cdpx-ink);
}

.cdpx-input,
.cdpx-select {
	width: 100%;
	height: 46px;
	padding: 0 13px;
	border: 1px solid var(--cdpx-border-strong);
	border-radius: 10px;
	background: #fff;
	color: #323232;
	font: 400 14px/1 "DM Sans", Arial, sans-serif;
	box-shadow: none;
}

.cdpx-input:focus,
.cdpx-select:focus {
	outline: 2px solid rgba(210, 167, 40, .24);
	outline-offset: 1px;
	border-color: var(--cdpx-gold);
}

.cdpx-check-option {
	display: flex !important;
	align-items: center;
	gap: 9px;
	width: 100%;
	margin: 0 0 10px !important;
	font-size: 13px !important;
	font-weight: 400 !important;
	color: #484848 !important;
	cursor: pointer;
}

.cdpx-check-option:last-child {
	margin-bottom: 0 !important;
}

.cdpx-check-option input {
	appearance: none;
	width: 16px;
	height: 16px;
	margin: 0;
	border: 1px solid #999;
	border-radius: 50%;
	background: #fff;
	box-shadow: none;
}

.cdpx-check-option input:checked {
	border-color: var(--cdpx-gold-text);
	box-shadow: inset 0 0 0 4px #fff;
	background: var(--cdpx-gold);
}

.cdpx-range-row {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 8px;
}

.cdpx-apply-button,
.cdpx-clear-button,
.cdpx-filter-toggle {
	width: 100%;
	height: 44px;
	border-radius: 10px;
	font: 700 13px/1 "DM Sans", Arial, sans-serif;
	cursor: pointer;
}

.cdpx-apply-button {
	border: 1px solid #111;
	background: #111;
	color: #fff;
}

.cdpx-clear-button {
	margin-top: 9px;
	border: 1px solid var(--cdpx-border-strong);
	background: #fff;
	color: #333;
}

.cdpx-filter-toggle {
	display: none;
}

.cdpx-marketplace__content {
	min-width: 0;
}

.cdpx-marketplace__toolbar {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
	min-height: 46px;
	margin-bottom: 22px;
}

.cdpx-result-count {
	margin: 0;
	font-size: 14px;
	color: var(--cdpx-muted);
}

.cdpx-result-count strong {
	font-weight: 400;
}

.cdpx-toolbar-actions .cdpx-select {
	width: auto;
	min-width: 180px;
}

.cdpx-product-grid {
	display: grid;
	grid-template-columns: repeat(4, minmax(0, 1fr));
	gap: 20px;
}

.cdpx-market-card {
	min-width: 0;
	overflow: hidden;
	border: 1px solid var(--cdpx-border);
	border-radius: 24px;
	background: #fff;
	transition: transform .22s ease, box-shadow .22s ease, border-color .22s ease;
}

.cdpx-market-card:hover {
	transform: translateY(-3px);
	border-color: #d7cda9;
	box-shadow: 0 16px 36px rgba(17, 17, 17, .075);
}

.cdpx-market-card[hidden] {
	display: none !important;
}

.cdpx-market-card__media {
	position: relative;
	width: 100%;
	aspect-ratio: 1 / 1;
	overflow: hidden;
	background: #fff;
}

.cdpx-market-card__media > a:first-child {
	display: block;
	width: 100%;
	height: 100%;
}

.cdpx-market-card__media img {
	display: block;
	width: 100% !important;
	height: 100% !important;
	/* Keep a generous safe area around wide product photography. This is
	 * especially important on narrow phone cards where the source image can
	 * otherwise appear to touch the card edges. */
	padding: 14%;
	object-fit: contain !important;
	object-position: center center !important;
	box-sizing: border-box !important;
	background: #fff;
	transition: transform .4s ease;
}

.cdpx-market-card:hover .cdpx-market-card__media img {
	/* Keep the complete product visible on hover; wide items must never be
	 clipped by a decorative zoom. */
	transform: none;
}

.cdpx-market-card__wishlist {
	position: absolute;
	right: 12px;
	top: 12px;
	display: grid;
	place-items: center;
	width: 38px;
	height: 38px;
	border: 1px solid rgba(255,255,255,.92);
	border-radius: 50%;
	background: rgba(255,255,255,.9);
	backdrop-filter: blur(4px);
}

/* Homepage drop cards remain Elementor-editable while using live catalogue
 * data and the same interaction affordance as category cards. */
.cdpx-home-drop-card { cursor: pointer; }
.cdpx-home-drop-card > .elementor-widget-image img {
	display: block;
	width: 100% !important;
	height: auto !important;
	object-fit: contain !important;
	object-position: center center !important;
	box-sizing: border-box !important;
	border: 0 !important;
	box-shadow: none !important;
}
.cdpx-home-drop-card .elementor-icon-list-icon img {
	display: block;
	width: 32px !important;
	height: 32px !important;
	max-width: 32px !important;
	padding: 0 !important;
	border: 0 !important;
	border-radius: 50% !important;
	object-fit: cover !important;
	object-position: center center !important;
	box-shadow: none !important;
}
.cdpx-home-drop-card .elementor-heading-title {
	font-family: "Poppins", "DM Sans", Arial, sans-serif !important;
	font-size: 18px !important;
	font-weight: 500 !important;
	line-height: 1.15 !important;
	letter-spacing: 0 !important;
}
.cdpx-home-drop-card .elementor-widget-text-editor,
.cdpx-home-drop-card .elementor-heading-title { text-align: left; }
.cdpx-home-drop-card .cdpx-home-drop-seller-link { color: inherit; text-decoration: none; }
.cdpx-home-drop-card .cdpx-home-drop-seller-link:hover { color: #c89a22; }

.cdpx-market-card__wishlist span {
	width: 22px;
	height: 22px;
	background: center / contain no-repeat url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%231d1d1d' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20.8 4.6a5.5 5.5 0 0 0-7.8 0L12 5.6l-1-1a5.5 5.5 0 0 0-7.8 7.8l1 1L12 21l7.8-7.6 1-1a5.5 5.5 0 0 0 0-7.8Z'/%3E%3C/svg%3E");
}

.cdpx-market-card__body {
	display: flex;
	flex-direction: column;
	min-height: 186px;
	padding: 15px;
}

.cdpx-market-card__seller {
	min-width: 0;
	margin-bottom: 9px;
}

.cdpx-market-card__seller-link {
	display: flex;
	align-items: center;
	gap: 8px;
	min-width: 0;
	color: var(--cdpx-muted) !important;
	font-size: 12px;
	line-height: 1.2;
	text-decoration: none !important;
}

.cdpx-market-card__seller-link img {
	flex: 0 0 25px;
	width: 25px !important;
	height: 25px !important;
	padding: 0 !important;
	border-radius: 50% !important;
	object-fit: cover !important;
	object-position: center !important;
	background: #f5f0e7;
}

.cdpx-market-card__seller-link > span:not(.cdpx-market-card__verified) {
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.cdpx-market-card__verified {
	display: inline-grid;
	flex: 0 0 14px;
	place-items: center;
	width: 14px;
	height: 14px;
	border-radius: 50%;
	background: var(--cdpx-gold);
	color: #111;
	font-size: 8px;
	font-weight: 800;
}

.cdpx-market-card__title {
	display: -webkit-box;
	overflow: hidden;
	-webkit-box-orient: vertical;
	-webkit-line-clamp: 2;
	min-height: 42px;
	margin: 0 0 7px;
	font-family: "DM Sans", Arial, sans-serif !important;
	font-size: 16px !important;
	font-weight: 700 !important;
	line-height: 1.32 !important;
	letter-spacing: -.015em;
}

.cdpx-market-card__title a {
	color: var(--cdpx-ink) !important;
	font: inherit !important;
	text-decoration: none !important;
}

.cdpx-market-card__meta {
	display: flex;
	align-items: center;
	gap: 8px;
	margin-bottom: 9px;
	color: var(--cdpx-dim);
	font-size: 12px;
	line-height: 1.3;
}

.cdpx-market-card__dot {
	color: #c7c1b9;
}

.cdpx-market-card__footer {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	margin-top: auto;
}

.cdpx-market-card__price,
.cdpx-market-card__price .woocommerce-Price-amount,
.cdpx-market-card__price bdi {
	font-family: "Poppins", "DM Sans", Arial, sans-serif !important;
	font-size: 18px !important;
	font-weight: 600 !important;
	line-height: 1.1 !important;
	letter-spacing: -.02em !important;
	color: var(--cdpx-gold-text) !important;
	text-decoration: none !important;
}

.cdpx-market-card__cart {
	display: grid !important;
	flex: 0 0 36px;
	place-items: center;
	width: 36px !important;
	height: 36px !important;
	padding: 0 !important;
	border: 1px solid var(--cdpx-border) !important;
	border-radius: 50% !important;
	background: #fff !important;
	box-shadow: none !important;
}

.cdpx-market-card__cart span {
	width: 20px;
	height: 20px;
	background: center / contain no-repeat url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32' fill='none' stroke='%231c1c1c' stroke-width='2.3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M7 11h18l2 17H5l2-17Z'/%3E%3Cpath d='M11 12V8a5 5 0 0 1 10 0v4'/%3E%3C/svg%3E");
}

.cdpx-market-card__cart:hover,
.cdpx-market-card__cart:focus-visible {
	border-color: var(--cdpx-gold) !important;
	background: var(--cdpx-gold) !important;
}

.cdpx-empty-state {
	padding: 80px 20px;
	text-align: center;
}

.cdpx-empty-state h3 {
	margin: 0 0 8px;
	font: 700 24px/1.2 "DM Sans", Arial, sans-serif;
}

.cdpx-empty-state p {
	margin: 0;
	color: var(--cdpx-muted);
}

@media (max-width: 1280px) {
	.cdpx-product-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 1024px) {
	.cdpx-marketplace { grid-template-columns: 210px minmax(0, 1fr); gap: 24px; }
	.cdpx-product-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.cdpx-market-card__media img { padding: 16%; }
	.cdpx-home-drop-card > .elementor-widget-image img { padding: 6% !important; }
}

@media (max-width: 767px) {
	.cdpx-marketplace { display: block; padding-bottom: 52px; }
	.cdpx-filter-toggle { display: flex; align-items: center; justify-content: center; gap: 8px; margin-bottom: 16px; border: 1px solid var(--cdpx-border-strong); background: #fff; color: #222; }
	.cdpx-filter-panel { display: none; position: static; margin-bottom: 24px; padding: 20px; border: 1px solid var(--cdpx-border); border-radius: 18px; }
	.cdpx-marketplace.is-filter-open .cdpx-filter-panel { display: block; }
	.cdpx-marketplace__toolbar { align-items: flex-start; }
	.cdpx-toolbar-actions .cdpx-select { min-width: 150px; }
	.cdpx-product-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
	.cdpx-market-card { border-radius: 18px; }
	.cdpx-market-card__media img { padding: 18%; }
	.cdpx-home-drop-card > .elementor-widget-image img { padding: 8% !important; }
	.cdpx-market-card__body { min-height: 176px; padding: 12px; }
	.cdpx-market-card__title { min-height: 38px; font-size: 14px !important; }
	.cdpx-market-card__price, .cdpx-market-card__price .woocommerce-Price-amount, .cdpx-market-card__price bdi { font-size: 16px !important; }
}

@media (max-width: 430px) {
	.cdpx-product-grid { grid-template-columns: 1fr; gap: 16px; }
	.cdpx-marketplace__toolbar { align-items: stretch; flex-direction: column; }
	.cdpx-toolbar-actions .cdpx-select { width: 100%; }
	.cdpx-market-card__media img { padding: 15%; }
}
