RewriteEngine On
RewriteBase /

# 1. Force HTTPS (Optional - வெப்சைட் பாதுகாப்பிற்கு)
# RewriteCond %{HTTPS} off
# RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]

# 2. Hide .php extension
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME}\.php -f
RewriteRule ^([^\.]+)/?$ $1.php [L]

# 3. Prevent directory browsing (பாதுகாப்பிற்கு)
Options -Indexes