RewriteEngine On

# Sempre servir o QR como PNG dinâmico (evita sumir no hosting)
RewriteRule ^img/qr\.png$ api/qr_png.php [L,NC]

RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ $1.php [L]

# STREAMBOX REMOTE CONFIG - evitar cache de JSON/configuração dinâmica
<IfModule mod_headers.c>
    <FilesMatch "^(cores|app_config)\.json$">
        Header set Cache-Control "no-store, no-cache, must-revalidate, max-age=0"
        Header set Pragma "no-cache"
        Header set Expires "0"
    </FilesMatch>
</IfModule>
