48Consequently, while it is for the Member States, by means of their national legislation, to define the detailed rules under which the unfairness of a contractual term is established and the actual legal effects of that finding are produced, the fact remains that such a finding must allow the restoration of the legal and factual situation that the consumer would have been in if that unfair term had not existed, by, inter alia, creating a right to restitution of advantages wrongly obtained, to the consumer’s detriment, by the seller or supplier on the basis of that unfair term (judgment of 25 April 2024, Caixabank (Limitation period), C‑484/21, EU:C:2024:360, paragraph 20 and the case-law cited).