/* 3.1.2: Magical Night header and mobile popup hotfix. Loaded last. */
#event-center-btn.event-center-btn { display:inline-flex!important; align-items:center!important; justify-content:center!important; gap:8px!important; min-width:0!important; }
#event-center-btn.event-center-btn > .magical-nav-currency { display:block!important; position:static!important; width:25px!important; height:25px!important; max-width:25px!important; max-height:25px!important; flex:0 0 25px!important; object-fit:contain!important; }
#event-center-btn.event-center-btn > .magical-nav-name { display:inline!important; min-width:0!important; flex:0 1 auto!important; font:inherit!important; font-weight:750!important; line-height:1.15!important; text-align:left!important; white-space:normal!important; overflow-wrap:normal!important; }
#event-center-btn.event-center-btn > #event-center-progress { display:none!important; }
#event-center-content .magical-dialog-head h2 .magical-currency-icon { display:inline-block!important; width:26px!important; height:26px!important; flex:0 0 26px!important; max-width:26px!important; max-height:26px!important; object-fit:contain!important; }
#event-center-content .magical-center .magical-center-content { overscroll-behavior:contain; scrollbar-gutter:stable; }
@media(max-width:760px){
  /* Page won't scroll beneath a modal: let the dialog scroll in one continuous direction. */
  html body #event-center-dialog.event-center-dialog:modal { position:fixed!important; inset:0!important; width:100vw!important; max-width:100vw!important; min-width:0!important; height:100dvh!important; max-height:100dvh!important; margin:0!important; border-radius:0!important; box-sizing:border-box!important; padding:0 0 env(safe-area-inset-bottom,0px)!important; overflow-x:hidden!important; overflow-y:auto!important; -webkit-overflow-scrolling:touch; overscroll-behavior:contain; }
  html body #event-center-dialog #event-center-content { display:block!important; height:auto!important; min-height:0!important; max-height:none!important; overflow:visible!important; }
  html body #event-center-dialog #event-center-content > .event-v2-shell.magical-center { display:block!important; height:auto!important; min-height:0!important; max-height:none!important; overflow:visible!important; }
  html body #event-center-dialog #event-center-content .magical-center-content { display:flex!important; flex-direction:column!important; min-height:0!important; height:auto!important; max-height:none!important; overflow:visible!important; padding-bottom:calc(32px + env(safe-area-inset-bottom,0px))!important; }
  html body #event-center-dialog #event-center-content .magical-dialog-head { position:relative!important; }
  html.aniiland-phone body.nightfall-homeland .homeland-mobile-shortcuts #event-center-btn.event-center-btn > .magical-nav-name { display:inline!important; font-size:12px!important; max-width:105px!important; }
  html.aniiland-phone body.nightfall-homeland .homeland-mobile-shortcuts #event-center-btn.event-center-btn > .magical-nav-currency { display:block!important; }
  html body #feature-help-dialog:modal { max-height:calc(100dvh - 16px)!important; overflow-y:auto!important; -webkit-overflow-scrolling:touch; }
}
