Attention is a muscle. Train your metacognition to notice when your mind drifts, gently release the distraction, and snap back to target.
The moment you catch yourself scrolling, day-dreaming, or opening a new tab, pause and mentally say: "Aha! Distraction spotted."