Christian Pulisic converts his late-game penalty kick against Mexico. (Jack Dempsey/AP)

DENVER — The United States and Mexico renewed their fierce men’s soccer rivalry Sunday with all the usual venom and theater that has defined decades of memorable clashes.

And with a trophy at stake — in the Concacaf Nations League final, a precursor to 2022 World Cup qualifying this fall — the regional titans added another unforgettable layer to their storied history.

The United States won, 3-2, in extra time. If only it were that straightforward.

The bash whiplashed end to end, brought goals early and late in regulation, a goalkeeping change, multiple scuffles and video replays that overturned a Mexican goal and provided penalty kicks to each team in extra time.

Christian Pulisic, eight days removed from winning the Champions League with Chelsea, converted a penalty in the 114th minute to break the tie. Then Ethan Horvath, a Denver native who replaced Zack Steffen in net in the second half, saved Andres Guardado’s penalty four minutes into stoppage time of extra time.

“This game falls in line with the heritage of the U.S.-Mexico rivalry,” U.S. Coach Gregg Berhalter said. “We’re a part of it now, just like all the teams before us were part of it. Each and every game unfolds in a different way, and today is going to go down as one of the classic U.S.-Mexico games.”

Pulisic, 22, was in the middle of the decisive sequence, drawing contact that required video replay. He lashed his penalty kick into the top right corner for his 17th goal in 37 appearances.

The celebration in the corner brought a barrage of objects thrown by Mexican fans, one of which struck Gio Reyna in the head. He was helped to the bench. Berhalter said he would be okay.

Later, after a U.S. handball that required video review, Horvath dived to his right to preserve the lead.

“Overtime was just a complete mess, to be honest,” Berhalter said. “With everything that was going on in the game, the guys were able to still stay cool and focus.”

Said Mexican assistant coach Jorge Theiler: “I believe Mexico is a power in the region and the United States beating Mexico, you could see how they were celebrating. This is a rivalry.”

A young U.S. squad had fallen behind after just 62 seconds and drew even before halftime on a goal by 18-year-old Reyna. It faced another deficit in the 79th minute but answered three minutes later on a header by 22-year-old Weston McKennie.

The United States ended a string of four consecutive defeats to Mexico in the knockout stage of an official tournament. The last victory came in the 2007 Gold Cup final.

They might meet again in the Gold Cup this summer and are set to play twice in World Cup qualifying.

Starting the youngest U.S. squad for a final of any competition, Berhalter said on the eve of the final, “I’m looking forward to seeing how we are able to handle the magnitude of the final.”

It did not handle it well early.

DeAndre Yedlin passed back to Mark McKenzie deep in their defensive end. Under some pressure on both sides, McKenzie tried to play the ball wide. Jesus Corona intercepted at the top of the penalty area, took one touch, then ripped an angled eight-yarder over Steffen.

The Americans did begin to find some traction in the attack. Josh Sargent took advantage of a misplay on the right flank to stream into the box, but his off-balance bid was stopped by goalkeeper Guillermo Ochoa.

The Americans remained messy in the back, passing aimlessly and crumbling under pressure. They appeared to fall further behind in the 24th minute, when Hector Moreno was left unmarked at the edge of the six-yard box and nodded in Hector Herrera’s cross.

Video replay, however, showed Moreno a whisker offside when the pass was delivered, prompting referee John Pitti to annul the goal.

The swing in momentum was almost immediate and punishing.

In the 27th minute, McKennie headed Pulisic’s corner kick off the left post. The rebound caromed to Reyna poaching in the six-yard box and kept onside by Uriel Antuna. The son of a former U.S. captain (Claudio Reyna) stuck it past Ochoa for his third goal in seven senior appearances.

The rest of the half was bonkers. The Americans had additional chances, but their defensive and passing deficiencies left them exposed. As he did against Honduras, Steffen made a critical one-on-one save, this time on Hirving Lozano in the 43rd minute.

The intensity grew in the second half. Both teams threatened. A scuffle broke out. Berhalter adjusted his formation, playing with four in the back instead of three.

Steffen departed with a noncontact knee injury in the 69th minute; Horvath entered. Ochoa made a spectacular save on McKennie’s header off a corner kick. Mexico’s Nester Araujo shoved Berhalter when the coach tried to scoop up the ball as it crossed the sideline.

Mexico went back ahead in the 79th minute. A moment after entering, Diego Lainez created a sliver of space on the right side of the box, and with a quick release he beat Horvath to the near corner with a low, 15-yard shot.

Again, the Americans responded. A bad touch by a Mexican defender resulted in a corner kick in the 82nd minute. Reyna delivered it. On the back side, McKennie beat Jesus Gallardo to the header at the edge of the six-yard box and directed it into the near corner for his seventh international goal.

The way things were transpiring, extra time was not a foregone conclusion. Horvath made a soaring save on Lozano’s 25-yard rocket.

In stoppage time, the match was halted because some fans used a Spanish homophobic chant that has plagued Mexican matches for years. Additional incidents could have led to the match being abandoned and finished without a crowd the next day.

Extra time brought video replay when Pulisic was upended in the box. Then there was another review at the other end. Through it all, the Americans prevailed.

“We’re a young side and we need to learn how to win," Berhalter said. "These games are very difficult, and for us, it was about having a game plan, executing the game plan but then it’s also about the fight and spirit. … They really showed the heart of champions.”

Read more on soccer:

Jordan Siebatcheu was born in D.C., grew up in France and could have a bright USMNT future

Why the Champions League final represented a huge step forward for U.S. men’s soccer

USWNT roster for June friendlies offers clues about the Olympic squad