/* Lugal Speed v1.8.4 — Mobile menu close: anchored to the actual viewport-side panel,
   independent of grid ordering, old circular button and legacy transform rules. */
@media (max-width: 720px) {
  .motion-menu .menu-panel-left {
    /* Position anchor is the full-width overlay panel, not the 2-row header grid. */
    position: relative !important;
    padding-top: max(20px, env(safe-area-inset-top, 0px)) !important;
  }
  .motion-menu .menu-left-top {
    position: static !important;
    display: grid !important;
    grid-template-columns: minmax(0,1fr) auto !important;
    align-items: center !important;
    justify-content: stretch !important;
    gap: 8px !important;
    padding-right: 66px !important;
    min-height: 58px;
  }
  .motion-menu .menu-left-top .motion-menu-brand {
    grid-column:1 !important;
    grid-row:1 !important;
    justify-self:start !important;
    min-width:0 !important;
    max-width:min(170px,100%) !important;
  }
  .motion-menu .menu-left-top .tar-menu-language {
    grid-column:2 !important;
    grid-row:1 !important;
    margin:0 !important;
    justify-self:end !important;
    white-space:nowrap !important;
  }
  .motion-menu .menu-left-top #menuClose.ls-precision-close.menu-close {
    position:absolute !important;
    /* Override legacy flex/grid placement and keep X at top RIGHT on every phone width. */
    top:calc(14px + env(safe-area-inset-top, 0px)) !important;
    right:calc(16px + env(safe-area-inset-right, 0px)) !important;
    left:auto !important;
    bottom:auto !important;
    inset-inline-start:auto !important;
    inset-inline-end:calc(16px + env(safe-area-inset-right, 0px)) !important;
    grid-column:auto !important;
    grid-row:auto !important;
    display:block !important;
    width:48px !important;
    min-width:48px !important;
    height:48px !important;
    min-height:48px !important;
    margin:0 !important;
    padding:0 !important;
    box-sizing:border-box !important;
    border:1px solid rgba(224,187,120,.65) !important;
    border-radius:10px !important;
    clip-path:none !important;
    background:rgba(12,13,17,.92) !important;
    box-shadow:0 8px 24px rgba(0,0,0,.28) !important;
    transform:none !important;
    z-index:100 !important;
    overflow:hidden !important;
    -webkit-appearance:none;
    appearance:none;
    touch-action:manipulation;
    -webkit-tap-highlight-color:transparent;
    transition:background-color .25s ease,border-color .25s ease,box-shadow .25s ease !important;
  }
  .motion-menu .menu-left-top #menuClose::before,
  .motion-menu .menu-left-top #menuClose .ls-close-halo {display:none !important;content:none !important}
  .motion-menu .menu-left-top #menuClose span:not(.ls-close-halo) {
    position:absolute !important;
    top:50% !important;
    left:50% !important;
    width:23px !important;
    height:2px !important;
    margin:0 !important;
    border:0 !important;
    border-radius:4px !important;
    background:#f2d39d !important;
    opacity:1 !important;
    transform-origin:center !important;
    transition:transform .28s ease,background-color .25s ease !important;
  }
  .motion-menu .menu-left-top #menuClose span:first-child {transform:translate(-50%,-50%) rotate(45deg) !important}
  .motion-menu .menu-left-top #menuClose span:nth-child(2) {transform:translate(-50%,-50%) rotate(-45deg) !important}
  .motion-menu .menu-left-top #menuClose:hover,
  .motion-menu .menu-left-top #menuClose:focus-visible {
    background:#282024 !important;
    border-color:#f3dca8 !important;
    box-shadow:0 8px 24px rgba(0,0,0,.35),0 0 0 3px rgba(224,187,120,.13) !important;
    transform:none !important;
  }
  .motion-menu .menu-left-top #menuClose:hover span:first-child,
  .motion-menu .menu-left-top #menuClose:focus-visible span:first-child {transform:translate(-50%,-50%) rotate(135deg) !important}
  .motion-menu .menu-left-top #menuClose:hover span:nth-child(2),
  .motion-menu .menu-left-top #menuClose:focus-visible span:nth-child(2) {transform:translate(-50%,-50%) rotate(45deg) !important}
  .motion-menu .menu-left-top #menuClose:focus-visible{outline:2px solid white !important;outline-offset:2px !important}
}
@media (max-width: 375px){
  .motion-menu .menu-left-top{padding-right:62px !important}
  .motion-menu .menu-left-top .motion-menu-brand{max-width:108px !important}
  .motion-menu .menu-left-top #menuClose.ls-precision-close.menu-close {right:calc(12px + env(safe-area-inset-right, 0px)) !important;inset-inline-end:calc(12px + env(safe-area-inset-right, 0px)) !important}
}
@media (prefers-reduced-motion: reduce){
  .motion-menu #menuClose, .motion-menu #menuClose span{transition:none !important}
}
