RewriteEngine On

# Pasar Authorization header a PHP (cPanel lo bloquea)
RewriteCond %{HTTP:Authorization} .
RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]

# Redirigir todo al router
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ index.php [QSA,L]

Options -Indexes
RewriteRule ^config/ - [F,L]
RewriteRule ^controllers/ - [F,L]
RewriteRule ^helpers/ - [F,L]
RewriteRule ^middleware/ - [F,L]
