✆Book now
// ĐO MÀN HÌNH THẬT (chuẩn tự nhận diện màn hình): data-man/huong/cham + --vh (thanh địa chỉ iPhone) + --hh.
// CSS đã tự đủ ở 6 mốc — phần này chỉ bổ trợ, mất JS bố cục vẫn đúng.
(function(){function fs(){var r=document.documentElement,h=document.querySelector(".head");
r.style.setProperty("--vh",(innerHeight*0.01)+"px");r.style.setProperty("--hh",((h&&h.offsetHeight)||70)+"px");
r.dataset.man=innerWidth<=699?"dt":(innerWidth<=1023?"tab":(innerWidth<=1699?"pc":"to"));
r.dataset.huong=innerWidth>=innerHeight?"ngang":"doc";
r.dataset.cham=(window.matchMedia&&matchMedia("(pointer:coarse)").matches)?"1":"0";}
function fss(){fs();requestAnimationFrame(fs);}
addEventListener("resize",fss);addEventListener("orientationchange",fss);
try{matchMedia("(max-width:699px)").addEventListener("change",fss);}catch(e){}
if(window.ResizeObserver){try{var hd=document.querySelector(".head");if(hd)new ResizeObserver(fs).observe(hd);}catch(e){}}
fss();})();