# Dynamic theme endpoint (dynamic-theme.php) outputs CSS from PHP.
# Guarantee PHP executes here and the response is served as a stylesheet.

Options -Indexes

<IfModule mod_mime.c>
  # Explicitly allow PHP execution inside this directory (cPanel / LiteSpeed).
  AddHandler application/x-httpd-php .php
</IfModule>

AddType text/css .css
AddCharset UTF-8 .css

# Clean stylesheet URL: /public/dist/css/dynamic-theme.css
<IfModule mod_rewrite.c>
  RewriteEngine On
  RewriteRule ^dynamic-theme\.css$ dynamic-theme.php [L]
</IfModule>