Each of A, B, and C had some marbles. B distributed half the marbles with him among A and C in the ratio 1:3. Then C distributed half the marbles with him among A and B in the ratio 1:3. After that, A distributed half the marbles with him among B and C in the ratio 1:3. If each of them now has 64 marbles, find the difference between the number of marbles with A and C in the beginning.