:root.kwtw-modal-open {
	overflow: hidden;
}

.kwtw-whatsapp-button {
	--kwtw-color: #25D366;
	position: fixed;
	bottom: 24px;
	z-index: 999998;
	display: inline-flex;
	align-items: center;
	gap: 10px;
	min-height: 56px;
	padding: 0 18px;
	border: 0;
	border-radius: 999px;
	background: var(--kwtw-color);
	color: #fff;
	font: inherit;
	font-size: 15px;
	font-weight: 700;
	line-height: 1;
	cursor: pointer;
	box-shadow: 0 8px 24px rgba(0,0,0,.22);
	transition: transform .2s ease, box-shadow .2s ease;
}

.kwtw-whatsapp-button:hover,
.kwtw-whatsapp-button:focus {
	color: #fff;
	transform: translateY(-2px);
	box-shadow: 0 12px 28px rgba(0,0,0,.28);
}

.kwtw-whatsapp-button svg {
	width: 28px;
	height: 28px;
	flex: 0 0 auto;
}

.kwtw-position-right { right: 24px; }
.kwtw-position-left { left: 24px; }

.kwtw-modal[hidden] {
	display: none !important;
}

.kwtw-modal {
	position: fixed;
	inset: 0;
	z-index: 999999;
	display: grid;
	place-items: center;
	padding: 20px;
}

.kwtw-modal__backdrop {
	position: absolute;
	inset: 0;
	background: rgba(15, 23, 42, .58);
	backdrop-filter: blur(2px);
}

.kwtw-modal__dialog {
	position: relative;
	width: min(100%, 480px);
	max-height: calc(100vh - 40px);
	overflow: auto;
	padding: 30px;
	border-radius: 16px;
	background: #fff;
	color: #1f2937;
	box-shadow: 0 24px 70px rgba(0,0,0,.28);
}

.kwtw-modal__dialog h2 {
	margin: 0 36px 8px 0;
	font-size: 26px;
	line-height: 1.2;
}

.kwtw-modal__dialog > p {
	margin: 0 0 20px;
	color: #4b5563;
}

.kwtw-modal__close {
	position: absolute;
	top: 12px;
	right: 14px;
	width: 38px;
	height: 38px;
	padding: 0;
	border: 0;
	background: transparent;
	color: #374151;
	font-size: 30px;
	line-height: 1;
	cursor: pointer;
}

.kwtw-product-summary {
	margin: 0 0 20px;
	padding: 14px 16px;
	border-radius: 10px;
	background: #f3f4f6;
}

.kwtw-product-summary strong,
.kwtw-product-summary span {
	display: block;
}

.kwtw-product-summary span {
	margin-top: 5px;
	color: #4b5563;
	font-size: 13px;
}

#kwtw-lead-form label:not(.kwtw-consent) {
	display: block;
	margin: 15px 0 7px;
	font-weight: 700;
}

#kwtw-lead-form label span {
	font-weight: 400;
	color: #6b7280;
}

#kwtw-lead-form input[type="text"],
#kwtw-lead-form input[type="tel"] {
	box-sizing: border-box;
	width: 100%;
	min-height: 48px;
	padding: 10px 12px;
	border: 1px solid #d1d5db;
	border-radius: 8px;
	background: #fff;
	color: #111827;
	font: inherit;
}

#kwtw-lead-form input:focus {
	outline: 2px solid rgba(37, 211, 102, .2);
	border-color: #25D366;
}

.kwtw-consent {
	display: flex;
	gap: 10px;
	align-items: flex-start;
	margin: 18px 0;
	font-size: 14px;
	line-height: 1.45;
}

.kwtw-consent input {
	margin-top: 3px;
	flex: 0 0 auto;
}

.kwtw-consent a {
	text-decoration: underline;
}

.kwtw-error {
	margin: 0 0 12px;
	padding: 10px 12px;
	border-radius: 8px;
	background: #fef2f2;
	color: #b91c1c;
	font-size: 14px;
}

.kwtw-submit {
	--kwtw-color: #25D366;
	width: 100%;
	min-height: 50px;
	padding: 12px 18px;
	border: 0;
	border-radius: 9px;
	background: var(--kwtw-color);
	color: #fff;
	font: inherit;
	font-weight: 700;
	cursor: pointer;
}

@media (max-width: 767px) {
	.kwtw-whatsapp-button {
		bottom: 18px;
		min-width: 56px;
		width: 56px;
		height: 56px;
		padding: 0;
		justify-content: center;
	}

	.kwtw-whatsapp-button > span {
		position: absolute;
		width: 1px;
		height: 1px;
		padding: 0;
		margin: -1px;
		overflow: hidden;
		clip: rect(0,0,0,0);
		white-space: nowrap;
		border: 0;
	}

	.kwtw-position-right { right: 18px; }
	.kwtw-position-left { left: 18px; }

	.kwtw-modal {
		padding: 12px;
		align-items: end;
	}

	.kwtw-modal__dialog {
		width: 100%;
		max-height: calc(100vh - 24px);
		padding: 24px 20px;
		border-radius: 16px 16px 10px 10px;
	}
}


/*
 * Compatibilidad reforzada con temas, Elementor y estilos globales.
 * Se usan selectores específicos y !important únicamente en los colores
 * y propiedades visuales esenciales del botón.
 */
html body button#kwtw-open-modal.kwtw-whatsapp-button,
html body button#kwtw-open-modal.kwtw-whatsapp-button:hover,
html body button#kwtw-open-modal.kwtw-whatsapp-button:focus,
html body button#kwtw-open-modal.kwtw-whatsapp-button:active {
	-webkit-appearance: none !important;
	appearance: none !important;
	background: var(--kwtw-color) !important;
	background-color: var(--kwtw-color) !important;
	background-image: none !important;
	color: #ffffff !important;
	border: 0 !important;
	border-color: transparent !important;
	text-shadow: none !important;
	box-shadow: 0 8px 24px rgba(0,0,0,.22) !important;
	opacity: 1 !important;
}

html body button#kwtw-open-modal.kwtw-whatsapp-button:hover,
html body button#kwtw-open-modal.kwtw-whatsapp-button:focus {
	box-shadow: 0 12px 28px rgba(0,0,0,.28) !important;
}

html body button#kwtw-open-modal.kwtw-whatsapp-button,
html body button#kwtw-open-modal.kwtw-whatsapp-button span,
html body button#kwtw-open-modal.kwtw-whatsapp-button svg,
html body button#kwtw-open-modal.kwtw-whatsapp-button svg path {
	color: #ffffff !important;
	fill: currentColor !important;
}

html body .kwtw-modal .kwtw-modal__dialog button.kwtw-submit,
html body .kwtw-modal .kwtw-modal__dialog button.kwtw-submit:hover,
html body .kwtw-modal .kwtw-modal__dialog button.kwtw-submit:focus,
html body .kwtw-modal .kwtw-modal__dialog button.kwtw-submit:active {
	-webkit-appearance: none !important;
	appearance: none !important;
	background: var(--kwtw-color) !important;
	background-color: var(--kwtw-color) !important;
	background-image: none !important;
	color: #ffffff !important;
	border: 0 !important;
	border-color: transparent !important;
	text-shadow: none !important;
	opacity: 1 !important;
}


/* 1.3.1: botón flotante siempre circular y solo con icono */
html body button#kwtw-open-modal.kwtw-whatsapp-button {
	width: 58px !important;
	min-width: 58px !important;
	height: 58px !important;
	min-height: 58px !important;
	padding: 0 !important;
	justify-content: center !important;
	border-radius: 50% !important;
}

html body button#kwtw-open-modal.kwtw-whatsapp-button > span {
	position: absolute !important;
	width: 1px !important;
	height: 1px !important;
	padding: 0 !important;
	margin: -1px !important;
	overflow: hidden !important;
	clip: rect(0, 0, 0, 0) !important;
	white-space: nowrap !important;
	border: 0 !important;
}

html body button#kwtw-open-modal.kwtw-whatsapp-button svg {
	width: 30px !important;
	height: 30px !important;
	display: block !important;
}


/* 1.3.3: ajuste visual exclusivo del botón flotante */
html body button#kwtw-open-modal.kwtw-whatsapp-button {
	width: 60px !important;
	min-width: 60px !important;
	height: 60px !important;
	min-height: 60px !important;
	padding: 0 !important;
	display: flex !important;
	align-items: center !important;
	justify-content: center !important;
	border-radius: 999px !important;
	line-height: 0 !important;
}

html body button#kwtw-open-modal.kwtw-whatsapp-button svg {
	width: 38px !important;
	height: 38px !important;
	min-width: 38px !important;
	min-height: 38px !important;
	margin: 0 !important;
	padding: 0 !important;
	display: block !important;
	position: static !important;
	transform: none !important;
}

html body button#kwtw-open-modal.kwtw-whatsapp-button svg path {
	fill: #ffffff !important;
	color: #ffffff !important;
}
