/* V45 — Gallery corrections and reliable mobile navigation */

/* Keep the mobile menu button inside the header and make the opened menu fully visible. */
@media (max-width:900px){
  .site-header,
  .site-header.scrolled{
    overflow:visible!important;
  }

  .site-header .header-inner{
    position:relative!important;
    width:calc(100% - 20px)!important;
    max-width:none!important;
    gap:8px!important;
    overflow:visible!important;
  }

  .site-header .brand{
    flex:1 1 auto!important;
    min-width:0!important;
    width:auto!important;
    max-width:calc(100% - 104px)!important;
    margin-right:0!important;
  }

  .site-header .brand img,
  .site-header.scrolled .brand img{
    width:auto!important;
    max-width:100%!important;
    height:auto!important;
  }

  .site-header .header-actions{
    position:relative!important;
    z-index:1402!important;
    flex:0 0 auto!important;
    margin-left:auto!important;
    gap:6px!important;
  }

  .site-header .header-book{
    display:none!important;
  }

  .site-header .lang-switch{
    display:grid!important;
    flex:0 0 42px!important;
    width:42px!important;
    height:42px!important;
  }

  .site-header .menu-toggle{
    display:block!important;
    visibility:visible!important;
    opacity:1!important;
    position:relative!important;
    z-index:1403!important;
    flex:0 0 44px!important;
    width:44px!important;
    height:44px!important;
    margin:0!important;
  }

  .site-header .main-nav{
    position:fixed!important;
    top:var(--header-h)!important;
    left:10px!important;
    right:10px!important;
    bottom:auto!important;
    width:auto!important;
    max-width:none!important;
    max-height:calc(100dvh - var(--header-h) - 20px)!important;
    overflow-x:hidden!important;
    overflow-y:auto!important;
    overscroll-behavior:contain!important;
    z-index:1401!important;
    display:none!important;
    flex-direction:column!important;
    align-items:stretch!important;
    gap:3px!important;
    padding:12px!important;
    border:1px solid rgba(63,54,88,.12)!important;
    border-radius:16px!important;
    background:rgba(255,255,255,.98)!important;
    box-shadow:0 20px 50px rgba(30,28,60,.22)!important;
  }

  .site-header .main-nav.open{
    display:flex!important;
  }

  .site-header .main-nav a{
    display:flex!important;
    align-items:center!important;
    width:100%!important;
    min-height:44px!important;
    padding:11px 14px!important;
    border-radius:10px!important;
    font-size:.96rem!important;
    line-height:1.35!important;
    white-space:normal!important;
  }

  .site-header .main-nav a.active{
    background:rgba(21,151,168,.09)!important;
  }

  body.mobile-nav-open{
    overflow:hidden!important;
  }
}

@media (max-width:420px){
  .site-header .header-inner{
    width:calc(100% - 14px)!important;
    gap:5px!important;
  }
  .site-header .brand{
    max-width:calc(100% - 98px)!important;
  }
  .site-header .lang-switch{
    flex-basis:40px!important;
    width:40px!important;
    height:40px!important;
  }
  .site-header .menu-toggle{
    flex-basis:42px!important;
    width:42px!important;
    height:42px!important;
  }
}
