The anchor text, or the text that is hyperlinked on a page, is often overlooked, but search engines actually read it and surrounding text to make sense of the content on a site. The founders of Google have incorporated the practice from the very beginning, writing about it while still at Stanford. Page and Brin made the point that the anchor text was more relevant at describing the purpose of a link than the page on which it was listed, and Google likely now uses natural language processing to examine anchor text and surround words and context.
The best practice for anchor text follows the logic for SEO over all in that web masters should build the best content possible and make it as easily understood by the users. Avoid gaming the search engine by stuffing keywords into the anchor text, just like you should avoid keyword stuffing on web pages. Mix up the types of anchor text used, and describe the linked resource in the surround text to make it clear to both human and machine users what they are linking to.
McCoy, Julia What Is Anchor Text? Everything You Need to Know for SEO. Semrush Blog. May 25, 2021
Moz Blog. Anchor Text.
If you think a URL is too long, take a look and see if there is extra stuff at the end or if it is just a long string of words used for the URL. Some URLs are based on a blog post title and are just a long string of words and that is not really a problem. For stability, you want the simplest link that resolves to the target page, and may URLs have extra stuff at the end, so try removing it in chunks to see if you still get to the page you want.
Here are examples of long links along with some reasons they went bad.
Many US Executive branch websites will archive everything from past presidential administrations.
US Congressional sites are also archived routinely for past congressional sessions