/* Ecom Elements - Frontend Styles */

/* ---------- Reset helpers ---------- */
.ecom-product-grid,
.ecom-category-grid {
	list-style: none;
	margin: 0;
	padding: 0;
}

/* ---------- Product Grid ---------- */
.ecom-product-grid {
	display: grid;
	grid-template-columns: repeat(var(--ecom-columns, 4), 1fr);
	gap: 24px;
}

.ecom-product-card {
	position: relative;
	background: #fff;
	border-radius: 10px;
	overflow: hidden;
	display: flex;
	flex-direction: column;
	transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.ecom-product-card:hover {
	transform: translateY(-4px);
}

.ecom-product-badge {
	position: absolute;
	top: 12px;
	left: 12px;
	background: #d63447;
	color: #fff;
	font-size: 11px;
	font-weight: 700;
	text-transform: uppercase;
	padding: 4px 10px;
	border-radius: 4px;
	z-index: 2;
}

.ecom-product-image-link {
	display: block;
	aspect-ratio: 1 / 1;
	overflow: hidden;
	background: #f4f4f4;
}

.ecom-product-image-link img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform 0.4s ease;
}

.ecom-product-card:hover .ecom-product-image-link img {
	transform: scale(1.06);
}

.ecom-product-info {
	padding: 16px;
	text-align: center;
}

.ecom-product-title {
	font-size: 16px;
	font-weight: 600;
	margin: 0 0 8px;
}

.ecom-product-price {
	margin-bottom: 12px;
	font-size: 15px;
	font-weight: 700;
}

.ecom-product-price-old {
	text-decoration: line-through;
	color: #999;
	font-weight: 400;
	margin-right: 8px;
	font-size: 13px;
}

.ecom-product-btn {
	display: inline-block;
	width: 100%;
	padding: 10px 16px;
	background: #1a1a1a;
	color: #fff;
	text-decoration: none;
	border-radius: 6px;
	font-size: 14px;
	font-weight: 600;
	transition: opacity 0.2s ease;
}

.ecom-product-btn:hover {
	opacity: 0.85;
	color: #fff;
}

/* ---------- Product Category Grid ---------- */
.ecom-category-grid {
	display: grid;
	grid-template-columns: repeat(var(--ecom-columns, 3), 1fr);
	gap: 20px;
}

.ecom-category-card {
	position: relative;
	display: block;
	aspect-ratio: var(--ecom-aspect-ratio, 4 / 3);
	border-radius: 12px;
	overflow: hidden;
	text-decoration: none;
}

.ecom-category-card img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform 0.4s ease, opacity 0.4s ease, filter 0.4s ease;
}

/* Hover effects */
.ecom-hover-zoom:hover img {
	transform: scale(1.08);
}

.ecom-hover-fade img {
	opacity: 1;
}

.ecom-hover-fade:hover img {
	opacity: 0.7;
}

.ecom-hover-grayscale img {
	filter: grayscale(100%);
}

.ecom-hover-grayscale:hover img {
	filter: grayscale(0%);
}

.ecom-hover-slide-up .ecom-category-btn {
	opacity: 0;
	transform: translateY(10px);
	transition: opacity 0.3s ease, transform 0.3s ease;
}

.ecom-hover-slide-up:hover .ecom-category-btn {
	opacity: 1;
	transform: translateY(0);
}

.ecom-category-caption {
	position: absolute;
	left: 0;
	right: 0;
	bottom: 0;
	display: flex;
	flex-direction: column;
	padding: 20px;
	text-align: left;
}

.ecom-overlay-gradient .ecom-category-caption {
	background: linear-gradient(to top, rgba(0,0,0,0.7), rgba(0,0,0,0));
}

.ecom-overlay-solid .ecom-category-caption {
	background: rgba(0,0,0,0.55);
}

.ecom-overlay-full .ecom-category-caption {
	top: 0;
	background: rgba(0,0,0,0.45);
	justify-content: center;
	align-items: center;
	text-align: center;
}

.ecom-overlay-none {
	display: flex;
	flex-direction: column;
}

.ecom-overlay-none .ecom-category-caption {
	position: static;
	background: none;
	padding: 12px 4px 0;
}

.ecom-overlay-none .ecom-category-title,
.ecom-overlay-none .ecom-category-count {
	color: #1a1a1a;
}

.ecom-category-title {
	margin: 0 0 4px;
	font-size: 18px;
	font-weight: 700;
}

.ecom-category-count {
	font-size: 13px;
	opacity: 0.9;
}

.ecom-category-btn {
	display: inline-block;
	margin-top: 10px;
	padding: 8px 18px;
	font-size: 12px;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.04em;
	background: #ffffff;
	color: #1a1a1a;
	border-radius: 20px;
	align-self: flex-start;
}

/* Caption alignment */
.ecom-caption-align-left {
	text-align: left;
	align-items: flex-start;
}

.ecom-caption-align-center {
	text-align: center;
	align-items: center;
}

.ecom-caption-align-right {
	text-align: right;
	align-items: flex-end;
}

.ecom-caption-align-center .ecom-category-btn,
.ecom-caption-align-right .ecom-category-btn {
	align-self: inherit;
}

/* ---------- Pricing Table ---------- */
.ecom-pricing-card {
	--ecom-accent: #2563eb;
	position: relative;
	background: #fff;
	border-radius: 14px;
	padding: 40px 30px;
	text-align: center;
	border: 1px solid #eaeaea;
}

.ecom-pricing-featured {
	border: 2px solid var(--ecom-accent);
	transform: scale(1.03);
}

.ecom-pricing-ribbon {
	position: absolute;
	top: -14px;
	left: 50%;
	transform: translateX(-50%);
	background: var(--ecom-accent);
	color: #fff;
	font-size: 12px;
	font-weight: 700;
	padding: 6px 18px;
	border-radius: 20px;
	white-space: nowrap;
}

.ecom-pricing-plan-name {
	font-size: 20px;
	font-weight: 700;
	margin: 10px 0;
}

.ecom-pricing-price {
	margin-bottom: 12px;
}

.ecom-pricing-currency {
	font-size: 20px;
	font-weight: 600;
	vertical-align: top;
	position: relative;
	top: 8px;
}

.ecom-pricing-amount {
	font-size: 46px;
	font-weight: 800;
	color: var(--ecom-accent);
}

.ecom-pricing-period {
	font-size: 14px;
	color: #888;
}

.ecom-pricing-desc {
	color: #777;
	font-size: 14px;
	margin-bottom: 24px;
}

.ecom-pricing-features {
	list-style: none;
	margin: 0 0 28px;
	padding: 0;
	text-align: left;
}

.ecom-pricing-features li {
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 8px 0;
	font-size: 14px;
	border-bottom: 1px solid #f2f2f2;
}

.ecom-feature-yes .ecom-feature-icon {
	color: #16a34a;
	font-weight: 700;
}

.ecom-feature-no {
	color: #aaa;
}

.ecom-feature-no .ecom-feature-icon {
	color: #d63447;
}

.ecom-pricing-btn {
	display: inline-block;
	width: 100%;
	padding: 14px;
	background: var(--ecom-accent);
	color: #fff;
	text-decoration: none;
	border-radius: 8px;
	font-weight: 700;
	transition: opacity 0.2s ease;
}

.ecom-pricing-btn:hover {
	opacity: 0.88;
	color: #fff;
}

/* ---------- Testimonial Carousel ---------- */
.ecom-testimonial-carousel {
	position: relative;
	overflow: hidden;
}

.ecom-testimonial-track {
	display: flex;
	transition: transform 0.5s ease;
}

.ecom-testimonial-slide {
	flex: 0 0 calc(100% / var(--ecom-slides, 3));
	padding: 0 12px;
	box-sizing: border-box;
}

.ecom-testimonial-card {
	background: #f8f9fb;
	border-radius: 12px;
	padding: 28px;
	height: 100%;
	box-sizing: border-box;
}

.ecom-testimonial-rating {
	color: #f5b301;
	font-size: 15px;
	margin-bottom: 12px;
}

.ecom-testimonial-content {
	font-size: 15px;
	line-height: 1.7;
	color: #333;
	margin: 0 0 20px;
}

.ecom-testimonial-author {
	display: flex;
	align-items: center;
	gap: 12px;
}

.ecom-testimonial-avatar {
	width: 48px;
	height: 48px;
	border-radius: 50%;
	object-fit: cover;
}

.ecom-testimonial-meta {
	display: flex;
	flex-direction: column;
}

.ecom-testimonial-name {
	font-weight: 700;
	font-size: 14px;
}

.ecom-testimonial-role {
	font-size: 12px;
	color: #888;
}

.ecom-testimonial-nav {
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	background: #fff;
	border: 1px solid #eaeaea;
	width: 38px;
	height: 38px;
	border-radius: 50%;
	cursor: pointer;
	z-index: 3;
	display: flex;
	align-items: center;
	justify-content: center;
}

.ecom-testimonial-prev {
	left: 0;
}

.ecom-testimonial-next {
	right: 0;
}

.ecom-testimonial-dots {
	display: flex;
	justify-content: center;
	gap: 8px;
	margin-top: 20px;
}

.ecom-testimonial-dots span {
	width: 9px;
	height: 9px;
	border-radius: 50%;
	background: #d9d9d9;
	cursor: pointer;
	display: inline-block;
}

.ecom-testimonial-dots span.active {
	background: #1a1a1a;
}

/* ---------- Countdown Timer ---------- */
.ecom-countdown-timer {
	display: flex;
	gap: 12px;
	flex-wrap: wrap;
}

.ecom-countdown-box {
	background: #1a1a1a;
	color: #fff;
	border-radius: 8px;
	padding: 16px 20px;
	text-align: center;
	min-width: 80px;
}

.ecom-countdown-number {
	display: block;
	font-size: 32px;
	font-weight: 800;
	line-height: 1;
}

.ecom-countdown-label {
	display: block;
	font-size: 12px;
	margin-top: 6px;
	color: #bbbbbb;
	text-transform: uppercase;
	letter-spacing: 0.05em;
}

.ecom-countdown-expired {
	font-size: 18px;
	font-weight: 700;
	padding: 16px;
}

/* ---------- Team Member ---------- */
.ecom-team-card {
	background: #fff;
	border-radius: 12px;
	padding: 30px;
	text-align: center;
}

.ecom-team-photo img {
	width: 130px;
	height: 130px;
	border-radius: 50%;
	object-fit: cover;
	margin: 0 auto 18px;
}

.ecom-team-name {
	margin: 0 0 4px;
	font-size: 18px;
	font-weight: 700;
}

.ecom-team-designation {
	display: block;
	font-size: 13px;
	color: #777;
	margin-bottom: 12px;
}

.ecom-team-bio {
	font-size: 14px;
	color: #666;
	margin-bottom: 16px;
}

.ecom-team-social {
	display: flex;
	justify-content: center;
	gap: 10px;
}

.ecom-team-social a {
	width: 36px;
	height: 36px;
	border-radius: 50%;
	background: #f2f2f2;
	color: #1a1a1a;
	display: flex;
	align-items: center;
	justify-content: center;
	text-decoration: none;
	transition: opacity 0.2s ease;
}

.ecom-team-social a:hover {
	opacity: 0.7;
}

/* ---------- WhatsApp Button ---------- */
.ecom-whatsapp-btn {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	background: #25D366;
	color: #fff;
	text-decoration: none;
	font-weight: 600;
	border-radius: 30px;
	padding: 12px 20px;
}

.ecom-whatsapp-btn:hover {
	color: #fff;
	opacity: 0.9;
}

.ecom-whatsapp-floating {
	position: fixed;
	bottom: 24px;
	z-index: 9999;
	box-shadow: 0 6px 16px rgba(0,0,0,0.2);
}

.ecom-whatsapp-bottom-right {
	right: 24px;
}

.ecom-whatsapp-bottom-left {
	left: 24px;
}

.ecom-whatsapp-btn i {
	font-size: 22px;
}

.ecom-whatsapp-pulse::before {
	content: "";
	position: absolute;
	inset: 0;
	border-radius: 30px;
	background: #25D366;
	opacity: 0.6;
	animation: ecom-whatsapp-pulse 2s infinite;
	z-index: -1;
}

@keyframes ecom-whatsapp-pulse {
	0% { transform: scale(1); opacity: 0.6; }
	100% { transform: scale(1.5); opacity: 0; }
}

/* ---------- Off-canvas Cart ---------- */
.ecom-cart-trigger {
	position: relative;
	background: none;
	border: none;
	cursor: pointer;
	font-size: 20px;
	color: #1a1a1a;
	padding: 6px;
}

.ecom-cart-badge {
	position: absolute;
	top: -4px;
	right: -6px;
	background: #d63447;
	color: #fff;
	font-size: 10px;
	font-weight: 700;
	width: 18px;
	height: 18px;
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
}

.ecom-cart-overlay {
	position: fixed;
	inset: 0;
	background: rgba(0,0,0,0.45);
	opacity: 0;
	visibility: hidden;
	transition: opacity 0.3s ease;
	z-index: 9998;
}

.ecom-cart-overlay.ecom-cart-active {
	opacity: 1;
	visibility: visible;
}

.ecom-cart-panel {
	position: fixed;
	top: 0;
	bottom: 0;
	width: 360px;
	max-width: 90vw;
	background: #fff;
	z-index: 9999;
	display: flex;
	flex-direction: column;
	transition: transform 0.35s ease;
	box-shadow: 0 0 24px rgba(0,0,0,0.15);
}

.ecom-cart-panel-right {
	right: 0;
	transform: translateX(100%);
}

.ecom-cart-panel-left {
	left: 0;
	transform: translateX(-100%);
}

.ecom-cart-panel.ecom-cart-active {
	transform: translateX(0);
}

.ecom-cart-header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 20px;
	border-bottom: 1px solid #eee;
}

.ecom-cart-header h3 {
	margin: 0;
	font-size: 17px;
}

.ecom-cart-close {
	background: none;
	border: none;
	font-size: 24px;
	cursor: pointer;
	line-height: 1;
}

.ecom-cart-items {
	flex: 1;
	overflow-y: auto;
	padding: 16px 20px;
}

.ecom-cart-item {
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 12px 0;
	border-bottom: 1px solid #f2f2f2;
}

.ecom-cart-item img {
	width: 56px;
	height: 56px;
	object-fit: cover;
	border-radius: 6px;
	background: #f4f4f4;
}

.ecom-cart-item-info {
	flex: 1;
	display: flex;
	flex-direction: column;
}

.ecom-cart-item-title {
	font-size: 14px;
	font-weight: 600;
}

.ecom-cart-item-qty {
	font-size: 12px;
	color: #888;
}

.ecom-cart-item-price {
	font-size: 14px;
	font-weight: 700;
}

.ecom-cart-empty {
	text-align: center;
	color: #999;
	padding: 40px 0;
}

.ecom-cart-footer {
	padding: 20px;
	border-top: 1px solid #eee;
}

.ecom-cart-subtotal {
	display: flex;
	justify-content: space-between;
	font-size: 15px;
	font-weight: 700;
	margin-bottom: 16px;
}

.ecom-cart-checkout-btn {
	display: block;
	width: 100%;
	padding: 14px;
	text-align: center;
	background: #1a1a1a;
	color: #fff;
	text-decoration: none;
	border-radius: 8px;
	font-weight: 700;
	box-sizing: border-box;
}

.ecom-cart-checkout-btn:hover {
	color: #fff;
	opacity: 0.88;
}

/* ---------- Responsive ---------- */
@media (max-width: 767px) {
	.ecom-product-grid,
	.ecom-category-grid {
		grid-template-columns: repeat(2, 1fr);
	}

	.ecom-testimonial-slide {
		flex: 0 0 100%;
	}

	.ecom-pricing-featured {
		transform: none;
	}
}
