Hello, Thanks for sharing your health concern with us. In the current scenario, it appears as though you are experiencing ovulation pain, presuming you have regular 28-30 day cycles. The correlation of spotting with the pain enhances the possibility of Mittelschmerz . The period you had the unprotected sexual intercourse should fall within the safe period, presuming the cycle length to be 28-30 days. Please note that ovulation occurs two weeks prior to the onset of the next period and this is the fertile phase of the cycle. Hope you find this information useful. Take care.