Update: I built an espfs image with Cygwin's find binary and flashed it both with the published firmware and my compiled one.
Unsurprisingly, the espfs image worked with the published firmware, but not with my compiled firmware (same bad css/js).
I guess it points that the problem is with the own compiled firmware; though I didn't notice any difference when compiled against different sdk versions, and I assume the sources are fine.