#polycule-pds-update-indicator {
  position: fixed;
  z-index: 2147483000;
  top: 50%;
  right: max(1rem, env(safe-area-inset-right));
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  box-sizing: border-box;
  max-width: min(21rem, calc(100vw - 2rem));
  padding: 0.65rem 0.8rem;
  border: 1px solid color-mix(in srgb, #54b7ff 60%, transparent);
  border-radius: 999px;
  color: var(--text, #f5f7ff);
  background: color-mix(in srgb, var(--bg, #111827) 92%, #0b4f83);
  box-shadow: 0 12px 30px rgb(0 0 0 / 0.28);
  font: 700 0.8rem/1.2 system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  letter-spacing: 0.01em;
  transform: translateY(-50%);
}

#polycule-pds-update-indicator[hidden] {
  display: none;
}

.polycule-pds-update-spinner {
  width: 1rem;
  height: 1rem;
  flex: 0 0 1rem;
  border: 2px solid rgb(203 235 255 / 0.35);
  border-top-color: #8dd7ff;
  border-radius: 50%;
  animation: polycule-pds-update-spin 0.75s linear infinite;
}

@keyframes polycule-pds-update-spin {
  to { transform: rotate(360deg); }
}

@media (max-width: 720px) {
  #polycule-pds-update-indicator {
    top: max(0.75rem, env(safe-area-inset-top));
    right: auto;
    left: 50%;
    max-width: calc(100vw - 1.5rem);
    transform: translateX(-50%);
  }
}

@media (prefers-reduced-motion: reduce) {
  .polycule-pds-update-spinner { animation: none; }
}
