Invitation email sent but "Join Now" button is not clickable

That depends on your deployment method.
On binary deployments, you can find the config.json file in the directory /opt/mattermost/config/config.json (if you used the default directories). Search for the string SiteUrl in there.

When you used the docker-compose deployment, you should check the environment variable MM_SERVICESETTINGS_SITEURL in your .env file.