What sabatonsky posted is half right. Buy when it's green, sell when it's red. If you notice, green price amounts are always low, while red prices are always high. So if you buy it when it's green, that means you're paying less than what it's "normally" at, normal being that yellow / orange-ish color. Red prices mean they're higher at that place than the market average, meaning you should sell it there. I can't speak confidently about the whole seller perk, but if you hover over the item the money amount shows up with those colors, and that's how you should decide where to sell / buy. Horses and livestock don't have those colors applied for some reason, so you just have to remember what you paid and try to sell at higher amounts.