Thank you for your questions Athena which I would like to cover in 2 sections, sins that deprive someone of heaven and secondly, Christian sex and marriage.
For the first section, the passage you are thinking of is 1 John 5:16-17. In that passage the apostle John mysteriously tells the Christian readers to pray for those committing sin, unless they are committing a sin which leads to death. Looking through John’s letter the possibilities would include denying Jesus (1:7; 2:22-28), disobedience (2:3-6; 3:4-6), hatred of one’s [Christian] brothers or sisters (2:9-11; 3:15-17) or love of the world (2:15-17). A good way to narrow down the possibility is to examine the positive argument - what behaviour guarantees eternal life? Here we can see several positive arguments such as these:
1 John 3:23-24 “And this is his command: to believe in the name of his Son, Jesus Christ, and to love one another as he commanded us. Those who obey his commands live in him, and he in them. And this is how we know that he lives in us: We know it by the Spirit he gave us.”
1 John 4:7-10 “Dear friends, let us love one another, for love comes from God. Everyone who loves has been born of God and knows God. Whoever does not love does not know God, because God is love. This is how God showed his love among us: He sent his one and only Son into the world that we might live through him. This is love: not that we loved God, but that he loved us and sent his Son as an atoning sacrifice for our sins.”
1 John 5:1-5Â “Everyone who believes that Jesus is the Christ is born of God, and everyone who loves the father loves his child as well. This is how we know that we love the children of God: by loving God and carrying out his commands. This is love for God: to obey his commands. And his commands are not burdensome, for everyone born of God overcomes the world. This is the victory that has overcome the world, even our faith. Who is it that overcomes the world? Only he who believes that Jesus is the Son of God.”
Based on these passages (also Matthew 12:31-32 and Mark 3:28-29) most Christians believe the unforgivable sin is denying Jesus as our Lord and Saviour either in word or by our actions.
I then view the second part of your question through this lens.
The Christian picture of sex and marriage is I think profound. Man and Woman are created for each other for life long exclusive union. In Genesis 2 we are told that a man leaves his mother and father to cling to his wife and they become one flesh, a picture of great unity. Thus the Bible affirms the goodness of sexual union within the context of marriage. Husband and wife are called to engage in sex (1 Corinthians 7:3-5) but that the unmarried should be self-controlled and if they cannot they should marry (1 Corinthians 7:8-9).
Your situation is even more difficult by virtue of marriage to a non-Christian which brings its own difficulties. If you are engaging in sex now then I would give you two encouragements. Firstly, as I’ve hinted at above it is not the sin which excludes you from heaven. If you trust in Jesus as your Saviour and Lord then the passages above make it clear that your sins are forgiven and you are born of God. Secondly however my encouragement would be to repent, that is cease sex until you are married - be obedient and honour God with your body. The Christian life is one of repentance and no matter how awkward it may feel, it is good to confess our failures to God, repent, and ask for his forgiveness knowing that he forgives those who seek him because of Jesus’ death on our behalf. The risk of defying God’s good purposes for sex is that you will harden your heart further against him and fall away from his grace (Hebrews 6:4-12).
Sorry for such a long response but it is my hope and prayer that you will trust that the Lord is good and depend on him through our Lord Jesus Christ.