I was wondering what an "illegal relationship" was, and worried if I have had any myself :p

In Australia the laws on these sorts of things are generally centered around consent - so intercourse involving the young, people lacking mental capacity (through either the provision of drugs, or mental disorders), non-consensual intercourse between adults of age, and adults are all "illegal".

There are also illegal sexual acts (such as having sex in public places, for instance) but in this case it is the act, and not the relationship, which is deemed illegal.

I'd be surprised if any modern country had any laws fundamentally different to this.