/* HomeLynx V8.1.48 — native mobile peek/retract chrome.
   Parent: V8.1.47.
   Mobile presentation only. No map/PSET/Worth math/hopper/source/media/auth changes.

   YouTube-style layering, translated to HomeLynx:
   TOP       = full OS (wordmark/product tabs/hamburger + thumb lane).
   EXPLORE   = full-scroll consumption; top identity and thumb lane retract.
   NAVIGATE  = small reverse intent; thumb lane pops back, but top identity stays
               away until the real top boundary.

   Critical V8.1.48 fix: the fixed .hlx-v8-head is a structural host for the
   bottom-docked omnibox. Never fade/translate that ancestor. Hide its top-only
   children instead so the dock can independently pop back in during NAVIGATE. */

:root{
  --hlx-mobile-chrome-ms:185ms;
  --hlx-mobile-chrome-ease:cubic-bezier(.22,.78,.22,1);
}

.hlx-mobile-hydrator{display:none}

@media(max-width:767px){
  /* Structural host stays stable. A transformed/faded ancestor would drag or
     suppress the fixed omnibox that lives inside it. */
  .hlx-v8-head{
    opacity:1!important;
    translate:0 0!important;
    visibility:visible!important;
    pointer-events:none!important;
    transition:background-color var(--hlx-mobile-chrome-ms) ease!important;
  }

  /* Top-only identity/orientation chrome. Hamburger and Neo are body-level
     fixed instruments, so they must participate explicitly. */
  .hlx-v8-brand,
  .hlx-v8-head .hlx-intent-tabs,
  .hlx-menu-trigger,
  .hlx-neo-float,
  .hlx-os-top,
  .hlx-os-segments,
  .hlx-owner-topline,
  .hlx-finance-brand,
  .hlx-owner-auth-brand,
  .hlx-v8-searchrow.hlx-bottom-dock,
  .hlx-neo-attach-chiphost.hlx-bottom-dock-chiphost,
  #tabbar,
  .hlx-pd-dock{
    transition:
      opacity var(--hlx-mobile-chrome-ms) ease,
      translate var(--hlx-mobile-chrome-ms) var(--hlx-mobile-chrome-ease),
      visibility 0s linear 0s!important;
    will-change:opacity,translate;
  }

  /* TOP: the complete HomeLynx orientation layer is visible. */
  body.hlx-mobile-chrome-top .hlx-v8-head{
    background:#FFFFFF!important;
    background-image:none!important;
  }
  body.hlx-mobile-chrome-top .hlx-v8-brand,
  body.hlx-mobile-chrome-top .hlx-v8-head .hlx-intent-tabs,
  body.hlx-mobile-chrome-top .hlx-menu-trigger,
  body.hlx-mobile-chrome-top .hlx-neo-float,
  body.hlx-mobile-chrome-top .hlx-os-top,
  body.hlx-mobile-chrome-top .hlx-os-segments,
  body.hlx-mobile-chrome-top .hlx-owner-topline,
  body.hlx-mobile-chrome-top .hlx-finance-brand,
  body.hlx-mobile-chrome-top .hlx-owner-auth-brand,
  body.hlx-mobile-chrome-top .hlx-v8-searchrow.hlx-bottom-dock,
  body.hlx-mobile-chrome-top .hlx-neo-attach-chiphost.hlx-bottom-dock-chiphost,
  body.hlx-mobile-chrome-top #tabbar,
  body.hlx-mobile-chrome-top .hlx-pd-dock{
    opacity:1!important;
    translate:0 0!important;
    visibility:visible!important;
    pointer-events:auto!important;
  }

  /* Away from absolute top, the top white glass itself disappears. It remains
     structurally mounted so the bottom composer has a stable containing tree. */
  body.hlx-mobile-chrome-explore .hlx-v8-head,
  body.hlx-mobile-chrome-navigate .hlx-v8-head{
    background:transparent!important;
    background-image:none!important;
    box-shadow:none!important;
  }

  /* EXPLORE: content owns the screen. Top identity exits upward; thumb controls
     exit downward. */
  body.hlx-mobile-chrome-explore .hlx-v8-brand,
  body.hlx-mobile-chrome-explore .hlx-v8-head .hlx-intent-tabs,
  body.hlx-mobile-chrome-explore .hlx-menu-trigger,
  body.hlx-mobile-chrome-explore .hlx-neo-float,
  body.hlx-mobile-chrome-explore .hlx-os-top,
  body.hlx-mobile-chrome-explore .hlx-os-segments,
  body.hlx-mobile-chrome-explore .hlx-owner-topline,
  body.hlx-mobile-chrome-explore .hlx-finance-brand,
  body.hlx-mobile-chrome-explore .hlx-owner-auth-brand{
    opacity:0!important;
    translate:0 calc(-100% - 18px)!important;
    visibility:hidden!important;
    pointer-events:none!important;
    transition:
      opacity var(--hlx-mobile-chrome-ms) ease,
      translate var(--hlx-mobile-chrome-ms) var(--hlx-mobile-chrome-ease),
      visibility 0s linear var(--hlx-mobile-chrome-ms)!important;
  }
  body.hlx-mobile-chrome-explore .hlx-v8-searchrow.hlx-bottom-dock,
  body.hlx-mobile-chrome-explore .hlx-neo-attach-chiphost.hlx-bottom-dock-chiphost,
  body.hlx-mobile-chrome-explore #tabbar,
  body.hlx-mobile-chrome-explore .hlx-pd-dock{
    opacity:0!important;
    translate:0 calc(100% + 30px)!important;
    visibility:hidden!important;
    pointer-events:none!important;
    transition:
      opacity var(--hlx-mobile-chrome-ms) ease,
      translate var(--hlx-mobile-chrome-ms) var(--hlx-mobile-chrome-ease),
      visibility 0s linear var(--hlx-mobile-chrome-ms)!important;
  }

  /* NAVIGATE: this is the native "peek" state. A small reverse swipe brings
     the tab/search/thumb lane back immediately. Logo, product tabs, hamburger
     and other orientation chrome still wait for absolute top. */
  body.hlx-mobile-chrome-navigate .hlx-v8-brand,
  body.hlx-mobile-chrome-navigate .hlx-v8-head .hlx-intent-tabs,
  body.hlx-mobile-chrome-navigate .hlx-menu-trigger,
  body.hlx-mobile-chrome-navigate .hlx-neo-float,
  body.hlx-mobile-chrome-navigate .hlx-os-top,
  body.hlx-mobile-chrome-navigate .hlx-os-segments,
  body.hlx-mobile-chrome-navigate .hlx-owner-topline,
  body.hlx-mobile-chrome-navigate .hlx-finance-brand,
  body.hlx-mobile-chrome-navigate .hlx-owner-auth-brand{
    opacity:0!important;
    translate:0 calc(-100% - 18px)!important;
    visibility:hidden!important;
    pointer-events:none!important;
  }
  body.hlx-mobile-chrome-navigate .hlx-v8-searchrow.hlx-bottom-dock,
  body.hlx-mobile-chrome-navigate .hlx-neo-attach-chiphost.hlx-bottom-dock-chiphost,
  body.hlx-mobile-chrome-navigate #tabbar,
  body.hlx-mobile-chrome-navigate .hlx-pd-dock{
    opacity:1!important;
    translate:0 0!important;
    visibility:visible!important;
    pointer-events:auto!important;
  }

  /* The structural header never becomes an interception plane while its visual
     top layer is retracted. */
  body.hlx-mobile-chrome-explore .hlx-v8-head,
  body.hlx-mobile-chrome-navigate .hlx-v8-head{pointer-events:none!important}

  /* Persistent escape route law. */
  body.hlx-property-detail-route .hlx-pd-back-wrap,
  .hlx-v8-results-head [data-hlx-close-results],
  [aria-modal="true"] [data-close],
  [aria-modal="true"] [aria-label*="Close" i]{
    opacity:1!important;
    translate:0 0!important;
    visibility:visible!important;
    pointer-events:auto!important;
  }

  /* Bottom-of-content signal retained from V8.1.47. */
  .hlx-mobile-hydrator{
    position:fixed;
    z-index:2147481200;
    left:50%;
    bottom:max(16px,calc(env(safe-area-inset-bottom,0px) + 12px));
    width:30px;height:30px;margin-left:-15px;
    display:grid;place-items:center;
    opacity:0;translate:0 10px;pointer-events:none;
    transition:opacity 150ms ease,translate 190ms var(--hlx-mobile-chrome-ease);
  }
  .hlx-mobile-hydrator__ring{
    width:20px;height:20px;box-sizing:border-box;border-radius:50%;
    border:2px solid rgba(11,13,12,.18);border-top-color:#0B0D0C;
    animation:hlx-mobile-hydrator-spin .72s linear infinite;
    box-shadow:0 4px 18px rgba(11,13,12,.08);
    background:rgba(255,255,255,.28);
    -webkit-backdrop-filter:blur(8px);backdrop-filter:blur(8px);
  }
  body.hlx-mobile-at-bottom .hlx-mobile-hydrator{opacity:1;translate:0 0}
  body.hlx-mobile-bottom-settled .hlx-mobile-hydrator__ring{
    width:7px;height:7px;border:0;background:#0B0D0C;animation:none;box-shadow:none;
    transition:width 160ms ease,height 160ms ease,background 160ms ease;
  }
  @keyframes hlx-mobile-hydrator-spin{to{transform:rotate(360deg)}}

  /* Interaction lock stabilizes the active thumb lane without violating the
     absolute-top law. If focus/modal began deep in content, top identity stays
     hidden; if it began at TOP, the TOP state keeps it visible. */
  body.hlx-mobile-chrome-lock .hlx-v8-searchrow.hlx-bottom-dock,
  body.hlx-mobile-chrome-lock .hlx-neo-attach-chiphost.hlx-bottom-dock-chiphost,
  body.hlx-mobile-chrome-lock #tabbar,
  body.hlx-mobile-chrome-lock .hlx-pd-dock{
    opacity:1!important;
    translate:0 0!important;
    visibility:visible!important;
    pointer-events:auto!important;
  }
}

@media(prefers-reduced-motion:reduce){
  :root{--hlx-mobile-chrome-ms:1ms}
  .hlx-mobile-hydrator__ring{animation-duration:1.4s}
}
