The third quarter of Thursday’s game between the Maryland women’s basketball team and Michigan was as tight a quarter the Terps have played all season. It had four ties and eight lead changes.

The final play of the quarter went Maryland’s way. With six seconds left and the game tied, forward Kiah Gillespie stole a Michigan pass. She fumbled and kicked the ball as she tried to push up the court but gathered possession as she approached the three-point line and the clock ticked below one second.

Gillespie pulled up in transition from just beyond the arc, and though the shot looked awkward, it was good enough for Gillespie’s second 3-pointer of the season and gave Maryland a 64-61 lead. Gillespie pumped her fist as the shot went in, and soon after, her teammates mobbed around her.

The Terps extended their lead from there and won, 83-70, for their sixth consecutive triumph to stay undefeated in Big Ten play.

“I thought I could shoot it from half-court — even though Coach [Brenda Frese] is not having that — after that [shot],” Gillespie said. “Especially going into the fourth quarter, it gave us the little buzz we needed.”

Maryland won the final quarter, 19-9, to close the game holding some of its biggest leads of the night.

If it weren’t for Michigan guard Katelynn Flaherty, the game likely would’ve been decided before that. Flaherty scored 13 points in the third quarter after finishing the first half with 14.

“Flaherty was sensational,” Frese said. “She really got into a groove in the third quarter.”

In response, Maryland’s defense hounded her in the fourth and allowed her just three points in the final 10 minutes.

“Our fourth quarter came down to defense and rebounding,” Frese said. “We did a really solid job to be able to put this game away.”

Much of that stemmed from center Brionna Jones, who missed some time in the second and third quarters in foul trouble. Still, Jones finished with 25 points, 10 rebounds and her ninth-consecutive double-double while pestering Michigan center Hallie Thome, who fouled out with nine points.

“It’s just effort and staying focused and locked in on all the little things,” Jones said.

Her foul trouble helped the Terps find a balanced offense, though. Guards Shatori Walker-Kimbrough and Kaila Charles scored 17 and 16 points, respectively. Gillespie pitched in nine points and six rebounds.

“Kaila and Kiah did a phenomenal job,” Frese said. “We didn’t miss a beat. That’s what you’re supposed to do.”

Yet Maryland was inconsistent in the first half. Frese said her team was “out of sync” defensively to start the game, which led to a 15-7 Michigan lead, spurred by a four-minute field goal drought from the Terps.

Guard Destiny Slocum ended that streak with a 3-pointer and hit another a couple of minutes later to help her team back into it, and guard Kristen Confroy buried a triple of her own to get the Terps within one as the first quarter ended.

“[We were] trying to figure out how they were defending us,” Frese said of her team’s early struggles.

Maryland carried the momentum into the second quarter via an 8-0 run that prompted a Michigan timeout, but the Wolverines closed the half on a 9-0 stretch, trimming the Terps’ lead to 39-35 at halftime.

Flaherty powered Michigan’s offense in the third period as the Wolverines shot 5-for-7 on 3-pointers. It didn’t help when Maryland missed its first five shots from beyond the arc and made just 41 percent of its attempts overall.

But then Gillespie beat the buzzer for Maryland’s only 3-pointer of the quarter, and her team never trailed again.