# Si el subdominio ya apunta a /public, no necesitamos redirección aquí.
# Solo mantenemos bloqueos de seguridad por si acaso.

<IfModule mod_rewrite.c>
    RewriteEngine On
</IfModule>

# Seguridad: Bloquear acceso a archivos sensibles (si llegaran a ser accesibles)
<FilesMatch "^\.env|composer\.(json|lock)|package(-lock)?\.json|phpunit\.xml|vite\.config\.js|tailwind\.config\.js|artisan|README\.md$">
    <IfModule mod_authz_core.c>
        Require all denied
    </IfModule>
    <IfModule !mod_authz_core.c>
        Order deny,allow
        Deny from all
    </IfModule>
</FilesMatch>

# Bloquear directorios internos
RedirectMatch 404 ^/(app|bootstrap|config|database|resources|routes|storage|tests|vendor|node_modules)/
