/* Progressive enhancement. The legacy app remains usable without this file. */
.pwa-install-btn{appearance:none;border:1px solid var(--border,#c8d1dd);background:var(--card,#fff);color:var(--accent,#334f73);border-radius:8px;padding:8px 12px;min-height:40px;font:inherit;font-size:13px;font-weight:600;white-space:nowrap;cursor:pointer}
.pwa-install-btn:hover{background:var(--accent-soft,#eaf0f8)}
.pwa-install-btn:focus-visible,.pwa-dialog button:focus-visible{outline:3px solid #8daedb;outline-offset:2px}
.pwa-install-btn[hidden],.pwa-connection[hidden],.pwa-dialog[hidden]{display:none!important}
.ruang-theme.login-page .pwa-install-btn{margin:12px 0 0;min-height:44px;padding:10px 16px;background:transparent;max-width:100%}
.ruang-theme #workspace .pwa-install-btn{font-size:13px!important;min-height:40px!important;padding:8px 12px!important;line-height:1.3!important;margin-top:12px;background:var(--card);width:auto;display:inline-flex;align-items:center;justify-content:center}
.pwa-connection{position:relative;z-index:56;background:#f6eecb;color:#58460f;border-bottom:1px solid #e5d38c;padding:9px 16px;text-align:center;font-size:13px;line-height:1.35}
.pwa-dialog{border:1px solid #d7dfeb;border-radius:16px;padding:0;color:#243648;background:#fff;width:min(400px,calc(100vw - 32px));max-height:85dvh;box-shadow:0 18px 50px #071c3e36}
.pwa-dialog::backdrop{background:rgba(15,32,51,.52)}
.pwa-dialog-body{padding:24px}
.pwa-dialog h2{font-weight:650;font-size:22px;line-height:1.3;margin:0 0 10px}
.pwa-dialog p,.pwa-dialog li{font-size:15px;line-height:1.55}
.pwa-dialog ol{padding-left:22px}
.pwa-dialog .pwa-close{background:#334f73;color:white;border:0;border-radius:8px;width:100%;min-height:46px;cursor:pointer;margin-top:18px}
@media(max-width:760px){.ruang-theme #workspace header .tools{flex-wrap:wrap;justify-content:flex-end}.ruang-theme #workspace .pwa-install-btn{min-height:40px!important;padding:8px 12px!important}}
@media(prefers-reduced-motion:reduce){.pwa-dialog *{scroll-behavior:auto}}

/* Touch and viewport consistency on small phones. */
@media(max-width:760px){.ruang-theme #workspace .app-shell,.ruang-theme #workspace main{min-width:0}.ruang-theme #workspace button:not(.pwa-install-btn){touch-action:manipulation}.ruang-theme #workspace #demoMainNav{padding-bottom:max(8px,env(safe-area-inset-bottom))}.ruang-theme #workspace #demoMainNav button{min-width:0;white-space:normal!important}.ruang-theme .demo-room-grid>*{min-width:0}}
