simplified hiding elements in main and footer