hi @compumatter
it should no be such hard. In general you can migrate to another server using this procedure:
https://docs.nextcloud.com/server/latest/admin_manual/maintenance/migrating.html
but as you are looking not to switch the server but change the DNS name as well you might need to adopt the trusted_domains
in your server config (maybe initially only add the new one before removing the old domain)
https://docs.nextcloud.com/server/latest/admin_manual/installation/installation_wizard.html#trusted-domains
https://docs.nextcloud.com/server/20/admin_manual/configuration_server/config_sample_php_parameters.html?highlight=trusted_domains#default-parameters
depending on your config you might need to adopt overwrite* attributes as well.
Beware - changing server hostname can brake your shares and federations if any. It could result in bad experience with client sync (as client doesn’t know the “new” server is the same as the old one) - best is you remove old sync config and create new from scratch…