Not sure if my answer will be helpful to you, but I believe it contains some key concepts related to build systems.
Every frontend library or framework utilizes a build system to compile projects. For instance, Angular uses webpack for this purpose. In all of my projects, whether Angular or React based, I always create a customized webpack configuration. This is because the default configurations provided are quite basic.
In your case, it seems that the current Angular setup does not support the @ symbol in CSS. Personally, I recommend using css-loader along with MiniCssExtract, and for SCSS files, incorporating scss-loader as well. Here's a snippet of code:
{
test: /\.css$/,
use: [MiniCssExtractPlugin.loader, "css-loader"],
},
{
test: /\.s[ac]ss$/i,
use: [
MiniCssExtractPlugin.loader,
"css-loader",
"sass-loader",
],
}
I suggest exploring how to create a custom webpack configuration. It can introduce you to many new concepts. For instance, by implementing a custom webpack setup, you can optimize performance by compressing output files to reduce their size.