This can even be seen in art and is the reason why their statues are all depicted with small penises.
Hi Grey,
I think it's helpful to make a distinction between smaller dicks being desirable, and them being masculine, as these are two slightly different things.
For the Greeks, having a big penis wasn't necessarily any less masculine than a small one, and that distinction between a 'masculine' and 'feminine' ideal wasn't as central to their conception of attractiveness as it is for us today. Remember, this was a society whose conception of sexuality and attraction is far less defined by gender than our own, so 'presenting more masculine' wasn't a singular, fixed set of traits in the way it would later become.
Rather, penis-size was used to symbolise different aspects or presentations of masculinity, some of which that the Greeks saw as desirable, and others less so. A big penis is still masculine, but it represents the animalistic, instinctual parts of the 'male nature' they disapproved of. God's like Priapos , or Dionysus are both very masculine and very well endowed, but as deities of reproduction/male fertility and partying/alcohol respectively, they represent the barbaric 'base' parts of masculinity.
Similarly, a smaller penis came to represent the triumph of the 'higher order' of civilised masculine traits like reason, logic, and philosophy and a man's mastery of his coarser instincts. These higher traits still epitomised a form of masculinity, (indeed they still do to this day), but just on the other side of the coin to those a larger penis represented. Today, those two sides of masculinity are traditionally seen as part-and parcel of the same ideal, but for the Greeks they were decidedly separate.
Importantly, this did not mean they found larger penises universally unattractive. Excavations of Greek or Roman brothels and pornographic art frequently feature depictions or dedications to the barbaric big-dick deities like Priapos, and the images of even the regular men involved often show them very well endowed as well. A large penis and an animalistic masculinity were still attractive, it was just reserved for more taboo and carnal situations. While to our modern sensibilities, nudity is usually seen as sexual in some way, for the greeks things were not as clear-cut. The 'heroic' nude sculpture of public figures, mythical heroes, and deities we associate with the Greeks weren't necessarily intended to be sexualised in the same way those depictions in brothels were. They're meant to be attractive, certainly, but more in the sense of aesthetically than lustfully, because the later is barbaric and un-greek. They're not being given smaller dicks because they're inherently more masculine, they're being given smaller dicks because they're inherently more civilised. (Sorry, feel I haven't expalined that distinction well, feel free to ask me to clarify).
To some extent, this association of our genitalia with instinctive virility continues to this day. 'thinking with your dick, not your head' is a common sentiment/description for blindly following your horny urges rather than considering them rationally, and overly-small or tight swimming trunks are often regarded as inappropriate for men to wear etc. The difference is that in our more binary 'masculine/feminine-centric' conception of beauty, we don't see the aspects of masculinity in that association as being a negative or taboo in the way the Greeks did. Being more masculine is traditionally attractive, whatever form it takes, so having a big dick and the traits it's associated with are generally seen as a good thing for men to have. Being 'rational' and being sexually aggressive are part of the same (positive) male stereotype for us, whereas for the Greeks they were part of two separate, conflicting, ones.
TL;DR, the underlying associations didn't really change, the fact different aspects of masculinity were in tension with our social ideals of manhood did.
As for when that shift occurred, it's hard to put a precise date on it for a few reasons:
The Roman empire's gradual decline and cultural fragmentation means there isn't a clear demarcation between the death of greco-roman dominant culture, and the variety that replaced it. Did the Germanic tribes increasingly integrated into Rome's borders share these cultural/aesthetic sensibilities, or did they just mimic Roman customs insincerely to gain access to her empire? Should we see them as replacing Greco-Roman norms with new ones, or just as existing cultures filling the vacuum caused by the decline of Rome as a political entity? The answers to these are more a matter of perspective than anything else, and can lead you to results ranging from 'It was never idealised in this way outside of Greece and Rome in the first place' to 'only with the final fall of Byzantium in 1453'.
Complicating our picture future is the trend of European nobility and artists to hark back to and mimic the aesthetic traditions and norms of Greece and especially Rome to symbolise their own civility and learnedness. Thus, even in an era where padded codpieces and sculpted genital armour is the norm, paintings and sculptures depicting nude figures with smaller penises are still not uncommon because that's how classical art portrayed them, and everyone's trying to copy/learn from classical art. Should we see this as a genuine expression of aesthetic preference, or just a copying of Greco-roman norms?
There isn't a definitive right and wrong answer to these questions, it more depends on your take on some of the biggest and most intractable questions of post-classical history.
Sorry that's not a particularly satisfying answer, but hopefully it's an interesting one :)
Have a lovely day