/**
 * LumeaPag Engine Styles
 * Modal de Checkout Universal Multimoedas com Design de Alta Conversão
 */

:root {
  --lp-primary: #00b050;
  --lp-primary-hover: #009343;
  --lp-primary-glow: rgba(0, 176, 80, 0.25);
  --lp-bg: #0f172a;
  --lp-card: #1e293b;
  --lp-card-border: #334155;
  --lp-text: #f8fafc;
  --lp-text-muted: #94a3b8;
  --lp-accent: #38bdf8;
  --lp-warning: #f59e0b;
  --lp-danger: #ef4444;
}

#lp-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.85);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 999999;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 16px;
  opacity: 0;
  transition: opacity 0.25s ease;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  box-sizing: border-box;
}

#lp-modal-overlay.lp-active {
  display: flex;
  opacity: 1;
}

.lp-modal-container {
  background: #111827;
  border: 1px solid #374151;
  border-radius: 20px;
  width: 100%;
  max-width: 480px;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.7), 0 0 30px var(--lp-primary-glow);
  color: var(--lp-text);
  padding: 24px;
  position: relative;
  animation: lpModalPop 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  box-sizing: border-box;
}

@keyframes lpModalPop {
  0% { transform: scale(0.95); opacity: 0; }
  100% { transform: scale(1); opacity: 1; }
}

.lp-close-btn {
  position: absolute;
  top: 16px;
  right: 16px;
  background: rgba(255, 255, 255, 0.1);
  border: none;
  color: var(--lp-text-muted);
  width: 32px;
  height: 32px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  font-weight: 700;
  transition: all 0.2s;
}

.lp-close-btn:hover {
  background: rgba(255, 255, 255, 0.2);
  color: #fff;
}

.lp-header {
  text-align: center;
  margin-bottom: 20px;
}

.lp-badge-secure {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(0, 176, 80, 0.15);
  border: 1px solid rgba(0, 176, 80, 0.3);
  color: #4ade80;
  font-size: 12px;
  font-weight: 600;
  padding: 4px 12px;
  border-radius: 100px;
  margin-bottom: 12px;
}

.lp-title {
  font-size: 20px;
  font-weight: 800;
  margin: 0 0 6px 0;
  color: #fff;
}

.lp-subtitle {
  font-size: 14px;
  color: var(--lp-text-muted);
  margin: 0;
}

.lp-amount-card {
  background: #1f2937;
  border: 1px solid #374151;
  border-radius: 12px;
  padding: 14px 18px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
}

.lp-amount-label {
  font-size: 13px;
  color: var(--lp-text-muted);
  font-weight: 500;
}

.lp-amount-val {
  font-size: 22px;
  font-weight: 900;
  color: #4ade80;
}

/* Timer */
.lp-timer-box {
  background: rgba(245, 158, 11, 0.1);
  border: 1px solid rgba(245, 158, 11, 0.3);
  color: #fbbf24;
  border-radius: 8px;
  padding: 10px;
  text-align: center;
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

/* QR Code Section */
.lp-qr-wrap {
  text-align: center;
  margin-bottom: 18px;
}

.lp-qr-frame {
  display: inline-block;
  background: #ffffff;
  padding: 12px;
  border-radius: 14px;
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.5);
  line-height: 0;
}

.lp-qr-canvas {
  width: 190px;
  height: 190px;
  display: block;
}

/* Copy Field */
.lp-copy-field {
  margin-bottom: 18px;
}

.lp-copy-input-wrap {
  position: relative;
  display: flex;
  margin-top: 6px;
}

.lp-copy-input {
  width: 100%;
  background: #1f2937;
  border: 1px solid #4b5563;
  color: #e5e7eb;
  padding: 12px 14px;
  border-radius: 8px;
  font-size: 12px;
  font-family: monospace;
  outline: none;
  box-sizing: border-box;
}

.lp-copy-input:focus {
  border-color: var(--lp-primary);
}

.lp-btn-action {
  width: 100%;
  background: var(--lp-primary);
  color: #ffffff;
  border: none;
  padding: 14px 20px;
  border-radius: 10px;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  box-shadow: 0 4px 14px var(--lp-primary-glow);
  transition: all 0.2s;
  box-sizing: border-box;
}

.lp-btn-action:hover {
  background: var(--lp-primary-hover);
  transform: translateY(-1px);
}

.lp-btn-action:active {
  transform: translateY(0);
}

/* Instruções Multimoedas (SPEI, MBWAY, COP, ARS, VES) */
.lp-inst-list {
  background: #1f2937;
  border: 1px solid #374151;
  border-radius: 12px;
  padding: 16px;
  margin-bottom: 18px;
}

.lp-inst-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 0;
  border-bottom: 1px solid #374151;
  font-size: 13px;
}

.lp-inst-item:last-child {
  border-bottom: none;
}

.lp-inst-k {
  color: var(--lp-text-muted);
  font-weight: 500;
}

.lp-inst-v {
  color: #fff;
  font-weight: 700;
  text-align: right;
  word-break: break-all;
  display: flex;
  align-items: center;
  gap: 6px;
}

.lp-mini-copy-btn {
  background: #374151;
  border: none;
  color: #38bdf8;
  padding: 2px 6px;
  border-radius: 4px;
  cursor: pointer;
  font-size: 11px;
}

/* Pulse / Status Polling */
.lp-status-box {
  text-align: center;
  padding: 12px;
  font-size: 13px;
  color: var(--lp-text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

.lp-pulse-dot {
  width: 10px;
  height: 10px;
  background: var(--lp-primary);
  border-radius: 50%;
  animation: lpPulse 1.5s infinite;
}

@keyframes lpPulse {
  0% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(0, 176, 80, 0.7); }
  70% { transform: scale(1.1); box-shadow: 0 0 0 8px rgba(0, 176, 80, 0); }
  100% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(0, 176, 80, 0); }
}

/* Spinner */
.lp-spinner {
  width: 32px;
  height: 32px;
  border: 3px solid rgba(255, 255, 255, 0.1);
  border-radius: 50%;
  border-top-color: var(--lp-primary);
  animation: lpSpin 0.8s linear infinite;
  margin: 20px auto;
}

@keyframes lpSpin {
  to { transform: rotate(360deg); }
}

/* Sucesso */
.lp-success-wrap {
  text-align: center;
  padding: 30px 10px;
}

.lp-success-icon {
  width: 64px;
  height: 64px;
  background: #22c55e;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
  color: #fff;
  margin: 0 auto 16px auto;
  box-shadow: 0 0 20px rgba(34, 197, 94, 0.5);
  animation: lpSuccessPop 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

@keyframes lpSuccessPop {
  0% { transform: scale(0.4); opacity: 0; }
  100% { transform: scale(1); opacity: 1; }
}
