A married maths teacher was discovered under the bed of a pupil he was having sex with by her mother, a court has heard.
Andrew Welsh, 36, was caught when the girl's mother returned home unexpectedly one morning last July, after he begun a relationship with the "impressionable" girl last summer while she was taking her GCSE exams, Bolton Crown Court heard.
When the mother went upstairs, she found her daughter with ruffled hair and smudged lipstick. She then noticed a pair of man's boots at the side of the bed in the 16-year-old's room, Geoff Whelan, prosecuting, told the jury.
This "understandably aroused suspicion" in the mother, who asked the girl: "What are you doing? Who is here?"
Mr Whelan said: "However, as that was said, she looked down and saw movement in the drawer compartment within the girl's single divan bed and the valance sheet folded back.
"She saw movement of material which seemed to match the suit jacket her daughter was holding.
"The girl replied 'Mr Welsh'. Her mother ordered the defendant to get out from under the bed and recognised him from the school."
The court heard the relationship began last May when Welsh took her to his home. There, they sat on the couch and began kissing. They met again shortly after and had sex.
On 18 July last year, they had full sex for a second time at the girl's home, and the following day their relationship was uncovered by her mother.
The St Andrews University graduate also sent the girl a series of text messages, including: "You left your glorious scent on the pillow for days, I loved it."
Welsh insisted to police that all sexual activity took place when the girl was aged 16 and had left school, and that it was consensual. But the judge ruled the charges should stand because Welsh had been in a position of trust, to which he then pleaded guilty to all six charges against him.
Nicola Gatto, defending Welsh, told the judge the former head of year had lost his good standing in the community and career, and is now selling double glazing.
"He was flattered by the attention that this young woman gave him. It's clear as the relationship developed this man developed a real fondness for the girl.
"The other victim in all of this has been his wife and son. His wife is a GP and she has made the very difficult decision to stand by him.
"He has effectively ruined his own life. It's going to take many years for this man to piece his life back together again, a daily reminder of the huge mistake he has made."
Passing sentence Judge Knopf told Welsh: "You were nearly 20 years older than this girl. "It is you who has to bear the responsibility for what happened. She was attracted to you, you should have exercised the judgment which you clearly lacked when you decided to embark on this relationship with her.”
Welsh, of High Bank, Atherton, near Wigan, who is married to a local doctor, admitted six counts of sexual activity with a child while in a position of trust.
He was given a 14-month jail term, suspended for two years, and ordered to do 200 hours of community service. He was also ordered to sign the sex offenders register for 10 years.
Additional reporting by PA