TAMPA, Fla. (AP) With the clock running down in a tie game, the Detroit Lions didn't have any qualms about the ball being in Matthew Stafford's injured throwing hand.

They've come to expect their quarterback to find a way to lead them to victory in those situations, and Stafford didn't disappoint Sunday, when he threw for 381 yards and set up Matt Prater for a 46-yard field goal in the closing seconds to beat the Tampa Bay Buccaneers 24-21.

The victory stopped a two-game skid and kept the Lions (7-6) in playoff contention with three games remaining.

''I just think we have a lot of confidence. I think guys that have been around here have understood that sometimes that's the way the game boils down. We go out there and make plays,'' Stafford said after directing a winning drive in the fourth quarter or overtime for the 32nd time in his career.

''When you have success, it breeds confidence,'' he added, ''Frankly, there's been some times this year where we haven't been successful in those situations, some really close calls in some other games. It feels good to get back out there and have a two-minute drive, go down there and win the game.''

Stafford made his 109th consecutive start despite being limited in practice after his right hand was stepped on during the previous week at Baltimore . He completed 36 of 44 attempts against the Bucs (4-9), and the Lions overcame two interceptions and a fumble to stay alive for a playoff spot.

Jameis Winston rallied Tampa Bay, which has lost eight of 10 following a 2-1 start, with a pair of fourth-quarter TD passes. But once again, the Bucs' defense couldn't hold off an opponent down the stretch.

A week ago, the Bucs led by a field goal in the closing minutes of regulation before losing 26-20 in overtime at Green Bay.

''This team is always going to fight. We've just got to learn how to come out on the other side of these things,'' Tampa Bay defensive tackle Gerald McCoy said.

''We fought back last week. We fought back this week,'' McCoy, who left the game in the opening half with a biceps injury. ''It's a fine line between winning and losing. The fine line was a field goal today.''

Stafford moved the Lions 49 yards in eight plays to set up Prater's winning kick with 20 seconds left - the fourth winning drive he's led this season.

''Tough guy who heals quickly. It's always been that way,'' Lions coach Jim Caldwell said. ''He's a great leader. Did a tremendous out there for us under tough circumstances. ... He threw the ball pretty well. I'm sure it wasn't easy, but he did a nice job.''

Stafford threw a 5-yard TD pass to Golden Tate and Theo Riddick scored on runs of 2 and 18 yards to help the Lions take a 21-7 lead into the fourth quarter.

Winston, who threw two interceptions and lost a fumble, led a 75-yard drive that he finished with a 2-yard scoring pass to O.J. Howard and then used a 40-yard pass interference call against Detroit cornerback DJ Hayden to set a 2-yard TD throw to seldom-used offensive lineman Leonard Wester to make it 21-21 with eight minutes remaining.

Winston completed 26 of 38 passes for 285 yards. His fumble led to Riddick's second TD run. Tampa Bay finished with five turnovers, and Winston was sacked three times.

The loss ensures the Bucs, who haven't made the playoffs since 2007, will finish with a losing record . The team entered this season with heightened expectations after going 9-7 in their first year under coach Dirk Koetter, who now finds himself deflecting questions about whether his relationship with Winston - the top pick in the 2015 draft - is deteriorating.

''That's obviously news to me. I think Jameis and I have an extremely consistent relationship for the last three years. I don't think anything's different about it, but that's just my opinion,'' the coach added before shrugging off another question about if he was concern about speculation about a possible riff between the two.

''It concerns me that we're not winning enough games. That's my biggest concern,'' Koetter said. ''I know the truth about our relationship. My big concern is our football team.''

TOUGH GUY

Stafford's streak of 109 consecutive starts is the third-longest among NFL quarterbacks behind Matt Ryan (128) and Philip Rivers (119).

BAD CALL

It took two replay reviews for officials to get it right on a play initially ruled an incomplete pass and 15-yard penalty against the Lions for a hit on a defenseless receiver in the first half.

Officials first looked at Winston's first-quarter completion to Howard, who fumbled after being hit in the shoulder by safety Quandre Diggs at Detroit's 18-yard line. The Bucs retained possession when the play was ruled an incompletion and that a 15-yard penalty should be assessed from the spot of the previous play.

The Lions then successfully challenged the ruling of an incomplete pass. Following another review, referee Ed Hochuli announced Howard indeed caught the ball and took four steps before being hit, and the Lions were awarded the ball on the fumble recovery. There was no foul for the hit, which was legal.

INJURIES

Lions: Played without RT Rick Wagner (ankle), who was inactive.

Buccaneers: DT Gerald McCoy left in the first half with a shoulder/biceps injury and did not return.

UP NEXT

Lions: Return home to face Chicago on Saturday.

Buccaneers: Begin a stretch of three consecutive games to end the season against NFC South rivals, hosting Atlanta next Monday night.

---

For more NFL coverage: http://www.pro32.ap.org and http://www.twitter.com/AP-NFL

Copyright 2017 by AP. Any commercial use or distribution without the express written consent of AP is strictly prohibited.