/*
Theme Name: Shoptimizer Child Theme
Theme URI: 
Description: Child theme of Shoptimizer
Author: CommerceGurus
Author URI: 
Template: shoptimizer
Version: 1.2.2
License:         	GNU General Public License v2 or later
License URI:     	http://www.gnu.org/licenses/gpl-2.0.html
*/

/* =========================================================
   LIME GARAGE — PRODUCT VARIATIONS
   Fabric Weight Cards
   ========================================================= */


/* Fabric Weight card stack */

.cgkit-attribute-swatches[data-attribute="attribute_pa_fabric-weight"] {
	display: flex !important;
	flex-direction: column;
	gap: 7px;
	width: 100%;
}


.cgkit-attribute-swatches[data-attribute="attribute_pa_fabric-weight"]
.cgkit-attribute-swatch {
	display: block !important;
	width: 100% !important;
	margin: 0 !important;
}


/* Individual Fabric Weight card */

.cgkit-attribute-swatches[data-attribute="attribute_pa_fabric-weight"]
.cgkit-swatch {
	display: flex !important;
	align-items: center;
	width: 100% !important;
	max-width: none !important;
	min-width: 0 !important;
	height: auto !important;
	min-height: 50px;
	padding: 10px 14px !important;
	border: 1px solid #dedede !important;
	border-radius: 4px !important;
	background: #fafafa !important;
	box-sizing: border-box;
	text-align: left !important;
	cursor: pointer !important;
	transition:
		border-color 0.15s ease,
		background-color 0.15s ease;
}


/* Hover */

.cgkit-attribute-swatches[data-attribute="attribute_pa_fabric-weight"]
.cgkit-swatch:hover {
	border-color: #888 !important;
}


/* Card content */

.limegarage-weight-card-content {
	display: flex;
	align-items: center;
	width: 100%;
}


/* Radio indicator */

.limegarage-weight-radio {
	position: relative;

	flex: 0 0 auto;

	width: 20px;
	height: 20px;

	margin-right: 10px;

	border: 2px solid #777;
	border-radius: 50%;

	box-sizing: border-box;

	background: transparent;
}


/* Selected radio center */

.cgkit-attribute-swatches[data-attribute="attribute_pa_fabric-weight"]
.cgkit-swatch.cgkit-swatch-selected
.limegarage-weight-radio::after {
	content: '';

	position: absolute;

	top: 50%;
	left: 50%;

	width: 8px;
	height: 8px;

	border-radius: 50%;

	background: #333;

	transform: translate(-50%, -50%);
}


/* Selected radio outline */

.cgkit-attribute-swatches[data-attribute="attribute_pa_fabric-weight"]
.cgkit-swatch.cgkit-swatch-selected
.limegarage-weight-radio {
	border-color: #333;
}


/* Fabric Weight text */

.limegarage-weight-card-text {
	display: block;
	min-width: 0;
	font-size: 14px;
	line-height: 1.35;
	color: #333;
	white-space: normal;
}


.limegarage-weight-name {
	font-weight: 600;
}


.limegarage-weight-card-description {
	font-weight: 400;
}


/* Selected card */

.cgkit-attribute-swatches[data-attribute="attribute_pa_fabric-weight"]
.cgkit-swatch.cgkit-swatch-selected {
	border-color: #555 !important;
	background: #f7f7f7 !important;
}


/* =========================================================
   Color Helper
   ========================================================= */

.limegarage-color-helper {
	padding: 6px 0;
	opacity: 0.7;
	font-size: 0.95em;
}


/* =========================================================
   Fabric Weight Availability
   =========================================================

   Fabric Weight is the primary choice.

   WooCommerce may temporarily mark a Weight unavailable
   because another attribute is selected. Keep the Weight
   interactive so our JS can clear Color first.
   ========================================================= */

.cgkit-attribute-swatches[data-attribute="attribute_pa_fabric-weight"]
.cgkit-swatch.cgkit-disabled {
	pointer-events: auto !important;
	opacity: 1 !important;
	cursor: pointer !important;
}


/* Don't show CommerceKit's crossed-out unavailable state
   on Fabric Weight. */

.cgkit-attribute-swatches[data-attribute="attribute_pa_fabric-weight"]
.cgkit-swatch.cgkit-disabled .cross {
	display: none !important;
}

/* =========================================================
   Lime Garage — Lifestyle Product Grid
   Default: Gallery image #1
   Hover: Featured product image
   ========================================================= */

/* Make the image wrapper our positioning context */
.lg-lifestyle-display .shoptimizer-plp-image-wrapper {
    position: relative;
}

/* FEATURED IMAGE
   Place over the gallery image, but hide initially */
.lg-lifestyle-display .shoptimizer-plp-image-wrapper > img:not(.gallery-image) {
    position: relative !important;
    opacity: 0 !important;
    visibility: visible !important;
    transform: none !important;
    transition: opacity 0.3s ease !important;
    z-index: 2;
}

/* GALLERY / LIFESTYLE IMAGE
   Position directly over the featured image and show initially */
.lg-lifestyle-display .shoptimizer-plp-image-wrapper > img.gallery-image {
    position: absolute !important;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 1 !important;
    visibility: visible !important;
    transform: none !important;
    transition: opacity 0.3s ease !important;
    z-index: 3;
}

/* HOVER — reveal featured image */
.lg-lifestyle-display .woocommerce-LoopProduct-link:hover
.shoptimizer-plp-image-wrapper > img:not(.gallery-image) {
    opacity: 1 !important;
}

/* HOVER — hide lifestyle image */
.lg-lifestyle-display .woocommerce-LoopProduct-link:hover
.shoptimizer-plp-image-wrapper > img.gallery-image {
    opacity: 0 !important;
}