/* --------------------------------------------------------------------------
 * GRZ Gaming — stable native mobile receipt grid (v1.7.8)
 *
 * Presentation only. WooCommerce's variation, quantity and submit controls
 * keep their original nodes, values and handlers. This layer prevents legacy
 * WooCommerce/parent-theme clearfix pseudo-elements from becoming anonymous
 * grid items when the structural wrappers use display: contents.
 * ----------------------------------------------------------------------- */

@media (max-width: 620px) {
	/* Real storefront stacks may still attach clearfix pseudo-elements to these
	 * wrappers. With display: contents those generated boxes become grid items,
	 * producing the split white bands seen on products without an account step.
	 * The wrappers no longer establish boxes here, so their clearfix paint has
	 * no job and is safe to suppress. */
	.single-product .grz-tp-card--summary .single_variation_wrap::before,
	.single-product .grz-tp-card--summary .single_variation_wrap::after,
	.single-product .grz-tp-card--summary .woocommerce-variation-add-to-cart::before,
	.single-product .grz-tp-card--summary .woocommerce-variation-add-to-cart::after,
	.single-product .grz-tp-card--summary .grz-tp-cart-actions::before,
	.single-product .grz-tp-card--summary .grz-tp-cart-actions::after,
	.single-product .grz-tp-card--summary .grz-tp-action-row::before,
	.single-product .grz-tp-card--summary .grz-tp-action-row::after {
		display: none !important;
		content: none !important;
	}

	/* v1.7.7 gives each receipt child its own 14px logical inset. Remove the
	 * older body inset in the native two-step state so dividers, Qty/Total and
	 * actions share one clean alignment axis instead of a doubled 26px inset. */
	.single-product .grz-tp-card--summary:not(:has(.grz-caller-box)) > .grz-tp-card__body {
		padding-inline: 0;
	}

	/* The final summary row and purchase row meet at one deliberate divider.
	 * It is generated by the real summary row, not by structural wrapper
	 * pseudo-elements, so hidden optional rows cannot create an empty seam. */
	.single-product .grz-tp-card--summary:not(:has(.grz-caller-box)) .grz-tp-summary-row:last-child {
		border-bottom-color: var(--grz-mobile-receipt-divider);
	}

	/* Earlier compact-grid layers put a border on each of the three Total-row
	 * cells. The receipt row already has one full-width divider, so those cell
	 * borders would render as two short lines with a visible centre break. */
	.single-product .grz-tp-card--summary:not(:has(.grz-caller-box)) .grz-tp-qty--action,
	.single-product .grz-tp-card--summary:not(:has(.grz-caller-box)) .grz-tp-total__label,
	.single-product .grz-tp-card--summary:not(:has(.grz-caller-box)) .grz-tp-total__prices {
		border-top: 0;
	}
}
