/**
 * Sellacious CSS Overrides
 * 
 * This file contains custom CSS overrides for Sellacious components.
 * Add all Sellacious styling customizations here instead of modifying
 * the vendor CSS files (fe.component.css, fe.view.*.css, etc.)
 * 
 * This file is loaded after all other Sellacious CSS files to ensure
 * overrides take precedence.
 */

/* ============================================
   Heart Icon (Favourites) Styles for Product Grid
   ============================================ */

/* Container positioning - no circular background */
.product-block-elegant .product-wishlist-container {
	position: absolute;
	top: 10px;
	right: 10px;
	z-index: 10;
	width: 36px;
	height: 36px;
	display: flex;
	align-items: center;
	justify-content: center;
	background: transparent;
	border: none;
	border-radius: 0;
	cursor: pointer;
	transition: all 0.2s ease;
}

.product-block-elegant .product-wishlist-container:hover {
	background: transparent;
	border: none;
	box-shadow: none;
}

/* Override ctech-rounded-circle and ctech-border-danger for grid hearts */
.product-block-elegant .product-wishlist-container.ctech-rounded-circle {
	border-radius: 0 !important;
}

.product-block-elegant .product-wishlist-container.ctech-border-danger {
	border: none !important;
}

/* Link styling - default state (empty heart, black outline) */
.product-block-elegant .product-wishlist-container .btn-wishlist {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	height: 100%;
	color: #1a1a1a;
	text-decoration: none;
}

.product-block-elegant .product-wishlist-container .btn-wishlist:hover {
	color: #e74c3c;
}

/* Icon sizing */
.product-block-elegant .product-wishlist-container .btn-wishlist i {
	font-size: 18px;
	transition: color 0.2s ease;
	color: inherit;
}

/* Active/Filled heart state - when ctech-text-danger is added by JS */
.product-block-elegant .product-wishlist-container.ctech-text-danger .btn-wishlist,
.product-block-elegant .product-wishlist-container.ctech-text-danger .btn-wishlist i {
	color: #e74c3c !important;
}

/* Ensure product-block-wrap has position for absolute children */
.product-block-elegant .product-block-wrap {
	position: relative;
}

/* ============================================
   UOM and Pack Attributes Display Styles
   ============================================ */

/* Product Grid - UOM/Pack styling */
.product-block-elegant .product-uom-pack {
	font-family: 'Montserrat', sans-serif;
	font-size: 12px;
	font-weight: 500;
	color: #666;
	margin: 4px 0;
	line-height: 1.4;
}

.product-block-elegant .product-uom-pack .uom-value,
.product-block-elegant .product-uom-pack .pack-value {
	font-family: 'Montserrat', sans-serif;
}

.product-block-elegant .product-uom-pack .uom-pack-separator {
	color: #999;
	margin: 0 2px;
}

/* Favourites List - UOM/Pack styling (Grid View) */
.favourites-products-grid .product-uom-pack {
	font-family: 'Montserrat', sans-serif;
	font-size: 12px;
	font-weight: 500;
	color: #666;
	margin: 3px 0;
	line-height: 1.3;
}

.favourites-products-grid .product-uom-pack .uom-value,
.favourites-products-grid .product-uom-pack .pack-value {
	font-family: 'Montserrat', sans-serif;
}

.favourites-products-grid .product-uom-pack .uom-pack-separator {
	color: #999;
	margin: 0 2px;
}

/* Favourites List - UOM/Pack styling (List View) */
.favourites-products-list .product-uom-pack {
	font-family: 'Montserrat', sans-serif;
	font-size: 12px;
	font-weight: 500;
	color: #666;
	margin: 2px 0;
	line-height: 1.3;
}

.favourites-products-list .product-uom-pack .uom-value,
.favourites-products-list .product-uom-pack .pack-value {
	font-family: 'Montserrat', sans-serif;
}

.favourites-products-list .product-uom-pack .uom-pack-separator {
	color: #999;
	margin: 0 2px;
}

/* ============================================
   Skeleton Loading UI for AJAX-first loading
   ============================================ */

.products-skeleton-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    padding: 20px;
}

@media (max-width: 1200px) {
    .products-skeleton-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {
    .products-skeleton-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 480px) {
    .products-skeleton-grid {
        grid-template-columns: 1fr;
    }
}

.product-skeleton-card {
    background: #f8f8f8;
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 15px;
}

.skeleton-image {
    width: 100%;
    height: 180px;
    background: linear-gradient(90deg, #e8e8e8 0%, #d0d0d0 20%, #c0c0c0 40%, #d0d0d0 60%, #e8e8e8 80%, #e8e8e8 100%);
    background-size: 300% 100%;
    animation: skeleton-shimmer 1.2s ease-in-out infinite;
    border-radius: 4px;
    margin-bottom: 12px;
}

.skeleton-title {
    height: 18px;
    background: linear-gradient(90deg, #e8e8e8 0%, #d0d0d0 20%, #c0c0c0 40%, #d0d0d0 60%, #e8e8e8 80%, #e8e8e8 100%);
    background-size: 300% 100%;
    animation: skeleton-shimmer 1.2s ease-in-out infinite;
    animation-delay: 0.1s;
    border-radius: 4px;
    margin-bottom: 8px;
    width: 80%;
}

.skeleton-price {
    height: 22px;
    background: linear-gradient(90deg, #e8e8e8 0%, #d0d0d0 20%, #c0c0c0 40%, #d0d0d0 60%, #e8e8e8 80%, #e8e8e8 100%);
    background-size: 300% 100%;
    animation: skeleton-shimmer 1.2s ease-in-out infinite;
    animation-delay: 0.2s;
    border-radius: 4px;
    margin-bottom: 12px;
    width: 40%;
}

.skeleton-button {
    height: 36px;
    background: linear-gradient(90deg, #e8e8e8 0%, #d0d0d0 20%, #c0c0c0 40%, #d0d0d0 60%, #e8e8e8 80%, #e8e8e8 100%);
    background-size: 300% 100%;
    animation: skeleton-shimmer 1.2s ease-in-out infinite;
    animation-delay: 0.3s;
    border-radius: 4px;
    width: 100%;
}

@keyframes skeleton-shimmer {
    0% {
        background-position: 100% 0;
    }
    100% {
        background-position: -100% 0;
    }
}

/* ============================================
   Load More Button for Infinite Scroll
   ============================================ */

.load-more-container {
    text-align: center;
    padding: 30px 20px;
    margin: 20px 0;
}

.btn-load-more {
    background: #559945;
    color: white;
    border: none;
    padding: 12px 40px;
    font-size: 16px;
    font-weight: 600;
    border-radius: 4px;
    cursor: pointer;
    transition: background 0.3s, transform 0.2s;
}

.btn-load-more:hover {
    background: #4a8639;
    transform: translateY(-2px);
}

.btn-load-more:active {
    transform: translateY(0);
}

.end-of-results {
    color: #888;
    font-size: 14px;
    padding: 20px;
}

/* Loading spinner for infinite scroll */
.load-more-container.loading .btn-load-more {
    opacity: 0.7;
    pointer-events: none;
}

.load-more-container.loading .btn-load-more::after {
    content: '';
    display: inline-block;
    width: 16px;
    height: 16px;
    margin-left: 10px;
    border: 2px solid #fff;
    border-top-color: transparent;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* ============================================
   Favourites List Page Styling
   (Matching Product Grid Typography)
   ============================================ */

/* Page container */
.favourites-page-container {
	padding: 2rem 0;
}

.favourites-header {
	display: flex;
	justify-content: space-between;
	align-items: center;
	margin-bottom: 2rem;
}

.favourites-empty-state,
.favourites-empty-list {
	text-align: center;
	padding: 4rem 2rem;
}

.favourites-lists-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
	gap: 1.5rem;
	margin-top: 2rem;
}

/* List View Styles - Compact horizontal layout */
.favourites-products-list {
	display: flex;
	flex-direction: column;
	gap: 0;
}

.favourites-products-list .favourite-product-card {
	display: grid;
	grid-template-columns: 50px minmax(180px, 1fr) minmax(120px, 180px) 90px 170px 28px;
	align-items: center;
	padding: 8px 16px;
	min-height: auto;
	gap: 14px;
	border-radius: 0;
	border-bottom: 1px solid #eee;
	position: relative;
	height: auto;
}

.favourites-products-list .favourite-product-card:first-child {
	border-top: 1px solid #eee;
}

.favourites-products-list .product-image {
	width: 50px;
	height: 50px;
	min-height: 50px;
	max-height: 50px;
	margin-bottom: 0;
	flex-shrink: 0;
	border: 1px solid #eee;
	border-radius: 4px;
	background: #fff;
	display: flex;
	align-items: center;
	justify-content: center;
}

.favourites-products-list .product-image img {
	max-width: 100%;
	max-height: 100%;
	object-fit: contain;
}

.favourites-products-list .no-image {
	font-size: 1.5rem;
	color: #9CA3AF;
}

/* Column 2: Name + SKU */
.favourites-products-list .product-details-main {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 2px;
	min-width: 0;
}

.favourites-products-list .product-details-main h4 {
	height: auto;
	min-height: auto;
	-webkit-line-clamp: 2;
	margin-bottom: 0;
	font-size: 14px;
	font-weight: 600;
	line-height: 1.3;
	overflow: hidden;
	text-overflow: ellipsis;
	display: -webkit-box;
	-webkit-box-orient: vertical;
}

.favourites-products-list .product-details-main h4 a {
	color: #222;
	text-decoration: none;
}

.favourites-products-list .product-details-main h4 a:hover {
	color: var(--treno-darkgreen);
}

.favourites-products-list .product-sku {
	display: block;
	margin: 0;
	font-size: 12px;
	color: #666;
}

/* Column 3: UOM/Pack + Sold by - separate column */
.favourites-products-list .product-meta-col {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 2px;
	min-width: 0;
}

.favourites-products-list .product-uom-pack {
	display: block;
	margin: 0;
	font-size: 13px;
	color: #444;
}

.favourites-products-list .product-seller {
	display: block;
	margin: 0;
	font-size: 11px;
	color: #888;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

/* Column 4: Price */
.favourites-products-list .product-price {
	margin: 0;
	text-align: right;
	white-space: nowrap;
	font-size: 16px;
	font-weight: 700;
	color: #333;
}

/* Column 5: Quantity + Add to Cart - vertically centered */
.favourites-products-list .product-actions {
	border-top: none !important;
	padding-top: 0 !important;
	margin-top: 0 !important;
	flex-shrink: 0;
	align-self: center;
}

.favourites-products-list .product-actions .cart-row {
	display: flex;
	gap: 6px;
	align-items: center;
}

.favourites-products-list .product-actions .qty-input {
	width: 48px;
	padding: 5px 6px;
	text-align: center;
	font-size: 13px;
	height: 32px;
}

.favourites-products-list .product-actions .btn {
	padding: 5px 12px;
	font-size: 13px;
	white-space: nowrap;
	height: 32px;
}

.favourites-products-list .product-actions .btn-block {
	width: 100%;
}

/* Column 6: Remove button - positioned in grid */
.favourites-products-list .remove-btn-absolute {
	position: static;
	width: 28px;
	height: 28px;
	display: flex;
	align-items: center;
	justify-content: center;
	background: #f8f8f8;
	border: 1px solid #ddd;
	border-radius: 50%;
	color: #999;
	font-size: 12px;
	cursor: pointer;
	transition: all 0.2s;
	justify-self: center;
}

.favourites-products-list .remove-btn-absolute:hover {
	background: #fee;
	border-color: #e74c3c;
	color: #e74c3c;
}

/* Responsive: Tablet */
@media (max-width: 1024px) {
	.favourites-products-list .favourite-product-card {
		grid-template-columns: 45px minmax(140px, 1fr) minmax(100px, 140px) 75px 130px 26px;
		gap: 10px;
		padding: 8px 12px;
	}
	
	.favourites-products-list .product-image {
		width: 45px;
		height: 45px;
		min-height: 45px;
		max-height: 45px;
	}
	
	.favourites-products-list .product-details-main h4 {
		font-size: 13px;
	}
	
	.favourites-products-list .product-price {
		font-size: 14px;
	}
	
	.favourites-products-list .product-actions .qty-input {
		width: 45px;
		padding: 4px 6px;
	}
	
	.favourites-products-list .product-actions .btn {
		padding: 4px 10px;
		font-size: 12px;
	}
}

/* Responsive: Mobile */
@media (max-width: 767px) {
	.favourites-products-list .favourite-product-card {
		display: grid;
		grid-template-columns: 50px 1fr auto auto;
		grid-template-rows: auto auto auto;
		grid-template-areas: 
			"image details price remove"
			"meta meta meta meta"
			"actions actions actions actions";
		padding: 12px;
		gap: 8px 10px;
		border-radius: 8px;
		border: 1px solid #eee;
		margin-bottom: 10px;
		position: relative;
	}
	
	.favourites-products-list .favourite-product-card:first-child {
		border-top: 1px solid #eee;
	}
	
	.favourites-products-list .product-image {
		grid-area: image;
		width: 50px;
		height: 50px;
		align-self: center;
	}
	
	.favourites-products-list .product-details-main {
		grid-area: details;
		align-self: center;
		min-width: 0;
	}
	
	.favourites-products-list .product-details-main h4 {
		-webkit-line-clamp: 2;
		font-size: 13px;
	}
	
	.favourites-products-list .product-sku {
		font-size: 11px;
	}
	
	.favourites-products-list .product-meta-col {
		grid-area: meta;
		flex-direction: column;
		gap: 2px;
		padding-top: 4px;
		border-top: 1px solid #f5f5f5;
	}
	
	.favourites-products-list .product-uom-pack,
	.favourites-products-list .product-seller {
		font-size: 12px;
	}
	
	.favourites-products-list .product-price {
		grid-area: price;
		position: static;
		text-align: right;
		margin: 0;
		align-self: center;
		font-size: 15px;
		white-space: nowrap;
	}
	
	.favourites-products-list .product-actions {
		grid-area: actions;
		width: 100%;
		border-top: 1px solid #eee;
		padding-top: 10px;
		margin-top: 4px;
	}
	
	.favourites-products-list .remove-btn-absolute {
		grid-area: remove;
		position: static;
		justify-self: end;
		align-self: center;
	}
}

/* Extra small mobile - stack more aggressively */
@media (max-width: 420px) {
	.favourites-products-list .favourite-product-card {
		grid-template-columns: 45px 1fr;
		grid-template-rows: auto auto auto auto;
		grid-template-areas: 
			"image details"
			"price price"
			"meta meta"
			"actions actions";
		gap: 6px 10px;
		padding: 10px;
	}
	
	.favourites-products-list .product-image {
		width: 45px;
		height: 45px;
		min-height: 45px;
		max-height: 45px;
	}
	
	.favourites-products-list .product-details-main {
		position: relative;
		padding-right: 32px;
	}
	
	.favourites-products-list .product-details-main h4 {
		-webkit-line-clamp: 2;
		font-size: 13px;
		line-height: 1.3;
	}
	
	.favourites-products-list .product-price {
		grid-area: price;
		text-align: left;
		font-size: 16px;
		font-weight: 700;
		padding-left: 55px;
	}
	
	.favourites-products-list .product-meta-col {
		padding-left: 55px;
		padding-top: 0;
		border-top: none;
	}
	
	.favourites-products-list .remove-btn-absolute {
		grid-area: details;
		position: absolute;
		top: 0;
		right: 0;
		justify-self: end;
		align-self: start;
	}
	
	.favourites-products-list .product-actions .cart-row {
		justify-content: flex-start;
	}
}

/* List Card Styles */
.favourites-list-card {
	border: 1px solid var(--treno-midgreen);
	border-radius: 8px;
	padding: 1.5rem;
	transition: box-shadow 0.3s;
}

.favourites-list-card:hover {
	box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.list-card-link {
	text-decoration: none;
	color: inherit;
	display: flex;
	gap: 1rem;
	align-items: center;
}

.list-icon {
	font-size: 2rem;
}

.list-name {
	margin: 0;
	font-size: 1.25rem;
	color: var(--treno-darkgreen);
}

.list-count {
	color: #6B7280;
	margin: 0.5rem 0 0 0;
}

.list-actions {
	margin-top: 1rem;
	padding-top: 1rem;
	border-top: 1px solid #E5E7EB;
	display: flex;
	gap: 1rem;
}

.favourites-breadcrumb {
	margin-bottom: 1rem;
}

.favourites-list-header {
	display: flex;
	justify-content: space-between;
	align-items: center;
	margin-bottom: 2rem;
}

.list-header-actions {
	display: flex;
	flex-direction: column;
	align-items: flex-end;
	gap: 10px;
}

.view-toggle-group {
	margin-right: 0 !important;
}

/* Products Grid */
.favourites-products-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
	gap: 1.5rem;
}

/* Product Card (Grid view) */
.favourites-products-grid .favourite-product-card {
	border: 1px solid #E5E7EB;
	border-radius: 8px;
	padding: 1rem;
	position: relative;
	background: #fff;
	display: flex;
	flex-direction: column;
	height: 100%;
}

/* Grid view: ensure product-details-main and product-meta-col stack properly */
.favourites-products-grid .product-details-main,
.favourites-products-grid .product-meta-col {
	width: 100%;
}

.favourites-products-grid .product-meta-col {
	display: block;
}

/* Product Card (base styles for both views) */
.favourite-product-card {
	border: 1px solid #E5E7EB;
	border-radius: 8px;
	padding: 1rem;
	position: relative;
	background: #fff;
	display: flex;
	flex-direction: column;
	height: 100%;
}

.favourite-product-card .product-image {
	height: 200px;
	background: #ffffff;
	display: flex;
	align-items: center;
	justify-content: center;
	margin-bottom: 1rem;
	border-radius: 4px;
}

.favourite-product-card .product-image img {
	max-width: 100%;
	max-height: 100%;
	object-fit: contain;
}

.favourite-product-card .no-image {
	font-size: 3rem;
	color: #9CA3AF;
}

/* Product Title - matches .product-title in product grid (14px, 600 weight) */
.favourite-product-card .product-details-main h4 {
	font-size: 14px;
	font-weight: 600;
	line-height: 18px;
	margin: 0 0 6px 0;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
	text-overflow: ellipsis;
	height: auto;
	min-height: 36px;
	color: #222222;
}

/* SKU - matches product grid small text (12px) */
.favourite-product-card .product-sku {
	font-size: 12px;
	color: #9CA3AF;
	margin: 0 0 4px 0;
}

/* UOM/Pack - consistent sizing (13px) */
.favourite-product-card .product-uom-pack {
	font-size: 13px;
	color: #6B7280;
	margin: 0 0 4px 0;
}

/* Seller - matches seller overlay in product grid (11px, blue with SOLD BY label) */
.favourite-product-card .product-seller {
	font-size: 11px;
	color: #0078d4;
	margin: 4px 0;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

.favourite-product-card .product-seller .seller-label {
	font-weight: bold;
	color: #0078d4;
}

/* Price - matches .product-price in product grid (16px, 600 weight) */
.favourite-product-card .product-price {
	font-size: 16px;
	font-weight: 600;
	color: #212121;
	margin: 8px 0;
	max-width: 100%;
	letter-spacing: 0.5px;
}

/* Remove Button (Grid view - absolute positioned) */
.favourites-products-grid .remove-btn-absolute {
	position: absolute;
	top: 0.5rem;
	right: 0.5rem;
	color: #EF4444;
	background: rgba(255,255,255,0.9);
	border-radius: 50%;
	width: 30px;
	height: 30px;
	display: flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
	border: 1px solid #E5E7EB;
	transition: all 0.2s;
	z-index: 2;
	padding: 0;
}

.favourites-products-grid .remove-btn-absolute:hover {
	background: #FEE2E2;
	transform: scale(1.1);
}

/* Product Actions */
.favourite-product-card .product-actions {
	margin-top: auto;
	padding-top: 1rem;
	border-top: 1px solid #E5E7EB;
}

.favourite-product-card .cart-row {
	display: flex;
	gap: 0.5rem;
	align-items: stretch;
}

.favourite-product-card .cart-row .qty-input {
	width: 70px;
	text-align: center;
}

.favourite-product-card .btn-block {
	display: block;
	width: 100%;
}

/* Toggle Buttons */
.view-toggle-group .btn.active {
	background-color: var(--treno-darkgreen);
	border-color: var(--treno-darkgreen);
	color: white;
	z-index: 2;
}

/* Header Actions */
.favourites-header-actions {
	display: flex;
	align-items: center;
}

@media (max-width: 767px) {
	.favourites-header {
		flex-direction: column;
		align-items: flex-start;
		gap: 1rem;
	}
	
	.favourites-header-actions {
		width: 100%;
		flex-direction: column;
		gap: 0.5rem;
	}
	
	.favourites-header-actions .btn {
		width: 100%;
		margin-right: 0 !important;
	}
}

/* ============================================
   Stores/Suppliers Page - Modern Card Styles
   ============================================ */

/* Override default stores grid styles if they exist */
.store-blocks-container .store-list-block,
.store-blocks-container .store-block-default {
	border: none !important;
}

.store-blocks-container .store-wrap {
	border: none !important;
	border-radius: 16px !important;
	overflow: hidden;
	background: #fff;
	transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.store-blocks-container .store-wrap:hover {
	transform: translateY(-4px);
	box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12) !important;
}

.store-blocks-container .store-box {
	border: none !important;
	border-radius: 16px !important;
}

.store-blocks-container .image-box {
	background: #fafafa;
	border-bottom: none !important;
}

.store-blocks-container .store-info-box {
	padding: 20px;
	text-align: center;
}

.store-blocks-container .store-title {
	font-size: 18px;
	font-weight: 600;
	color: #333;
}

.store-blocks-container .store-title a {
	color: inherit;
	text-decoration: none;
}

.store-blocks-container .store-title a:hover {
	color: #559945;
}

/* ============================================
   Suppliers/Stores Page - Search & Grid Styles
   ============================================ */

/* Search bar styles */
.stores-search-wrapper {
	margin-bottom: 24px;
}

.stores-search-container {
	position: relative;
	max-width: 500px;
}

.stores-search-input {
	width: 100%;
	padding: 14px 48px 14px 20px;
	font-size: 16px;
	border: 2px solid #e0e0e0;
	border-radius: 12px;
	background: #fff;
	transition: border-color 0.2s ease, box-shadow 0.2s ease;
	outline: none;
}

.stores-search-input:focus {
	border-color: #559945;
	box-shadow: 0 0 0 3px rgba(85, 153, 69, 0.15);
}

.stores-search-input::placeholder {
	color: #999;
}

.stores-search-icon {
	position: absolute;
	right: 16px;
	top: 50%;
	transform: translateY(-50%);
	color: #999;
	font-size: 18px;
	pointer-events: none;
}

.stores-search-container.searching .stores-search-icon {
	animation: storesSearchPulse 1s ease-in-out infinite;
}

@keyframes storesSearchPulse {
	0%, 100% { opacity: 1; }
	50% { opacity: 0.4; }
}

.stores-search-clear {
	position: absolute;
	right: 44px;
	top: 50%;
	transform: translateY(-50%);
	color: #999;
	font-size: 16px;
	cursor: pointer;
	padding: 4px;
	display: none;
}

.stores-search-clear:hover {
	color: #333;
}

.stores-search-container.has-value .stores-search-clear {
	display: block;
}

.stores-search-results-info {
	margin-top: 12px;
	font-size: 14px;
	color: #666;
	display: none;
}

.stores-search-results-info.active {
	display: block;
}

/* Skeleton loading styles */
.store-card-skeleton {
	background: #fff;
	border-radius: 16px;
	overflow: hidden;
}

.skeleton-logo {
	height: 180px;
	background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
	background-size: 200% 100%;
	animation: storesShimmer 1.5s infinite;
}

.skeleton-info {
	padding: 20px;
	text-align: center;
}

.skeleton-title {
	height: 20px;
	width: 60%;
	margin: 0 auto 16px;
	background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
	background-size: 200% 100%;
	animation: storesShimmer 1.5s infinite;
	border-radius: 4px;
}

.skeleton-button {
	height: 40px;
	width: 120px;
	margin: 0 auto;
	background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
	background-size: 200% 100%;
	animation: storesShimmer 1.5s infinite;
	border-radius: 8px;
}

@keyframes storesShimmer {
	0% { background-position: 200% 0; }
	100% { background-position: -200% 0; }
}

/* Stores grid container */
.stores-grid-container {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
	gap: 24px;
	padding: 20px 0;
}

.store-card {
	background: #fff;
	border-radius: 16px;
	overflow: hidden;
	transition: transform 0.2s ease, box-shadow 0.2s ease;
	cursor: pointer;
	display: flex;
	flex-direction: column;
}

.store-card:hover {
	transform: translateY(-4px);
	box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
}

.store-logo-wrap {
	height: 180px;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 20px;
	background: #fafafa;
}

.store-logo-wrap img {
	max-width: 100%;
	max-height: 140px;
	object-fit: contain;
}

.store-info {
	padding: 20px;
	text-align: center;
	flex-grow: 1;
	display: flex;
	flex-direction: column;
	justify-content: space-between;
}

.store-name {
	font-size: 18px;
	font-weight: 600;
	color: #333;
	margin: 0 0 16px 0;
}

.store-name a {
	color: inherit;
	text-decoration: none;
}

.store-name a:hover {
	color: #559945;
}

/* Connection button styles */
#stores-page .btn-connect {
	background: linear-gradient(135deg, #559945 0%, #6ab854 100%);
	color: white;
	border: none;
	padding: 10px 24px;
	font-size: 14px;
	font-weight: 600;
	border-radius: 8px;
	cursor: pointer;
	transition: all 0.3s ease;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
}

#stores-page .btn-connect:hover {
	background: linear-gradient(135deg, #477d39 0%, #559945 100%);
	transform: translateY(-1px);
}

#stores-page .btn-connect.guest {
	background: #6c757d;
}

#stores-page .btn-connect.guest:hover {
	background: #5a6268;
}

#stores-page .badge-connected {
	background: linear-gradient(135deg, #559945 0%, #6ab854 100%);
	color: white;
	padding: 10px 24px;
	font-size: 14px;
	font-weight: 600;
	border-radius: 8px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
}

#stores-page .badge-connected-clickable {
	cursor: pointer;
	transition: all 0.3s ease;
}

#stores-page .badge-connected-clickable:hover {
	background: linear-gradient(135deg, #477d39 0%, #559945 100%);
	box-shadow: 0 4px 12px rgba(85, 153, 69, 0.4);
	transform: translateY(-2px);
}

#stores-page .badge-connected-clickable::after {
	content: '\f040';
	font-family: FontAwesome;
	margin-left: 6px;
	font-size: 12px;
	opacity: 0;
	transition: opacity 0.3s ease;
}

#stores-page .badge-connected-clickable:hover::after {
	opacity: 1;
}

#stores-page .badge-pending {
	background: #f0ad4e;
	color: white;
	padding: 10px 24px;
	font-size: 14px;
	font-weight: 600;
	border-radius: 8px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
}

#stores-page .badge-rejected {
	background: #d9534f;
	color: white;
	padding: 10px 24px;
	font-size: 14px;
	font-weight: 600;
	border-radius: 8px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
}

/* No stores message */
#stores-page .no-stores {
	text-align: center;
	padding: 60px 20px;
	color: #666;
}

#stores-page .no-stores h4 {
	margin: 0;
	font-size: 18px;
}

/* Connect Modal */
.stores-connect-modal {
	display: none;
	position: fixed;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	background: rgba(0, 0, 0, 0.6);
	z-index: 10000;
	align-items: center;
	justify-content: center;
}

.stores-connect-modal.active {
	display: flex;
}

.stores-connect-modal-content {
	background: white;
	border-radius: 16px;
	max-width: 480px;
	width: 90%;
	max-height: 90vh;
	overflow-y: auto;
	position: relative;
}

.stores-connect-modal-close {
	position: absolute;
	top: 15px;
	right: 20px;
	font-size: 28px;
	cursor: pointer;
	color: #999;
	line-height: 1;
}

.stores-connect-modal-close:hover {
	color: #333;
}

.stores-connect-modal-header {
	padding: 30px 30px 20px;
	text-align: center;
	border-bottom: 1px solid #eee;
}

.stores-connect-modal-header h2 {
	margin: 0 0 8px;
	font-size: 24px;
	color: #333;
}

.stores-connect-modal-header p {
	margin: 0;
	color: #666;
}

.stores-connect-modal-body {
	padding: 20px 30px 30px;
}

.stores-connect-modal .connect-option {
	display: flex;
	align-items: center;
	padding: 20px;
	border: 1px solid #eee;
	border-radius: 12px;
	margin-bottom: 15px;
	cursor: pointer;
	transition: all 0.2s ease;
}

.stores-connect-modal .connect-option:hover {
	border-color: #559945;
	background: #f9fff7;
}

.stores-connect-modal .connect-option:last-child {
	margin-bottom: 0;
}

.stores-connect-modal .connect-option-icon {
	width: 50px;
	height: 50px;
	border-radius: 50%;
	background: linear-gradient(135deg, #559945 0%, #6ab854 100%);
	display: flex;
	align-items: center;
	justify-content: center;
	margin-right: 16px;
	flex-shrink: 0;
}

.stores-connect-modal .connect-option-icon i {
	font-size: 20px;
	color: white;
}

.stores-connect-modal .connect-option-content {
	flex-grow: 1;
}

.stores-connect-modal .connect-option-content h3 {
	margin: 0 0 4px;
	font-size: 16px;
	color: #333;
}

.stores-connect-modal .connect-option-content p {
	margin: 0;
	font-size: 14px;
	color: #666;
}

.stores-connect-modal .connect-option-arrow {
	color: #ccc;
	margin-left: 10px;
}

/* Responsive styles */
@media (max-width: 768px) {
	.stores-grid-container {
		grid-template-columns: repeat(2, 1fr);
		gap: 16px;
	}
	
	.store-logo-wrap {
		height: 140px;
	}
	
	.store-info {
		padding: 15px;
	}
	
	.store-name {
		font-size: 16px;
	}
	
	#stores-page .btn-connect,
	#stores-page .badge-connected,
	#stores-page .badge-pending {
		padding: 8px 16px;
		font-size: 12px;
	}
}

@media (max-width: 480px) {
	.stores-grid-container {
		grid-template-columns: 1fr;
	}
}

/* ============================================
   Sell Infobox Branding Overrides (Treno Green Theme)
   ============================================ */

.sell-infobox {
	border: 1px solid #e0e0e0 !important;
	border-radius: 4px;
	overflow: hidden;
}

.sell-infobox > h5 {
	background: linear-gradient(135deg, #4a7c59 0%, #3d6a4a 100%) !important;
	color: #fff !important;
	border-bottom: none !important;
	font-weight: 600;
	letter-spacing: 0.3px;
}

/* Specification table styling */
.specification-box .tbl-specifications thead th {
	background: #f8f9f8 !important;
	color: #4a7c59;
	font-weight: 600;
}

.specification-box .tbl-specifications tbody tr:nth-child(even) {
	background: #fafbfa;
}

.specification-box .tbl-specifications tbody th {
	color: #555;
	font-weight: 500;
}

/* Description box */
.description-box > h5,
.package-box > h5,
.rating-box > h5,
.questionarea-box > h5,
.price-history-box > h5 {
	background: linear-gradient(135deg, #4a7c59 0%, #3d6a4a 100%) !important;
	color: #fff !important;
}

/* ============================================
   Price History Chart Styles (Pure CSS/SVG)
   ============================================ */

.price-history-box {
	margin-top: 20px;
}

.price-history-box h5 {
	margin-bottom: 15px;
}

.price-history-inner {
	padding: 15px;
}

.price-history-subtitle {
	color: #666;
	font-size: 14px;
	margin-bottom: 20px;
}

.price-history-chart-wrapper {
	overflow-x: auto;
	overflow-y: hidden;
	max-width: 100%;
	padding-bottom: 10px;
}

.price-history-chart-wrapper::-webkit-scrollbar {
	height: 8px;
}

.price-history-chart-wrapper::-webkit-scrollbar-track {
	background: #f1f1f1;
	border-radius: 4px;
}

.price-history-chart-wrapper::-webkit-scrollbar-thumb {
	background: #4a7c59;
	border-radius: 4px;
}

.price-history-chart-wrapper::-webkit-scrollbar-thumb:hover {
	background: #3d6a4a;
}

.price-history-chart {
	display: flex;
	flex-direction: column;
	min-width: 100%;
}

.price-history-chart-row {
	display: flex;
	height: 250px;
}

.price-history-y-axis {
	width: 70px;
	display: flex;
	flex-direction: column;
	justify-content: space-between;
	padding-right: 10px;
	text-align: right;
}

.price-history-y-axis .y-label {
	font-size: 11px;
	color: #666;
	line-height: 1;
}

.price-history-plot-area {
	flex: 1;
	position: relative;
	border-left: 1px solid #ddd;
	border-bottom: 1px solid #ddd;
	background: #fff;
}

.price-history-grid-lines {
	position: absolute;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	display: flex;
	flex-direction: column;
	justify-content: space-between;
	pointer-events: none;
}

.price-history-grid-lines .grid-line {
	border-top: 1px dashed #eee;
	width: 100%;
}

.price-history-points {
	position: absolute;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
}

.price-point {
	position: absolute;
	transform: translate(-50%, 50%);
	z-index: 10;
	cursor: pointer;
}

.price-point .point-dot {
	width: 12px;
	height: 12px;
	background: #4a7c59;
	border: 2px solid #fff;
	border-radius: 50%;
	box-shadow: 0 2px 4px rgba(0,0,0,0.2);
	transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.price-point:hover .point-dot {
	transform: scale(1.3);
	box-shadow: 0 3px 8px rgba(0,0,0,0.3);
}

.price-point .point-tooltip {
	position: absolute;
	bottom: 100%;
	left: 50%;
	transform: translateX(-50%);
	background: rgba(0, 0, 0, 0.85);
	color: #fff;
	padding: 8px 12px;
	border-radius: 6px;
	font-size: 12px;
	white-space: nowrap;
	opacity: 0;
	visibility: hidden;
	transition: opacity 0.2s ease, visibility 0.2s ease;
	margin-bottom: 8px;
	z-index: 100;
}

.price-point .point-tooltip::after {
	content: '';
	position: absolute;
	top: 100%;
	left: 50%;
	transform: translateX(-50%);
	border: 6px solid transparent;
	border-top-color: rgba(0, 0, 0, 0.85);
}

.price-point:hover .point-tooltip {
	opacity: 1;
	visibility: visible;
}

/* Tooltip below for points near top of chart */
.price-point.tooltip-below .point-tooltip {
	bottom: auto;
	top: 100%;
	margin-bottom: 0;
	margin-top: 8px;
}

.price-point.tooltip-below .point-tooltip::after {
	top: auto;
	bottom: 100%;
	border-top-color: transparent;
	border-bottom-color: rgba(0, 0, 0, 0.85);
}

.point-tooltip .tooltip-date {
	font-weight: bold;
	margin-bottom: 4px;
}

.point-tooltip .tooltip-price {
	color: #7fcd91;
	font-size: 14px;
	font-weight: bold;
}

.point-tooltip .tooltip-qty {
	color: #aaa;
	font-size: 11px;
	margin-top: 2px;
}

.price-history-line {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	pointer-events: none;
}

.price-history-x-axis-row {
	display: flex;
	height: 30px;
}

.price-history-y-axis-spacer {
	width: 70px;
	flex-shrink: 0;
}

.price-history-x-axis {
	position: relative;
	flex: 1;
}

.price-history-x-axis .x-label {
	position: absolute;
	transform: translateX(-50%);
	font-size: 11px;
	color: #666;
	padding-top: 8px;
	white-space: nowrap;
}

@media (max-width: 768px) {
	.price-history-chart-row {
		height: 200px;
	}
	
	.price-history-y-axis,
	.price-history-y-axis-spacer {
		width: 60px;
	}
}

@media (max-width: 480px) {
	.price-history-chart-row {
		height: 180px;
	}
	
	.price-history-y-axis,
	.price-history-y-axis-spacer {
		width: 50px;
	}
	
	.price-history-y-axis .y-label,
	.price-history-x-axis .x-label {
		font-size: 10px;
	}
	
	.price-history-subtitle {
		font-size: 12px;
	}
}

/* ============================================
   Add to Cart Button - Standardized Color (#5c7c55)
   ============================================ */

/* Favourites List Page - Add button */
.favourites-products-list .cart-row .btn.btn-primary,
.favourites-products-grid .cart-row .btn.btn-primary {
	background: #5c7c55 !important;
	border-color: #5c7c55 !important;
	color: #fff !important;
}

.favourites-products-list .cart-row .btn.btn-primary:hover,
.favourites-products-grid .cart-row .btn.btn-primary:hover {
	background: #4a6a45 !important;
	border-color: #4a6a45 !important;
}

/* Product Detail Page - Add to Cart button */
.ctech-btn.ctech-btn-warning.btn-cart.btn-add-cart,
button.ctech-btn.ctech-btn-warning.btn-cart.btn-add-cart,
.sell-product-page .ctech-btn-warning.btn-add-cart,
.sell-product-page .btn-add-cart {
	background-color: #5c7c55 !important;
	background: #5c7c55 !important;
	border-color: #5c7c55 !important;
	color: #fff !important;
}

.ctech-btn.ctech-btn-warning.btn-cart.btn-add-cart:hover,
button.ctech-btn.ctech-btn-warning.btn-cart.btn-add-cart:hover,
.sell-product-page .ctech-btn-warning.btn-add-cart:hover,
.sell-product-page .btn-add-cart:hover {
	background-color: #4a6a45 !important;
	background: #4a6a45 !important;
	border-color: #4a6a45 !important;
}

/* ============================================
   CART DRAWER - Side-loading Modal
   ============================================ */

/* Override the modal to be a side drawer */
#modal-cart.ctech-modal {
	/* Reset default modal positioning */
	display: flex !important;
	visibility: hidden;
	opacity: 0;
	pointer-events: none;
	transition: visibility 0s linear 0.3s, opacity 0.3s ease;
	z-index: 99999 !important; /* Ensure drawer appears above header on all pages */
}

#modal-cart.ctech-modal.ctech-show,
#modal-cart.ctech-modal.show {
	visibility: visible;
	opacity: 1;
	pointer-events: auto;
	transition: visibility 0s linear 0s, opacity 0.3s ease;
}

/* Drawer dialog - slides in from right */
#modal-cart .ctech-modal-dialog {
	position: fixed;
	top: 0;
	right: 0;
	bottom: 0;
	margin: 0;
	width: 420px;
	max-width: 100%;
	height: 100vh;
	transform: translateX(100%);
	transition: transform 0.3s ease-out;
}

#modal-cart.ctech-show .ctech-modal-dialog,
#modal-cart.show .ctech-modal-dialog {
	transform: translateX(0);
}

/* Reset centered/lg classes that conflict with drawer */
#modal-cart .ctech-modal-dialog.ctech-modal-dialog-centered {
	align-items: stretch;
}

#modal-cart .ctech-modal-dialog.ctech-modal-lg {
	max-width: 420px;
}

/* Modal content fills the drawer height */
#modal-cart .ctech-modal-content {
	height: 100%;
	border: none;
	border-radius: 0;
	display: flex;
	flex-direction: column;
	box-shadow: -4px 0 20px rgba(0, 0, 0, 0.15);
	background: #fff !important; /* Override fe.view.cart.css transparent background */
}

/* Custom header for drawer */
#modal-cart .ctech-modal-body {
	flex: 1;
	overflow-y: auto;
	padding: 0;
	display: flex;
	flex-direction: column;
}

/* Cart drawer header styling */
#modal-cart .cart-drawer-header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 16px 20px;
	border-bottom: 1px solid #eee;
	background: #fff;
	position: sticky;
	top: 0;
	z-index: 10;
}

#modal-cart .cart-drawer-header h3 {
	margin: 0;
	font-size: 18px;
	font-weight: 600;
	color: #1a1a1a;
}

#modal-cart .cart-drawer-close {
	background: none;
	border: none;
	font-size: 24px;
	color: #666;
	cursor: pointer;
	padding: 4px 8px;
	line-height: 1;
	transition: color 0.2s ease;
}

#modal-cart .cart-drawer-close:hover {
	color: #1a1a1a;
}

/* Cart items container - must fill available space and use flexbox for drawer layout */
#modal-cart #cart-items,
#modal-cart #cart-aio-items {
	flex: 1;
	display: flex;
	flex-direction: column;
	overflow: hidden; /* Contain scroll to .cart-drawer-items */
	padding: 0;
	min-height: 0; /* Allow flex child to shrink below content size */
}

/* Hide legacy modal elements that don't belong in drawer */
#modal-cart #cart-aio-summary,
#modal-cart .cart-items-summary,
#modal-cart .ctech-container-fluid > .ctech-row,
#modal-cart .cart-items-list {
	display: none !important;
}

/* Ensure new drawer layout elements are visible (not hidden by any parent rules) */
#modal-cart #cart-items > .cart-drawer-items,
#modal-cart #cart-items > .cart-drawer-footer,
#modal-cart #cart-items > .cart-drawer-empty {
	visibility: visible;
}

/* Override table-based cart items layout */
#modal-cart .cart-items-table {
	width: 100%;
	border-collapse: collapse;
}

#modal-cart .cart-items-table tbody tr {
	display: flex;
	flex-wrap: wrap;
	padding: 16px 20px;
	border-bottom: 1px solid #f0f0f0;
	align-items: flex-start;
	gap: 12px;
}

#modal-cart .cart-items-table tbody tr:hover {
	background: #fafafa;
}

/* Product thumbnail */
#modal-cart .cart-items-table tbody td:first-child {
	width: 60px !important;
	flex-shrink: 0;
}

#modal-cart .cart-items-table .product-thumb {
	width: 60px;
	height: 60px;
	object-fit: cover;
	border-radius: 8px;
	border: 1px solid #eee;
}

/* Product info cell */
#modal-cart .cart-items-table td.cart-item {
	flex: 1;
	min-width: 0;
	padding: 0 !important;
}

#modal-cart .cart-items-table .cart-item-title {
	font-size: 14px;
	font-weight: 500;
	color: #1a1a1a;
	text-decoration: none;
	display: block;
	margin-bottom: 4px;
	line-height: 1.4;
}

#modal-cart .cart-items-table .cart-item-title:hover {
	color: #5c7c55;
}

/* Seller info */
#modal-cart .cart-items-table td.cart-item > div {
	font-size: 12px;
	color: #888;
}

/* Error messages in cart */
#modal-cart .cart-items-table td.cart-item .red {
	font-size: 12px;
	color: #dc3545;
	margin-top: 4px;
	background: #fff5f5;
	padding: 6px 8px;
	border-radius: 4px;
	border-left: 3px solid #dc3545;
}

/* Quantity input */
#modal-cart .cart-items-table .item-quantity {
	width: 50px !important;
	height: 36px;
	text-align: center;
	border: 1px solid #ddd;
	border-radius: 6px;
	font-size: 14px;
	font-weight: 500;
}

#modal-cart .cart-items-table .item-quantity:focus {
	outline: none;
	border-color: #5c7c55;
	box-shadow: 0 0 0 2px rgba(92, 124, 85, 0.1);
}

#modal-cart .cart-items-table .item-quantity.updating {
	opacity: 0.6;
	background: #f5f5f5;
}

/* Price cells */
#modal-cart .cart-items-table td.text-right {
	font-size: 14px;
	font-weight: 600;
	color: #1a1a1a;
	white-space: nowrap;
}

/* Remove button */
#modal-cart .cart-items-table .btn-remove-item {
	color: #999;
	font-size: 18px;
	transition: color 0.2s ease;
}

#modal-cart .cart-items-table .btn-remove-item:hover {
	color: #dc3545;
}

/* Footer buttons - hide clutter, show only checkout */
#modal-cart .cart-items-table tfoot {
	display: block;
	position: sticky;
	bottom: 0;
	background: #fff;
	border-top: 1px solid #eee;
	padding: 16px 20px;
}

#modal-cart .cart-items-table tfoot tr {
	display: flex;
	justify-content: center;
}

#modal-cart .cart-items-table tfoot td {
	display: flex;
	gap: 10px;
	width: 100%;
	justify-content: flex-end;
}

/* Hide refresh, clear, and close buttons in drawer mode */
#modal-cart .cart-items-table tfoot .btn-refresh,
#modal-cart .cart-items-table tfoot .btn-clear-cart,
#modal-cart .cart-items-table tfoot .btn-close {
	display: none !important;
}

/* Style the Next/Checkout button prominently */
#modal-cart .cart-items-table tfoot .btn-next {
	flex: 1;
	background: #5c7c55 !important;
	color: #fff !important;
	border: none !important;
	border-radius: 8px;
	padding: 14px 24px;
	font-size: 15px;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: 0.5px;
	transition: background 0.2s ease;
	margin: 0 !important;
}

#modal-cart .cart-items-table tfoot .btn-next:hover {
	background: #4a6a45 !important;
}

/* Empty cart state */
#modal-cart .cart-empty-message,
#modal-cart .empty-cart-notice {
	text-align: center;
	padding: 60px 20px;
	color: #888;
}

#modal-cart .cart-empty-message i,
#modal-cart .empty-cart-notice i {
	font-size: 48px;
	color: #ddd;
	margin-bottom: 16px;
	display: block;
}

/* Loading state */
#modal-cart .ajax-overlay {
	background: rgba(255, 255, 255, 0.9);
}

/* Backdrop styling */
#modal-cart + .ctech-modal-backdrop,
.ctech-modal-backdrop {
	background: rgba(0, 0, 0, 0.5);
}

/* Mobile responsive - full width drawer */
@media (max-width: 480px) {
	#modal-cart .ctech-modal-dialog {
		width: 100%;
	}
	
	#modal-cart .ctech-modal-dialog.ctech-modal-lg {
		max-width: 100%;
	}
	
	#modal-cart .cart-items-table tbody tr {
		padding: 12px 16px;
	}
	
	#modal-cart .cart-items-table tfoot {
		padding: 12px 16px;
	}
}

/* Tablet - slightly wider drawer */
@media (min-width: 481px) and (max-width: 768px) {
	#modal-cart .ctech-modal-dialog {
		width: 380px;
	}
}

/* Hide the default modal header close button if present */
#modal-cart .ctech-modal-header {
	display: none;
}

/* ============================================
   Header Cart Icon - Click to Open Drawer
   ============================================ */

/* Make the cart container clickable */
.mod-sellacious-cart .mod-cart-container {
	cursor: pointer;
	transition: opacity 0.2s ease;
}

.mod-sellacious-cart .mod-cart-container:hover {
	opacity: 0.8;
}

/* Hide the dropdown hover menu since we use drawer now */
.mod-sellacious-cart .mod-cart-ul {
	display: none !important;
}

/* Style the cart count badge */
.mod-sellacious-cart .mod-total-products {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 20px;
	height: 20px;
	background: #5c7c55;
	color: #fff;
	border-radius: 10px;
	font-size: 12px;
	font-weight: 600;
	padding: 0 6px;
	margin-left: 4px;
}

/* Animation for cart count update */
@keyframes cartBounce {
	0%, 100% { transform: scale(1); }
	50% { transform: scale(1.3); }
}

.mod-sellacious-cart .mod-total-products.updated {
	animation: cartBounce 0.3s ease;
}

/* ============================================
   Cart Drawer - Cascading Items Layout
   ============================================ */

/* Items container - scrollable area for cart items */
#modal-cart .cart-drawer-items {
	flex: 1;
	overflow-y: auto;
	overflow-x: hidden;
	padding: 0;
	min-height: 0;
}

/* Individual cart item - stacked rows */
#modal-cart .cart-drawer-item {
	display: flex;
	flex-direction: column;
	padding: 16px 20px;
	border-bottom: 1px solid #f0f0f0;
	transition: background 0.2s ease;
}

#modal-cart .cart-drawer-item:hover {
	background: #fafafa;
}

/* Row 1: Image + Name/Supplier */
#modal-cart .cart-item-row-top {
	display: flex;
	align-items: flex-start;
	gap: 12px;
	margin-bottom: 12px;
}

/* Product image - thumbnail size like favourites list */
#modal-cart .cart-item-image {
	flex-shrink: 0;
	width: 50px;
	height: 50px;
}

#modal-cart .cart-item-image img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	border-radius: 6px;
	border: 1px solid #eee;
}

/* Product info (name + supplier stacked) */
#modal-cart .cart-item-info {
	flex: 1;
	min-width: 0;
	display: flex;
	flex-direction: column;
	justify-content: center;
}

#modal-cart .cart-item-name {
	font-size: 14px;
	font-weight: 500;
	color: #1a1a1a;
	text-decoration: none;
	display: block;
	line-height: 1.4;
	margin-bottom: 2px;
	/* Full name - no truncation */
	word-wrap: break-word;
	overflow-wrap: break-word;
}

#modal-cart .cart-item-name:hover {
	color: #5c7c55;
}

#modal-cart .cart-item-seller {
	font-size: 12px;
	color: #888;
	line-height: 1.3;
}

/* Error messages */
#modal-cart .cart-item-errors {
	margin-top: 6px;
}

#modal-cart .cart-item-error {
	font-size: 11px;
	color: #dc3545;
	background: #fff5f5;
	padding: 4px 8px;
	border-radius: 4px;
	border-left: 2px solid #dc3545;
	margin-top: 4px;
}

#modal-cart .cart-item-error i {
	margin-right: 4px;
}

/* Row 2: Controls - cascading right (quantity, unit price, subtotal, remove) */
#modal-cart .cart-item-row-controls {
	display: flex;
	align-items: center;
	gap: 12px;
	padding-left: 62px; /* Align with text (image width 50px + gap 12px) */
}

/* Quantity control */
#modal-cart .quantity-control {
	display: flex;
	align-items: center;
	border: 1px solid #ddd;
	border-radius: 4px;
	overflow: hidden;
	flex-shrink: 0;
}

#modal-cart .qty-btn {
	width: 28px;
	height: 30px;
	background: #f8f8f8;
	border: none;
	font-size: 16px;
	font-weight: 500;
	color: #666;
	cursor: pointer;
	transition: all 0.15s ease;
	display: flex;
	align-items: center;
	justify-content: center;
}

#modal-cart .qty-btn:hover {
	background: #eee;
	color: #1a1a1a;
}

#modal-cart .qty-btn:active {
	background: #ddd;
}

#modal-cart .qty-input,
#modal-cart .quantity-control .item-quantity {
	width: 36px;
	height: 30px;
	border: none;
	border-left: 1px solid #ddd;
	border-right: 1px solid #ddd;
	text-align: center;
	font-size: 13px;
	font-weight: 500;
	-moz-appearance: textfield;
	padding: 0;
	margin: 0;
	box-shadow: none;
	background: #fff;
}

#modal-cart .qty-input::-webkit-outer-spin-button,
#modal-cart .qty-input::-webkit-inner-spin-button,
#modal-cart .quantity-control .item-quantity::-webkit-outer-spin-button,
#modal-cart .quantity-control .item-quantity::-webkit-inner-spin-button {
	-webkit-appearance: none;
	margin: 0;
}

#modal-cart .qty-input:focus,
#modal-cart .quantity-control .item-quantity:focus {
	outline: none;
	background: #fafafa;
}

/* Unit price */
#modal-cart .cart-item-unit-price {
	font-size: 13px;
	color: #666;
	white-space: nowrap;
}

/* Subtotal */
#modal-cart .cart-item-subtotal {
	font-size: 14px;
	font-weight: 600;
	color: #1a1a1a;
	white-space: nowrap;
	margin-left: auto; /* Push to right */
}

/* Remove button */
#modal-cart .btn-remove-item {
	background: none;
	border: none;
	color: #ccc;
	font-size: 18px;
	cursor: pointer;
	padding: 4px;
	transition: color 0.15s ease;
	flex-shrink: 0;
}

#modal-cart .btn-remove-item:hover {
	color: #dc3545;
}

/* Updating state */
#modal-cart .cart-drawer-item.updating {
	opacity: 0.6;
	pointer-events: none;
}

/* ============================================
   Cart Drawer Footer
   ============================================ */

#modal-cart .cart-drawer-footer {
	border-top: 1px solid #eee;
	background: #fff;
	padding: 16px 20px;
	flex-shrink: 0;
}

#modal-cart .cart-summary {
	margin-bottom: 16px;
}

#modal-cart .cart-summary-row {
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding: 4px 0;
}

#modal-cart .cart-summary-total .summary-label {
	font-size: 14px;
	font-weight: 500;
	color: #666;
}

#modal-cart .cart-summary-total .summary-value {
	font-size: 18px;
	font-weight: 700;
	color: #1a1a1a;
}

#modal-cart .cart-summary-note {
	font-size: 11px;
	color: #999;
	text-align: right;
}

/* Action buttons */
#modal-cart .cart-actions {
	display: flex;
	flex-direction: column;
	gap: 10px;
}

#modal-cart .btn-checkout {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	background: #5c7c55;
	color: #fff;
	border: none;
	border-radius: 8px;
	padding: 14px 24px;
	font-size: 15px;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: 0.5px;
	text-decoration: none;
	cursor: pointer;
	transition: background 0.2s ease;
}

#modal-cart .btn-checkout:hover {
	background: #4a6a45;
	color: #fff;
}

#modal-cart .btn-checkout i {
	font-size: 14px;
}

#modal-cart .btn-view-cart {
	display: block;
	text-align: center;
	color: #666;
	font-size: 13px;
	text-decoration: underline;
	padding: 8px;
}

#modal-cart .btn-view-cart:hover {
	color: #1a1a1a;
}

/* ============================================
   Cart Drawer Empty State
   ============================================ */

#modal-cart .cart-drawer-empty {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	padding: 60px 30px;
	text-align: center;
	flex: 1;
}

#modal-cart .cart-drawer-empty .empty-icon {
	width: 80px;
	height: 80px;
	background: #f5f5f5;
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
	margin-bottom: 20px;
}

#modal-cart .cart-drawer-empty .empty-icon i {
	font-size: 32px;
	color: #ccc;
}

#modal-cart .cart-drawer-empty .empty-title {
	font-size: 18px;
	font-weight: 600;
	color: #1a1a1a;
	margin: 0 0 8px 0;
}

#modal-cart .cart-drawer-empty .empty-message {
	font-size: 14px;
	color: #888;
	margin: 0 0 24px 0;
}

#modal-cart .cart-drawer-empty .btn-continue-shopping {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	background: #5c7c55;
	color: #fff;
	border: none;
	border-radius: 8px;
	padding: 12px 24px;
	font-size: 14px;
	font-weight: 500;
	text-decoration: none;
	transition: background 0.2s ease;
}

#modal-cart .cart-drawer-empty .btn-continue-shopping:hover {
	background: #4a6a45;
	color: #fff;
}

/* ============================================
   Cart Drawer Mobile Optimizations
   ============================================ */

/* Prevent X button clipping when drawer width is constrained */
@media (max-width: 768px) {
	#modal-cart .cart-item-row-controls {
		padding-left: 0;
		gap: 8px;
	}
}

@media (max-width: 480px) {
	#modal-cart .cart-drawer-item {
		padding: 12px 16px;
		gap: 10px;
	}
	
	#modal-cart .cart-item-image {
		width: 56px;
		height: 56px;
	}
	
	#modal-cart .cart-item-name {
		font-size: 13px;
	}
	
	/* Reduce left padding to prevent X button clipping on narrow screens */
	#modal-cart .cart-item-row-controls {
		padding-left: 0;
		flex-wrap: wrap;
		gap: 8px;
	}
	
	#modal-cart .quantity-control {
		transform: scale(0.9);
		transform-origin: left center;
	}
	
	#modal-cart .cart-drawer-footer {
		padding: 12px 16px;
	}
	
	#modal-cart .cart-summary-total .summary-value {
		font-size: 16px;
	}
	
	#modal-cart .btn-checkout {
		padding: 12px 20px;
		font-size: 14px;
	}
}

/* ============================================
   Cart Drawer Loading Skeleton
   ============================================ */

@keyframes shimmer {
	0% { background-position: -200px 0; }
	100% { background-position: calc(200px + 100%) 0; }
}

#modal-cart .cart-skeleton {
	padding: 16px 20px;
}

#modal-cart .cart-skeleton-item {
	display: flex;
	gap: 12px;
	padding: 12px 0;
	border-bottom: 1px solid #f0f0f0;
}

#modal-cart .skeleton-image {
	width: 70px;
	height: 70px;
	border-radius: 8px;
	background: linear-gradient(90deg, #f0f0f0 0px, #e8e8e8 40px, #f0f0f0 80px);
	background-size: 200px 100%;
	animation: shimmer 1.2s ease-in-out infinite;
}

#modal-cart .skeleton-content {
	flex: 1;
}

#modal-cart .skeleton-line {
	height: 14px;
	border-radius: 4px;
	background: linear-gradient(90deg, #f0f0f0 0px, #e8e8e8 40px, #f0f0f0 80px);
	background-size: 200px 100%;
	animation: shimmer 1.2s ease-in-out infinite;
	margin-bottom: 8px;
}

#modal-cart .skeleton-line.short {
	width: 60%;
}

#modal-cart .skeleton-line.shorter {
	width: 40%;
}

#modal-cart .skeleton-line.price {
	width: 25%;
	height: 18px;
}

/* Hide old table-based layout when new layout is present */
#modal-cart .cart-drawer-items + .cart-items-table,
#modal-cart .cart-drawer-empty + .cart-items-table {
	display: none;
}

/* Cart drawer backdrop is now applied directly to .ctech-modal wrapper via JS */

/* Empty cart state styling */
.cart-drawer-empty {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	flex: 1;
	padding: 60px 20px;
	text-align: center;
}

.cart-drawer-empty .empty-icon {
	font-size: 64px;
	color: #ccc;
	margin-bottom: 20px;
}

.cart-drawer-empty .empty-title {
	font-size: 22px;
	font-weight: 600;
	color: #333;
	margin: 0 0 10px 0;
}

.cart-drawer-empty .empty-message {
	font-size: 14px;
	color: #888;
	margin: 0;
}