The stark facts are simple - nearly 20% of Ukranian territory has been strategically captured by the Russians. Ukraine has no real chance of getting it back. Ukraine's counter-offensive has failed twice. It cannot launch any more counter-offensive because it doesn't have the men - any counter-offensive by recalling men from other parts of the frontline would weaken the defence line. So any new counter offensive launched needs to really bloody the Russians to completely back off, or the whole frontline will collapse and Ukraine will face a complete military defeat. Whatever Russian territory Ukraine had occupied has been recovered by the Russians. In case Ukraine doesn't accede to Russian terms, Russia has also been working on a plan B that entails systematically destroying Ukraine's industrial infrastructure (demilitarisation through de-industrialisation - https://politics.stackexchange.com/a/94244 ).
All Ukraine does now is to launch drones and missile attacks at Russian infrastructure for western and social media PR (as it is the only way EU will keep funding Zelensky's government and the war), while it is forced to retreat in the frontlines every week as the Russians slowly keep advancing.