Mean-field analysis of ground-state and low-lying electric dipole strength in $^{22}$C