#nativeHomeBtn {
  position: fixed;
  left: calc(0.75rem + env(safe-area-inset-left, 0px));
  bottom: calc(1.25rem + env(safe-area-inset-bottom, 0px));
  z-index: 99990;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.55rem 0.85rem 0.55rem 0.7rem;
  border: none;
  border-radius: 999px;
  background: linear-gradient(135deg, #e66239 0%, #f97316 100%);
  color: #fff;
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  box-shadow: 0 8px 24px rgba(230, 98, 57, 0.45);
  cursor: pointer;
  touch-action: manipulation;
}

#nativeHomeBtn:active {
  transform: scale(0.97);
}

#nativeHomeBtn svg {
  flex-shrink: 0;
}

@media (max-width: 992px) {
  body.native-app.has-offline-bar #nativeHomeBtn {
    bottom: calc(3.25rem + env(safe-area-inset-bottom, 0px));
  }
}

body.native-app {
  -webkit-tap-highlight-color: transparent;
  overscroll-behavior-y: none;
}

body.native-app .btn,
body.native-app .nav-link,
body.native-app .report-type-btn {
  touch-action: manipulation;
}

#nativeOfflineBar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 99998;
  display: none;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  padding: calc(0.45rem + env(safe-area-inset-top, 0px)) 0.75rem 0.45rem;
  background: linear-gradient(180deg, #b91c1c 0%, #991b1b 100%);
  color: #fff;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  box-shadow: 0 4px 16px rgba(185, 28, 28, 0.35);
}

#nativeOfflineBar.is-visible {
  display: flex;
}

#nativePageLoader {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  width: 0;
  z-index: 99997;
  background: linear-gradient(90deg, #e66239, #f97316, #fb923c);
  box-shadow: 0 0 12px rgba(230, 98, 57, 0.55);
  opacity: 0;
  transition: width 0.35s ease, opacity 0.2s ease;
  pointer-events: none;
}

#nativePageLoader.is-active {
  opacity: 1;
}

#nativePageLoader.is-done {
  width: 100% !important;
  opacity: 0;
}

body.native-app.has-offline-bar #topbar.topbar.navbar {
  top: calc(2rem + env(safe-area-inset-top, 0px));
}

body.native-app.has-offline-bar .content {
  padding-top: calc(var(--mobile-topbar-h, 3.5rem) + var(--app-safe-top, env(safe-area-inset-top, 0px)) + 2rem + 1rem) !important;
}

@media (max-width: 992px) {
  body.native-app.has-offline-bar .sidebar {
    top: calc(var(--mobile-topbar-h, 3.5rem) + var(--app-safe-top, env(safe-area-inset-top, 0px)) + 2rem) !important;
  }
}
