/* OrderWeb WooCommerce & paybride-CM Integration Styles */
.orderweb-progress-backdrop {
  position: fixed;
  inset: 0;
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  background: rgba(15, 23, 42, 0.72);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}

.orderweb-progress-backdrop[hidden] {
  display: none !important;
}

.orderweb-progress-card {
  width: min(440px, calc(100vw - 32px));
  background: #0f172a;
  color: #f8fafc;
  border: 1px solid rgba(148, 163, 184, 0.24);
  border-radius: 14px;
  padding: 24px 22px;
  box-shadow: 0 24px 48px rgba(0, 0, 0, 0.45);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  text-align: left;
}

.orderweb-progress-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}

.orderweb-progress-spinner {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 3px solid rgba(56, 189, 248, 0.25);
  border-top-color: #38bdf8;
  animation: orderweb-spin 0.85s linear infinite;
  flex-shrink: 0;
}

.orderweb-progress-card.is-error .orderweb-progress-spinner {
  border-color: rgba(248, 113, 113, 0.35);
  border-top-color: #f87171;
  animation: none;
}

.orderweb-progress-card.is-done .orderweb-progress-spinner {
  border-color: #34d399;
  background: rgba(52, 211, 153, 0.18);
  animation: none;
}

@media (prefers-reduced-motion: reduce) {
  .orderweb-progress-spinner {
    animation: none;
    border-top-color: #38bdf8;
    border-right-color: #38bdf8;
  }
}

@keyframes orderweb-spin {
  to {
    transform: rotate(360deg);
  }
}

.orderweb-progress-title {
  font-size: 17px;
  font-weight: 700;
  color: #f8fafc;
  margin: 0;
}

.orderweb-progress-stage {
  font-size: 13.5px;
  line-height: 1.5;
  color: #cbd5e1;
  margin: 0 0 14px;
  min-height: 20px;
  word-break: break-word;
}

.orderweb-progress-track {
  width: 100%;
  height: 8px;
  background: rgba(148, 163, 184, 0.2);
  border-radius: 999px;
  overflow: hidden;
  margin-bottom: 10px;
}

.orderweb-progress-bar {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, #0ea5e9, #22c55e);
  border-radius: 999px;
  transition: width 0.2s ease;
}

.orderweb-progress-card.is-error .orderweb-progress-bar {
  background: #ef4444;
}

.orderweb-progress-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12px;
  color: #94a3b8;
}

.orderweb-progress-error {
  margin-top: 12px;
  padding: 10px 12px;
  border-radius: 8px;
  background: rgba(239, 68, 68, 0.14);
  border: 1px solid rgba(248, 113, 113, 0.35);
  color: #fecaca;
  font-size: 13px;
  line-height: 1.45;
  word-break: break-word;
}

.orderweb-progress-actions {
  margin-top: 14px;
  display: flex;
  justify-content: flex-end;
  gap: 8px;
}

.orderweb-progress-btn {
  padding: 7px 14px;
  border-radius: 7px;
  border: 1px solid rgba(148, 163, 184, 0.35);
  background: #1e293b;
  color: #f8fafc;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
}

.orderweb-progress-btn:hover {
  background: #334155;
}

/* Same-page Payment Channel Switcher (PayBridge-Shopify Style with Brand Icons) */
.orderweb-channel-box {
  margin: 10px 10px 8px;
  text-align: left;
  font-family: Arial, Helvetica, sans-serif;
}

.orderweb-paybridge-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
  width: 100%;
  margin-bottom: 10px;
}

.orderweb-pb-wallets {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 10px;
}

.orderweb-pb-btn {
  appearance: none;
  box-sizing: border-box;
  width: 100%;
  height: 48px;
  min-height: 48px;
  border-radius: 5px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  cursor: pointer;
  transition: transform 0.12s ease, box-shadow 0.15s ease, border-color 0.15s ease;
  padding: 0 10px;
  position: relative;
}

.orderweb-pb-btn:hover {
  transform: translateY(-1px);
}

.orderweb-pb-btn--card {
  border: 2px solid #3b82d0;
  background: #ffffff;
  color: #337dcc;
  font: 700 14px/1 Arial, Helvetica, sans-serif;
  letter-spacing: 0.2px;
}

.orderweb-pb-card-icon {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

.orderweb-pb-btn--wallet {
  border: 2px solid #000000;
  background: #000000;
  color: #ffffff;
  font: 500 20px/1 Arial, Helvetica, sans-serif;
}

.orderweb-pb-btn--apple {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
  font-weight: 600;
}

.orderweb-pb-wallet-brand {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  white-space: nowrap;
}

.orderweb-pb-google-mark {
  width: 22px;
  height: 22px;
  flex-shrink: 0;
}

.orderweb-pb-apple-mark {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

.orderweb-pb-btn--paypal {
  border: 2px solid #ffc439;
  background: #ffc439;
  color: #111111;
  font: 400 18px/1 Arial, Helvetica, sans-serif;
  gap: 8px;
}

.orderweb-pb-paypal-logo {
  display: block;
  width: auto;
  height: 23px;
  max-width: 88px;
  flex-shrink: 0;
}

.orderweb-pb-btn.is-active {
  box-shadow: 0 0 0 3px rgba(59, 130, 208, 0.38), 0 4px 10px rgba(15, 23, 42, 0.14);
}

.orderweb-pb-btn--wallet.is-active {
  border-color: #38bdf8;
  box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.45), 0 4px 10px rgba(15, 23, 42, 0.2);
}

.orderweb-pb-btn--paypal.is-active {
  border-color: #0070e0;
  box-shadow: 0 0 0 3px rgba(0, 112, 224, 0.35), 0 4px 10px rgba(15, 23, 42, 0.15);
}

.orderweb-hosted-badge {
  font-size: 11.5px;
  line-height: 1.4;
  color: #475569;
  background: #f8fafc;
  border: 1px dashed #94a3b8;
  border-radius: 6px;
  padding: 6px 9px;
  margin: 4px 0 4px;
  text-align: left;
}

.orderweb-summary-card {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  color: #1e293b;
  line-height: 1.55;
  font-size: 14px;
}

.orderweb-summary-card dl {
  display: grid;
  grid-template-columns: 135px 1fr;
  gap: 6px 10px;
  margin: 12px 0;
  padding: 12px;
  background: #f8fafc;
  border-radius: 8px;
  border: 1px solid #e2e8f0;
}

.orderweb-summary-card dt {
  font-weight: 600;
  color: #475569;
}

.orderweb-summary-card dd {
  margin: 0;
  color: #0f172a;
  word-break: break-all;
}

.orderweb-status-pill {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  background: #dbeafe;
  color: #1d4ed8;
}

.orderweb-status-pill.is-paid {
  background: #dcfce7;
  color: #15803d;
}

.orderweb-status-pill.is-warn {
  background: #fef3c7;
  color: #b45309;
}
