/* App shell: back-to-top button + the standalone/PWA bottom bar
   (Back / Home / Menu), injected by assets/js/app-shell.js on every
   logged-in page. Was previously copy-pasted into just two pages'
   inline <style> blocks (resale.php, fr_groups.php), so the bar only
   ever rendered styled there — everywhere else app-shell.js still
   injected the markup, just with no CSS to match, so it looked broken
   or didn't visibly appear at all. */
.back-to-top-btn{position:fixed;right:18px;bottom:18px;width:44px;height:44px;border-radius:50%;border:none;background:#0b1f3a;color:#fff;font-size:18px;line-height:1;cursor:pointer;box-shadow:0 4px 14px rgba(11,31,58,.28);opacity:0;visibility:hidden;transform:translateY(8px) translateZ(0);transition:opacity .15s ease,transform .15s ease,visibility .15s;z-index:900;}
.back-to-top-btn.visible{opacity:1;visibility:visible;transform:translateY(0) translateZ(0);}
html.is-standalone .back-to-top-btn{bottom:calc(66px + env(safe-area-inset-bottom, 0px));}

/* iOS Safari/WKWebView (the PWA's actual runtime once installed) doesn't
   always keep a plain position:fixed element glued to the viewport during
   the momentum phase of a scroll gesture - it can visibly lag behind and
   "float" wherever the page happened to be mid-scroll instead of snapping
   back to the bottom, exactly the "floats intermittently and goes in the
   middle" bug report. Promoting it to its own GPU compositing layer
   (translateZ(0)) is the standard fix - it forces the browser to track the
   viewport for this layer directly rather than repainting it lazily with
   the rest of the document. */
.app-bottom-nav{position:fixed;left:0;right:0;bottom:0;display:flex;background:linear-gradient(135deg,#6c63ff,#5850EC);border-top:1px solid rgba(255,255,255,.15);padding:6px 4px calc(6px + env(safe-area-inset-bottom, 0px));z-index:950;-webkit-transform:translateZ(0);transform:translateZ(0);-webkit-backface-visibility:hidden;backface-visibility:hidden;will-change:transform;}
.abn-btn{flex:1;display:flex;flex-direction:column;align-items:center;gap:2px;background:none;border:none;color:#fff;font-size:11px;font-weight:600;padding:6px 4px;cursor:pointer;text-decoration:none;}
.abn-icon{font-size:19px;line-height:1;}
.abn-icon svg{width:19px;height:19px;display:block;}
html.is-standalone body{padding-bottom:calc(64px + env(safe-area-inset-bottom, 0px));}

.app-shell-drawer{position:fixed;inset:0;z-index:980;visibility:hidden;pointer-events:none;}
.app-shell-drawer.open{visibility:visible;pointer-events:auto;}
.app-shell-drawer-overlay{position:absolute;inset:0;background:rgba(11,31,58,.45);opacity:0;transition:opacity .15s ease;}
.app-shell-drawer.open .app-shell-drawer-overlay{opacity:1;}
.app-shell-drawer-panel{position:absolute;left:0;right:0;bottom:0;background:#fff;border-radius:14px 14px 0 0;padding:14px 10px calc(14px + env(safe-area-inset-bottom, 0px));transform:translateY(100%);transition:transform .18s ease;max-height:70vh;overflow-y:auto;}
.app-shell-drawer.open .app-shell-drawer-panel{transform:translateY(0);}
.app-shell-drawer-close{display:block;margin-left:auto;background:none;border:none;font-size:16px;padding:6px 10px;cursor:pointer;color:#667781;}
.app-shell-drawer-panel nav{display:flex;flex-direction:column;}
.app-shell-drawer-panel nav a{padding:12px 14px;color:#0b1f3a;text-decoration:none;font-weight:600;font-size:14px;border-radius:8px;}
.app-shell-drawer-panel nav a.active{background:#ece9fb;color:#5850EC;}
.app-shell-drawer-panel nav a:hover{background:#f5f6f8;}
