added legend to main page