The semifinal lineup is complete at the 2015 CONCACAF Gold Cup following two marathon quarterfinals Sunday at MetLife Stadium in East Rutherford, New Jersey.
In the early match, Panama played to a 1-1 draw against Trinidad and Tobago over 120 minutes before winning 6-5 on penalties.
In the late game, Mexico needed a last-minute penalty in extra time to beat Costa Rica 1-0.
Here are the key takeaways from Day 13 at the Gold Cup.
Mexico moves on after controversial penalty
In the end, Mexico deserved the result. Just not this way.
After more than 120 minutes of scoreless football against a dogged Costa Rica side, Mexico finally broke through in the 124th minute as captain Andres Guardado slammed home a penalty. But that tells only part of the story.
The foul, according to referee Walter Lopez, occurred moments earlier, when Costa Rica's Roy Miller made the slightest of contact with Mexican striker Oribe Peralta. Replays suggested the penalty was soft at best—and nonexistent at worst. Costa Rica's players angrily confronted Lopez, who a few minutes earlier had failed to send off Peralta for a dangerous, scissored tackle on Elias Aguilar.
Guardado left no doubts with his finish, slamming in the penalty to send Mexico into the semifinals, where El Tri will face Panama on Wednesday in Atlanta.
And yet, for all the controversy, Mexico surely deserved to win the match. El Tri created the best chances, especially in the second half, and would have had a goal or two if not for some poor finishing on the part of Peralta and Carlos Vela.
That will serve as little consolation for Costa Rica, which defended with determination and even created a few chances of its own, notably through the exciting feet of Joel Campbell. After advancing to the quarterfinals of the World Cup last year, the Ticos disappointed this summer, failing to win any of their four Gold Cup games and finishing second in Group B behind Jamaica.
Mexico has been equally unimpressive, but all that matters is that El Tri remain alive. Coach Miguel Herrera faced enormous pressure to deliver a win Sunday night and could have been fired following a loss, but now El Piojo and his team have new life in the knockout stages of the Gold Cup.
Herrera, though, remains concerned by his side's lack of sharpness in front of goal. "That has been our main concern since the beginning of the tournament, to be effective up front," Herrera said, according to the Associated Press' Rachel Cohen. "Unfortunately we haven't been able to be as effective as we would want to."
Up next is a match against Panama, which also played 120 minutes Sunday. With both teams battling fatigue, anything could happen in the next round, but Mexico knows that it has the better, more talented players and will be confident of booking a place in the final.
Panama survives, but at a cost
Panama survived a penalty shootout against Trinidad and Tobago to advance to the semifinals following a 1-1 draw in the day's first quarterfinal.
The Central Americans took the lead in the 37th minute through Luis Tejada, following a failed clearance by Sheldon Bateau. Trinidad and Tobago drew level in the 54th minute as Kenwyne Jones headed in a Khaleem Hyland free kick.
Panama created the better chances in regular time and extra time, but Los Canaleros needed penalties to advance. In fact, they also needed Daneil Cyrus to miss his penalty when Trinidad and Tobago had a chance to win in sudden death.
Three rounds after Cyrus' miss, Blas Perez converted the final penalty for Panama in the ninth round to make it 6-5. Goalkeeper Jaime Penedo then pushed Lester Peltier's shot onto the bar to preserve the victory.
And so Panama's run continues despite a poor showing in the group stage and another uneven performance in the quarterfinals. For the fourth straight game at this Gold Cup, Hernan Dario Gomez's side took the lead before surrendering it. Los Canaleros still have a chance to match their run to the 2013 final, but to do so, they'll have to put together a solid 90 minutes for the first time in this tournament.
It won't be easy. After playing 120 grueling minutes in oppressive heat and humidity, Panama will have only two full days to recover for the semifinal. Then again, its opponent will have to overcome the same challenge.