It's almost as if the atoms in a sample somehow 'know' how many other atoms are in the sample.
This is the key. It is actually exactly the opposite, it is precisely because they don’t know how many other atoms are in the sample that the half life is constant.
Survival curves don’t just happen with atoms, they happen with all sorts of objects. You can think of the number of rabbits in a population that die, or the number of some type of car parts that fail, and so forth. These things generally do not have constant failure rates, or half lives.
The failure rates of car parts tends to be high for new parts, some parts break in the first hundred hours because of manufacturing defects.
Then the failure rate levels off, and becomes stable, almost like a constant half life. In this range it is just a random lottery, with every part playing the game every hour it is in use, with equal odds of each part failing in any given hour it is used.
Then, the failure rate begins to increase again as the parts become mechanically worn. They failure as higher rate towards the end of their usable life. So the failure rate is not constant as the part "ages".
Similarly, healthy adult rabbits can live with a low failure rate if there is a modest number rabbits in the population. Each rabbit has aessentially an independent random chance of dying any day by accident. But if there are too many they die more frequently by starvation or if there are too few rabbits in the population then they die at a much higher rate by predation. So their individual death rate depends on the number of other rabbits.
Atoms are not like cars. There aren’t defective atoms and they don’t wear out, they only have that constant middle part. Atoms are also not like rabbits, they don’t care how many they are. There isn’t an age or population based adjustment to the constant random decay rate.
So why is the half life constant, it’s because atoms of a particular type are all identical.