/* ==========================================================================
   AFFANECOM - horizontal overflow fix
   Loaded last (priority 99).

   Cause: flex and grid items default to min-width:auto, which means they
   refuse to shrink below their content's intrinsic width. The marquee track is
   deliberately width:max-content, so its parent could not shrink, the hero
   container widened past the viewport, and the page-level overflow-x:clip then
   cut the right edge off everything instead of scrolling.

   Fixing min-width at the container level is the real repair; clipping the
   page was only ever hiding the symptom.
   ========================================================================== */

/* Elementor containers, their inner wrappers and widgets. */
.e-con,
.e-con-inner,
.e-con > .elementor-widget,
.elementor-widget,
.elementor-widget-container{
	min-width:0;
}

/* The marquee viewport must be allowed to shrink; only its inner track is
   wide, and that track is clipped by this element. */
.affan-hero-trustrow,
.affan-hero-trustrow[data-affan-marquee="1"]{
	min-width:0 !important;
	max-width:100% !important;
	width:100% !important;
	overflow:hidden !important;
}
.affan-marquee{
	min-width:0;
}

/* Same reasoning for every other horizontal scroller on the site. */
.affan-trust-row,
.affan-steps.e-con,
.woocommerce ul.products,
ul.products{
	min-width:0;
	max-width:100%;
}

/* Mobile header: the logo block must be able to shrink so the currency
   selector and menu toggle are not pushed off the edge. */
@media (max-width:921px){
	#ast-mobile-header .ast-builder-grid-row,
	#ast-mobile-header .site-header-primary-section-left,
	#ast-mobile-header .site-header-primary-section-right,
	#ast-mobile-header .ast-site-identity,
	#ast-mobile-header .ast-site-title-wrap{
		min-width:0;
	}
	#ast-mobile-header .site-header-primary-section-left{
		flex:1 1 auto;
		overflow:hidden;
	}
	#ast-mobile-header .site-header-primary-section-right{
		flex:0 0 auto;
	}
	#ast-mobile-header .site-title{
		overflow:hidden;
		text-overflow:ellipsis;
		white-space:nowrap;
	}
}

/* Long unbroken strings are the other common cause of a widened page. */
@media (max-width:767px){
	body{
		overflow-wrap:break-word;
	}
	.elementor-widget-text-editor p,
	.elementor-heading-title{
		min-width:0;
	}
}

/* Nothing may exceed the viewport, whatever else changes later. */
img,
video,
iframe,
canvas,
svg:not(.affan-fx__icon):not(.affan-tool__svg):not(.affan-fx__caret svg){
	max-width:100%;
}
