opam: split Sort into sort.ml and add Value.sort
Follow the pattern already applied to json, xml, toml, cbor, csv, and
protobuf: extract the opam value sorts (Bool, Int, String, Relop,
Prefix_relop, Logop, Pfxop, Ident, List, Group, Option, Env_binding)
into a standalone sort.ml, expose Value.sort as the Value -> Sort.t
conversion, and replace codec.ml's inline kind_name function with
Sort.to_string (Value.sort v).
Sort is re-exported at Opam.Sort so the full API is Opam.Sort.{t,
to_string, pp}.
Opam_error already had a Loc.Error facade with typed kinds
(Unexpected_char, Unterminated_string, Sort_mismatch, ...). No changes
there in this commit.