Five-year-old Daniel Dana was poisoned by his mother in what prosecutors said was an act of jealous rage. (Courtesy of family members of Daniel Dana.)

In the two years since she poisoned her 5-year-old son with cold medicine and staged a fiery car crash with his body wedged on a back-seat floorboard, Narges Shafeirad has never publicly said why she did it.

On Monday, in a Maryland courtroom, she had her chance. Shafeirad, 35, spoke about a bitter divorce and custody fight she was enduring, and how she’d been ­depressed.

“I was a broken woman,” she said, adding that her son was everything to her. “I am still not able to believe that I have lost my son.”

Shafeirad’s words — spoken just before she was sentenced to 50 years for the murder of Daniel Dana — left the judge in front of a packed courtroom searching for an explanation.

“A mother murdering her child is a crime so horrific that it is natural to try to determine why,” said Montgomery County Circuit Court Judge Nelson Rupp, who had read a psychological evaluation of Shafeirad. “The only thing that I can conclude is that it was a determination made by the defendant for reasons only she knows of.”

Narges Shafeirad (Montgomery County Sheriff's Office)

Rupp noted that Shafeirad showed very little emotion in court, even as Daniel’s father and grandparents broke down as they spoke, and even as prosecutors detailed how she had forced the child to drink lethal doses of diphenhydramine, the active ingredient in drugs such as Benadryl.

“No visible indication of any reaction whatsoever,” Rupp said.

Earlier in the hearing, prosecutors listed bruises and abrasions around Daniel’s mouth that showed how Shafeirad force-fed him a full bottle of cold medicine. She continued doses every two to four hours until he was dead, according to prosecutors.

He probably experienced blurry vision, confusion, vomiting and possible seizures.

“I think there’s the impression, especially in this case, ‘Well, at least he wasn’t burned to death and he was poisoned to death,’ ” Assistant State’s Attorney Marybeth Ayres said. “Well, no, it’s not some peaceful thing where you just fall asleep. . . . Even to an adult, these things would be extremely scary.”

To try to cover her tracks, Shafeirad placed Daniel’s body in the back seat of her Toyota Corolla, drove to a gas station where she filled a gallon-water bottle with gas and later drove off the side of a road in Gaithersburg, doused the interior of the car with the gas and ignited the interior. She told detectives that she and Daniel had been on their way to the beach and that she had gasoline with her as a precaution in case she could not find an open gas station. As she was driving, she claimed, she lit a cigarette and the car caught on fire.

Shafeirad suffered burns on 40 percent of her body and was hospitalized for a month.

A bright, curious boy who was taking guitar and karate classes, Daniel was the only child of Shafeirad and Hamid Dana. The couple had met in Iran and married in 2007, according to court records. Daniel was born in 2009, and by 2011 all three were living in ­Gaithersburg.

But two years later, the couple separated and went through a bitter divorce, previous court filings show. Joint custody was worked out, with Daniel staying with his mother four days a week and his father three days a week, according to court documents. But the acrimony grew.

At one point, according to documents, Shafeirad told her husband: “I will make you cry. You will be sorry.”

Prosecutors picked up on statements such as that, saying Shafeirad was motivated by jealousy over a nanny her husband had hired, and by her financial insecurities.

“The defendant has demonstrated that she is willing to do whatever it takes, including murder her own son, in order to find peace in her own life,” prosecutors Ayres and Steve Chaikin wrote in court ­papers.

One of Shafeirad’s attorneys, Melanie Creedon, said her client wasn’t driven by jealous rage and that the 2015 crime did not follow a calculated plan. The custody battle, Creedon said, had left Shafeirad suffering from anxiety and a sense of “impending doom.” Shafeirad lost her job caring for an older person, and found out she was about to be evicted. “This was an act of a helpless and hopeless, broken woman who had basically reached the end, and who saw no way out,” Creedon said.

Hamid Dana, Daniel’s father, tried to address the judge Monday and tried to collect himself several times. He told the judge the last words he spoke to Daniel, when he was dropping him off at his mother’s and was worried about problems his son was having around her.

“I told him, ‘Please be strong,’ ” Dana said in court, his voice trembling. “He said: ‘Daddy, I’m strong. You be strong.’ ”

Dana had earlier composed a letter to Rupp.

“He was everything to me,” the father wrote of the effect of the killing. “Since my Daniel is gone and left me alone, I am gone, too. I am a hopeless person walking.”

In the letter, Dana addressed problems he’d had with Shafeirad, but said he always wanted to do right by Daniel and “find a way where Daniel could have both mother and father.”

He wrote: “I knew she was not caring for Daniel and yet I could not hold Daniel just to myself. So I kept praying that we would get through this time.”

Dana also wrote of plans and dreams he had for Daniel: the two of them fishing together, his son playing guitar in a band, Daniel’s succeeding in college.

Now, he wrote, his thoughts go to what happened in the early morning of June 16, 2015.

“I wake up at nights with nightmares. I keep seeing Daniel’s beautiful face being forced a bottle of poison. Daniel had a beautiful face but he didn’t like medicine. So I keep dreaming how Narges forced the medicine down his mouth, and that was the last thing Daniel experienced in this world. Why?”