A court commissioner has ordered Britney Spears to undergo random drug testing and hire a parenting coach to help her raise her children with ex-husband Kevin Federline.
The documents, which were posted on celebrity news site TMZ.com, result from a Monday hearing in the bitter custody battle between Spears and Federline.
''Based on the evidence presented, the court finds that there is habitual, frequent and continuous use of controlled substances and alcohol by the petitioner,'' who is Spears, Superior Court Commissioner Scott Gordon wrote in his ruling.
Federline had been asking for increased custody, but Gordon maintained a 50/50 joint arrangement.
Gordon ordered both Spears, 25, and Federline, 29, to complete a ''parenting without conflict'' program, and said each must refrain from making derogatory remarks about the other.
But he saved his most stringent requirements for Spears, who in recent months has exhibited odd behavior after completing a rehab program in March.
Gordon ordered Spears to undergo testing for drugs and alcohol twice per week on random dates and times.
She must meet with a counselor at least once a week to address parenting issues and work with a parenting coach at least eight hours a week in at least two sessions per week.
Adding to her woes, the star has also been dumped by her managers as she struggles to rebuild her career after a heavily criticised public performance earlier this month.
A statement from Spears's manager Jeff Kwatinetz said his company had severed its links with the singer, who has been the subject of frenzied tabloid attention following her concert at the MTV Video Music Awards.
"It saddens us to confirm media reports that we have terminated our professional relationship with Britney Spears," Kwatinetz said in a statement released late yesterday.
"We believe Britney is enormously talented, and has made a terrific record, but current circumstances have prevented us from properly doing our job."
Kwatinetz was hired by Spears a month ago as the singer prepares to release her long-awaited new album in November.
After receiving a critical mauling following her performance in Las Vegas last month, several tabloid reports have said Spears's handlers grew frustrated at the singer's wild lifestyle and refusal to meet with them.
Meanwhile, Spears's lawyer Laura Wasser confirmed after a closed doors court hearing yesterday that she was no longer representing the star.
Wasser insisted, however, that the decision should not be perceived "that we're dumping Britney".