# ==============================================================================
# Paharika Lake Retreat — cPanel .htaccess Configuration
# ==============================================================================

# 1. Enable Engine & Directory Index
DirectoryIndex index.php index.html

# 2. Security Headers
<IfModule mod_headers.c>
    Header set X-Content-Type-Options "nosniff"
    Header set X-Frame-Options "SAMEORIGIN"
    Header set X-XSS-Protection "1; mode=block"
    Header set Referrer-Policy "strict-origin-when-cross-origin"
</IfModule>

# 3. Prevent Directory Browsing
Options -Indexes

# 4. Protect Sensitive Configuration & System Files
<FilesMatch "^\.ht|config\.local\.php|\.git|composer\.*">
    Order allow,deny
    Deny from all
</FilesMatch>

# 5. Enable GZIP / Deflate Compression
<IfModule mod_deflate.c>
    AddOutputFilterByType DEFLATE text/html text/plain text/xml text/css text/javascript application/javascript application/json image/svg+xml
</IfModule>

# 6. Browser Caching for Images & Assets
<IfModule mod_expires.c>
    ExpiresActive On
    ExpiresByType image/webp "access plus 1 year"
    ExpiresByType image/jpeg "access plus 1 year"
    ExpiresByType image/png "access plus 1 year"
    ExpiresByType text/css "access plus 1 month"
    ExpiresByType application/javascript "access plus 1 month"
</IfModule>
