The gods conspired against Japan on Sunday as Philippe Troussier's under-23s defeated Slovakia 2-1 to go the top of Olympic Group D, only to learn that Brazil had suffered a shock defeat to South Africa.

South Africa's 3-1 win in Brisbane has set up a crunch match between Japan and Brazil on Wednesday night.

Japan, coming off a 2-1 victory against the South Africans last Thursday, dominated Slovakia in front of 15,289 at Canberra's Bruce Stadium and looked set to book a quarterfinal spot after second-half goals from midfield stars Hidetoshi Nakata and Junichi Inamoto.