Ecuador secured a nerve-wracking 0-0 draw with Mexico on Sunday to book their place in the Copa America quarterfinals, while Venezuela clinched the top spot in Group B with a 3-0 win over Jamaica.
Ecuador, needing only a point against Mexico in Glendale, Arizona, to advance on goal difference, withstood a furious late onslaught from 'El Tri' to reach the last eight.
Mexico launched wave after wave of attacks in the final quarter, with Johan Vasquez forcing a save from Ecuador goalkeeper Alexander Dominguez in the 71st minute, just six minutes after Santiago Gimenez struck the post with a close-range shot.
There was almost a dramatic twist deep into the eight minutes of added time when Guatemalan referee Mario Escobar awarded what would have been a winning penalty to Mexico after Ecuador's Felix Torres appeared to foul Guillermo Martinez in the area.
The Mexican-dominated crowd erupted in delight, only for the celebrations to be cut short when VAR instructed Escobar to review the decision.
Replays showed that Torres clearly got a touch on the ball in his challenge on Martinez, leading to the penalty being overturned.
Ecuador will now face Group A winners Argentina in the quarterfinals in Houston on Thursday.
Venezuela, meanwhile, will take on Group A runners-up Canada in Arlington on Friday as they chase a place in the semifinals.
The Venezuelans, who were already assured of a quarterfinal place after wins over Ecuador and Mexico, preserved their 100% record against winless Jamaica.
Eduard Bello headed Venezuela into the lead after 49 minutes, nodding home at the far post after a perfectly weighted cross from Jon Aramburu.
Veteran striker Salomon Rondon then doubled Venezuela's lead on 56 minutes, latching onto a through ball from Yangel Herrera and finishing low past advancing Jamaica goalkeeper Jahmali Waite.
A decisive victory was sealed in the 85th minute when Eric Ramirez was sent through on goal by Kervin Andrade before coolly finishing past Waite.