Johannesburg:The United States turned Group B upside down at the Confederations Cup, moving from last place to a spot in the semi-finals ahead of both Italy and Egypt.
The Americans beat African champion Egypt 3-0 in Rustenburg on Sunday to overtake both the Egyptians and the Italians, who lost to Group B winner Brazil 3-0, in the standings.
Clint Dempsey headed in the deciding goal in the 71st minute, eight minutes after Michael Bradley gave the Americans hope with a goal in the 63rd. Charlie Davies also scored, sending a shot from point-blank range into the net off the hand of Egypt goalkeeper Essam El Hadary in the 21st.
"Big surprise, but we know we are capable of this," United States forward Landon Donovan said. "Good game for us, maybe not the best game for Egypt."
The United States, which advanced on goals scored, nearly had another in the 53rd when Hani Said blocked a shot from Jozy Altidore on the goal line first with his thigh and then with his arm. Appeals for a penalty went unheeded.
The Americans came into the match after a pair of losses, first to Italy after leading 1-0 and then to Brazil. But against Egypt, everything seemed to come together as they managed 10 shots on goal.
"We have a way of working on the inside," United States coach Bob Bradley said. "Playing against the top teams is important. It puts everything under a magnifying glass and tells us what we need to do and what we need to do better."
Egypt, however, looked to be the team that would advance heading into Sunday's matches. The African champions nearly held on for a draw with Brazil before losing 4-3 to a last-minute penalty by Kaka, and they then upset Italy 1-0.
But despite their quality play through the first week of the World Cup warm-up tournament, the Egyptians created little on Sunday.
"We played well in the last two matches but didn't have the concentration," Egypt assistant coach Chawki Gharib said. "We tried to play better but we accept this weakness that we had tonight."
In Pretoria, Luis Fabiano scored a pair of first-half goals for the Brazilians, who have fully recovered from the lackluster play that gave them the slim win over Egypt in their opening Group B match. The Brazil striker scored in the 37th and 43rd minutes.
"I'm very happy for having scored and with the match Brazil played," Luis Fabiano said. "It comes from a lot of effort and a lot of work."
Italy defender Andrea Dossena gave Brazil its third with an own-goal in the 45th.
"Unfortunately we're out, and we're very upset," Italy coach Marcello Lippi said.
Lippi again tinkered with his starting lineup, this time putting Luca Toni up front between Vicenzo Iaquinta and Mauro Camoranesi. Giuseppe Rossi, who started in the middle against Egypt after scoring twice as a substitute against the United States, came off the bench late in the first half on Sunday but couldn't find the net.
"We're really still trying to get to know each other," the American-born Rossi said. "We still have a lot of work to do and we hope we will do well the next time we come back here."
The United States will play in the first semifinal match against European champion Spain on Wednesday in Bloemfontein. Five-time world champion Brazil will face host South Africa on Thursday in Johannesburg.
"Now a very difficult game," Donovan said. "Very big match, difficult, but we have nothing to lose."
South Africa managed to advance to the semi-finals on Saturday despite losing to Group A winner Spain 2-0 because Iraq was a held to a 0-0 draw by New Zealand.
The final is set for next Sunday in Johannesburg.