Improved template organization