The problem is that you are combining loops before other llops. That is a common mistake. You are using many trailing stop within the same structure. They should be separated instead as independnt structures and, above all, disconnected from the last 'common' part of the structure. On the other hand I never recommend using 'bucket of trades' blocks. It is always more recommended to use 'for each trade' blocks instead.