A SEX attacker was yesterday detained indefinitely in a secure hospital after his lawyer hit out at the national health service and begun a battle for his freedom.

Mentally impaired Mohammed Latif, 21, was sent to the Calderstones secure complex in Whalley, after Judge Raymond Bennett made a hospital admission order at Burnley Crown Court.

But the defendant's barrister announced immediately he planned to take the decision to the Court of Appeal.

Oliver Jarvis claimed it had been conceded Latif could be treated in the community but that option was not available because of a lack of health service resources.

He told the court it was wrong in principle to send Latif to hospital as he had now been on bail for more than two years.

Latif was refused bail pending appeal and because he could not be taken to hospital straight away will spend some time in jail first.

If his defence cannot persuade a higher court the sentence was wrong, he will stay in hospital until the Secretary of State or a mental health tribunal says he can be released.

Judge Bennett, who said the case had caused him a lot of concern as he had considered it over the weekend, told the court he had carried out a complete review of all the medical evidence available. He had concluded the hospital admission order was the proper one - but it was right the Court of Appeal should review it.

His comments came at the end of an almost year-long wrangle over Latif's fate after he molested a 15-year-old girl.

The judge had originally wanted to impose a supervision and treatment order so that the defendant could be helped in the community.

But, last week he was faced with the "stark," choice of giving him an absolute discharge and letting him go free or detaining him indefinitely at Calderstones as the only way he would get the treatment he needed.

Medics wanted him admitted as the hospital does not provide outpatient facilities to treat him in the Burnley area and the town's general hospital can't help out either.

Latif, of Montague Street, Brierfield, who is said to have a mental age of nine, had earlier been found not fit to plead. He was last April cleared by a jury of attempted rape on the schoolgirl in November 1999, but it found he did the act complained of the indecent assault.

Judge Bennett said yesterday he had to put high on the list the risk of Latif repeating his behaviour.