I have got the same error couples of days back for postcss file. But the real error was in my tailwind.config.ts, there was a syntax error for font-family array. It previously looked like below:
font-family: [sans-serif\n ,inter\n, ......]
i have made it to:
font-family: [sans-serif, inter.....]
An then i ran 'convert indentation to spaces' in vscode command pallete(cntrl+shift+p). And then it solved my error.