Trying to style Printmaker Plugin PDF by linking css in head of PDF template Similar to this issue Render styled output using Printmaker plugin

I am having the same issue and can't seem to figure out how to style the PDF.

Here is my code to generate the PDF:

    {% set html %}
        {% include '_includes/_pdf/social.twig' %}
    {% endset %}

    {% set pdfUrl = craft.printmaker.pdfFromHtml(html).url %}

    &lt;a href="{{ pdfUrl }}" target="_blank"&gt;Print Page&lt;/a&gt;


This opens the PDF in a separate tab.

and then I am loading pdf.css into the head of _includes/_pdf/social.twig but the PDF is not styled.

&lt;!DOCTYPE html&gt;
&lt;html lang="en" dir="ltr"&gt;
    &lt;head&gt;
        &lt;meta charset="utf-8"&gt;
        &lt;title&gt;PDF Template&lt;/title&gt;
        &lt;link href="pdf.css" rel="stylesheet" type="text/css"&gt;
    &lt;/head&gt;
    &lt;body&gt;

        // PDF HTML

    &lt;/body&gt;
&lt;/html&gt;


and here is my directory structure

_includes
    _pdf
        pdf.css
        social.twig


Is it possible to style the PDF this way or do I need to use &lt;style&gt; tag or inline styles?
You can link to the CSS in this way, but if it's not working for you then try changing the path to

&lt;link href="./pdf.css" rel="stylesheet" type="text/css"&gt;


assuming that your CSS is in the site root.