"hacked" would imply they targeted you specifically.
Broke into the password database, found your credentials, decrypted your password, and then logged into your account. Unlikely scenario but possible. No hacker would risk such length to steal accounts unless that account is worth a lot, like, a really really lot.
Likely scenarios:
Same credentials used elsewhere, copy paste.
You entered your credentials on an account recording website.
Your account name was laid bare to the world, password guessable, or password brute forced.
Database leak.
Lately I've been working to use one password, and one login per medium I sign up for. But, that is getting difficult to do nowadays. The list is getting painful. really difficult to remember 50+ different 8-16 character passwords and logins.
Riot can usually, but not always, tell if this was the case. I had an account compromised that I never use(should have deleted it) They locked it before damage was done. It was part of an old email, that also was heavily compromised, but recovered and re-secured.
Also, very helpful resource.
https://haveibeenpwned.com/