Bhagavad Gita purely deals with spiritual aspect of life. As per Bhagavad Gita we are primarily a spirit, consciousness existing in our heart as soul atman. Furthermore it is this spirit, consciousness that manifested human form and not vice versa.
When the spirit within is the absolute master and controller of human body, the journey of life also belongs to soul atman within. Prime reason why Bhagavad Gita recommends indulging in karma, nishkama karma way of life!
At all stages of spiritual pursuit we could never attach self to fruits of karma performed. It was strictly prohibited. If we attached self to fruits of karma performed we could never undertake spiritual journey satisfactorily.
For a seeker, traveler of spiritual path, one indulging in spirituality all the time indulgence in sex was only meant for progeny. One just could not over indulge in sexuality. This may sometimes lead to promiscuity, adultery. When the human body was manifested by our soul atman, we just could not remain attached, attracted to bondages of flesh alone.
For a human being whose goal of life is not spiritual there was never a taboo on practice of sexuality. Only spiritual travelers indulging in spirituality like Swami Vivekananda were restricted in practice of sex, prime reason why Swami Vivekananda preferred remaining a bachelor all his life.
Sri Ramakrishna Paramhansa under pressure of family married early in life but his goal of life was different, purely spiritual. This led him to practicing spirituality even while living in family. After a certain stage in life Sri Ramakrishna Paramhansa considered his spouse, escort Ma Sharda as sister and later on as a Devi, a representative of mother earth.
A sincere and serious spiritual traveler would always indulge in sex only for the sake of progeny.