Effective management of blood glucose levels in individuals with type 1 diabetes, especially after meals, is crucial for diabetes care. Artificial pancreas systems (APS) perform automated insulin delivery in subjects with type 1 diabetes mellitus (T1DM). In this study, an optimized fuzzy logic controller was designed to achieve a euglycemic range after a substantial meal intake. All in silico simulations were performed using the MATLAB/Simulink environment, leveraging control variability grid analysis (CVGA), and the performance of the controller was evaluated. The proposed controller is based on a fuzzy-logic control law designed in three stages. First, a nonlinear framework of the glucose-insulin regulatory system was identified based on the heavy meal protocol of three patients given as follows: for subject ID 117-1, a total of 295 gCHO; for subject ID 126-1, 236 gCHO; and subject ID 128-1, 394 gCHO over a day. Then, an iterative tree structure was employed to establish a stabilizing control rule for insulin delivery, integrating inputs from two Mamdani Fuzzy Inference System (FIS) objects. Finally, a genetic algorithm refines the control system by fine-tuning the uncertainty of the fuzzy membership functions. Two scenarios were considered for three patients to assess the performance of the proposed controller. The results indicated its effectiveness under various conditions, achieving a time in the range of 61.25%, 71% and 61.10% respectively for the three subjects. The obtained results are analyzed and compared with IMC and multi-objective output feedback controllers. The findings of the study reveal that the proposed controller shows promising advancements in tailored strategies for type 1 diabetes patients, outperforming the other controllers in terms of blood glucose regulation.