Finished form design and various bug fixes