Avalanches caused by heavy snowfall have killed at least 22 people in the mountainous northern Afghan province of Panjshir, leaving dozens more trapped in their homes, officials said on Wednesday.