Optimal electricity tariff design with demand-side investments