I have had similar problems recently on both the iPad and Mac, so I called Apple Care. The fix was to remove the email account, then add the account back in System Preferences> Internet Accounts.
Be careful when you set up the account to specify whether you are setting up just a mail account, or mail + notes + calendar accounts.
Since your Gmail account is an IMAP account, all of your emails should re-populate in the Mail app after the "new" account is re-established in your Mac.
Just to be sure that you don't lose emails, you might consider backing up your "active" mailboxes using the Mailbox>Export Mailbox function within the Mail app. By "active" mailbox I mean those mailboxes at the top of your mailbox list, e.g., each mailbox in the "inbox" or "sent" categories. Those emails sync with the email provider's servers and don't permanently reside in your computer.
Any emails that you have transferred to "local" mailboxes are already stored locally in your computer and don't need to be backed up.
If your notes and calendar also synced through this email provider (instead of through iCloud), you might consider backing up your notes and calendar entries also. However, I'm pretty sure that Google emails (Gmail) and Google Calendar entries will sync back after you remove and re-install those accounts on your Mac. Probably the same with notes, but I don't know for sure.
Be advised that I'm no computer expert. This worked well for me, but you might consider running this advice by one or two knowledgeable people to get 2nd or 3rd opinions.
Good luck.