⚖️ Target Adjustment
Work out the next difficulty target the way Bitcoin Core does every 2016 blocks: scale by the actual time taken, clamped to a factor of 4.
Current bits (0x-hex)
Time of first block in period (Unix)
Time of last block in period (Unix)
Actual timespan (seconds)