/* AppleJr Glisse navigation — official glisse@0.5.0 TabBar + scoped integration.
   Based on https://github.com/0kzh/glisse (MIT). */
.aj-glisse-root {
  --lg-foreground:rgb(255 255 255);
  --lg-muted:rgb(235 235 245 / .6);
  --lg-glass:rgba(35,36,41,.94);
  --lg-glass-active:rgba(69,71,78,.94);
  --lg-edge:rgba(255,255,255,.25);
  --lg-selection:rgb(255 255 255 / .145);
  --lg-drop:rgba(0,0,0,.43);
  --lg-fill:#0091ff;
  --lg-tab-selected:#0091ff;
  --lg-tab-bend:0.35;
  --lg-tab-dispersion:3;
  --lg-glass-bend:0.62;
  --lg-glass-dispersion:0.8;
  --lg-rim-shine:0.42;
  --lg-blur:16px;
  position:fixed;
  left:50%;
  bottom:calc(13px + env(safe-area-inset-bottom, 0px));
  transform:translateX(-50%);
  z-index:500;
  width:min(420px, calc(100vw - 28px));
  box-sizing:border-box;
  isolation:isolate;
  color:#ffffff;
  font-family:system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;
  display:none;
}
body.aj-glisse-ready .aj-glisse-root {display:block}
body.aj-glisse-ready .bottom-nav-glass {display:none!important}
.aj-glisse-root .lg-tab-bar,
.aj-glisse-root .lg-tab-bar[data-icons] {
  --lg-tab-inset:5px;
  --lg-tab-width:calc((min(420px, 100vw - 28px) - 10px)/4);
  --lg-tab-height:57px;
  --lg-lens-grow-x:24px;
  --lg-lens-grow-y:15px;
  display:flex;
  width:100%;
  box-sizing:border-box;
  min-height:67px;
  padding:var(--lg-tab-inset);
  border-radius:35px;
  filter:drop-shadow(0 15px 25px rgba(0,0,0,.52));
  background:transparent;
}
.aj-glisse-root .lg-tab-bar-glass {
  border-radius:35px;
  box-shadow:inset 0 1px 0 rgba(255,255,255,.43),inset 0 -1px 0 rgba(255,255,255,.08),0 8px 23px rgba(0,0,0,.34);
}
.aj-glisse-root .lg-tab-bar[data-icons] :is(.lg-tab,.lg-tab-copy) {
  gap:3px;
  font-size:10px;
  font-weight:600;
  letter-spacing:-.15px;
}
.aj-glisse-root .lg-tab-icon>svg {
  width:23px;
  height:23px;
  fill:currentColor;
}
.aj-glisse-root .lg-tab {
  color:rgb(255 255 255)!important;
  -webkit-tap-highlight-color:transparent;
}
.aj-glisse-root .lg-tab-label {
  white-space:nowrap;
}
.aj-glisse-root .lg-tab-tint {
  color:#0091ff;
}
.aj-glisse-root .lg-tab-lens {
  border-radius:29px;
}
.aj-glisse-root .lg-tab-bar .lg-tab[data-selected] {
  color:var(--lg-tab-selected)!important;
}
@media(max-width:390px) {
  .aj-glisse-root {
    width:calc(100vw - 20px);
    bottom:calc(9px + env(safe-area-inset-bottom, 0px));
  }
  .aj-glisse-root .lg-tab-bar,
  .aj-glisse-root .lg-tab-bar[data-icons] {
    --lg-tab-width:calc((100vw - 30px)/4);
    --lg-tab-height:54px;
    --lg-lens-grow-x:20px;
    --lg-lens-grow-y:12px;
    min-height:64px;
    border-radius:33px;
  }
  .aj-glisse-root .lg-tab-bar[data-icons] :is(.lg-tab,.lg-tab-copy) {
    font-size:9px;
  }
  .aj-glisse-root .lg-tab-icon>svg {
    width:22px;
    height:22px;
  }
}
@media(prefers-reduced-motion:reduce) {
  .aj-glisse-root .lg-tab-bar,
  .aj-glisse-root .lg-tab {
    transition:none!important;
  }
}

/* APPLEJR_GLISSE_SOLID_AND_MOBILE_V3 */
.aj-glisse-root .lg-tab-bar-glass {
  box-shadow:inset 0 1px 0 rgba(255,255,255,.31), inset 0 -1px 0 rgba(255,255,255,.12),0 12px 30px rgba(0,0,0,.44);
}
@media(max-width:600px), (pointer:coarse) {
  .aj-glisse-root .lg-tab-bar,
  .aj-glisse-root .lg-tab-bar-glass {
    will-change:transform;
  }
  .aj-glisse-root .lg-tab-lens,
  .aj-glisse-root .lg-tab-tint {
    will-change:transform;
    backface-visibility:hidden;
    -webkit-backface-visibility:hidden;
  }
  /* On mobile, keep the moving Glisse glass lens and spring but avoid the
     heavy per-frame SVG refraction of text (WebKit CPU redraw). */
  .aj-glisse-root .lg-tab-lensed {
    visibility:hidden!important;
  }
  .aj-glisse-root .lg-tab-bar[data-lensing] .lg-tab-tint {
    visibility:visible;
  }
}


/* APPLEJR_GLISSE_BEND_DISPERSION_RIM_V4
   Enhanced Glisse optics: stronger optical bend, channel dispersion,
   rim lighting, and lightweight prismatic edges on mobile. */
.aj-glisse-root .lg-tab-bar-glass{
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,.60),
    inset 0 -1px 0 rgba(255,255,255,.17),
    inset 1px 0 rgba(132,201,255,.22),
    inset -1px 0 rgba(255,156,198,.19),
    0 12px 30px rgba(0,0,0,.44);
}
.aj-glisse-root .lg-tab-lens::before{
  box-shadow:
    inset 1.2px 0 rgba(99,188,255,.42),
    inset -1.2px 0 rgba(255,120,160,.36),
    inset 0 1px rgba(255,255,255,.33),
    inset 0 -1px rgba(255,255,255,.14);
  border-radius:inherit;
}
@media(max-width:600px), (pointer:coarse){
  .aj-glisse-root .lg-tab-lens::before{
    box-shadow:
      inset 1px 0 rgba(102,194,255,.36),
      inset -1px 0 rgba(255,139,177,.32),
      inset 0 1px rgba(255,255,255,.30);
  }
}
