/* PWA-only surfaces; keep the existing customer and admin themes intact. */
body.af-pwa .preloader[hidden] { display:none !important; }
body.af-pwa .preloader > img { width:72px !important; height:72px !important; object-fit:contain; border-radius:0 !important; background:transparent; }
.af-pwa-update[hidden], #edlinpay-pwa-install[hidden], #edlinpay-pwa-help[hidden] { display:none !important; }
.af-pwa-update, #edlinpay-pwa-install {
    box-sizing:border-box; position:fixed; z-index:1050; right:max(14px,env(safe-area-inset-right,0px));
    bottom:calc(120px + env(safe-area-inset-bottom,0px)); width:min(420px,calc(100% - 28px));
    padding:18px; border:1px solid #344057; border-radius:20px; background:#181f2e; color:#e9eef7;
    box-shadow:0 8px 28px #0005; font:inherit;
}
.af-pwa-update p, #edlinpay-pwa-install p { margin:0 0 12px; color:#b9c3d5; font-size:14px; line-height:1.5; }
.af-pwa-update button, #edlinpay-pwa-install button { min-width:44px; min-height:44px; border:1px solid #344057; border-radius:12px; padding:10px 14px; color:#e9eef7; background:#2e3462; font:inherit; cursor:pointer; touch-action:manipulation; }
.af-pwa-update button:first-of-type, #edlinpay-pwa-install .edlinpay-pwa-install-button { color:#15110b; background:#c99535; font-weight:600; }
.af-pwa-update button + button { margin-left:8px; }
#edlinpay-pwa-install .edlinpay-pwa-close { position:absolute; right:8px; top:8px; padding:0; font-size:24px; background:transparent; border:0; }
#edlinpay-pwa-install .edlinpay-pwa-content { display:flex; align-items:center; gap:14px; padding-right:30px; }
#edlinpay-pwa-install .edlinpay-pwa-icon { width:48px; height:48px; flex:0 0 48px; object-fit:contain; }
#edlinpay-pwa-install strong { display:block; color:#f4f7fc; font-size:17px; margin-bottom:6px; }
#edlinpay-pwa-install .edlinpay-pwa-help { padding:12px; background:#101725; border-radius:12px; }
#edlinpay-pwa-install .edlinpay-pwa-actions { display:flex; flex-wrap:wrap; gap:8px; }
.af-pwa-update button:focus-visible, #edlinpay-pwa-install button:focus-visible { outline:2px solid #dfb96e; outline-offset:3px; }
.af-pwa-update button:disabled { opacity:.6; cursor:wait; }
body:has(.af-pwa-update:not([hidden])) #edlinpay-pwa-install { display:none; }
@media(min-width:1200px) { .af-pwa-update, #edlinpay-pwa-install { bottom:20px; } }
@media(display-mode:standalone) {
    body.af-pwa { padding-left:env(safe-area-inset-left,0px); padding-right:env(safe-area-inset-right,0px); }
    body.af-pwa .dashboard-header { padding-top:env(safe-area-inset-top,0px); }
}
@media(pointer:coarse) { body.af-pwa .dashboard :is(input:not([type=checkbox]):not([type=radio]),select,textarea) { font-size:16px; } }
@media(hover:hover) and (pointer:fine) { .af-pwa-update button:hover, #edlinpay-pwa-install button:hover { filter:brightness(1.1); } }
