Egypt’s top court has ruled as invalid the country's Senate and the panel that drafted the Constitution, state media report.