Refactored the main index page