/*
 * Pymetech responsive layer.
 * Desktop is intentionally untouched: every rule is scoped to <= 1024px.
 */

@media (max-width: 1024px) {
	html,
	body {
		max-width: 100%;
		overflow-x: clip;
		-webkit-text-size-adjust: 100%;
		text-size-adjust: 100%;
	}

	body:not(.elementor-editor-active) .elementor-invisible {
		visibility: visible !important;
		opacity: 1 !important;
		transform: none !important;
		animation: none !important;
	}

	body:not(.elementor-editor-active) .e-con,
	body:not(.elementor-editor-active) .elementor-column,
	body:not(.elementor-editor-active) .elementor-widget {
		min-width: 0;
	}

	body:not(.elementor-editor-active)
		.elementor:not(.elementor-location-header):not(.elementor-location-footer)
		:where(p, li, label, input, select, textarea, button, .elementor-button-text) {
		font-size: max(14px, 100%) !important;
		line-height: max(1.45em, 20px);
	}

	body:not(.elementor-editor-active)
		.elementor:not(.elementor-location-header):not(.elementor-location-footer)
		:where(h1, h2, h3, h4, h5, h6) {
		overflow-wrap: anywhere;
		text-wrap: balance;
	}

	body:not(.elementor-editor-active) .elementor-button {
		display: inline-flex;
		align-items: center;
		justify-content: center;
		font-size: 14px !important;
		min-height: 44px;
		max-width: 100%;
		white-space: normal;
		text-align: center;
		line-height: 1.25;
	}

	body:not(.elementor-editor-active) :where(img, picture, figure, iframe, video, canvas) {
		max-width: 100%;
	}

	body:not(.elementor-editor-active) .elementor-widget-image img {
		height: auto;
		object-position: center;
	}

	body:not(.elementor-editor-active) .elementor-widget-video iframe,
	body:not(.elementor-editor-active) .elementor-widget-video video {
		width: 100%;
	}

	.elementor-location-footer :where(h1, h2, h3, h4, h5, h6, p, a, li, span, strong, b) {
		color: #fff !important;
		font-size: max(14px, 100%) !important;
		line-height: max(1.45em, 20px);
		overflow-wrap: anywhere;
	}

	/* ERP: las pestañas se desplazan dentro del componente, no dentro de la página. */
	.page-id-105 .elementor-element-e23cf21,
	.page-id-105 .elementor-element-e23cf21 .e-n-tabs,
	.page-id-105 .elementor-element-e23cf21 .e-n-tabs-content,
	.page-id-105 .elementor-element-e23cf21 .e-n-tabs-content > .e-con {
		width: 100% !important;
		max-width: 100% !important;
		min-width: 0 !important;
	}

	.page-id-105 .elementor-element-e23cf21 .e-n-tabs-heading {
		display: flex !important;
		width: 100% !important;
		max-width: 100% !important;
		min-width: 0 !important;
		justify-content: flex-start !important;
		overflow-x: auto !important;
		overflow-y: hidden !important;
		overscroll-behavior-inline: contain;
		scroll-snap-type: inline proximity;
		-webkit-overflow-scrolling: touch;
		scrollbar-width: thin;
		padding-block-end: 6px;
	}

	.page-id-105 .elementor-element-e23cf21 .e-n-tab-title {
		flex: 0 0 auto !important;
		min-height: 44px;
		padding-inline: 18px !important;
		scroll-snap-align: start;
	}

	.page-id-105 .elementor-element-804905d,
	.page-id-105 .elementor-element-772ad45 {
		inset-inline: auto !important;
		width: 100% !important;
		max-width: 100% !important;
		margin-inline: 0 !important;
		padding-inline: clamp(16px, 4vw, 32px) !important;
	}

	/* Tablas y visores con ancho intrínseco: el desplazamiento queda local. */
	.page-id-116 .elementor-element-22e627e {
		width: 100% !important;
		max-width: 100% !important;
		overflow-x: auto !important;
		overflow-y: hidden;
		overscroll-behavior-inline: contain;
		-webkit-overflow-scrolling: touch;
		scrollbar-width: thin;
	}

	.page-id-116 .elementor-element-4abdbd9,
	.page-id-121 .elementor-element-0c5c167 {
		max-width: 100% !important;
		overflow-x: hidden !important;
	}

	.page-id-124 .elementor-element-d56470e {
		width: calc(100vw - 40px) !important;
		max-width: calc(100vw - 40px) !important;
		margin-inline: auto !important;
		align-self: stretch !important;
	}

	.page-id-124 .elementor-element-d56470e .elementor-heading-title,
	.page-id-124 .elementor-element-790eab31 .elementor-heading-title {
		font-size: clamp(30px, 4.5vw, 36px) !important;
		line-height: 1.08 !important;
		text-align: center;
		white-space: normal !important;
		overflow-wrap: anywhere;
	}

	/* Libro de reclamaciones: controles táctiles y etiquetas ordenadas. */
	.page-id-1545 #rt_form_libro,
	.page-id-1545 #responsive-form,
	.page-id-1545 #rt_form_libro .form-row-libro {
		max-width: 100%;
	}

	.page-id-1545 #rt_form_libro label {
		display: block;
		text-align: left !important;
		line-height: 1.45 !important;
	}

	.page-id-1545 #rt_form_libro :where(input:not([type='checkbox']):not([type='radio']), select, textarea) {
		width: 100%;
		max-width: 100%;
		min-height: 48px;
		font-size: 16px !important;
		line-height: 1.35;
	}

	.page-id-1545 #rt_form_libro textarea {
		min-height: 140px;
		resize: vertical;
	}
}

@media (min-width: 768px) and (max-width: 1024px) {
	/* Las tarjetas de cuatro columnas pasan a 2x2 para conservar lectura y precios completos. */
	.page-id-116 .elementor-element-4ba2484,
	.page-id-121 .elementor-element-3f3f2e8,
	.page-id-129 .elementor-element-ad61f8d,
	.page-id-105 .elementor-element-0d5bc19 {
		display: grid !important;
		grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
		gap: 24px !important;
		width: 100% !important;
		max-width: 100% !important;
		align-items: stretch !important;
	}

	.page-id-116 .elementor-element-4ba2484 > .e-con,
	.page-id-121 .elementor-element-3f3f2e8 > .e-con,
	.page-id-129 .elementor-element-ad61f8d > .e-con,
	.page-id-105 .elementor-element-0d5bc19 > .e-con,
	.page-id-129 .elementor-element-ad61f8d > .e-con > .e-con {
		width: 100% !important;
		max-width: none !important;
		min-width: 0 !important;
	}

	body:is(.page-id-105, .page-id-111, .page-id-116, .page-id-121, .page-id-124, .page-id-129)
		.elementor-inner-section
		.elementor-column.elementor-col-25 {
		width: 50% !important;
	}
}

@media (max-width: 767px) {
	body:not(.elementor-editor-active)
		.elementor:not(.elementor-location-header):not(.elementor-location-footer)
		:where(p, li, label, input, select, textarea, button, .elementor-button-text) {
		font-size: max(15px, 100%) !important;
		line-height: max(1.5em, 22px);
	}

	body:not(.elementor-editor-active) .elementor-button {
		font-size: 15px !important;
		min-height: 46px;
		padding-inline: 18px;
	}

	.elementor-location-footer :where(h1, h2, h3, h4, h5, h6, p, a, li, span, strong, b) {
		font-size: max(14px, 100%) !important;
		line-height: max(1.5em, 21px);
	}

	.page-id-105 .elementor-element-e23cf21 .e-n-tab-title {
		padding-inline: 16px !important;
	}

	.page-id-124 .elementor-element-d56470e {
		width: calc(100vw - 28px) !important;
		max-width: calc(100vw - 28px) !important;
	}

	.page-id-124 .elementor-element-d56470e .elementor-heading-title,
	.page-id-124 .elementor-element-790eab31 .elementor-heading-title {
		font-size: clamp(30px, 9vw, 36px) !important;
	}

	.page-id-1545 #rt_form_libro label,
	.page-id-1545 #rt_form_libro .form-row-libro {
		text-align: left !important;
	}
}
