Gokarna is a fantastic place and any place is safe depending on the area you choose to live in and how you choose to interact with the locals. Being a solo female traveller myself, I can tell you that I've been to places like Bali (which are very unsafe) and had safe experiences only by choosing to go to specific areas. Gokarna is a super safe place and it is much safer compared to Goa. There are budget resorts here too which are right on the beach and provide a safe and cheap escapade. Should do Gokarna!