.pwa-tabs, .pwa-app-header { display: none; }
.pwa-menu-toggle, .pwa-menu-backdrop, .pwa-menu-close { display: none; }
.pwa-banner { position: fixed; bottom: calc(210px + env(safe-area-inset-bottom)); left: 50%; transform: translateX(-50%); width: min(480px, calc(100% - 24px)); z-index: 1040; box-shadow: 0 4px 18px #0002; }
.pwa-install-sheet { height: auto !important; max-height: 85dvh; border-radius: 18px 18px 0 0; padding-bottom: env(safe-area-inset-bottom); }
#installBanner { position: relative; inset: auto; transform: none; width: 100%; margin: 0 0 16px; box-shadow: none; z-index: auto; }
.pwa-banner[hidden], .chat-install-hint[hidden] { display: none !important; }
#iosInstallSheet.pwa-safari-guide { bottom: calc(44px + env(safe-area-inset-bottom)); max-height: 60svh; max-height: 60dvh; overflow: visible; }
.pwa-safari-guide .offcanvas-body { overflow-y: auto; min-height: 0; }
.pwa-install-steps { counter-reset: install-step; list-style: none; padding: 0; text-align: left; }
.pwa-install-steps li { display: flex; align-items: flex-start; gap: 10px; margin-bottom: 12px; }
.pwa-install-steps li::before { counter-increment: install-step; content: counter(install-step); flex: 0 0 24px; height: 24px; border-radius: 50%; text-align: center; background: #e8edf7; color: #044bd9; font-weight: 700; }
.pwa-install-steps i { color: #044bd9; margin-right: 4px; }
.pwa-safari-arrow { display: none; pointer-events: none; position: absolute; width: 44px; height: 48px; bottom: -48px; left: calc(50% - 22px); color: #044bd9; }
.pwa-safari-guide .pwa-safari-arrow { display: block; }
.pwa-safari-guide.pwa-safari-ipad { top: calc(44px + env(safe-area-inset-top)); bottom: auto; }
.pwa-safari-guide.pwa-safari-ipad .pwa-safari-arrow { bottom: auto; left: auto; top: -48px; right: 16px; transform: rotate(180deg); }
.pwa-profile-menu .list-group-item { display: flex; align-items: center; gap: 14px; padding: 16px; }
.pwa-profile-menu .list-group-item span { flex: 1; }
.pwa-profile-menu .list-group-item > i { width: 22px; flex: 0 0 22px; text-align: center; }
.pwa-profile-share .st-support-share-feedback:empty, .pwa-profile-share script { display: none; }
.pwa-notification-count { position: absolute; top: -2px; right: -4px; font-size: 10px; }
.app-notification-item { color: inherit; text-decoration: none; }
.app-notification-dot { width: 8px; height: 8px; flex: 0 0 8px; background: #044bd9; border-radius: 50%; }
.pwa-header-actions { display: flex; gap: 4px; }
.chat-install-hint { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }
.st-ptr { position: fixed; left: 0; right: 0; height: 0; display: flex; justify-content: center; z-index: 1038; pointer-events: none; }
.st-ptr[hidden] { display: none; }
.st-ptr-circle { position: relative; display: grid; place-items: center; width: 44px; height: 44px; margin-top: -44px; border-radius: 50%; background: #fff; color: #044bd9; box-shadow: 0 2px 10px #0003; }
.st-ptr-arrow { font-size: 24px; }
.st-ptr-spinner { display: none; }
.st-ptr-refreshing .st-ptr-arrow { display: none; }
.st-ptr-refreshing .st-ptr-spinner { display: block; }
.st-ptr-settling .st-ptr-circle { transition: transform .18s ease-out; }
.st-ptr-label { position: absolute; top: 48px; white-space: nowrap; padding: 2px 8px; border-radius: 8px; background: #fff; font-size: 12px; }
html.is-app:has([data-ptr]) { overscroll-behavior-y: none; }
@media (max-width: 767.98px) { html:has([data-ptr]) { overscroll-behavior-y: none; } }
@media (prefers-reduced-motion: reduce) {
  .st-ptr-arrow { display: none; }
  .st-ptr-spinner { display: block; }
  .st-ptr-settling .st-ptr-circle { transition: none; }
}
@media (max-width: 767.98px) {
  #chatRoot .chat-card { height: 100%; min-height: 0; border-radius: 0; margin: 0; overflow: hidden; box-shadow: none; }
  body:has(#chatRoot), body:has(#chatRoot) #main { height: -webkit-fill-available; height: 100svh; height: 100dvh; overflow: hidden; }
  body:has(#chatRoot) #main > .pagetitle, body:has(#chatRoot) #main .breadcrumb, body:has(#chatRoot) .pwa-tabs { display: none !important; }
  body:has(#chatRoot) #header, body:has(#chatRoot) .back-to-top { display: none !important; }
  body:has(#chatRoot) #main { position: fixed; top: var(--chat-viewport-top, 0px); left: 0; right: 0; height: var(--chat-viewport-height, -webkit-fill-available); height: var(--chat-viewport-height, 100svh); height: var(--chat-viewport-height, 100dvh); margin: 0; padding: 0; transition: none; display: flex; flex-direction: column; min-height: 0; }
  #chatRoot { height: 100%; width: 100%; flex: 1; min-height: 0; }
  #chatRoot .chat-install-hint { max-height: 22%; overflow-y: auto; flex-wrap: wrap; margin-bottom: 0; }
  #chatRoot .chat-install-hint > [data-pwa-install-text] { flex: 1 1 180px; }
  #chatRoot .chat-install-hint .pwa-install { white-space: normal; }
  #chatRoot .st-support-banner { display: none; }
  #chatRoot .chat-textarea { font-size: 16px; }
  #chatRoot .chat-header { padding-top: calc(12px + env(safe-area-inset-top)); padding-left: max(16px, env(safe-area-inset-left)); padding-right: max(16px, env(safe-area-inset-right)); }
  #chatRoot .chat-messages-area { flex: 1; min-height: 0; overscroll-behavior: contain; }
  #chatRoot .chat-input-area { flex-shrink: 0; padding-bottom: calc(12px + env(safe-area-inset-bottom)); padding-left: max(16px, env(safe-area-inset-left)); padding-right: max(16px, env(safe-area-inset-right)); }
  #cards-container .st-card-photo { display: block; aspect-ratio: 4 / 3; height: auto; max-height: 45vh; overflow: hidden; }
  #cards-container .st-card-photo img { width: 100%; height: 100%; object-fit: cover; }
  #cards-container .st-card-photo--initials { display: block; aspect-ratio: auto; height: 160px; max-height: 160px; }
  .pwa-request-segments { display: flex; position: relative; z-index: 2; margin: 70px 16px 0; padding: 4px; background: #e8edf7; border-radius: 12px; }
  .pwa-request-segments a { flex: 1; text-align: center; padding: 10px 4px; color: #49566a; border-radius: 8px; }
  .pwa-request-segments a[aria-current] { background: #044bd9; color: #fff; }
  body:has(#chatRoot) #sidebar { display: none; }
  body:has(#chatRoot) #main { margin-left: 0; }
  .pwa-menu-toggle { display: inline-flex; }
  body.pwa-menu-open { overflow: hidden; }
  body.pwa-menu-open .pwa-menu-backdrop { display: block; position: fixed; inset: 0; background: #0006; border: 0; z-index: 1044; }
  body.pwa-menu-open .pwa-menu-close { display: block; position: fixed; left: 252px; top: calc(74px + env(safe-area-inset-top)); z-index: 1046; }
  .is-app body:has(.pwa-tabs) #main { padding-bottom: calc(90px + env(safe-area-inset-bottom)); }
  .is-app body:has(.pwa-tabs) #header .toggle-sidebar-btn { display: none; }
  .is-app body:has(.pwa-tabs) #sidebar { display: none; }
  body.pwa-menu-open #sidebar { display: block; z-index: 1045; left: 0; bottom: calc(70px + env(safe-area-inset-bottom)); }
  .is-app .pwa-tabs { position: fixed; inset: auto 0 0; background: #fff; border-top: 1px solid #dce3ef; display: flex; justify-content: space-around; padding: 8px 4px calc(8px + env(safe-area-inset-bottom)); z-index: 1040; }
  .pwa-tabs a { position: relative; display: flex; flex: 1; flex-direction: column; align-items: center; gap: 2px; color: #49566a; font-size: 12px; }
  .pwa-tabs i { font-size: 22px; }
  .pwa-tabs a[aria-current] { color: #044bd9; font-weight: 700; }
  .pwa-tabs .badge { position: absolute; top: -2px; left: 55%; }
  .is-app body:has(.pwa-tabs) .tools-fab { bottom: calc(88px + env(safe-area-inset-bottom)); }
  .is-app body:has(.pwa-tabs) .filter-fab { bottom: calc(144px + env(safe-area-inset-bottom)); }
  .is-app body:has(.pwa-tabs) .back-to-top { bottom: calc(200px + env(safe-area-inset-bottom)) !important; }
  .is-app body:has(.pwa-tabs) .st-profile-list-column { padding-bottom: calc(280px + env(safe-area-inset-bottom)); }
  .is-app body:has(.pwa-tabs) .st-toast-container, .is-app body:has(.pwa-tabs) .pwa-banner { bottom: calc(268px + env(safe-area-inset-bottom)); }
  .is-app body:has(.pwa-tabs) #stickyCta { bottom: calc(70px + env(safe-area-inset-bottom)); }
  .is-app body:has(.pwa-tabs) .chat-card { height: calc(100dvh - 240px); min-height: 280px; }
}
.is-app .pwa-uninstalled-only { display: none !important; }
html.is-app, .is-app body { overscroll-behavior: none; }
.is-app button, .is-app .btn, .is-app nav a { user-select: none; -webkit-user-select: none; -webkit-tap-highlight-color: transparent; }
@media (max-width: 767.98px) {
  .is-app .pagetitle, .is-app #main h1, .is-app #main .breadcrumb { display: none; }
  .is-app #cards-container .card { position: relative; overflow: hidden; }
  .is-app #cards-container .st-card-photo { display: block; aspect-ratio: 4 / 3; height: auto; max-height: 45vh; overflow: hidden; }
  .is-app #cards-container .st-card-photo--initials { aspect-ratio: auto; height: 160px; max-height: 160px; }
  .is-app #cards-container .st-card-photo img { width: 100%; height: 100%; object-fit: cover; border-radius: 0 !important; }
  .is-app #cards-container .bookmark-btn { position: absolute; top: 12px; right: 12px; z-index: 1; background: #fff; border-radius: 50%; padding: 8px !important; }
  .is-app #cards-container .card-body { padding: 12px 16px; }
  .is-app #st-recent-viewed[data-count="1"], .is-app #st-recent-viewed[data-count="2"] { display: none !important; }
  .is-app #st-recent-viewed .st-recent-viewed-header { display: none; }
  .is-app #st-recent-viewed .st-recent-viewed-list { display: flex; flex-wrap: nowrap; overflow-x: auto; }
  .is-app #st-recent-viewed .st-recent-viewed-item { flex: 0 0 52px; font-size: 11px; }
  .is-app #st-recent-viewed img, .is-app #st-recent-viewed .st-recent-viewed-initials { width: 40px !important; height: 40px !important; font-size: 18px !important; }
  .is-app .pwa-request-segments { position: fixed; top: calc(60px + env(safe-area-inset-top)); left: 12px; right: 12px; margin: 0; z-index: 1030; }
  .is-app body:has(.pwa-request-segments) #main { padding-top: 68px; }
  .is-app body:has(.pwa-app-header) #header { display: none !important; }
  .is-app .pwa-app-header { display: flex; position: fixed; top: 0; left: 0; right: 0; align-items: center; gap: 16px; min-height: 52px; padding: calc(10px + env(safe-area-inset-top)) max(16px, env(safe-area-inset-right)) 10px max(16px, env(safe-area-inset-left)); background: #fff; border-bottom: 1px solid #dce3ef; z-index: 1035; }
  .is-app .pwa-app-header span { font-weight: 700; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
  .is-app body:not(:has(#chatRoot)) #main { margin-top: calc(60px + env(safe-area-inset-top)); }
  .is-app #sidebar { top: calc(60px + env(safe-area-inset-top)); }
  .is-app #chatRoot .st-support-banner { display: none; }
}
