@media (max-width: 767px) {
	/* Prevent tiny text and iOS zoom triggers on storefront forms/content */
	html {
		text-size-adjust: 100%;
		-webkit-text-size-adjust: 100%;
	}

	body,
	input,
	select,
	textarea,
	button {
		font-size: 16px;
	}

	/* Keep media inside the mobile viewport */
	img,
	picture,
	video,
	iframe,
	svg {
		max-width: 100%;
		height: auto;
	}

	/* Make all primary tap targets meet Google's 44px guideline */
	button,
	.button,
	input[type="button"],
	input[type="submit"],
	input[type="reset"],
	a.button,
	.wp-element-button,
	.wc-block-components-button {
		min-height: 44px;
	}

	/* Shop/archive CTA buttons were collapsing too small on mobile */
	.woocommerce ul.products li.product .button,
	.woocommerce-page ul.products li.product .button,
	.woocommerce ul.products li.product a.button,
	.woocommerce-page ul.products li.product a.button {
		display: inline-flex;
		align-items: center;
		justify-content: center;
		width: 100%;
		min-height: 44px;
		padding: 12px 14px;
		text-align: center;
		line-height: 1.25;
		white-space: normal;
	}

	/* Single product CTA should span full mobile width */
	.single-product form.cart,
	.single-product .cart {
		width: 100%;
	}

	.single-product form.cart .single_add_to_cart_button,
	.single-product .cart .single_add_to_cart_button,
	.single-product .cart .button.single_add_to_cart_button {
		display: inline-flex;
		align-items: center;
		justify-content: center;
		width: 100%;
		min-height: 44px;
		padding: 12px 16px;
		text-align: center;
	}

	/* 404 recovery links need larger touch area */
	body.error404 a,
	body.error404 .button,
	body.error404 .wp-element-button {
		min-height: 44px;
		display: inline-flex;
		align-items: center;
	}

	/* Footer/legal links were readable but too short for touch */
	footer a,
	.site-footer a,
	.ct-footer a {
		display: inline-flex;
		align-items: center;
		min-height: 44px;
		padding-top: 8px;
		padding-bottom: 8px;
	}
}

/* =============================================================================
   REGALWEAR — Sticky product image column (desktop only)
   Added: 2026-07 · Fixes large empty space under product image
   ============================================================================= */

@media (min-width: 992px) {

    /* Make the product gallery column sticky so it follows the scroll */
    .single-product div.product .woocommerce-product-gallery,
    .single-product .rw-product-gallery,
    .single-product .product .images {
        position: sticky;
        top: 100px;
        align-self: flex-start;
        max-height: calc(100vh - 120px);
    }

    /* Ensure the parent container allows sticky positioning */
    .single-product div.product,
    .single-product .rw-product-layout {
        align-items: flex-start;
    }

    /* Prevent the gallery from stretching to match the summary column */
    .single-product div.product .woocommerce-product-gallery__wrapper {
        height: auto;
    }
}

/* Reduce excessive bottom padding on the summary column */
@media (min-width: 992px) {
    .single-product div.product .summary,
    .single-product .rw-product-summary {
        padding-bottom: 2rem;
    }
}

/* Theme-specific selectors — live markup uses rw-single-product__* classes */
@media (min-width: 992px) {
    .single-product .rw-single-product__gallery {
        position: sticky;
        top: 100px;
        align-self: start;
        max-height: calc(100vh - 120px);
    }

    .single-product .rw-single-product__layout {
        align-items: start;
    }

    .single-product .rw-single-product__summary {
        padding-bottom: 2rem;
    }
}
