[...] after receiving the order they sent me an invoice for customs services for about 48€. The shipment was to Spain.
Was that 48€ really only for FedEx's
services (putting your package through customs)? That would be a painfully high fee. But I assume that the amount also included the actual import tax, i.e. your 21% VAT, payable on the PCB value plus the shipping cost?
That tax you will have to pay in any case; your only choice is whether you pre-pay it via JLCPCB or post-pay it via the shipping company. The EU has become much more pedantic about actually collecting that money...
What you
can avoid is paying the handling fee to FedEx or other shipping companies. If you choose a shipping method that is listed as "DDP", i.e. delivered duty paid, you pre-pay the VAT to JLCPCB and pay not additional fee, or a very small one. Last time I ordered something, JLCPCB offered "DHL Express DDP" (fast and expensive) and Europacket (a bit slower, much cheaper). That was to Germany, and a few months ago. Do you still get those options?