LOS ANGELES — California firefighters who spent 20 minutes performing mouth-to-snout resuscitation on a dog they rescued from a burning apartment are being hailed as heroes.

The dog’s owner, 35-year-old Crystal Lamirande, had just returned to her Santa Monica apartment Tuesday when a neighbor yelled there was a fire.

Lamirande frantically tried to save her dog, a 10-year-old Bichon Frise/Shih Tzu named Nalu, but the smoke was too thick for her to go inside, she said Thursday.

Moments later firefighters arrived and Lamirande told them her dog was trapped inside.

That’s when firefighter Andrew Klein sprang into action, getting on all fours to search the apartment for Nalu as another firefighter sprayed water to keep the flames at bay. Klein found the unconscious dog a few feet from the fire in a bedroom.

“He was totally lifeless,” Klein said. “I picked him up and ran out of the apartment because time is key, especially with a small dog … Failure was not an option.”

As Lamirande knelt nearby crying, Klein and his crew spent the next 20 minutes working on reviving the dog using oxygen, CPR and what’s known as mouth-to-snout resuscitation.

Video taken by a passerby and posted on Facebook shows Klein and another firefighter patting Nalu’s belly as he starts breathing again with the help of oxygen.

“Alright, bud,” Klein tells the dog as he continues to rub him and encourage him to walk.

Lamirande, a radiology nurse, said she couldn’t believe how much time the firefighters took to save her dog, who she describes as family.

“His eyes were glazed over and he was not breathing and I assumed he was dead,” she said. “The firefighter said ‘I’m a positive person. Let’s just get him back.'”

Lamirande said Nalu spent the next 24 hours recovering in an oxygen chamber and was almost back to his normal self again Thursday.

“He’s been coughing but right now he’s fine and he’s so happy and smiling,” she said.

Klein, a self-described dog lover with two four-legged friends at home, said he felt proud of the outcome.

“He was essentially dead, so to see him kissing people and walking around wagging his tail was definitely a good feeling,” he said.

“He’s very happy, and we’re very happy, too.”