Please don't worry, this is the process they go through as they develop their social awareness. They have their friendly to everyone phase then they get a little older and their brains start to develop a sense of 'stranger danger' and they need time and experience to work out who is in the stranger category. Keep talking to her about these are your family, we know them well, we can play with them. At 3 it's a nice time to get them into some simple games that teach turn taking like pop up pirate or some of the orchard card games. It's a foundation social skill, can build their confidence in interactions and it's a bit of nice bonding time.
Also noticed shyness… i know i was a shy kid…