Highly absorbing black Mg and rare-earth-Mg switchable mirrors