Highlight elements in the list using pattern matching
rg = RelationGraph[UnsameQ @ ## && Length@Intersection[##] >= 2 &, list]
hl = VertexList @ EdgeList @ rg
{{a, b, c}, {b, c, d}, {c, a, m}, {c, d, n}}
list /. x : Alternatives @@ hl :> Style[x, Gray]
list /. x : Alternatives @@ hl :> Highlighted[x, BaseStyle -> Red]
HighlightGraph[rg, hl]
You can also use ConnectedComponents
and select components with more than 1 vertex:
ccs = Select[Length @ # >= 2 &] @ ConnectedComponents[rg]
{{{a, b, c}, {b, c, d}, {c, a, m}, {c, d, n}}}
list /. x : Alternatives @@ # :> Highlighted[x, BaseStyle -> Red]& /@ ccs
ClearAll[formatList]
formatList[list_] := Module[{rules},
rules =
AssociationThread[
list -> (If[Max[#] >= 2, Gray, Black] & /@
Function[{element},
Length@Intersection[element, #] & /@
Complement[list, {element}]] /@ list)
];
Style[#, rules[#]] & /@ list
]
formatList[list]