(()=>{let e=Number(localStorage.getItem("appearance")||0);const a=document.documentElement,t=()=>{a.classList.remove("dark","light"),2===e?a.classList.add("dark"):1===e?a.classList.add("light"):a.classList.add(window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light")};t(),0===e&&(window.matchMedia("(prefers-color-scheme: dark)").addEventListener("change",t),window.matchMedia("(prefers-color-scheme: light)").addEventListener("change",t))})();