The delivery of their first child was rough, and Kacie and Alejandro Torres looked forward to an easier one with their second, another girl.

But the then-24-year-old mother knew something was wrong as soon as she saw Emma. Medical staff yelled for chest compressions on the newborn.

“I started freaking out,” said Kacie, a former pastry chef who is now a stay-at-home mom to three children in Corona, California.

Tests showed Emma had a heart defect, and she was rushed to Children’s Hospital Los Angeles an hour away for open-heart surgery.

She had been born with total anomalous pulmonary venous return, a defect in which the veins that transport oxygen-rich blood from the lungs are not correctly attached to the heart. The blood returns to the wrong side of the heart, a problem that if not fixed could lead oxygen-starved organs to shut down.

Emma spent about a week after surgery connected to a machine helping her breathe and pumping blood through her body.

Her story of resilience is remarkable because she was “as close to death as you could be,” said John-Charles A. Loo, M.D., Emma’s pediatric cardiologist at Kaiser Permanente.

Today, the baby girl that doctors weren’t sure would survive is a healthy and chatty 4-year-old.

“She’s the silly one out of the siblings,” Kacie said.

Emma clowns around with sister Gabby, 6, and brother Eli, 1. She likes to dance, sing and dress up as her favorite Disney characters.

“She does everything a girl of her age should be doing,” said Alejandro, a 33-year-old high school math teacher.

The family nicknamed the mark on her chest: zipper scar.

In a Skype interview from her home, Emma squealed with laughter as she flipped through an album of photos taken during the early days of her life.

“What’s that thing on my head?” she asked her mother.

Kacie and Alejandro weren’t sure Emma would pull through and admit they were hesitant at first to get too attached. For weeks after she was born, they couldn’t even hold her.

“That was a really hard time,” Kacie said.

The experience taught Alejandro to let go of what he couldn’t control and accept that he couldn’t be the father and husband “who fixes everything.”

In a situation like that, he said, “the most you can do is support your family.”

Emma is doing well, but concerns for her health are never far from the couple’s thoughts. They exercise and eat healthy to keep themselves and their children well.

Kacie’s older sister, Kendall Eliason, has a soft spot for her niece, who she calls “Miracle Baby.”

“She’s a lot like Kacie — spunky and kind of crazy,” Eliason said. “She’s always so happy, and it’s just amazing to see the little girl that she’s turning into.”

Alejandro chronicled his daughter’s early days and the message delivered through his video sums it up: Emma’s journey continues.