When you restore a synced user from Entra or office portal , Entra connect will not able to sync it again and see it as a cloud only account. To restore the sync of synced account you should delete it again using Entra or office portal and move the user account in AD to synced OU.
All synced objects should be modified from on-prem Active directory through EntraConnect server.
Please don't forget to accept helpful answer