OAKLAND, Calif. (AP) For the first 36 minutes, the game went as scripted for the Buffalo Bills. Then, in a span of a little more than 15 minutes, the game, and most likely their playoff hopes, fell out of the Bills' grasp.
Buffalo squandered a 15-point lead by allowing 29 straight points to the Raiders in a 38-24 loss Sunday that dealt a major blow to the playoff hopes for a franchise that hasn't made it to the postseason since 1999.
''You feel that momentum shift and it just snowballed on us,'' coach Rex Ryan said. ''Sometimes I think we lose confidence and you just can't let that happen to you.''
The Bills (6-6) had scored touchdowns on the first two drives of the second half to build a 24-9 lead before Derek Carr, Khalil Mack and the Raiders (10-2) took it over for Oakland's biggest comeback victory since 1999.
Carr engineered four touchdown drives in a span of 15:27, while the Bills went three-and-out on three straight possessions and then threw an interception by Tyrod Taylor that just about sealed the game. Buffalo was outgained 212-8 during that stretch.
''It was crazy,'' safety Corey Graham said. ''It was one of those situations where everything they did went right and we just couldn't make a play. I've never really been in a situation like that where everything went wrong, just like you couldn't make a play, and then those guys went on a roll and it was like everything they did turned to gold.''
The Bills fell two games behind Denver in the race for the second wild-card spot in the AFC and now will need lots of help to end the NFL's longest active playoff drought now that they are in a three-way tie for eighth place in the conference.
Buffalo appeared capable of putting together an impressive win against a top-notch opponent the way the offense opened the second half. LeSean McCoy ran 54 yards on the first play before Taylor scored on a 12-yard keeper after that to make it 17-9.
After forcing a three-and-out and a short punt, Buffalo methodically drove down field and scored again on Mike Gillislee's second TD run to make it 24-9.
''I just felt like this is a game that we had in our hands and we let slip away,'' said McCoy, who ran for 130 yards and added 61 more receiving.
Carr began carving up the Bills defense after that, throwing TD passes to Michael Crabtree and Amari Cooper in his sixth fourth-quarter comeback of the season.
The Raiders also had success on the ground with Latavius Murray scoring on two TD runs and even capitalized on two rare turnovers by the Bills to put the game away.
With Buffalo trailing by six points midway through the fourth, Mack got pressure and deflected a pass out of the end zone from Taylor that Nate Allen intercepted to set up Murray's second score that made it 38-24.
The Bills then got the offense moving on the next drive only to lose the ball when Mack broke through for a strip sack and recovered the fumble.
Buffalo had been on a record pace protecting the ball, committing just six turnovers coming into the game - the fewest ever in the NFL after 11 games.
''We just made it tougher on ourselves,'' Taylor said. ''But we have the type of guys in our locker room who can bounce back. As far as moving forward, we just have to out there and win.''
For more NFL coverage: http://www.pro32.ap.org and http://www.twitter.com/AP-NFL