MADRID — Cristiano Ronaldo came through for Real Madrid again, this time with a backheel flick that saved his team from a loss in the Spanish league.

Ronaldo netted an 87th-minute equalizer with a subtle touch of the ball with his back to the goal, redirecting a low shot by Luka Modric from outside the area to give Madrid a 1-1 draw against Athletic Bilbao on Wednesday.

The goal added to Ronaldo's impressive scoring run and kept Madrid in the fight for second place, three points from Atletico Madrid, which visits Real Sociedad on Thursday.

Barcelona, which drew 2-2 at Celta Vigo on Tuesday, holds a 12-point lead at the top of the standings.

Inaki Williams put Athletic ahead with a chip shot from inside the area in the 14th, but Madrid pressured throughout the match at Santiago Bernabeu Stadium until finally breaking through with the neat close-range touch by Ronaldo, who extended his scoring streak to 12 consecutive matches to tie his best run with the Spanish club. He has 22 goals during that streak, and 26 goals in total in his last 15 matches.

"We leave with mixed feelings," Athletic coach Jose Angel Ziganda said. "The team played well throughout the match. It was a pity to concede that goal in the end. We were close to victory."

Athletic goalkeeper Kepa Arrizabalaga, who reportedly was close to being signed by Madrid in the off-season, had a great performance to keep the hosts at bay earlier.

"To earn a positive result in this stadium, you need the goalkeeper to play well," Arrizabalaga said. "It makes you mad to concede the equalizer in the end, but if you look at the whole match, they created a lot of chances."

Athletic nearly made it 2-0 when Raul Garcia struck the crossbar with a shot from near the penalty spot in the 66th.

Ronaldo had struck the woodwork with a header early in the first half.

"We are happy with our performance but not with the result," Madrid coach Zinedine Zidane said. "We lacked calm on the final pass and ended up making too many crosses into the area, which was not ideal."

It was the third straight game without a win at home for Madrid.

Athletic, sitting 13th in the standings, was looking for its first win at the Bernabeu since 2005.

VALENCIA'S SETBACK

Valencia stayed in fourth place after a 2-1 home loss to Getafe, its second straight setback after a run of nine consecutive matches unbeaten.

It had won its last five games at Mestalla Stadium, with its last defeat coming against Real Madrid in January.

Loic Remy scored a goal in each half for Getafe, which moved to eighth place with the victory.

Rodrigo scored his seventh goal in seven matches to pull Valencia closer in the 69th.

The hosts played the final minutes with 10 men as Dani Parejo was sent off for elbowing an opponent.

ESPANYOL STRUGGLES

Espanyol lost 1-0 to Eibar at home, extending its winless streak to five matches and increasing pressure on coach Enrique "Quique" Sanchez Flores.

Fans jeered the team and called for Quique's dismissal after the loss, the team's third straight.

Espanyol, which hasn't scored in five matches, still remains in danger of relegation. It is in 16th place, nine points from the relegation zone.

Eibar, sitting 11th, hadn't won in sixth consecutive matches.

Defender David Lomban netted the game's winner with a 32nd-minute header.

___

More AP Spanish soccer coverage: https://apnews.com/tag/LaLiga

___

Tales Azzoni on Twitter: http://twitter.com/tazzoni