It definitely is a sin. Adultery occurs even by thinking about having intimate relations with someone other than one’s spouse. If you wish, I can show you the section of the Catechism of the Catholic Church that deals with this (I can also show you at least one quote from the Bible). The hardest thing to do is to face this sin and expel it from the mind. I strongly suggest Reconciliation as soon as possible. I also suggest not seeing this person any more. Avoid this person so as to protect yourself from temptation.
Your brother in Christ,
FdeS2