Added waiting class to main element