/* Loaded after page styles: navigation must not depend on a sticky header. */
body[data-history-navigation="fixed"]{
 padding-bottom:calc(var(--history-navigation-clearance,84px) + env(safe-area-inset-bottom,0px))!important;
}
.history-navigation-floating,.history-navigation-dialog{
 position:fixed!important;
 inset:auto 16px calc(var(--history-navigation-bottom,12px) + env(safe-area-inset-bottom,0px)) auto!important;
 display:flex!important;
 align-items:center;
 justify-content:center;
 gap:6px;
 width:max-content;
 max-width:calc(100vw - 24px);
 margin:0!important;
 padding:6px!important;
 border:1px solid #bac8dc;
 border-radius:16px;
 background:#fffffff5;
 box-shadow:0 4px 20px #14223c33;
 z-index:10000;
 isolation:isolate;
}
.history-navigation-floating .history-button,.history-navigation-dialog .history-button{
 display:inline-flex;
 align-items:center;
 justify-content:center;
 min-width:88px;
 min-height:44px;
 margin:0;
 padding:9px 13px;
 border:1px solid #abc0d9;
 border-radius:11px;
 background:#f5f9ff;
 color:#1d4d7a;
 font:inherit;
 font-size:13px;
 font-weight:700;
 line-height:1.25;
 white-space:nowrap;
 touch-action:manipulation;
 cursor:pointer;
}
.history-navigation-floating .history-button:disabled,.history-navigation-dialog .history-button:disabled{
 color:#667386;
 border-color:#d5dce7;
 background:#f0f2f6;
 opacity:.6;
 cursor:default;
}
.history-navigation .history-button:focus-visible{
 outline:3px solid #d8a621;
 outline-offset:2px;
}
.history-navigation-floating[hidden],.history-navigation-dialog[hidden]{display:none!important;}
/* Information dialogs are in the native top layer; the body controls are inert.
   Cancel transform animation so their fixed controls use the viewport. */
dialog.history-dialog-fixed{
 transform:none!important;
 animation:none!important;
 padding-bottom:calc(90px + env(safe-area-inset-bottom,0px))!important;
}
dialog.history-dialog-fixed>.history-navigation-dialog{
 inset:auto auto calc(12px + env(safe-area-inset-bottom,0px)) 50%!important;
 transform:translateX(-50%);
}
/* The hub header and its controls stay outside its only scrolling child. */
dialog.hub-sheet[open]{
 position:fixed!important;
 display:flex!important;
 flex-direction:column;
 overflow:hidden!important;
 padding:0!important;
 transform:none!important;
 animation:none!important;
}
.hub-sheet>.hub-sheet-header{
 position:relative!important;
 inset:auto!important;
 flex:0 0 auto;
 min-height:66px;
 z-index:2;
}
.hub-sheet>.hub-sheet-header button{min-height:44px;touch-action:manipulation;}
.hub-sheet>#hub-sheet-content{
 flex:1 1 auto;
 min-height:0;
 height:auto!important;
 overflow:auto!important;
 overscroll-behavior:contain;
 padding-bottom:calc(22px + env(safe-area-inset-bottom,0px));
}
@media(max-width:650px){
 .history-navigation-floating{
  inset:auto auto calc(var(--history-navigation-bottom,12px) + env(safe-area-inset-bottom,0px)) 50%!important;
  transform:translateX(-50%);
 }
 .hub-sheet>.hub-sheet-header{gap:6px;padding:8px 10px;}
 .hub-sheet>.hub-sheet-header strong{min-width:0;flex:1 1 auto;}
 .hub-sheet>.hub-sheet-header button{flex:0 0 auto;font-size:12px;padding:7px 9px;}
}
@media(max-height:500px) and (orientation:landscape){
 .history-navigation-floating,.history-navigation-dialog{padding:4px!important;border-radius:13px;}
 .history-navigation-floating .history-button,.history-navigation-dialog .history-button{min-height:44px;min-width:80px;padding:7px 10px;}
 .hub-sheet>.hub-sheet-header{min-height:54px;padding-block:5px;}
}
