Painful family matters are rarely simple, and when they become a matter for the courts, it’s rarely a neat fit.

The Appeals Court of North Carolina sent a case of termination of parental rights back to a local court to make it fit better with the wording in state law, and to make sure a Burlington woman will be able to afford to visit her children even if she can’t live with them.

The Appeals Court affirmed and vacated different parts of Alamance County District Court Judge Larry Brown’s decision terminating the parental rights of a mother with a history of drug addiction and family violence. It didn’t restore the woman’s rights to raise her children, but instructed the local court to clarify rules about paying the cost of a safe-visitation program and ordering more review hearings before the children can be placed permanently with their grandparents.

The woman’s parents — the “grandparents” in the court opinion — called the Department of Social Services in late summer 2017 saying the woman’s and the father’s — the “parents” — drug use was harmful to their children. The parents were renting a house in Burlington from the grandparents.

A week after allegations that the father had held the mother and children hostage, the mother left the children with the grandparents.

By late October, the mother entered a Temporary Parental Safety Agreement allowing the children to stay with her parents, stay sober and agree to supervised visits. Around the same time, the grandparents evicted the parents for not paying the rent. DSS lost touch with the mother after that, and had reports that she was back on drugs and the father was frequently abusing her.

Contacts with DSS and visits with the children were spotty at best, and in May the Alamance County District Court granted the parents visits with the children at Family Abuse Services’ supervised visitation program for an hour a week, and court-ordered services. The woman’s rules included staying clean, getting help, and participating in parenting.

By July, DSS asked that the mother’s visitation rights be suspended because she wasn’t participating. She agreed to grant guardianship of the children to the grandparents if she could have visits. There were still conditions, which she had trouble meeting, according to the court opinion. She also basically gave up her right to get the children back.

She appealed the court’s order in August.

The Appeals Court agreed with the mother that the local court should have waited until the children had been with the grandparents for a full year before permanently granting them custody without the required review hearings. The local court rationalized that the children had been with them collectively for more than a year, but not yet an uninterrupted year. The Appeals Court decided that was not the letter of the law and opened the door for abuse.

Reporter Isaac Groves can be reached at igroves@thetimesnews.com or 336-506-3045. Follow him on Twitter at @tnigroves.