:root {
  --ux-focus: #38bdf8;
  --ux-success: #16a34a;
  --ux-error: #dc2626;
  --ux-warning: #d97706;
  --ux-surface: rgba(17, 24, 39, 0.92);
}

*:focus-visible {
  outline: 3px solid var(--ux-focus) !important;
  outline-offset: 2px;
}

button,
a,
input,
select,
textarea {
  transition: filter 0.2s ease, transform 0.15s ease;
}

button:hover,
a:hover {
  filter: brightness(1.05);
}

button:active {
  transform: scale(0.98);
}

.ux-loading {
  cursor: wait !important;
  opacity: 0.75 !important;
  pointer-events: none !important;
}

.ux-connection-banner {
  position: fixed;
  top: 12px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--ux-surface);
  color: #fff;
  padding: 10px 14px;
  border-radius: 999px;
  z-index: 20000;
  font-size: 13px;
  font-weight: 700;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.35);
}

.ux-connection-banner.error {
  background: rgba(127, 29, 29, 0.95);
}

.ux-toast-container {
  position: fixed;
  right: 14px;
  bottom: 14px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  z-index: 20000;
  max-width: 360px;
}

.ux-toast {
  background: var(--ux-surface);
  color: #fff;
  border-left: 4px solid #38bdf8;
  border-radius: 10px;
  padding: 10px 12px;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.35);
  font-size: 13px;
  line-height: 1.35;
}

.ux-toast.success {
  border-left-color: var(--ux-success);
}

.ux-toast.error {
  border-left-color: var(--ux-error);
}

.ux-toast.warning {
  border-left-color: var(--ux-warning);
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }
}
