The large styrofoam piece is to cover the amp and other electronics down there......
Disconnecting the batter will NOT cause loss of radio programing.... or anything else that I have found..... I disconnect mine frequently and haven't had to re-do anything..... (I dont use my NAV so I will exclude that from my comment).....