Context-dependent genetic benefits of polyandry in a marine hermaphrodite