Hiding a form after it was successfully submitted is easy with HTML Forms.
Open up your form, navigate to the “Settings” tab and toggle the setting shown below to “Yes”.
This will hide your form fields after the form is submitted without errors. The success message will still show.