Cyprus joined the European Exchange Rate Mechanism ( ERM2 ) in May 2005 and adopted the euro as its national currency on 1 January 2008 .