document.addEventListener('input', function (event) {
if (event.target.matches('.elementor-field-text')) { // Change the selector to match your field type
event.target.value = event.target.value.replace(/[^a-zA-Z\s]/g, ''); // Allows only letters and spaces
}
});