Set class to an input with twig
You could use this in your theme:

function template_preprocess_input(&amp;$variables) {
  $variables['attributes']['class'][] = 'your_class';
}


and maybe even check the type like:

function template_preprocess_input(&amp;$variables) {
  if ($variables['attributes']['type'] == 'email') {
    $variables['attributes']['class'][] = 'your_class_email';
  }
}