A teenager has admitted having illegal sex with an 11-year-old schoolgirl who reportedly became Scotland's youngest mother.
Sentence at the High Court in Edinburgh was deferred
The 15-year-old boy, who cannot be identified for legal reasons, had been charged with raping her.
He has pleaded guilty to a statutory charge of having unlawful sexual intercourse with a girl under the age of 13 years on 22 August 2005.
Sentence at the High Court in Edinburgh was deferred for background reports.
The court heard the girl became a mother to a baby daughter last month.
Advocate depute Graeme Jessop said: "She and the child were put in foster care together and are reported to be doing well.
"She maintains this is a private matter between her and the accused. She stated she still has feelings for the accused."
Lord Carloway ordered the teenager should be put on the sex offenders' register.
The court heard that the youth, who has no previous convictions, had been at a residential school with the girl's older brother.
He met her when she visited the school with her mother on a few occasions.
On the day of the incident the girl, from West Lothian, arrived in Edinburgh with a friend. They met her 15-year-old brother and another boy aged 11.
The advocate depute said: "The accused appears to have known the girl was the younger sister of his friend who he knew was 15."
The girl indicated that he had asked for her consent beforehand and "she fully agreed to sexual intercourse".
The teenager was interviewed by police and admitted having sex with the girl, but explained he thought she was 14 and it was entirely consensual.
The teenager was allowed bail at an earlier court appearance with a special condition that he did not approach the victim.