FORT WORTH, Texas (AP) — Max Duggan and No. 13 TCU found themselves down in a hurry in their biggest game so far with coach Sonny Dykes.

When it was all over against eighth-ranked Oklahoma State, the Horned Frogs were getting swarmed by their fans after needing some extra time to wrap up an impressive comeback.

“It shows the culture of this team,” Duggan said.

Kendre Miller scored on a 2-yard run in the second overtime and TCU won 43-40 in a matchup of the Big 12’s last remaining undefeated teams Saturday. The Frogs trailed quickly after quarterback Spencer Sanders had TD runs on Oklahoma State’s the first two drives, and TCU still trailed by two touchdowns in the fourth quarter.

“Great win for our program,” Dykes said. “We made every mistake humanly possible in the first half, and guys just kind of kept hanging in there battling and I really thought we had a good mentality at halftime. … Then we just came out defensively in the second half and just played lights out.”

The teams traded touchdowns in the first overtime, with receivers getting wide open for big plays.

Duggan threw a 25-yard touchdown pass to a wide-open Quentin Johnston on the second play of overtime for TCU (6-0, 3-0 Big 12). The Cowboys were then facing fourth-and-9 when Sanders found Braydon Johnson by himself for a 23-yard gain to the 1, setting up Dominic Richardson’s tying TD run.

Oklahoma State (5-1, 2-1), which beat TCU 63-17 without Duggan last November, got the ball to start the second overtime. But the Cowboys had to settle for Tanner Brown’s fourth field goal, a 52-yarder, after a holding call and three consecutive incomplete passes.

It was pure pandemonium when Miller got into the end zone for his second touchdown. He finished with 104 yards rushing on 22 carries, including another TD on a 3-yard run in the fourth quarter.

Duggan completed 23 of 40 passes for 286 yards and two touchdowns, while Johnston had eight catches for 180 yards.

Sanders was only 16 of 36 passing for 245 yards with a touchdown and an interception after not practicing all week. He dinged his right (throwing) shoulder late in their win over Texas Tech last week, but insisted he was fine and that the lack of practice wasn’t the problem.

“It’s just football at the end of the day,” Sanders said. “I just had to physically come out and play better.”

The Cowboys led 24-7 five minutes into the second quarter after an incredible 22-yard TD catch by John Paul Richardson, who was tangled with cornerback Josh Newton, reached out his right hand and pulled the ball into his chest.

TCU used a little trickery to tie the game at 30-30 with 1:57 left in regulation. After a shift in the backfield for running back Emari Demarcado to take the shotgun snap, he handed the ball right back to Duggan, who found tight end Jared Wiley wide open in the right flat for a 10-yard touchdown. Wiley had a 13-yard catch two plays before that on that eight-play, 94-yard drive.

That followed a sequence when Sanders threw an interception with 7:18 left on a deep ball to Johnson, who appeared to get pushed by Bud Clark before the safety came down with the ball on the TCU 8. The Horned Frogs went three-and-out, but then Oklahoma State did the same before TCU’s tying drive.

“We know that we’re better than that, but I think that’s where the frustration comes in,” said Cowboys linebacker Mason Cobb, who had 16 tackles. “We’ve still got a lot more games left to play, so we’ve got to move on.”

THE TAKEAWAY

Oklahoma State: After taking the big lead in the second quarter, the Cowboys managed only two more field goals by Brown and didn’t score another touchdown until the overtime. … Oklahoma State had won six games in a row since their loss in the Big 12 championship game, and had won 11 of 12 overall.

TCU: Duggan, the senior who lost his starting job going into the season with the new coaching staff, has thrown for a Big 12-best 16 touchdowns in his five starts since taking back over after Chandler Morris sprained his left knee in the season opener.

“Max Duggan continues to play as good as football as any quarterback I’ve ever been around,” Dykes said.

POLL IMPLICATIONS

Oklahoma State and TCU could potentially cross paths in the new poll, with the Cowboys moving down and the Frogs moving up. Regardless, Oklahoma State most likely will extend its streak of consecutive top-15 rankings to 19 consecutive polls.

RUNNING SANDERS

Sanders, whose TD runs covered 29 and 8 yards, finished with 68 yards on 11 carries and took over the Oklahoma State record for career rushing yards for a quarterback. His 1,874 yards pushed him four yards past Brent Blackman’s career mark.

UP NEXT

Oklahoma State hosts No. 22 Texas (5-2, 3-1) next Saturday in its only home game in a four-week stretch.

TCU is home again next Saturday night to play No. 17 Kansas State (5-1, 3-0), which had an open date this weekend.

___

More AP college football: https://apnews.com/hub/college-football and https://twitter.com/ap_top25. Sign up for the AP’s college football newsletter: https://tinyurl.com/mrxhe6f2