Microcontroller not working as expected or crashes after a few days
Is it possible to stack and static data collide?


Yes, that is entirely possible. Atmega has no dedicated stack space, so if you use too much of it, you will overflow and crash your static data.

Try to reduce your memory consumption (use the smallest suitable data types for variables, reduce your array sizes etc.) Make sure you don't have any recursion or unusually long call trees under certain conditions.

If you can get your hands on better hardware, try running your program on a 2K version of the controller. If it runs without issues, you can confirm it's an insufficient memory problem without having any extra programming effort to do.

PS. As @Edesign says, servicing the watchdog from a timer interrupt is useless: doing so would protect against timer failures, not code failures. You should service the watchdog from your main loop, ideally from a sanity check function:

//main loop
while(1) {
  uart_task();
  sensor_task();
  wdg_task();
}

void wdg_task(void) {
  if(uart_ok() &amp;&amp; sensor_ok()) do_wdg_reset();
}


Note that the watchdog is supposed to help with errors which cannot be accounted for programmatically, like power glitches. Using a watchdog to reset a buggy program instead of fixing the bug is not the way to go.