refactoring index, changing bg colour