In a sensible world inet_pton would be deprecated with a compiler warning and replaced with inet_pton2 that just accepted the sensible subset.
The HTTP RFCs actually do restrict the format within URIs, but modern browsers are still more liberal
https://www.rfc-editor.org/rfc/rfc3986#section-3.2.2
One thing I've previously lamented is how IPv6 requires parens for IP:port pair string - particularly problematic if you want to be able to have a default port when the suffix is missing.
You upgrade an IPv4 address to an IPv6 address by appending it to 64:ff9b::/96, or whichever /96 prefix your ISP has chosen. For example, in an NAT64-enabled network, connecting to 64:ff9b::1.1.1.1 will get you to 1.1.1.1 as expected.
All the other questions are much safer since they will at worst produce a failure, but it would probably be best to be extra-strict for them too.