) if present
$html = preg_replace('/^<\?php\s*\?>/i', '', $html);
// ═══════════════════════════════════════
// INJECT CLOUD BRIDGE SCRIPT
// This overrides save()/load()/auth functions
// to use MySQL instead of localStorage
// ═══════════════════════════════════════
$cloudBridge = <<<'JSBRIDGE'
JSBRIDGE;
// Inject bridge script BEFORE the closing