Morocco has a coast by the Atlantic Ocean that reaches past the Strait of Gibraltar into the Mediterranean Sea. It is bordered by Spain to the north (a water border through the Strait and land borders with three small Spanish-controlled exclaves, Ceuta, Melilla, and Peñón de Vélez de la Gomera), Algeria to the east, and Western Sahara to the south. Since Morocco controls most of Western Sahara, its de facto southern boundary is with Mauritania.

The internationally recognised borders of the country lie between latitudes 27° and 36°N, and longitudes 1° and 14°W. Adding Western Sahara, Morocco lies mostly between 21° and 36°N, and 1° and 17°W (the Ras Nouadhibou peninsula is slightly south of 21° and west of 17°).

The geography of Morocco spans from the Atlantic Ocean, to mountainous areas, to the Sahara desert. Morocco is a Northern African country, bordering the North Atlantic Ocean and the Mediterranean Sea, between Algeria and the annexed Western Sahara. It is one of only three nations (along with Spain and France) to have both Atlantic and Mediterranean coastlines.

A large part of Morocco is mountainous. The Atlas Mountains are located mainly in the centre and the south of the country. The Rif Mountains are located in the north of the country. Both ranges are mainly inhabited by the Berber people. At 446,550 km2 (172,414 sq mi), Morocco excluding Western Sahara is the fifty-seventh largest country in the world. Algeria borders Morocco to the east and southeast, though the border between the two countries has been closed since 1994.

Spanish territory in Northwest Africa neighbouring Morocco comprises five enclaves on the Mediterranean coast: Ceuta, Melilla, Peñón de Vélez de la Gomera, Peñón de Alhucemas, the Chafarinas islands, and the disputed islet Perejil. Off the Atlantic coast the Canary Islands belong to Spain, whereas Madeira to the north is Portuguese. To the north, Morocco is bordered by the Strait of Gibraltar, where international shipping has unimpeded transit passage between the Atlantic and Mediterranean.

The Rif mountains stretch over the region bordering the Mediterranean from the north-west to the north-east. The Atlas Mountains run down the backbone of the country, from the northeast to the southwest. Most of the southeast portion of the country is in the Sahara Desert and as such is generally sparsely populated and unproductive economically.
Can you give me some details about the moroccan geography ?
Morocco has a coast by the Atlantic ocean and the mediterranean sea. It's bordered by Spain, Algeria and Mauritania. The geography of Morocco spans from the Atlantic ocean , to mountainous areas to the Sahara desert. The Rif mountains are located in the North and The Atlas mountains are located mainly in the center and south of the country.