@keyframes pricing-shimmer {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

html:not([data-pricing-state="ready"]) :is(
  #priceOld, #priceNew, #priceCur, #urgPriceOld, #urgPriceNew, #urgPriceCur,
  #val1, #val2, #val3, #val4, #val5, #val6, #val7, #val8, #val9, #val10,
  #stackOldPrice, #stackNewPrice,
  #summary-total, #summary-total-detail, #summary-total-desktop,
  #summary-original-price, #summary-original-price-desktop,
  #widget-price-compare, #widget-price-final, #widget-price-savings,
  #widget-price-summary-subtotal, #widget-price-summary-discount,
  #widget-price-summary-total, #widget-accept-price,
  [data-price-mirror], [data-compare-mirror], [data-savings-mirror]
) {
  color: transparent;
  background: linear-gradient(90deg, #e5e7eb 25%, #f3f4f6 50%, #e5e7eb 75%);
  background-size: 200% 100%;
  border-radius: 0.35rem;
  min-width: 4.75rem;
  min-height: 1em;
  display: inline-block;
  animation: pricing-shimmer 1.2s ease-in-out infinite;
  pointer-events: none;
  user-select: none;
}

html:not([data-pricing-state="ready"]) :is(#priceNew, #urgPriceNew, #summary-total, #summary-total-desktop) {
  min-width: 7rem;
}

html[data-pricing-state="loading"] [data-pricing-gated="true"],
html[data-pricing-state="error"] [data-pricing-gated="true"] {
  opacity: 0.62;
  cursor: wait;
}

html:not([data-pricing-state="ready"]) :is(a[data-cta], [data-checkout]) {
  pointer-events: none;
  opacity: 0.62;
}

html:not([data-pricing-state="ready"]) :is(#upsell-accept-btn, #upsell-decline-btn) {
  pointer-events: none;
  opacity: 0.62;
}

html:not([data-pricing-state="ready"]) #pay-unified-btn {
  pointer-events: none;
  opacity: 0.5;
}

#pricing-load-error {
  display: none;
  margin: 0.75rem auto;
  max-width: 36rem;
  padding: 0.75rem 1rem;
  border: 1px solid #fecaca;
  border-radius: 0.75rem;
  background: #fef2f2;
  color: #b91c1c;
  font-size: 0.875rem;
  font-weight: 600;
  text-align: center;
}

html[data-pricing-state="error"] #pricing-load-error {
  display: block;
}

@media (prefers-reduced-motion: reduce) {
  html:not([data-pricing-state="ready"]) :is(
    #priceNew, #urgPriceNew, #summary-total, #summary-total-desktop,
    #widget-price-final, #widget-price-summary-total
  ) {
    animation: none;
  }
}
