Ivorian Christian Kouame had shocked Carlo Ancelotti's side by opening the scoring after 20 minutes in a match which was suspended for 13 minutes around the hour mark because of torrential rain.
But substitute Ruiz pulled Napoli level immediately after play resumed, with defender Biraschi piling the misery on the hosts by turning into his own net three minutes from time.
Napoli move up into second place, three points behind champions Juventus who travel to AC Milan on Sunday, and three ahead of third-placed Inter Milan who play at Bergamo side Atalanta.
"This success is worth even more than three points, because it was achieved on a difficult pitch made heavy by the rain," said Brazilian midfielder Allan.
"We won and that's what is important. It gives us peace of mind before the (international) break."
Ancelotti's side proved wasteful in the first half with Lorenzo Insigne hitting the post and Poland's Arkadiusz Milik being denied in front of goal.
Dries Mertens started on the bench, with Polish pair Milik and Krzysztof Piatek up front for the visitors.
Insigne rattled the post on 11 minutes with Argentina defender Cristian Romero deflecting away a Zielinski strike.
But Kouame broke the deadlock from a Romulo cross, rising highest to nod in his second goal this season.
Home goalkeeper Andrei Radu punched a dangerous Insigne cross off the head of Jose Callejon, before denying Milik with 10 minutes left of the first half.
Ancelotti's side had already lost in Genoa this season when they fell 3-0 to Sampdoria, and another defeat was looming as the rain came down.
But Ruiz found a way through when Allan crossed to Mertens whose clever backheel in the penalty area set up the Spaniard to beat Radu.
Biraschi worsened Genoa's current crisis amid a scramble in his own goalmouth, as they slipped to a third straight loss after last week's 5-0 thrashing by Inter.
"It hurts to lose to a late own goal," said Genoa coach Ivan Juric.
Gervinho strikes for Parma
Earlier, promoted Parma came away with a 2-1 win from Torino to move level on 17 points with their rivals for a Europa League spot, who sit in eighth.
Walter Mazzarri's side are unbeaten since losing to Napoli on September 23.
Former Arsenal winger Gervinho scored his third goal this season after a defensive mix-up from Armando Izzo and Cameroonian Nicolas Nkoulou saw the Ivorian surge forward with a brilliant solo run after nine minutes, with Roberto Inglese adding a 25th-minute second.
Daniele Baselli pulled one back for Torino eight minutes before the break.
Cagliari came from two goals down to grab a point at SPAL.
Andrea Petagna headed in after less than three minutes for SPAL with captain Mirco Antenucci drilling in the second on 71 minutes.
But Cagliari battled back and five minutes later were level as Leonardo Pavoletti headed in a corner and Artur Ionita equalised with a quick turn and shot.