Some workarounds:
Please check SQL Server Configuration Manager and ensure that TCP/IP protocol is enabled for your SQL Server instance.
Ensure the firewall on your local machine or network is not blocking the connection to SQL Server.
In SSMS, enable SQL Server and Windows Authentication in service instance property table.
If still not work, please check SQL Server error logs for any additional error messages that might provide more details about the issue.
Best regards,
Cosmog
If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".