Again, the simpler scenarios get you. What if someone buys only a single item? Then to satisfy your constraint,
every item on the price list must have a decimal part <.25. If any two items are both priced with decimal parts between .13 and .25, then again, if the customer buys those two items, your constraint is violated. The only feasible way to do it is pricing everything at only .01 or .02, with the logic that if they buy over 25 items, then you no longer care about the constraint. But why do that when you can sell everything at even dollar amounts and avoid the whole mess?
I understand what it is you're looking to do, but in this exact formulation, no solution seems feasible, at least of the type you are looking for. This is similar to the coin problem. We demarcate our coins at 1,5,10,25, but these numbers are arbitrary. It is actually an extremely complex problem of finding the optimal demarcation -- that is, the one that requires on average the fewest number of coins to give exact change, and therefore requires less output of the mint.