I just went through the support ticket raised for this issue and I see that the issue was resolved.
I am just summarizing the support ticket resolution here for community benefit. It will help if you could mark the answer as accepted and add any additional details if I missed any.
Issue:
You were facing issue with your Azure CDN with a custom domain and a CDN-managed SSL cert, where the website started throwing HTTP 526 errors. I an attempt to fix it, you removed the SSL cert from the custom domain to let the process finish, purged everything from the CDN, and gave it a few hours. Since then, you were unable to recreate the CDN-managed cert as the portal is throwing an error about the domain not being validated. Although the website started working with a valid cert after it was auto-renewed by Azure CDN but the Azure Portal still showcased the error above.
Resolution:
As the website was accessible over HTTPS, the SSL certificate was being recognized. The support engineer helped in finding out that as the custom domain was pointed to the DNS provider so the SSL certificate above was procured by the DNS provider so it was not recognized by Azure.
After turning off the proxy for the custom domain in the DNS provider where the CNAME record resides, an SSL certificate was successfully created in the Azure portal. The SSL certificate is also being shown as created by Microsoft when checked at the custom domain.
Thank you!