force http to https doesn't work for subdomains
The redirection HTTP to HTTPS doesn't work for subdomain due to the RewriteCond ordering.
Because the RewriteCond {HTTPS} off is at the end, the rewrite rule for the subdomain is hit before.
Reversing the order works as expected.