If you've filed for divorce, and there's a disagreement regarding parenting time/custody, you are required to undergo mediation regardless of the county this is occurring in. In Cook, Mediation (for now) is free, but we're seeing 5 month return dates. Without knowing more about the pleadings involved, that's all I can say.
Best advice I can give; talk to a family law attorney in your area for specific guidance.
Without knowing more facts that would lead me to answer otherwise, your involvement with another person is not, in itself, a basis for your losing custody. Your relationship with the third party does not necessarily reflect on your ability to parent.
A weekly guide with tips and legal advice for each stage of the process.