Press the tofu by wrapping it in a clean towel and placing a weight on top for about 15 minutes until firm, then cut into 1-inch cubes.
In a small dry skillet, toast cumin and coriander seeds over medium heat until fragrant, about 1-2 minutes. Let cool slightly, then grind to a powder using a mortar and pestle or spice grinder.
Heat coconut oil in a heavy-bottomed pan over medium heat. Add diced onion and sauté for 5-7 minutes until golden and fragrant, stirring often.
Add minced garlic and grated ginger to the pan and cook for about 1 minute until fragrant and slightly bubbling.
Add the ground spices and turmeric to the pan, stirring constantly for 30 seconds to release their aroma.
Pour in the coconut milk and canned diced tomatoes, stirring to combine. Bring the mixture to a gentle simmer, and cook uncovered for about 10 minutes, until the sauce thickens slightly and fills the room with warm, spicy aromas.
Gently fold in the tofu cubes, ensuring they are coated with the sauce. Simmer for another 5 minutes to let the tofu soak up the flavors.
Squeeze fresh lime juice over the curry and stir gently. Taste and add salt as needed.
Garnish with chopped cilantro if desired, and serve hot with rice or flatbread for a comforting, vibrant meal.