With flights on time there will be no problem. You probably have only limited to no time to use the LH lounges but it is enough to change gates and get through passport control and maybe extra security. Regarding customs you will not go through customs in Munich. In the Europe-Schengen-Area customs is done at the final destination unlike in the US where you go through customs at the airport you enter the US first.