Actually, Paul said that all sex is a sin. He says that he would that all were to refrain from sex, but if they could not, then they should marry to keep their sins to a minimum.
The medieval church said that sex was only acceptable between a married couple with the woman on her back and the man on top, so long as they did it to expand the church and received no pleasure from the act.
During the protestant reformation, new christian philosophy came to decide that sex was no longer sinful in marriage. The eighteenth century brought forth the concept of childhood and childhood innocence, suggesting that god would not condemn children of sin until they were old enough to understand the choice to sin or not. Neither of these ideas have any biblical basis.