.btn i {
  margin-top: 5px;
}

/* Global Loader Overlay */
#global-loader {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  background: radial-gradient(
    ellipse at center,
    rgba(255, 255, 255, 0.95) 0%,
    rgba(245, 245, 245, 0.95) 100%
  );
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

/* Activate overlay when requested */
#global-loader.active,
html.show-loader #global-loader {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

/* Hide legacy loader markup if present */
#global-loader .inventory-loader {
  display: none !important;
}

/* Minimal, fast barcode-style loader */
.inv-loader-barcode {
  text-align: center;
}
.inv-loader-barcode .barcode {
  display: inline-flex;
  align-items: flex-end;
  gap: 6px;
  height: 32px;
}
.inv-loader-barcode .bar {
  width: 6px;
  background: #007bff;
  border-radius: 3px;
  transform-origin: bottom center;
  animation: invBar 1s ease-in-out infinite;
  box-shadow: 0 1px 0 rgba(0, 0, 0, 0.06);
}
.inv-loader-barcode .bar.b1 {
  height: 14px;
  animation-delay: 0s;
}
.inv-loader-barcode .bar.b2 {
  height: 18px;
  animation-delay: 0.1s;
}
.inv-loader-barcode .bar.b3 {
  height: 24px;
  animation-delay: 0.2s;
}
.inv-loader-barcode .bar.b4 {
  height: 18px;
  animation-delay: 0.3s;
}
.inv-loader-barcode .bar.b5 {
  height: 14px;
  animation-delay: 0.4s;
}

@keyframes invBar {
  0%,
  40%,
  100% {
    transform: scaleY(0.4);
    opacity: 0.5;
  }
  20% {
    transform: scaleY(1);
    opacity: 1;
  }
}

.inv-loader-barcode .loader-text {
  margin-top: 12px;
  font-weight: 600;
  color: #343a40;
  opacity: 0.85;
  letter-spacing: 0.2px;
}

@media (max-width: 768px) {
  .btn span {
    display: none;
    /* Hide button text for mobile view */
  }
  .btn i,
  .btn img {
    margin-right: 0;
    width: 20px;
    height: 20px;
  }
}
