.
if(!html.classList.contains('ga-loading')){ if(splash){splash.style.display='none';} return; }
var start=Date.now(), done=false;
// Reveal the logo ONLY if this render is still alive after the redirect-hop window (i.e. it's the page that sticks).
// Throwaway redirect hops are destroyed before this fires, so they stay PURE BLACK with no logo -> the flicker hides inside the black.
var revealTimer=setTimeout(function(){ html.classList.add('ga-show-logo'); }, 800);
function hide(){ if(done)return; done=true; clearTimeout(revealTimer); html.classList.remove('ga-loading'); html.style.background=''; if(splash){splash.classList.add('ga-hide'); setTimeout(function(){if(splash&&splash.parentNode)splash.parentNode.removeChild(splash);},450);} }
function onReady(){ setTimeout(hide, Math.max(0, 1800-(Date.now()-start))); } // hold long enough that the revealed logo is actually seen
if(document.readyState==='complete'){ onReady(); } else { window.addEventListener('load', onReady); }
setTimeout(hide, 8000); // safety cap
})();