Most human activity is based on rules. Without rules there could be no football. Without rules on quality, standards, safety etc., there could be no trade.
The EU is a group of countries that have got together and written rules that allow them to live and work together on a level playing field, so no one country can take unfair advantage over the others. In addition, the EU has agreed rules on governance and the environment; e.g. member countries must abide by the rule of law, have an independent judiciary, limit air pollution and reduce carbon dioxide emissions.
The ECJ is the referee ensuring all play by the same rules. It is made up of judges from each EU country (including ours) and it is responsible for adjudicating on disputes between countries and where countries break the EU rules they have agreed to. When we have written the rules and agreed to them, it is a nonsense to complain we don’t like them. These are not rules being imposed on us (as claimed by the Brexiteers), they are our rules.
The EU system is far better than the way the World Trade Organisation (WTO) works. The WTO rules are regularly ignored when deemed inconvenient by individual countries; the USA is a major culprit of this. In addition the USA is deliberately and slowly strangling the WTO by refusing to allow any new trade adjudicators to be appointed.
I know which group I think is better for the future of our country!