@import url('https://fonts.googleapis.com/css2?family=Inter:opsz,wght@14..32,400;14..32,500;14..32,600;14..32,700&display=swap');

:root {
  --sok-font: 'Inter', -apple-system, system-ui, sans-serif;
  --sok-bg: #ffffff;
  --sok-card-bg: #ffffff;
  --sok-text: #09090b;
  --sok-text-muted: #71717a;
  --sok-accent: #4f6fff;
  --sok-accent-hover: #3b5de7;
  --sok-accent-grad: linear-gradient(135deg, #4f6fff, #6c5ce7);
  --sok-border: #e4e4e7;
  --sok-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
  --sok-radius: 20px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --sok-bg: #12141a;
    --sok-card-bg: #181a22;
    --sok-text: #f3f4f6;
    --sok-text-muted: #9ca3af;
    --sok-accent: #5b7fff;
    --sok-accent-hover: #4f6fff;
    --sok-accent-grad: linear-gradient(135deg, #5b7fff, #7c6df0);
    --sok-border: rgba(255, 255, 255, 0.08);
    --sok-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
  }
}

.suioutkit-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  z-index: 99999;
  opacity: 0;
  transition: opacity 0.25s ease;
  font-family: var(--sok-font);
}

.suioutkit-overlay.active {
  opacity: 1;
}

.suioutkit-card {
  background: var(--sok-card-bg);
  border: 1px solid var(--sok-border);
  box-shadow: var(--sok-shadow);
  border-radius: var(--sok-radius);
  width: 400px;
  min-height: 440px;
  padding: 24px;
  position: relative;
  transform: translateY(12px) scale(0.98);
  transition: transform 0.25s ease;
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
}

.suioutkit-overlay.active .suioutkit-card {
  transform: translateY(0) scale(1);
}

.suioutkit-close {
  position: absolute;
  top: 16px;
  right: 16px;
  background: transparent;
  border: none;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--sok-text-muted);
  font-size: 16px;
  transition: background 0.2s ease, color 0.2s ease;
}

.suioutkit-close:hover {
  background: rgba(120, 120, 120, 0.1);
  color: var(--sok-text);
}

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

.suioutkit-title {
  font-size: 18px;
  font-weight: 700;
  color: var(--sok-text);
  margin: 0 0 4px;
  letter-spacing: -0.02em;
}

.suioutkit-subtitle {
  font-size: 13px;
  color: var(--sok-text-muted);
  margin: 0;
}

#sok-content-panel {
  flex: 1;
  display: flex;
  flex-direction: column;
}

.suioutkit-body {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.suioutkit-content {
  width: 100%;
}

.suioutkit-summary {
  display: none;
}

.suioutkit-option {
  background: transparent;
  border: 1px solid var(--sok-border);
  border-radius: 12px;
  padding: 10px 14px;
  display: block;
  width: 100%;
  cursor: pointer;
  transition: all 0.15s ease;
  text-align: left;
}

.suioutkit-option:hover {
  background: rgba(120, 120, 120, 0.05);
  border-color: var(--sok-accent);
}

.suioutkit-option-content {
  display: flex;
  align-items: center;
  gap: 14px;
}

.suioutkit-option-img {
  width: 34px;
  height: 34px;
  border-radius: 8px;
  object-fit: contain;
  background: white;
  padding: 2px;
}

.suioutkit-option-name {
  font-size: 15px;
  font-weight: 600;
  color: var(--sok-text);
}

.suioutkit-panel {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  width: 100%;
}

.suioutkit-back {
  align-self: flex-start;
  background: none;
  border: none;
  color: var(--sok-accent);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  padding: 0 0 12px;
  display: flex;
  align-items: center;
  gap: 4px;
}

.suioutkit-back:hover {
  opacity: 0.8;
}

.suioutkit-amount-box {
  margin-bottom: 16px;
}

.sok-fiat-amt {
  font-size: 28px;
  font-weight: 800;
  color: var(--sok-text);
  letter-spacing: -0.03em;
}

.sok-va-card {
  background: rgba(120, 120, 120, 0.04);
  border: 1px solid var(--sok-border);
  border-radius: 14px;
  width: 100%;
  padding: 16px;
  box-sizing: border-box;
  text-align: left;
  margin-bottom: 12px;
}

.sok-va-row {
  margin-bottom: 10px;
}

.sok-va-row:last-child {
  margin-bottom: 0;
}

.sok-va-lbl {
  font-size: 11px;
  font-weight: 500;
  text-transform: uppercase;
  color: var(--sok-text-muted);
  letter-spacing: 0.05em;
}

.sok-va-val {
  font-size: 16px;
  font-weight: 700;
  color: var(--sok-text);
  margin-top: 3px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.sok-copy-btn {
  background: var(--sok-accent);
  color: white;
  border: none;
  border-radius: 6px;
  padding: 4px 10px;
  font-size: 11px;
  font-weight: 600;
  cursor: pointer;
  transition: opacity 0.2s;
}

.sok-copy-btn:hover {
  opacity: 0.9;
}

.sok-copied-alert {
  position: absolute;
  top: 8px;
  right: 8px;
  background: #10b981;
  color: white;
  font-size: 11px;
  font-weight: 600;
  padding: 4px 8px;
  border-radius: 6px;
  opacity: 0;
  transform: translateY(-4px);
  transition: all 0.2s ease;
}

.sok-copied-alert.show {
  opacity: 1;
  transform: translateY(0);
}

.sok-spinner {
  width: 28px;
  height: 28px;
  border: 3px solid rgba(120, 120, 120, 0.1);
  border-radius: 50%;
  border-top-color: var(--sok-accent);
  animation: sok-spin 0.8s linear infinite;
  margin: 8px auto 10px;
}

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

.sok-status-text {
  font-size: 13px;
  font-weight: 500;
  color: var(--sok-text-muted);
  margin: 0;
}

.payment-status-ui {
  width: 100%;
}

.payment-status-copy {
  margin-top: 8px;
  font-size: 13px;
  font-weight: 600;
  color: var(--sok-text);
  text-align: center;
}

.sok-success-icon {
  margin-bottom: 10px;
}

.sok-success-title {
  font-size: 20px;
  font-weight: 700;
  color: var(--sok-text);
  margin-bottom: 4px;
}

.sok-success-desc {
  font-size: 13px;
  color: var(--sok-text-muted);
  margin-bottom: 16px;
}

.sok-success-details {
  background: rgba(79, 111, 255, 0.04);
  border: 1px solid rgba(79, 111, 255, 0.15);
  border-radius: 14px;
  padding: 14px;
  width: 100%;
  box-sizing: border-box;
  text-align: left;
  font-size: 12px;
}

.sok-receipt-row {
  display: flex;
  justify-content: space-between;
  margin-bottom: 8px;
}

.sok-receipt-row:last-child {
  margin-bottom: 0;
}

.sok-receipt-lbl {
  color: var(--sok-text-muted);
  font-weight: 500;
}

.sok-receipt-val {
  font-weight: 600;
  color: var(--sok-text);
  max-width: 180px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.sok-receipt-val a {
  color: var(--sok-accent);
  text-decoration: none;
}

.sok-receipt-val a:hover {
  text-decoration: underline;
}

.sok-btn {
  background: var(--sok-accent-grad);
  color: white;
  border: none;
  border-radius: 12px;
  padding: 12px 16px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  width: 100%;
  box-shadow: 0 4px 14px rgba(79, 111, 255, 0.25);
  transition: opacity 0.2s;
}

.sok-btn:hover {
  opacity: 0.92;
}

.sok-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  box-shadow: none;
}

.sok-btn-green {
  background: linear-gradient(135deg, #10b981 0%, #047857 100%);
  box-shadow: 0 4px 14px rgba(16, 185, 129, 0.25);
}

.sok-btn-blue {
  background: linear-gradient(135deg, #3b82f6 0%, #1d4ed8 100%);
  box-shadow: 0 4px 14px rgba(59, 130, 246, 0.25);
}

.sok-btn-indigo {
  background: linear-gradient(135deg, #6366f1 0%, #4338ca 100%);
  box-shadow: 0 4px 14px rgba(99, 102, 241, 0.25);
}

.sok-qr-card {
  background: var(--sok-bg);
  border: 1px solid var(--sok-border);
  border-radius: 14px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 12px;
  box-sizing: border-box;
  width: 100%;
}

.sok-qr-frame {
  background: #ffffff;
  padding: 12px;
  border-radius: 14px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06);
  position: relative;
  overflow: hidden;
  margin-bottom: 10px;
  width: 260px;
  height: 260px;
  box-sizing: border-box;
}

.sok-qr-img {
  width: 236px;
  height: 236px;
  display: block;
}

.sok-qr-logo-badge {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 32px;
  height: 32px;
  background: var(--sok-accent-grad);
  border-radius: 8px;
  border: 3px solid #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(79, 111, 255, 0.3);
}

.sok-qr-scan-pulse {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--sok-accent), transparent);
  animation: sok-qr-scan 2.5s ease-in-out infinite;
}

@keyframes sok-qr-scan {
  0% { top: 0; }
  50% { top: 100%; }
  100% { top: 0; }
}

.sok-coin-selector {
  display: flex;
  gap: 8px;
  justify-content: center;
  margin-bottom: 14px;
  flex-wrap: wrap;
}

.sok-coin-chip {
  background: var(--sok-card-bg);
  border: 2px solid var(--sok-border);
  border-radius: 20px;
  padding: 6px 18px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  color: var(--sok-text);
}

.sok-coin-chip:hover {
  border-color: var(--sok-accent);
  color: var(--sok-accent);
}

.sok-coin-chip.active {
  border-color: var(--sok-accent);
  background: var(--sok-accent);
  color: #ffffff;
}

.sok-coin-badge {
  display: inline-block;
  background: var(--sok-accent);
  color: #ffffff;
  border-radius: 20px;
  padding: 4px 16px;
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 14px;
}

.suioutkit-wallet-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  width: 100%;
}

.sok-wallet-card {
  background: var(--sok-card-bg);
  border: 1px solid var(--sok-border);
  border-radius: 14px;
  padding: 14px;
  display: flex;
  align-items: center;
  gap: 14px;
  cursor: pointer;
  transition: all 0.2s ease;
  text-align: left;
  width: 100%;
  color: var(--sok-text);
}

.sok-wallet-card:hover {
  background: rgba(120, 120, 120, 0.06);
  border-color: var(--sok-accent);
}

.sok-wallet-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  object-fit: contain;
  flex-shrink: 0;
  background: rgba(120, 120, 120, 0.08);
  padding: 4px;
}

.sok-wallet-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
  flex: 1;
  min-width: 0;
}

.sok-wallet-name {
  font-size: 15px;
  font-weight: 700;
  color: var(--sok-text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.sok-wallet-desc {
  font-size: 12px;
  opacity: 0.74;
  color: var(--sok-text-muted);
}

.sok-wallet-connect {
  font-size: 12px;
  font-weight: 700;
  color: var(--sok-accent);
}

.stepper {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin: 14px 0 10px;
}

.step {
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
}

.circle {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--sok-bg);
  border: 2px solid var(--sok-border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  font-size: 12px;
  color: var(--sok-text);
}

.circle.filled {
  background: var(--sok-accent);
  color: white;
  border-color: var(--sok-accent);
}

.label {
  margin-top: 4px;
  font-size: 12px;
  color: var(--sok-text-muted);
  text-align: center;
  min-width: 50px;
}

.line {
  position: absolute;
  top: 14px;
  left: 100%;
  width: 34px;
  height: 2px;
  background: var(--sok-border);
}

.step:not(:last-child) .line {
  display: block;
}

.step:last-child .line {
  display: none;
}

.sok-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
  align-items: center;
}

.sok-input {
  background: var(--sok-bg);
  border: 1px solid var(--sok-border);
  border-radius: 12px;
  padding: 12px 14px;
  font-size: 15px;
  font-weight: 500;
  color: var(--sok-text);
  width: 100%;
  box-sizing: border-box;
  outline: none;
  transition: border-color 0.2s ease;
}

.sok-input:focus {
  border-color: var(--sok-accent);
}

.sok-input::placeholder {
  color: var(--sok-text-muted);
  opacity: 0.6;
}

.sok-icon-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
}

.sok-text-green {
  color: #10b981;
}

.sok-text-red {
  color: #ef4444;
}

.sok-text-amber {
  color: #f59e0b;
}

.sok-text-sm {
  font-size: 12px;
}

.sok-op-75 {
  opacity: 0.75;
}

.sok-mt-16 {
  margin-top: 16px;
}

.sok-mt-12 {
  margin-top: 12px;
}

.sok-mb-12 {
  margin-bottom: 12px;
}

.sok-mb-20 {
  margin-bottom: 20px;
}

@media (max-width: 480px) {
  .suioutkit-overlay {
    padding: 8px;
    align-items: flex-start;
    padding-top: 32px;
  }

  .suioutkit-card {
    width: calc(100vw - 16px);
    min-height: auto;
    padding: 20px 16px;
    border-radius: 16px;
  }

  .suioutkit-title {
    font-size: 16px;
  }

  .sok-fiat-amt {
    font-size: 24px;
  }

  .sok-qr-frame {
    width: 220px;
    height: 220px;
  }

  .sok-qr-img {
    width: 196px;
    height: 196px;
  }

  .sok-success-details {
    padding: 12px;
  }
}
