Solar origins of space weather and space climate