Section links in head words
Well, firstly the links shouldn't "hide" information like that. If someone is supposed to figure out from a URL what sense and pronunciation is meant, then something needs to change. More generally though, such links are ambiguous because there may be many sections with the same name on a page, so there isn't even any guarantee that the link does what it was intended to do. The link should always include the language name, which is the only section name that is guaranteed to be unique. And finally, what if someone reorders the definitions so that Etymology 5 now refers to something else?
The link is not hiding anything, it is just linking to the right place. I don't think we normally give information on the component words in a compound phrase. That's what the link in the head word is supposed to do. If the link doesn't go anywhere useful, we may as well not have a link at all. The potential problems you raise could be solved by linking to an html anchor instead of a section heading, but what is the standard way of dealing with this?
Not for compound phrases it isn't. All the ones I have seen just link to the individual elements. Can you point to some examples.
No, it isn't, but my point is that the etymology is to be found at the entries for the component words. Do we ever give etymologies for phrases when the etys are just the etys of the components? Certainly things like bee's knees and cat's pajamas give etymologies, but of the history of the phrase, not its components. Etys for cat, bee, pajamas or knee cannot be found at those entries.
This is why {{compound}}
and similar templates have a gloss parameter; besides being just for clarity, it's to specify which of the senses the term should be understood as derived from. Similarly, if "cat" has several senses, then just linking to cat is not a proper etymology because it's not clear which of the senses the phrase derives from. An etymology section should be added to clarify this.