Major refactoring to clean up loose files and organize.