Can any portuguese speaker tell me why the map is masculino but ends with the "a"?
there are some words ending in -a but not feminine (another example: O dia)
not really. It consists more on tradition fixed by the usage than any other thing. if you compare latin languages will notice that (a viagem (fem) / el viaje ( masc / spanish); o sangue (masc)/ la sangre (fem / spanish), la sang (fem/ french)). These are masculine: O…clã, champanha, dó, formicida, grama (measurement/weight), milhar, pijama, sósia, telefonema…Words ended in -ema are usually masculine (poema, dilema, cinema, sistema)
If you look to the etymology of these words, you'll see that they are largely Greek in origin rather than Latin, so they were not governed by strictly Latin rules.
Obviously that's not going to help you decide day-to-day which article to use, but I think it's an interesting tidbit of info :P