Input Hash Size of ECDSA Signature over Curve secp521r1 For encryption authentication, I am using ECDSA signatures over the curve secp521r1. There is a hash function parameter, and as the curve is 521-bit, the hash output length should be > 512 bits, which is the highest offered output of the Standard SHA-2 hashes available.

However, in the SHA-3 specification, the cSHAKE function allows for variable length outputs, so is it recommended to use cSHAKE with an output length of something like 521 &lt; n &lt; 1024. If so, what is the recommended hash length to use?
The hash output length does not need to be larger than 512 bits; the ECDSA specification can handle any length. The curve secp521r1 is usually considered to provide 256 bits of security (even though it provides a bit more), see Table 2 of NIST SP 800-57 for example. Therefore, a 512-bit hash, i.e. SHA-512, should be fine ("The security strength of the hash function used shall meet or exceed the security
strength associated with the bit length of n", NIST FIPS 186-4)

Regarding cSHAKE (you probably meant SHAKE; cSHAKE is its customizable variant that is used to define KMAC and TupleHash), you could use any output equal to or larger than 512 bits. The NIST FIPS 186-5 draft mandates SHAKE256 with 512-bit output.