/* Desktop inherits the original site without any visual overrides. */
.ref-topbar{display:none}
@media(max-width:1023px){
 html body{padding-top:66px}
 html .sidebar,html body>.nav,html .content-title-row>.mode-toggle,html .blog-post-top-row>.mode-toggle{display:none!important}
 html .container{display:block;max-width:880px;margin:0 auto;padding:24px 18px;min-height:calc(100dvh - 66px)}
 html .main-content{width:100%;max-width:100%;margin:0;padding:0;min-height:0}
 .ref-topbar{position:fixed;top:0;left:0;right:0;z-index:100003;display:flex;align-items:center;gap:10px;height:66px;padding:0 18px;background:linear-gradient(145deg,rgba(255,255,255,.95),rgba(240,247,255,.84));border-bottom:1px solid rgba(92,145,224,.20);box-shadow:0 4px 20px rgba(51,91,155,.05);backdrop-filter:blur(20px)}
 html.dark-mode .ref-topbar{background:linear-gradient(145deg,rgba(43,56,78,.96),rgba(31,44,65,.94));border-color:rgba(133,173,233,.22)}
 .ref-brand{display:flex;align-items:center;gap:10px;margin-right:auto;color:var(--text-main)!important;text-decoration:none;font-size:16px;font-weight:700;min-height:44px}
 .ref-brand img{width:34px;height:34px;object-fit:cover;border:2px solid rgba(133,183,251,.24);border-radius:11px}
 .ref-brand span{display:grid;line-height:20px}.ref-brand small{font-size:10px;letter-spacing:.7px;color:var(--text-muted);font-weight:400}
 .ref-topbar button{display:inline-flex;position:static;align-items:center;justify-content:center;min-width:44px;width:44px;min-height:44px;height:44px;padding:0;border:1px solid rgba(92,145,224,.20);border-radius:13px;background:linear-gradient(145deg,rgba(255,255,255,.95),rgba(240,247,255,.84));color:#1768ce;box-shadow:0 3px 12px rgba(51,91,155,.07);font:inherit;cursor:pointer}
 html.dark-mode .ref-topbar button{background:linear-gradient(145deg,rgba(43,56,78,.96),rgba(31,44,65,.94));border-color:rgba(133,173,233,.22);color:#a9d5ff}
 .ref-topbar svg{width:19px;height:19px;fill:none;stroke:currentColor;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round}
 .ref-moon{display:none}html.dark-mode .ref-moon{display:block}html.dark-mode .ref-sun{display:none}
 .ref-topbar a:focus-visible,.ref-topbar button:focus-visible{outline:2px solid var(--primary-strong);outline-offset:3px}
 html .mobile-menu{display:none!important;position:fixed;left:18px;right:18px;top:78px;bottom:auto;width:auto;height:auto;max-height:calc(100dvh - 102px);overflow-y:auto;padding:14px;border:1px solid rgba(92,145,224,.20);border-radius:20px;background:linear-gradient(145deg,rgba(255,255,255,.97),rgba(240,247,255,.94))!important;box-shadow:0 14px 34px rgba(51,91,155,.12);backdrop-filter:blur(24px);transform:none!important;z-index:100004}
 html body.dark-mode .mobile-menu{background:linear-gradient(145deg,rgba(43,56,78,.98),rgba(31,44,65,.96))!important;border-color:rgba(133,173,233,.22)}
 html .mobile-menu.open{display:block!important}html .mobile-menu .close-menu,html .mobile-menu .mobile-mode-toggle{display:none!important}
 html .mobile-menu ul{display:grid;gap:4px;list-style:none}html .mobile-menu ul li a{display:flex;align-items:center;min-height:46px;width:100%;padding:10px 12px;font-size:15px;gap:12px}
 html .mobile-menu ul li a::before{display:none}.retained-nav-icon{width:18px;height:18px;fill:none;stroke:currentColor;stroke-width:1.6;stroke-linecap:round;stroke-linejoin:round;flex-shrink:0}
 html .mobile-menu ul li a.active{color:var(--primary-strong);background:var(--primary-soft);border-color:var(--primary-border-soft)}
 html .mobile-menu-backdrop{display:block;position:fixed;inset:66px 0 0;z-index:100002;background:rgba(19,40,72,.10);backdrop-filter:blur(3px);opacity:0;pointer-events:none}
 html body.mobile-menu-open .mobile-menu-backdrop{opacity:1;pointer-events:auto}html body.mobile-menu-open{overflow-y:auto;touch-action:auto}
 html section[id],html #publications,html #poster{scroll-margin-top:92px}
}
@media(min-width:1024px){html .mobile-menu,html .mobile-menu-backdrop{display:none!important}}
