what was gold used for in the past