noun
fraternization
frat-er-nuh-ZAY-shn/ˌfrætərnəˈzeɪʃn/
Friendly social contact, especially with people one is forbidden to associate with.
The guard's fraternization with the inmate includes a friendly chess game over tea.

Etymology
Originally an act of uniting as brothers, fraternization came to mean friendly social contact. Military use gave it the implication of crossing boundaries that discipline required people to respect.
In context
there are a few exceptions to fraternization such as if a couple is married prior to attaining their ranks and positions of differing status
More examples
- The company bans fraternization between supervisors and their direct reports.
- Guards face discipline for fraternization with prisoners.
- The annual picnic encourages fraternization among neighbors.
Forms
fraternize verb — To associate with others on friendly terms.
Similar words
- socializing
- Friendly interaction without necessarily suggesting forbidden or inappropriate contact.
- mingling
- Mixing casually with others, often at a social gathering.