/* V385 — final fixed header + fixed back button. Loaded LAST on purpose. */
:root{--mhur-top-height:72px;--mhur-back-gap:12px}
html{
  scroll-behavior:auto!important;
  scroll-padding-top:calc(var(--mhur-top-height) + 76px)!important;
}
body{
  padding-top:var(--mhur-top-height)!important;
}

/* The real top bar must stay attached to the viewport at all times. */
body > header.top,
header.top,
.top{
  position:fixed!important;
  inset:0 0 auto 0!important;
  top:0!important;
  left:0!important;
  right:0!important;
  width:100%!important;
  height:var(--mhur-top-height)!important;
  min-height:var(--mhur-top-height)!important;
  margin:0!important;
  transform:none!important;
  translate:none!important;
  z-index:2147483600!important;
  overflow:visible!important;
  isolation:isolate!important;
}
.top .menuBtn,
.menuBtn{
  display:flex!important;
  visibility:visible!important;
  opacity:1!important;
  pointer-events:auto!important;
  position:absolute!important;
  left:14px!important;
  top:50%!important;
  transform:translateY(-50%)!important;
  z-index:2147483603!important;
}
.top .brand{z-index:2147483601!important}
.top .mhurAccountButton,
.top .lang{
  visibility:visible!important;
  opacity:1!important;
  pointer-events:auto!important;
  z-index:2147483603!important;
}

/* Drawer is also tied to the viewport below the header. */
.drawer{
  position:fixed!important;
  top:var(--mhur-top-height)!important;
  bottom:0!important;
  left:0!important;
  height:auto!important;
  max-height:calc(100dvh - var(--mhur-top-height))!important;
  z-index:2147483500!important;
  overflow-y:auto!important;
  overscroll-behavior:contain!important;
}

/* Back remains usable while the detail page scrolls. */
#app > .back,
.wrap > .back,
.back{
  position:fixed!important;
  top:calc(var(--mhur-top-height) + var(--mhur-back-gap))!important;
  left:18px!important;
  z-index:2147483400!important;
  margin:0!important;
  visibility:visible!important;
  opacity:1!important;
  pointer-events:auto!important;
  transform:none!important;
}
/* Reserve space so page titles do not sit under the fixed back button. */
#app:has(> .back){padding-top:62px!important}

@media(max-width:700px){
  :root{--mhur-top-height:64px;--mhur-back-gap:10px}
  .top .menuBtn,.menuBtn{left:8px!important}
  #app > .back,.wrap > .back,.back{left:10px!important}
  #app:has(> .back){padding-top:58px!important}
}
