NEW YORK: Five-time champion Roger Federer found a new way to amaze Saturday as he reached the US Open last 16 with a 6-4, 6-1, 7-5 victory over Nick Kyrgios.

The second-seeded Swiss withstood an early onslaught from the unpredictable Aussie, firing 51 winners that included an unlikely forehand flicked around the net post that Kyrgios couldn’t believe.

“Definitely a bit of luck and good feet,” Federer said of the shot that had Kyrgios wide-eyed at the net.

The wonder shot was the talk of the day — but the night belonged to 2014 champion Marin Cilic and 19-year-old Australian Alex de Minaur, who battled for four hours on Louis Armstrong Stadium before Cilic pulled off a 4-6, 3-6, 6-3, 6-4, 7-5 victory.

De Minaur, ranked 45th in the world, pushed seventh-ranked Cilic until the bitter end, saving seven match points as he rallied from 5-2 down in the fifth set before finally succumbing after four hours on court.

“Incredible fighting spirit,” Cilic said of de Minaur after the young Aussie kept him on court until 2.22 am (0622 GMT) Sunday morning — the second-latest finish in US Open history.

Federer will take on Australian John Millman, who reached the last 16 of a major for the first time with a 6-4, 4-6, 6-1, 6-3 victory over Kazakhstan’s Mikhail Kukushkin.

Federer, Djokovic may meet in US Open quarters

If he makes it past Millman, Federer could find Wimbledon champion Novak Djokovic waiting in the last eight.

Djokovic, winner of US Open titles in 2011 and 2015, extended his dominance over Richard Gasquet with a 6-2, 6-3, 6-3 victory in front of a rowdy night crowd on the massive Ashe Stadium.

“It was the best match of the week so far without a doubt, and one of the best performances of the hardcourt season after Wimbledon,” said Djokovic, who warmed up for Flushing Meadows by beating Federer in the Cincinnati Masters final.

Djokovic saved all five break points he faced to book a meeting with Joao Sousa of Portugal, a 7-6 (7/5), 4-6, 7-6 (7/4), 7-6 (7/5) winner over France’s Lucas Pouille.

The third round was the end of the line for men’s and women’s fourth seeds from Germany; Alexander Zverev and Angelique Kerber.

Kerber, the 2016 US Open winner tying to become the third woman in the last 20 years to win both Wimbledon and the US Open in the same season, was bundled out by Slovakia’s Dominika Cibulkova 3-6, 6-3, 6-3.

Zverev, the 21-year-old sensation, who has lifted titles in Munich, Madrid and Washington this year and reached finals in Miami and Rome, fell 6-7 (1/7), 6-4, 6-1, 6-3 to veteran compatriot Philippe Kohlschreiber.

It was another Grand Slam disappointment for Zverev, touted as the youngster most likely to end the major dominance of Federer, Djokovic and Rafael Nadal.

Kohlschreiber will seek a quarter-final berth against 2014 runner-up Kei Nishikori after the Japanese downed Argentine Diego Schwartzman 6-4, 6-4, 5-7, 6-1.

Kerber’s defeat followed the early exits of world number one Simona Halep and Number 2 Caroline Wozniacki — who were both also seeking a second Grand Slam title of the year.