Solar flares are the most powerful explosions in our solar system, releasing up to 1032−1033 ergs within approximately 10–1000 seconds. During a flare, energy stored in non-potential magnetic fields is suddenly released, a process triggered by magnetic reconnection. Consequently, plasma in the corona and chromosphere is heated to tens of millions of Kelvin, resulting in the striking enhancement of soft X-ray and longer-wavelength emissions. At the primary energy release site, charged particles—electrons, protons, and heavier ions—are accelerated to high energies, emitting hard X-rays and γ-rays. We carry out a multiwavelength analysis of two consecutive flares of GOES classes C6.3 and M1.0, categorized as confined and eruptive, respectively. At the time of the flares, the Solar Orbiter was at 0.3263 AU from the Sun, with a light travel time to Earth of 335.2 seconds. The angular separation between Earth and Solar Orbiter was 85.1 degrees. XSM observes the spectrum in the 1–15 keV band, covering the thermal part of the solar flare spectrum, while STIX provides the spectrum in the complementary 4-150 keV energy range, covering the non-thermal part. Additionally, STIX provides X-ray images of the flare sources using an indirect imaging technique. Time-resolved spectra from both instruments were analyzed independently and then jointly modeled to infer the thermal and non-thermal parameters of the flares more precisely. We find that the XSM spectra are well fitted with a two-temperature model, the STIX spectra are well fitted with an isothermal and thick-target bremsstrahlung model, and the joint fitting of XSM and STIX spectra fits well with a two-temperature thermal model combined with a thick-target bremsstrahlung model. Combined fitting of XSM and STIX spectra provides better constraints on the estimation of thermal plasma parameters. We also use complementary imaging observations at longer wavelengths from AIA/SDO to understand the dynamics of coronal magnetic loops before and during the eruptive phenomena.