/* Lalitha Herbals — product page layout (regular products). Uses the theme's colour/font variables. */

/* Hide sections whose ACF content is empty (live site only) */
.lhpl-hide-when-empty:has(.lhpl-empty):not(:has(.lhpl-filled)) { display: none !important; }
.lhpl-hide-when-all-empty:not(:has(.lhpl-filled)) { display: none !important; }
.elementor-editor-active .lhpl-hide-when-empty,
.elementor-editor-active .lhpl-hide-when-all-empty { display: flex !important; }
.lhpl-editor-hint { font-size: 13px; padding: 18px; }
.lhpl-placeholder { opacity: .9; }

/* Gallery: vertical thumbnails on the left (add class "lhpl-gallery--vertical" to the images widget) */
@media (min-width: 768px) {
	.lhpl-gallery--vertical .woocommerce-product-gallery {
		display: grid !important;
		grid-template-columns: 88px minmax(0, 1fr);
		gap: 14px;
		align-items: start;
	}
	.lhpl-gallery--vertical .woocommerce-product-gallery .flex-viewport,
	.lhpl-gallery--vertical .woocommerce-product-gallery__wrapper { grid-column: 2; grid-row: 1; }
	.lhpl-gallery--vertical .woocommerce-product-gallery .flex-control-thumbs {
		grid-column: 1; grid-row: 1;
		display: flex !important; flex-direction: column; gap: 12px;
		margin: 0 !important; max-height: 640px; overflow-y: auto; scrollbar-width: thin;
	}
	.lhpl-gallery--vertical .woocommerce-product-gallery .flex-control-thumbs li { width: 100% !important; margin: 0 !important; }
	.lhpl-gallery--vertical .woocommerce-product-gallery__trigger { left: auto; right: 16px; }
}
.lhpl-gallery--vertical .flex-control-thumbs img { border: 1px solid var(--lh-sand, #E2D8C6); background: var(--lh-paper, #FCFAF5); }
.lhpl-gallery--vertical .flex-control-thumbs img.flex-active { border-color: var(--lh-primary, #3A3C17); }

/* Rating */
.lhpl-stars { position: relative; display: inline-block; font-size: 15px; line-height: 1; letter-spacing: .14em; color: #D99A2B; }
.lhpl-stars::before { content: "★★★★★"; opacity: .25; }
.lhpl-stars__fill { position: absolute; inset: 0 auto 0 0; overflow: hidden; white-space: nowrap; }
.lhpl-stars__fill::before { content: "★★★★★"; }
.lhpl-rating { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; }
.lhpl-rating__text { font-size: 13.5px; color: var(--lh-muted, #6B6754); }

/* Buy now */
.lh-theme .lhpl-buy-now {
	display: flex; align-items: center; justify-content: center; width: 100%; min-height: 50px; padding: 0 24px;
	font-family: var(--lh-font-sans); font-size: 12.5px; font-weight: 500; letter-spacing: .16em; text-transform: uppercase;
	color: var(--lh-primary, #3A3C17); background: transparent; border: 1px solid var(--lh-primary, #3A3C17); border-radius: 0; cursor: pointer;
	transition: background-color .25s, color .25s;
}
.lh-theme .lhpl-buy-now:hover { background: var(--lh-primary, #3A3C17); color: var(--lh-ivory, #F8F5EE); }
.lhpl-buy-now[disabled] { opacity: .6; }
.lhpl-product-actions .lh-add-to-cart form.cart { margin: 0 !important; }

/* WhatsApp + trust row */
.lhpl-wa { display: inline-flex; align-items: center; gap: 8px; text-decoration: none; }
.lhpl-wa__icon { color: #25A244; display: inline-flex; }
.lhpl-wa__text { font-size: 11.5px; line-height: 1.3; color: var(--lh-text, #2C2D20); }
.lhpl-trust .elementor-icon-box-wrapper { align-items: center; }
.lhpl-trust .elementor-icon-box-title { margin: 0 !important; }
.lhpl-trust .elementor-icon-box-description { margin: 0; }

/* Feature icons under the short description */
.lhpl-features .elementor-image-box-img { margin-bottom: 8px !important; }

/* Benefits strip */
.lhpl-benefits {
	display: grid; grid-template-columns: repeat(var(--lhpl-cols, 4), minmax(0, 1fr));
	background: var(--lh-linen, #F1EBE0); padding-block: 30px;
}
.lhpl-benefit { text-align: center; padding: 6px 22px; display: flex; flex-direction: column; align-items: center; gap: 6px; border-color: var(--lh-sand, #E2D8C6); }
.lhpl-benefits--dividers .lhpl-benefit + .lhpl-benefit { border-left: 1px solid; border-left-color: inherit; }
.lhpl-benefit__icon img { width: 44px; height: 44px; object-fit: contain; }
.lh-theme .lhpl-benefit__title { margin: 6px 0 0; font-family: var(--lh-font-sans); font-size: 15px; font-weight: 500; letter-spacing: .01em; color: var(--lh-text, #2C2D20); }
.lhpl-benefit__text { margin: 0; font-size: 12.5px; line-height: 1.5; color: var(--lh-muted, #6B6754); }
@media (max-width: 767px) {
	.lhpl-benefits { row-gap: 22px; }
	.lhpl-benefits--dividers .lhpl-benefit:nth-child(odd) { border-left: 0; }
}

/* Key ingredients */
.lhpl-ingredients { display: grid; grid-template-columns: repeat(var(--lhpl-cols, 4), minmax(0, 1fr)); gap: 22px; }
.lhpl-ingredient { text-align: center; }
.lhpl-ingredient__img { height: 120px; display: flex; align-items: flex-end; justify-content: center; margin-bottom: 14px; }
.lhpl-ingredient__img img { max-height: 100%; width: auto; max-width: 100%; object-fit: contain; }
.lhpl-ingredient__img img.lhpl-placeholder { height: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 50%; }
.lh-theme .lhpl-ingredient__title { margin: 0 0 4px; font-family: var(--lh-font-sans); font-size: 14px; font-weight: 600; color: var(--lh-text, #2C2D20); }
.lhpl-ingredient__text { margin: 0; font-size: 12.5px; line-height: 1.5; color: var(--lh-muted, #6B6754); }

/* Texture banner */
.lhpl-texture {
	--lhpl-shade: rgba(248, 245, 238, .92);
	position: relative; overflow: hidden; min-height: 420px; height: 100%;
	display: flex; align-items: flex-start;
}
.lhpl-texture__img { position: absolute; inset: 0; width: 100% !important; height: 100% !important; max-width: none !important; object-fit: cover; }
.lhpl-texture::before { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, var(--lhpl-shade) 0%, transparent 62%); z-index: 1; }
.lhpl-texture__content { position: relative; z-index: 2; max-width: 62%; padding: 34px 32px; }
.lh-theme .lhpl-texture__title { margin: 0 0 12px; font-family: var(--lh-font-serif); font-size: clamp(1.6rem, 2.4vw, 2.1rem); font-weight: 500; color: var(--lh-primary, #3A3C17); }
.lhpl-texture__text { margin: 0; font-size: 14.5px; line-height: 1.6; color: var(--lh-text, #2C2D20); }
.elementor-widget-lhpl-texture,
.elementor-widget-lhpl-texture > .elementor-widget-container { height: 100%; }

/* How to use steps */
.lhpl-steps { display: grid; grid-template-columns: repeat(var(--lhpl-cols, 3), minmax(0, 1fr)); gap: 30px; }
.lhpl-step__img { width: 190px; max-width: 100%; aspect-ratio: 1; overflow: hidden; margin-bottom: 16px; background: var(--lh-linen, #F1EBE0); }
.lhpl-step__img img { width: 100%; height: 100%; object-fit: cover; }
.lhpl-steps--circle .lhpl-step__img { border-radius: 50%; }
.lhpl-steps--rounded .lhpl-step__img { border-radius: 18px; }
.lh-theme .lhpl-step__title { margin: 0 0 4px; font-family: var(--lh-font-sans); font-size: 14.5px; font-weight: 600; color: var(--lh-text, #2C2D20); }
.lhpl-step__text { margin: 0; font-size: 13.5px; line-height: 1.55; color: var(--lh-muted, #6B6754); }
@media (max-width: 767px) {
	.lhpl-step { display: grid; grid-template-columns: 110px 1fr; column-gap: 18px; align-items: center; }
	.lhpl-step__img { width: 110px; margin: 0; grid-row: span 2; }
}

/* Pro tip */
.lhpl-tip { position: relative; overflow: hidden; min-height: 320px; height: 100%; display: flex; align-items: flex-start; padding: 22px; background: var(--lh-linen, #F1EBE0); }
.lhpl-tip__img { position: absolute; inset: 0; width: 100% !important; height: 100% !important; max-width: none !important; object-fit: cover; }
.lhpl-tip__box { position: relative; z-index: 1; max-width: 62%; padding: 18px 20px; background: rgba(248, 245, 238, .9); }
.lh-theme .lhpl-tip__title { display: flex; align-items: center; gap: 8px; margin: 0 0 8px; font-family: var(--lh-font-sans); font-size: 14px; font-weight: 600; color: var(--lh-text, #2C2D20); }
.lhpl-tip__icon { color: #D99A2B; display: inline-flex; }
.lhpl-tip__text { margin: 0; font-size: 13.5px; line-height: 1.6; color: var(--lh-muted, #6B6754); }
.elementor-widget-lhpl-pro-tip,
.elementor-widget-lhpl-pro-tip > .elementor-widget-container { height: 100%; }

/* Carousels */
.lhpl-carousel { --lhpl-gap: 22px; position: relative; display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 12px; }
.lhpl-carousel__track { min-width: 0; }
.lhpl-carousel > .lhpl-carousel__track:not(:has(ul.products)),
.lhpl-carousel__track ul.products {
	display: grid !important; grid-auto-flow: column;
	grid-template-columns: none !important;
	grid-auto-columns: calc((100% - (var(--lhpl-cols, 3) - 1) * var(--lhpl-gap)) / var(--lhpl-cols, 3));
	gap: var(--lhpl-gap) !important;
	overflow-x: auto; scroll-snap-type: x mandatory; scroll-behavior: smooth; scrollbar-width: none;
	padding: 4px 2px 10px !important;
}
.lhpl-carousel__track::-webkit-scrollbar,
.lhpl-carousel__track ul.products::-webkit-scrollbar { display: none; }
.lhpl-carousel__track > *,
.lhpl-carousel__track ul.products > li { scroll-snap-align: start; }
.lhpl-carousel__track .woocommerce { width: 100%; }
.lh-theme .lhpl-carousel__arrow {
	width: 40px; height: 40px; padding: 0; min-height: 0; display: inline-flex; align-items: center; justify-content: center;
	font-size: 24px; line-height: 1; color: var(--lh-primary, #3A3C17); background: var(--lh-paper, #FCFAF5);
	border: 1px solid var(--lh-sand, #E2D8C6); border-radius: 50%; cursor: pointer;
}
.lh-theme .lhpl-carousel__arrow:hover { background: var(--lh-primary, #3A3C17); color: var(--lh-ivory, #F8F5EE); }
.lhpl-carousel.is-static .lhpl-carousel__arrow { visibility: hidden; }
.lhpl-carousel__dots { grid-column: 1 / -1; display: flex; justify-content: center; gap: 8px; }
.lhpl-carousel__dot { width: 7px; height: 7px; border-radius: 50%; background: var(--lh-sand, #E2D8C6); }
.lhpl-carousel__dot.is-active { background: var(--lh-primary, #3A3C17); }
@media (max-width: 767px) { .lh-theme .lhpl-carousel__arrow { display: none; } .lhpl-carousel { grid-template-columns: minmax(0, 1fr); } }

/* Review cards */
.lhpl-review { margin: 0; padding: 22px 22px 20px; background: var(--lh-paper, #FCFAF5); border: 1px solid #EEE6D6; display: flex; flex-direction: column; gap: 12px; }
.lhpl-review__text { margin: 0; font-size: 14px; line-height: 1.6; color: var(--lh-muted, #6B6754); }
.lhpl-review__text p { margin: 0; }
.lhpl-review__text p::before { content: "“"; }
.lhpl-review__text p::after { content: "”"; }
.lhpl-review__name { font-size: 14px; font-weight: 600; color: var(--lh-text, #2C2D20); }

/* Category link */
.lhpl-catlink { font-size: 12.5px; letter-spacing: .06em; color: var(--lh-text, #2C2D20); text-decoration: none; white-space: nowrap; }
.lhpl-catlink:hover { color: var(--lh-secondary, #45191F); }

/* Info tabs */
.lhpl-tabs__list { display: flex; gap: 34px; border-bottom: 1px solid var(--lh-sand, #E2D8C6); overflow-x: auto; scrollbar-width: none; }
.lh-theme .lhpl-tabs__tab {
	padding: 14px 0; margin-bottom: -1px; min-height: 0; background: none; border: 0; border-bottom: 2px solid transparent; border-radius: 0;
	font-family: var(--lh-font-sans); font-size: 14.5px; font-weight: 400; letter-spacing: .02em; text-transform: none;
	color: var(--lh-muted, #6B6754); white-space: nowrap; cursor: pointer;
}
.lh-theme .lhpl-tabs__tab:hover { color: var(--lh-primary, #3A3C17); background: none; }
.lh-theme .lhpl-tabs__tab[aria-selected="true"] { color: var(--lh-text, #2C2D20); font-weight: 600; border-bottom-color: var(--lh-primary, #3A3C17); }
.lhpl-tabs__panel { padding: 22px 0 0; font-size: 15px; line-height: 1.7; color: var(--lh-text, #2C2D20); }
.lhpl-tabs__panel:focus { outline: none; }
.lhpl-faq { border-bottom: 1px solid var(--lh-sand, #E2D8C6); }
.lhpl-faq summary { list-style: none; cursor: pointer; display: flex; justify-content: space-between; gap: 14px; padding: 14px 0; font-weight: 500; }
.lhpl-faq summary::-webkit-details-marker { display: none; }
.lhpl-faq__icon { position: relative; width: 12px; height: 12px; flex-shrink: 0; margin-top: 6px; }
.lhpl-faq__icon::before, .lhpl-faq__icon::after { content: ""; position: absolute; left: 0; right: 0; top: 50%; height: 1.5px; background: currentColor; }
.lhpl-faq__icon::after { transform: rotate(90deg); transition: transform .2s; }
.lhpl-faq[open] .lhpl-faq__icon::after { transform: none; }
.lhpl-faq__a { padding: 0 0 14px; color: var(--lh-muted, #6B6754); }
.lhpl-tabs__reviews #reviews #comments h2 { font-size: 1.6rem; }

/* Our promise */
.lhpl-promise .elementor-image-box-title { margin: 0 !important; }

/* Mobile spacing */
@media (max-width: 767px) {
	.lhpl-texture__content, .lhpl-tip__box { max-width: 88%; }
	.lhpl-texture { min-height: 300px; }
}
