/**
 * Stage 05 (force-rerun) — CLS reserves + LCP geometry for home / listing.
 */

/* Header strip: reserve height so deferred chrome CSS does not shift first paint. */
.header-top {
	min-height: 72px;
}

.menu-top {
	min-height: 48px;
}

/* Match old UA/theme default: critical had vertical-align:middle on all img,
 * which shortens .header-phone__item line boxes (~4px) and recenters chrome via flex. */
.header-info img,
.header-phone__item img,
.header-mail img,
.header-adress img {
	vertical-align: baseline;
}

.slider-main {
	width: 100%;
	max-width: 100%;
	overflow: hidden;
	/* Theme-local light webp (1600×271 from PNG). Site-root /img/slider_back.webp left for old. */
	background: #0a6eb4 url(/wp-content/themes/twentytwelve-perf/img/slider_back.webp) no-repeat 50% 50% / cover;
	contain: layout paint;
}

/*
 * Match old first-viewport geometry: old uses typo class `containerа` so the slider
 * is full-bleed (1440×252 @ desktop). A real `.container` adds 15px padding +
 * object-fit:cover and shifts/crops the hero (~50%+ pixel delta).
 */
.slider-main > .container {
	max-width: none !important;
	width: 100% !important;
	padding-left: 0 !important;
	padding-right: 0 !important;
	margin-left: 0 !important;
	margin-right: 0 !important;
	aspect-ratio: 1920 / 336;
	height: auto !important;
	box-sizing: border-box;
}

.slider-main .huge_it_slideshow_image_wrap_1,
.slider-main .huge_it_slideshow_image_container_1,
.slider-main .huge_it_slider_1 {
	aspect-ratio: 1920 / 336;
	width: 100% !important;
	max-width: none !important;
	height: auto !important;
	min-height: 0;
	margin: 0 !important;
	padding: 0 !important;
	left: 0 !important;
	box-sizing: border-box;
}

.slider-main .huge_it_slideshow_image_1,
.slider-main .huge_it_slideshow_image_wrap_1 img.huge_it_slideshow_image_1 {
	width: 100% !important;
	height: 100% !important;
	max-width: none !important;
	display: block;
	aspect-ratio: auto;
	object-fit: fill;
}

.slider-main video {
	width: 100%;
	height: auto;
	max-width: 100%;
}

/* Hide loading gif flash that contributes to CLS before first slide paints. */
.slider-main #huge_it_loading_image_1 {
	display: none !important;
}

/*
 * MV-40: paint first hero slide without waiting for deferred bxSlider (home desktop LCP).
 * Non-first slides stay off-flow until hydrate/JS; first img keeps aspect and opacity.
 */
.slider-main .huge_it_slideshow_image_container_1,
.slider-main .huge_it_slider_1 {
	position: relative !important;
}

.slider-main li#image_id_1_0.huge_it_slideshow_image_item_1 {
	display: block !important;
	opacity: 1 !important;
	visibility: visible !important;
	position: relative !important;
	width: 100% !important;
	height: auto !important;
	z-index: 2;
}

.slider-main li.huge_it_slideshow_image_second_item_1 {
	position: absolute !important;
	left: 0;
	top: 0;
	width: 100%;
	height: 100%;
	opacity: 0 !important;
	pointer-events: none;
	z-index: 0;
}

.slider-main #huge_it_slideshow_image_1_0 {
	width: 100% !important;
	height: auto !important;
	aspect-ratio: 1920 / 336;
	opacity: 1 !important;
	visibility: visible !important;
	display: block !important;
}

.catalog__item-img {
	/* Reserve without shrinking ATF thumbs below old natural scale (~305px desktop / ~166px mobile). */
	contain: layout;
}

.catalog__item-img img {
	width: 100%;
	height: auto;
	max-width: 100%;
	display: block;
}

.types-slings__img,
.cargo-slings__item-img,
.benefits__item-img,
.prices-cargo__item-wrap {
	min-height: 1px;
	contain: layout;
}

.types-slings__img img,
.cargo-slings__item-img img,
.benefits__item-img img,
.prices-cargo__item-wrap > img {
	height: auto;
	max-width: 100%;
}

.subcategories-plates-wrapper {
	contain: layout;
}

/*
 * Match old ux.css plate geometry for pixel gate.
 * aspect-ratio 1/1 + width:100% + object-fit + min-height:2.6em
 * blew listing desktop first-viewport (~15% delta vs old 150×65 boxes).
 */
.subcategories-plates-wrapper .prod__item-content__image,
.subcategories-plates-wrapper .prod__item-content__image img {
	height: 150px;
	max-width: 100%;
	padding: 0 !important;
}

.subcategories-plates-wrapper .prod-item__category-title {
	min-height: 65px;
}

/* Tip over view-switch: keep out of flow to avoid desktop CLS. */
.new-product-list__head .view-switch {
	position: relative;
}

.new-product-list__head .view-switch .popover {
	position: absolute;
	z-index: 5;
	right: 0;
	left: auto;
}

.manual-price img {
	height: auto;
	max-width: 100%;
}

.slick-slider .m_p_author-logo img,
.slick-slider-logo .m_p_author-logo img {
	width: auto;
	height: auto;
	max-width: 100%;
}

/* Related / hits slider: reserve track height before late slick init. */
.related_slider .shop-products__list {
	min-height: 280px;
	contain: layout;
}

.new-product-list .product-item-2__table {
	contain: layout;
}
