/* PEP-MOBILE-APPBAR-ICON-VISIBILITY-AUTHORITY-128
 * Late geometry bridge for the canonical Theme mobile appbar.
 * No JS/controller/data ownership. Theme remains the renderer.
 */
:root{
  --kbm-128-appbar-h:112px;
  --kbm-128-appbar-icon:34px;
  --kbm-128-appbar-label:15px;
}

@media (max-width:767px){
  /* Keep all Core bottom-clearance contracts aligned with the taller Theme appbar. */
  body.kbm-mae-app{--kbm-mae-appbar-h:var(--kbm-128-appbar-h)!important}
  body.kbm-vp14-mobile-system{--kbm-vp14-bottom-h:var(--kbm-128-appbar-h)!important}
  body.kbm-mobile-app-ux{--kbm-app-bottom-nav-h:var(--kbm-128-appbar-h)!important}
  body.kbm-rsb-surface-app{--kbm-rsb-bottom-h:var(--kbm-128-appbar-h)!important}
  body.kbm-mps-a-active{--kbm-mps-a-appbar:var(--kbm-128-appbar-h)!important}
  body.kbm-theme-core{padding-bottom:calc(var(--kbm-128-appbar-h) + 18px + env(safe-area-inset-bottom,0px))!important}
  body.kbm-theme-core .kbm-theme-footer.kbm-theme-footer--compact{padding-bottom:calc(var(--kbm-128-appbar-h) + 18px + env(safe-area-inset-bottom,0px))!important}

  body :is(.kbm-theme-mobile-appbar,#kbm-app-bar,[data-kbm-theme-mobile-appbar],.kbm-quf-app-bar){
    box-sizing:border-box!important;
    inset-inline:3px!important;
    bottom:calc(4px + env(safe-area-inset-bottom,0px))!important;
    width:auto!important;max-width:none!important;
    height:var(--kbm-128-appbar-h)!important;
    min-height:var(--kbm-128-appbar-h)!important;
    padding:9px 6px!important;
    padding-bottom:calc(9px + env(safe-area-inset-bottom,0px))!important;
    align-items:stretch!important;
    border-radius:28px!important;
    gap:6px!important;
  }

  body :is(.kbm-theme-mobile-appbar,#kbm-app-bar,[data-kbm-theme-mobile-appbar],.kbm-quf-app-bar) :is(
    .kbm-quf-app-bar__item,.kbm-theme-mobile-appbar__item,[data-kbm-theme-appbar-item],[data-key]
  ){
    box-sizing:border-box!important;
    min-width:70px!important;
    min-height:86px!important;
    height:86px!important;
    padding:9px 6px!important;
    gap:7px!important;
    border-radius:22px!important;
    font-size:var(--kbm-128-appbar-label)!important;
    line-height:1.25!important;
  }

  body :is(.kbm-theme-mobile-appbar,#kbm-app-bar,[data-kbm-theme-mobile-appbar],.kbm-quf-app-bar) :is(
    .kbm-quf-app-bar__icon,.kbm-theme-mobile-appbar__icon,[data-kbm-nav-icon]
  ){
    width:var(--kbm-128-appbar-icon)!important;
    height:var(--kbm-128-appbar-icon)!important;
    min-width:var(--kbm-128-appbar-icon)!important;
    min-height:var(--kbm-128-appbar-icon)!important;
    flex:0 0 var(--kbm-128-appbar-icon)!important;
  }

  body :is(.kbm-theme-mobile-appbar,#kbm-app-bar,[data-kbm-theme-mobile-appbar],.kbm-quf-app-bar) :is(
    .kbm-quf-app-bar__icon,.kbm-theme-mobile-appbar__icon,[data-kbm-nav-icon]
  ) :is(svg,img),
  body :is(.kbm-theme-mobile-appbar,#kbm-app-bar,[data-kbm-theme-mobile-appbar],.kbm-quf-app-bar) :is(
    .kbm-quf-app-bar__item,.kbm-theme-mobile-appbar__item,[data-kbm-theme-appbar-item]
  ) > svg{
    width:var(--kbm-128-appbar-icon)!important;
    height:var(--kbm-128-appbar-icon)!important;
    max-width:none!important;max-height:none!important;object-fit:contain!important;
  }

  body :is(.kbm-theme-mobile-appbar,#kbm-app-bar,[data-kbm-theme-mobile-appbar],.kbm-quf-app-bar) :is(
    .kbm-quf-app-bar__label,.kbm-theme-mobile-appbar__label,[data-kbm-nav-label]
  ){
    font-size:var(--kbm-128-appbar-label)!important;
    font-weight:950!important;
    line-height:1.25!important;
    white-space:nowrap!important;
    overflow:visible!important;
    text-overflow:clip!important;
  }

  body :is(.kbm-theme-mobile-appbar,#kbm-app-bar,[data-kbm-theme-mobile-appbar],.kbm-quf-app-bar) :is(
    [data-key="submit"],.kbm-quf-app-bar__item--primary,.is-primary
  ){
    min-height:92px!important;height:92px!important;
    padding-top:10px!important;padding-bottom:10px!important;
    border-radius:24px!important;
  }
}

@media (max-width:390px){
  :root{--kbm-128-appbar-h:106px;--kbm-128-appbar-icon:32px;--kbm-128-appbar-label:14px}
  body :is(.kbm-theme-mobile-appbar,#kbm-app-bar,[data-kbm-theme-mobile-appbar],.kbm-quf-app-bar) :is(
    .kbm-quf-app-bar__item,.kbm-theme-mobile-appbar__item,[data-kbm-theme-appbar-item],[data-key]
  ){min-width:68px!important;min-height:80px!important;height:80px!important;padding-inline:5px!important}
  body :is(.kbm-theme-mobile-appbar,#kbm-app-bar,[data-kbm-theme-mobile-appbar],.kbm-quf-app-bar) :is(
    [data-key="submit"],.kbm-quf-app-bar__item--primary,.is-primary
  ){min-height:86px!important;height:86px!important}
}
