Energy for tides comes from the Earth's rotation. Tidal drag is actually slowing Earth's rotation, making the days longer, but very gradually. Just as the Moon is tidally locked to Earth, Earth would eventually become tidally locked to the Moon, but it would take billions of years. As As Earth spins much faster than the Moon orbits it, the tidal bulge stays slightly ahead of the Moon, this pulls on the Moon, accelerating it slightly, causing it to move farther from Earth. you might want to read https://en.wikipedia.org/wiki/Tidal_acceleration