/* ============================================
   DXIP Wallet Connection Modal Styles
   ============================================ */

/* Modal Overlay */
.wallet-modal-overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(5, 8, 22, 0.95);
  backdrop-filter: blur(10px);
  z-index: 10000;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.wallet-modal-overlay.active {
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 1;
}

/* Modal Container */
.wallet-modal {
  background: linear-gradient(135deg, #0a0e27, #050816);
  border: 1px solid rgba(255, 107, 43, 0.2);
  border-radius: 20px;
  padding: 2.5rem;
  max-width: 480px;
  width: 90%;
  position: relative;
  transform: scale(0.9);
  transition: transform 0.3s ease;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.wallet-modal-overlay.active .wallet-modal {
  transform: scale(1);
}

/* Close Button */
.wallet-modal-close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  background: transparent;
  border: none;
  color: var(--text-secondary);
  cursor: pointer;
  padding: 0.5rem;
  transition: color 0.3s;
  display: flex;
  align-items: center;
  justify-content: center;
}

.wallet-modal-close:hover {
  color: var(--accent-orange);
}

/* Modal Header */
.wallet-modal-header {
  text-align: center;
  margin-bottom: 2rem;
}

.wallet-modal-icon {
  width: 60px;
  height: 60px;
  background: linear-gradient(135deg, var(--accent-orange), #e55a1b);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1rem;
}

.wallet-modal-header h2 {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 0.5rem;
}

.wallet-modal-header p {
  font-size: 0.95rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

/* Wallet Options */
.wallet-options {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.wallet-option {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1.25rem;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.3s;
}

.wallet-option:hover {
  background: rgba(255, 107, 43, 0.1);
  border-color: var(--accent-orange);
  transform: translateY(-2px);
}

.wallet-option-icon {
  width: 40px;
  height: 40px;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.wallet-option-icon img {
  width: 24px;
  height: 24px;
}

.wallet-option-info {
  flex: 1;
}

.wallet-option-info h3 {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 0.25rem;
}

.wallet-option-info p {
  font-size: 0.85rem;
  color: var(--text-secondary);
}

.wallet-option-arrow {
  color: var(--text-muted);
  transition: transform 0.3s;
}

.wallet-option:hover .wallet-option-arrow {
  transform: translateX(4px);
  color: var(--accent-orange);
}

/* Connected State */
.wallet-connected {
  text-align: center;
  padding: 2rem 0;
}

.wallet-connected-icon {
  width: 80px;
  height: 80px;
  background: linear-gradient(135deg, rgba(34, 197, 94, 0.2), rgba(22, 163, 74, 0.2));
  border: 2px solid rgba(34, 197, 94, 0.5);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1.5rem;
}

.wallet-connected h3 {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 0.5rem;
}

.wallet-address {
  font-family: 'Courier New', monospace;
  font-size: 0.9rem;
  color: var(--accent-orange);
  background: rgba(255, 107, 43, 0.1);
  padding: 0.75rem 1rem;
  border-radius: 8px;
  margin: 1rem 0;
  word-break: break-all;
}

.wallet-network {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.85rem;
  color: var(--text-secondary);
  background: rgba(255, 255, 255, 0.03);
  padding: 0.5rem 1rem;
  border-radius: 20px;
  margin-top: 1rem;
}

/* Loading State */
.wallet-loading {
  text-align: center;
  padding: 2rem 0;
}

.wallet-loading-spinner {
  width: 50px;
  height: 50px;
  border: 3px solid rgba(255, 107, 43, 0.2);
  border-top-color: var(--accent-orange);
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin: 0 auto 1.5rem;
}

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

.wallet-loading p {
  font-size: 0.95rem;
  color: var(--text-secondary);
}

/* Error State */
.wallet-error {
  background: rgba(239, 68, 68, 0.1);
  border: 1px solid rgba(239, 68, 68, 0.3);
  border-radius: 8px;
  padding: 1rem;
  margin-top: 1rem;
}

.wallet-error p {
  font-size: 0.9rem;
  color: #ef4444;
  margin: 0;
}

/* Info Box */
.wallet-info {
  background: rgba(59, 130, 246, 0.1);
  border: 1px solid rgba(59, 130, 246, 0.3);
  border-radius: 8px;
  padding: 1rem;
  margin-top: 1.5rem;
}

.wallet-info p {
  font-size: 0.85rem;
  color: var(--text-secondary);
  margin: 0;
  line-height: 1.5;
}

/* Buttons */
.wallet-modal-actions {
  display: flex;
  gap: 1rem;
  margin-top: 1.5rem;
}

.wallet-btn {
  flex: 1;
  padding: 0.875rem 1.5rem;
  border-radius: 8px;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s;
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

.wallet-btn-primary {
  background: linear-gradient(135deg, var(--accent-orange), #e55a1b);
  color: white;
}

.wallet-btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(255, 107, 43, 0.4);
}

.wallet-btn-secondary {
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-primary);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.wallet-btn-secondary:hover {
  background: rgba(255, 255, 255, 0.08);
}

/* Responsive */
@media (max-width: 768px) {
  .wallet-modal {
    padding: 2rem 1.5rem;
    max-width: 95%;
  }

  .wallet-modal-header h2 {
    font-size: 1.25rem;
  }

  .wallet-option {
    padding: 1rem;
  }

  .wallet-modal-actions {
    flex-direction: column;
  }
}
