You picked the wrong opponent.

Literal

Opponent [subject-が] bad was [confirmation-な].

相手が悪かった is an idiom-like expression meaning 'the opponent was a bad match (for you)' — i.e., you were outclassed. な at the end is a masculine sentence-final particle adding a reflective or sympathetic tone. Short, punchy, and often heard in manga/anime after a fight.