が悪いんだ

be bad / be at fault

→ が
phrase Common #5,502
be bad / be at fault The meaning depends on what comes before が: it can mean being bad, wrong, at fault, unwell, or unlucky. んだ adds an explanatory or emphatic tone.
JA: 今回のことは私が悪いんだ。
EN: I'm the one at fault this time.

が悪いんだ

It's your fault.

家族と折り合いが悪いんだ

I don't get along well with my family.

ここは交通便が悪いんだ

Public transportation is inconvenient around here.

縁起が悪いんだって

Apparently, it's bad luck.

— 動くな、死ね、甦れ! (1990)

が悪いんだ

It was my fault to begin with.

— 映画 聲の形 (2016)

千草が悪いんだ

It's Chigusa's fault.

— バトル・ロワイアル (2000)

キャメロンが悪いんだ

Cameron has a foul mouth.

— いまを生きる (1989)

あんたが悪いんだ

It's your fault.

— レザボア・ドッグス (1992)

シアーシャが悪いんだ

It’s Saoirse’s fault!

— ソング・オブ・ザ・シー 海のうた (2014)