Zaslat SMS: First-principles method justifying the Dieke diagram and beyond