$16,000,380,209,200.2842
So here is a more detailed version. There are a lot of more practical considerations to consider, like
a) Preparation and transportation costs for the more dangerous ones.
b) You can't necessarily get everything this cheap due to many of the metals being at bulk rates. I know from looking on ebay that you'd have to spend a lot more than the listed price for a sample of pure tungsten, for example. When a price vs a bulk price was given, I used the non-bulk price.
c) You need special clearances for things like plutonium.
d) A few micrograms of polonium are incredibly deadly, a whole 1 g would be insane, so the price shouldn't be a surprise.
e) Some of them, while purchasable at small amounts, do not necessarily have as much as 1 g available. For example, a grand total of 0.66 g of berkelium was made over the course of 16 years (1966 - 1983). Requesting a full gram of it might cause other unique issues.
f) Some elements essentially cost nothing, depending in part on how pure you want them to be.
g) Different websites are giving very different prices for things like the lanthanides. I picked what seem to be the most up-to-date prices.
Of those elements that CAN be purchased in some way or another, the prices per gram are:
99 & above: unobtainable
98 - Californium - $60 million (cheapest isotope)
http://www.osti.gov/scitech/servlets/purl/15053
97 - Berkelium - $160 million
http://www.3rd1000.com/elements/Berkelium.htm
https://en.wikipedia.org/wiki/Berkelium#Synthesis_and_extraction
96 - Curium - $160 million (cheapest isotope)
https://en.wikipedia.org/wiki/Prices_of_chemical_elements
95 - Americium - $1500 (most commonly cited cost)
https://www.chemicool.com/elements/americium.html
94 - Plutonium - $4000
http://hypertextbook.com/facts/2008/AndrewMorel.shtml
93 - Neptunium - $660
http://www.chemistry.pomona.edu/chemistry/periodic_table/Elements/Neptunium/the%20facts.htm
92 - Uranium - $0.07
For this one, it seems that U3O8 is what's available. Considering that it's $25.75/lb and 85% U, I did conversions to get to that.
http://www.uranium.info/
91 - Protactinium - $280
http://www.chemicool.com/elements/protactinium.html
90 - Thorium - $5.29
https://www.aqua-calc.com/calculate/materials-price
89 - Actinium (not available)
Some sites are saying $100 per gram but they look suspect, most say not available.
88 - Radium - $100,000
https://artsandculture.google.com/exhibit/the-leaden-box-and-the-gram-of-radium-musée-curie/vAJyom1aXb5nJw?hl=en
87 - Francium - (essentially nonexistent)
86 - Radon - $102,000
There are extremely conflicting results on the cost of radon and it's not clear what units most of them are supposed to represent. So for this, I assume you take radium-223 and let it decay to radon-219 (half-life is 11.43 days), adjusting the price of radium accordingly.
https://en.wikipedia.org/wiki/Radium
85 - Astatine - (essentially nonexistent)
84 - Polonium - $16,000,000,000,000
http://education.jlab.org/itselemental/ele084.html
http://www.theglobeandmail.com/news/world/polonium-is-costly-undetectable-trillion-times-more-toxic-than-cyanide/article18179025/
Converted cost from microcuries to grams according to these two. Polonium is incredibly deadly in extremely small quantities.
83 - Bismuth - $0.39
https://bismuth-tristanrhee.weebly.com/uses-cost-and-facts.html
82 - Lead - $ 0.002
http://www.infomine.com/investment/metal-prices/
81 - Thallium - $30.85
http://minerals.usgs.gov/minerals/pubs/commodity/thallium/thallmcs07.pdf
80 - Mercury - $0.017
http://www.chemistry.pomona.edu/chemistry/periodic_table/Elements/Thallium/thallium.htm
79 - Gold - $43
https://www.google.com/search?q=price+of+gold
The price of gold changes constantly (most prices do but few are as available as gold is), so I rounded to the nearest dollar.
78 - Platinum - $34
https://www.google.com/search?q=price+of+platinum
As with gold.
77 - Iridium - $196
https://www.metalary.com/iridium-price/
As with gold. (1 troy ounce equals 31.1 grams)
76 - Osmium - $13
https://www.thoughtco.com/osmium-prices-2011-2012-2339901l
As with gold.
75 - Rhenium - $8.03
https://www.radiochemistry.org/periodictable/elements/75.html
As with gold
74 - Tungsten - $0.05
https://www.alibaba.com/product-detail/Tungsten-Carbide-Carbide-Blanks-K10-Tungsten_62567251801.html?spm=a2700.7724857.normal_offer.d_title.2cc62fbfT1Tpyz&s=p
73 - Tantalum - $5.95
https://www.albmaterials.com/knowledge/blog/how-much-does-tantalum-cost-per-1-gram.html
72 - Hafnium - $1
http://www.kitco.com/ind/Albrecht/2015-03-11-Weak-Zirconium-Demand-Depleting-Hafnium-Stock-Piles.html
71 - Lutetium - $6
https://luciteria.com/elements-for-sale/buy-lutetium
70 - Ytterbium - $3.00
https://luciteria.com/elements-for-sale/buy-ytterbium
69 - Thulium - $5.00
https://luciteria.com/elements-for-sale/buy-thulium
68 - Erbium - $0.65
https://www.chemicool.com/elements/erbium.html
67 - Holmium - $4.00
https://luciteria.com/elements-for-sale/buy-holmium
66 - Dysprosium - $3.50
https://luciteria.com/elements-for-sale/buy-dysprosium
65 - Terbium - $6.00
https://luciteria.com/elements-for-sale/terbium-metal-999-pieces
64 - Gadolinium - $0.12
https://www.chemicool.com/elements/gadolinium.html
63 - Europium - $19.90
https://www.amazon.com/Europium-Element-Sample-Inside-Labeled/dp/B082GZHT7D
62 - Samarium - $3.70
https://www.amazon.com/99-5-Samarium-Pieces-Element-Sample/dp/B07DQNBM6T
61 - Promethium - $193.90
https://www.novaelements.com/promethium/
60 - Neodymium - $8.99
https://www.ebay.com/itm/1-gram-Neodymium-metal-element-60-sample-Nd-pieces-99-9-in-labeled-glass-vial-/331796204621