Thrush during pregnancy??

I’m 16weeks pregnant and somehow have thrush ? I’ve never had it before

How do I treat this when pregnant?/what causes it?