2003 honda accord Transmission?

I have a 2003 honda accord lx. Transmission knocks pretty hard when shifting into drive First thing in the morning or after my car has sat for awhile, 8 or more hours. It only happens once. If I put it back into park then shift it back to drive it won't happen again. I'll be good for the rest of the day as long as my car isn't sitting for long time, 8 hours or so.

May need a fluid change. Drain and refill until fluid runs pink. Do not flush.

Think its the engine not the transmission. If transmission it will happen all the time hot or cold. Check engine oil if low refill and find the problem if full think the oil pump giving you the problem or engine on the way out. You'll have to leave it at the shop over night for them to get the noise to happen to give you accurate diagnosis

Go to the dealer and see if there's a recall on this issue. If not then best to get a full transmission service from the dealer or shop that knows hondas. Only use OEM spec fluid.