systems, particularly for both types of sequential hermaphroditism, given that it contains many gonochoristic, protogynous and protandrous species, with differences in sexual systems even between species belonging to the same genus. The main theoretical framework to explain the evolutionary advantage of sequential hermaphroditism based on sex allocation theory is the size-advantage model (SAM) 9,19-21. The SAM proposes that individuals should switch sex when the second sex achieves a greater fitness at a larger body size than the first sex, thus increasing lifetime fitness 22. When larger males have higher reproductive success than smaller males and similar sized females, fish should reproduce initially as female and change later to male (protogyny) 19,23,24. Conversely, protandry is expected when large females have greater fitness than smaller females and similar sized males 19,20. Empirical studies support this model in several fish families, explaining quantitatively the size or age at which an individual should change sex, as well as the overall population sex ratio 25,26. Typically, male-biased sex ratios are observed in populations of protandrous species, while female-biased sex ratios are observed in populations of protogynous species, especially in haremic groups 19,26,27. Mating systems (the number and social dominance of mates involved) and spawning mode (i.e., group spawning, where several males spawn with one or several females, or pair-mating, where a single male spawns with a single female), determine the fitness that a fish of a given size can achieve as a female or as a male 23,28. Fish mating systems range from monogamy or pair-mating, to harem polygyny (one dominant male controls access to multiple females 29), lek-type polygyny (temporary harems 25), and large polygamous or promiscuous aggregations (where group spawning occurs 30). Sperm competition is particularly intense in large aggregations with multiple males 31,32 while it is absent in monogamy and pair-mating, and low in polygynous mating systems. Sperm competition and spawning modes have been used to infer mating systems 33-35 , which are relevant when testing the predictions of SAM since they can generate sex-specific differences in reproductive expectations 23,24,36,37. Thus, the first study that tested the predictions of SAM incorporating the mating system in a phylogenetic context focused on the evolution of protogynous groupers according to pair spawning mode 35. Indeed, protandry should be favored when sperm competition is low (mating occurs between members of monogamous or random pairs 19,22-24), and mate monopolization by large males should occur in protogynous species 23. Even though sperm competition was not included in the original formulation of the model 9,19 , it was subsequently mentioned as absent in protogyny 21,23,24,38 , limited in protandry (considered typical of random pairing and small groups) 22,23 and high in gonochorism (when mating occurs in large groups) 21,23,35,39. The influence of sperm competition on sex c...