    /* Flex-item min-width fix for our custom `<main id="gaya-product">`.
     * Our isolated template (2026-04-19) bypasses Astra's default wrappers
     * (`<main id="main">` → `<div id="primary">`), putting our <main> directly
     * inside `.ast-container` which is `display: flex`. Flex items default to
     * `min-width: auto`, which expands them to their intrinsic min-content.
     * The Flashy reviews web component reports a wide min-content (~2279px),
     * so without this rule the main element overflows the viewport horizontally
     * on desktop, stretching the summary column and gallery. `min-width: 0`
     * is the canonical fix — lets the flex item shrink to its parent width. */
    body.single-product #gaya-product {
        min-width: 0;
    }

    #ast-sticky-row-summary {
        animation: reveal 0s 0.5s both;
    }

    /* Thumbs wrapper height is set dynamically by assets/js/gallery-height-sync.js
     * (inline) to exactly 4 × actual thumb height. Using JS with `!important` priority
     * to beat the wp-custom-css `height: 504px !important` rule that can't be edited
     * from the theme without DB access.
     */
    body.single-product .woocommerce-product-gallery__wrapper > .woocommerce-product-gallery__image img.wvs-archive-product-image {
        object-fit: contain !important;
    }

    /* style.css defines `.container { width: 1440px }` for full-width sections (related
     * products, videos gallery). When used INSIDE .summary.entry-summary (FAQ accordion,
     * mobile customer-videos) it forces the summary column to stretch past its 50% width.
     * Scope an override so containers inside summary follow the column width.
     */
    body.single-product .summary.entry-summary .container {
        width: 100% !important;
        display: block !important;
    }
    @keyframes reveal {
        from { opacity: 0; }
        to   { opacity: 1; }
    }
	
	@media (min-width: 922px) {

    .ast-product-img-summary-wrapper {
        display: flex !important;
        flex-direction: row-reverse !important;
    }
    .summary.entry-summary {
        width: 50% !important;
        margin-left: 4% !important;
    }
}

	/* Single <h1> pattern
	 * ----------------------------------------------------------------
	 * The product H1 lives once in summary.php. On desktop it sits naturally at the
	 * top of the summary column. On mobile we need it ABOVE the gallery, so we turn
	 * the gallery/summary wrapper into a flex column and use `display: contents` on
	 * summary to bubble its children (incl. the H1) into the wrapper's flex flow.
	 * Then flex-order places the H1 first, gallery second, everything else after.
	 */
	@media (max-width: 921px) {
		body.single-product .ast-product-img-summary-wrapper,
		body.single-product [id^="product-"] {
			display: flex !important;
			flex-direction: column !important;
		}
		body.single-product .summary.entry-summary {
			display: contents;
		}
		body.single-product .summary.entry-summary > h1.product_title.entry-title {
			display: block; /* override style.css:4088 which hid duplicate h1; now it's the only one */
			order: 1;
		}
		body.single-product .summary.entry-summary > .product-subtitle {
			order: 2;
		}
		body.single-product .summary.entry-summary > .stamped-videos {
			order: 3;
		}
		body.single-product .summary.entry-summary > .product-price {
			order: 4;
		}
		body.single-product .woocommerce-product-gallery {
			order: 5;
		}
		body.single-product .summary.entry-summary > *:not(h1.product_title):not(.product-subtitle):not(.stamped-videos):not(.product-price):not(.product-warranty) {
			order: 6;
		}
		body.single-product .summary.entry-summary > .product-warranty {
			order: 7; /* below the add-to-cart form on mobile */
		}
	}

	/* Read-more collapse — SEO-friendly alternative to display:none.
	 * Hidden content stays in the DOM with full render-tree participation
	 * (Google gives it full weight), but is visually collapsed via max-height.
	 * Overrides style.css `.hidden-item { display: none }` via higher specificity.
	 */
	body.single-product .product-full-description .hidden-content {
		max-height: 0;
		overflow: hidden;
		transition: max-height 0.4s ease;
	}
	body.single-product .product-full-description .hidden-content.is-expanded {
		max-height: none;
	}
	body.single-product .product-full-description li.hidden-item {
		display: list-item;
		max-height: 0;
		overflow: hidden;
		padding-block: 0;
		margin-block: 0;
		border-width: 0;
		transition: max-height 0.3s ease;
	}
	body.single-product .product-full-description li.hidden-item.is-expanded {
		max-height: 500px;
		padding-block: revert;
		margin-block: revert;
	}

	/* Accordion heading wrapper reset.
	 * Accordion buttons are wrapped in <h3 class="accordion-heading"> for proper
	 * WAI-ARIA accordion semantics and SEO heading hierarchy. This zeros out the
	 * h3 defaults (margin, bold, larger font-size) so it acts as a transparent
	 * structural wrapper — the button inside keeps its original visual styling
	 * from style.css (.accordion button rules continue to match). */
	body.single-product .accordion-heading {
		margin: 0;
		padding: 0;
		font-size: inherit;
		font-weight: inherit;
		line-height: inherit;
		color: inherit;
	}

	/* Video section heading for the Tolstoy shoppable-video carousel.
	 * Visual language matches .faq-primary-heading so the design feels cohesive.
	 * The :has() fallback hides this H2 on products where the widget fails to
	 * inject its carousel (heading's next sibling is still .product_advantages
	 * instead of the widget). Prevents an orphaned "ראו את X בפעולה" with no
	 * video content below it. */
	body.single-product .gaya-video-section-heading {
		text-align: right;
		margin: 32px 0 14px;
		font-size: 22px;
		font-weight: 700;
		color: #472E23;
	}
	body.single-product .gaya-video-section-heading:has(+ .product_advantages) {
		display: none;
	}

	/* Related-products product title alignment.
	 * After downgrading the product-title tag from H2 → H3 (heading hierarchy fix),
	 * the H3 defaults to RTL-right alignment instead of centered. Explicitly center
	 * it so the card design stays identical to the previous H2 rendering.
	 * Scoped to .featured-products (our related sections) so other shop loops
	 * across the site are untouched. */
	body.single-product .featured-products .woocommerce-loop-product__title {
		text-align: center;
	}

	/* Visually-hidden heading fallback (WP core usually provides this, but safeguard
	 * it so our SEO-critical .screen-reader-text H2s keep the heading in the DOM
	 * without affecting layout. Clip-path pattern — standard a11y approach. */
	body.single-product .screen-reader-text {
		border: 0;
		clip: rect(1px, 1px, 1px, 1px);
		clip-path: inset(50%);
		height: 1px;
		width: 1px;
		margin: -1px;
		overflow: hidden;
		padding: 0;
		position: absolute !important;
		white-space: nowrap;
		word-wrap: normal !important;
	}

	@media (max-width: 601px) {

    .bundle_button {
        width: 100%;
    }

    .quantity.buttons_added {
        width: 20% !important;
    }

    button.single_add_to_cart_button.bundle_add_to_cart_button.button.alt {
        width: 70% !important;
        margin-right: 5% !important;
    }
}

	@media (min-width: 1024px) {

.woocommerce div.product form.cart .button.single_add_to_cart_button {
/*     width: 78%; */
}
}

/* ----------------------------------------------------------------
 * Section heading shared style — applied to every post-Tolstoy section
 * heading on the product page so they feel cohesive: right-aligned
 * (RTL), 22px / 700 weight, brand-brown color, identical 32/14px
 * vertical rhythm. The shared margin lives at the heading itself
 * (not the wrapper) so re-ordering sections in single-product.php
 * doesn't introduce double spacing.
 *
 *   .gaya-video-section-heading       — "סרטון הדגמה"
 *   .gaya-skin-types__heading          — "לאיזה סוג עור המוצר מתאים?"
 *   .product_advantages__heading       — "מה מיוחד ב X של גאיה"
 *   .gaya-bullets__heading             — "מה מיוחד ב X"
 *   .product-description-heading       — "כל מה שצריך לדעת על X"
 *   .gaya-faq-secondary-heading        — "שאלות נפוצות"
 *
 * .product_advantages__heading also needs flex-basis:100% so it spans
 * the full row inside .product_advantages (which is display:flex). */
body.single-product .gaya-video-section-heading,
body.single-product .gaya-bullets__heading,
body.single-product .product-description-heading,
body.single-product .product_advantages__heading,
body.single-product .gaya-skin-types__heading,
body.single-product .gaya-faq-secondary-heading {
	/* 64/16 ratio: heading is 4× closer to its own content than to the
	 * previous section. The 22px heading text eats into the perceived
	 * gap, so 48px felt cramped — 64px gives the section break enough
	 * breathing room to read as a clear visual divider. */
	margin: 64px 0 16px;
	font-size: 22px;
	font-weight: 700;
	line-height: 1.3;
	color: #472E23;
	text-align: right;
}
/* product_advantages__heading lives INSIDE the .product_advantages flex card,
 * so its top margin would push the card open. Reset it — the wrapper itself
 * gets the 48px from .product_advantages's spacing (handled below). */
body.single-product .product_advantages__heading {
	flex-basis: 100%;
	margin-top: 0;
}
/* The .product_advantages card itself takes the section top margin (from
 * style.css line 2502 it was 35px; we bump it to match the shared heading
 * rhythm of 64px so the visual break before each section is consistent). */
body.single-product .product_advantages {
	margin-top: 64px !important;
}

/* ----------------------------------------------------------------
 * Product bullets — "מה מיוחד ב X" benefit list.
 * Source: ACF repeater `gaya_bullets` (rendered by parts/bullets.php).
 * Custom CSS check-mark marker (no SVG dependency).
 * ---------------------------------------------------------------- */
body.single-product .gaya-bullets {
	margin: 0; /* spacing comes from .gaya-bullets__heading shared rule */
}
body.single-product .gaya-bullets__list {
	list-style: none;
	margin: 0;
	padding: 0;
}
body.single-product .gaya-bullets__list li {
	position: relative;
	padding-inline-start: 24px;
	margin-bottom: 10px;
	font-size: 15px;
	line-height: 1.5;
	color: #472E23;
}
body.single-product .gaya-bullets__list li::before {
	content: "";
	position: absolute;
	inset-inline-start: 0;
	top: 0.5em;
	width: 9px;
	height: 5px;
	border-inline-start: 2px solid #604136;
	border-bottom: 2px solid #604136;
	transform: rotate(-45deg);
}
body.single-product .gaya-bullets__list li:last-child {
	margin-bottom: 0;
}

/* ----------------------------------------------------------------
 * Skin types — "למי {product} מתאים?" icon + label grid card.
 * Source: ACF checkbox `gaya_skin_types` (rendered by parts/skin-types.php).
 * Visual: cream rounded card, 3-col grid, line-art SVG icon + Hebrew label.
 * ---------------------------------------------------------------- */
body.single-product .gaya-skin-types {
	margin: 0; /* spacing comes from the shared section-heading rule above */
}
/* .gaya-skin-types__heading styling is defined in the shared section-heading
 * rule near the top of this file. Keeping a duplicate ruleset here was
 * overriding the 64px top-margin and collapsing the section gap. */
body.single-product .gaya-skin-types__grid {
	display: grid;
	/* 5 explicit columns on desktop — matches the 5 standard skin-type values
	 * (normal, dry, combination, oily, sensitive_acne) so no orphan dead-cell.
	 * The mobile @media block below collapses to 2/3 columns based on width. */
	grid-template-columns: repeat(5, 1fr);
	gap: 14px 12px;
	list-style: none;
	margin: 0;
	padding: 22px 20px;
	background: #f5efe8;
	border-radius: 14px;
	/* explicit RTL ensures items flow start-from-the-right. */
	direction: rtl;
}
body.single-product .gaya-skin-types__cell {
	display: flex;
	align-items: center;
	gap: 12px;
	margin: 0;
	padding: 0;
	/* In RTL flex, flex-start = right side. Text+icon stay glued to each other
	 * (gap of 12px) instead of being pushed to opposite ends of the cell. */
	justify-content: flex-start;
}
body.single-product .gaya-skin-types__text {
	font-size: 15px;
	font-weight: 500;
	line-height: 1.3;
	color: #472E23;
	text-align: right;
}
body.single-product .gaya-skin-types__icon {
	display: inline-flex;
	width: 44px;
	height: 44px;
	flex-shrink: 0;
	color: #604136;
}
body.single-product .gaya-skin-types__icon svg {
	width: 100%;
	height: 100%;
	display: block;
}

/* On narrow viewports, drop to 2 columns so labels keep their breathing room.
 * If the cell count is odd, the last cell spans the full row and centers itself
 * — avoids the lonely-orphan-on-the-wrong-side-of-the-row look. */
@media (max-width: 600px) {
	body.single-product .gaya-skin-types__grid {
		grid-template-columns: repeat(2, 1fr);
		gap: 14px 16px;
		padding: 18px 16px;
	}
	body.single-product .gaya-skin-types__icon {
		width: 36px;
		height: 36px;
	}
	body.single-product .gaya-skin-types__text {
		font-size: 14px;
	}
	body.single-product .gaya-skin-types__cell:last-child:nth-child(odd) {
		grid-column: 1 / -1;
		justify-content: center;
	}
}


}