# =========================
# 🔒 BLOCK SEMUA AKSES LANGSUNG
# =========================
Order Allow,Deny
Deny from all

# =========================
# 🔒 BLOCK FILE SENSITIF (DOUBLE SAFETY)
# =========================
<FilesMatch "\.(json|env|ini|log|key)$">
    Order Allow,Deny
    Deny from all
</FilesMatch>

# =========================
# 🚫 MATIKAN DIRECTORY LISTING
# =========================
Options -Indexes

# =========================
# 🚫 BLOCK AKSES VIA BROWSER (USER AGENT)
# =========================
<IfModule mod_rewrite.c>
    RewriteEngine On

    # Block akses langsung ke file config
    RewriteCond %{REQUEST_URI} ^/api/config/ [NC]
    RewriteRule ^.*$ - [F,L]
</IfModule>