There is a way to reset your mac account password without any data loss. This may help fix your problem
- Restart your mac and hold command+r until you see the loading bar. Then release and wait for recovery mode to open
- go to the menu bar and click Utilities> Terminal
- Type in resetpassword
- A prompt should pop up, and from there you can just follow the simple instructions to reset your password
- Restart your mac as normal and then see if it works with your new password
Note: Your iCloud keychain will still use your old password
If this was not helpful, there are some youtube videos online that can help too
Hope this helps!