Refactored forms and templates