You're calling "require" and then attaching the event handlers:
Code:
require(["jquery", "utility"], function ($, MO) {
		$("#username").on("focus", function () {
			$("#username").parent().removeClass("error");
		});
// etc.
});
So put those event handlers for username and submitImage INSIDE a jQuery on document load call, i.e.
Code:
require(["jquery", "utility"], function ($, MO) {
	$(function() {     // <--- new bit
		$("#username").on("focus", function () {
			$("#username").parent().removeClass("error");
		});
// etc.
         });    // <--- end of new bit
});
That way it will run after the document has been loaded and the event handlers will attach correctly.