It depends on the casino and on the details of your case. If your account gets hacked, most casinos are happy to help you recover it, but you won’t get your bankroll refunded.