Sex at 17 weeks pregnant! Please answer

My husband and I were having sex and he gets a little rough sometimes. I'm not bleeding or cramping but My stomach did tense up a whole lot and it got hard and hurt for a very little time. Is the baby okay? I'm spazzing lol first time mom here