It's only bad if it's part of blackmail or exchange (e.g. for grades, etc). Else, if it's a consentual relation, it's fine just like any other.
Lots of employees have had great relationships and marriages and kids with their bosses and vice versa. And even more students and professors had affairs (this will include someone like French President Macron). Humans are humans they don't easily compartmentalize their attraction or sexuality just because some bureaucratic rules say so.