/* Auth and Wallet UI Styles */

.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.85);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10000;
}

.modal-content {
  background: linear-gradient(145deg, #1a1a2e, #16213e);
  border-radius: 16px;
  padding: 32px;
  max-width: 420px;
  width: 90%;
  position: relative;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.modal-close {
  position: absolute;
  top: 12px;
  right: 16px;
  background: none;
  border: none;
  color: #888;
  font-size: 28px;
  cursor: pointer;
}

.modal-close:hover { color: #fff; }

.auth-modal h2 {
  margin: 0 0 8px;
  color: #fff;
  font-size: 24px;
  text-align: center;
}

.auth-modal > p {
  color: #888;
  text-align: center;
  margin: 0 0 24px;
  font-size: 14px;
}

.auth-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  width: 100%;
  padding: 14px 20px;
  border: none;
  border-radius: 8px;
  font-size: 16px;
  font-weight: 500;
  cursor: pointer;
}

.google-btn { background: #fff; color: #333; }
.google-btn:hover { background: #f0f0f0; }

.email-btn {
  background: linear-gradient(135deg, #667eea, #764ba2);
  color: #fff;
}

.auth-divider {
  display: flex;
  align-items: center;
  margin: 20px 0;
  color: #666;
}

.auth-divider::before,
.auth-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: #333;
}

.auth-divider span {
  padding: 0 16px;
  font-size: 12px;
  text-transform: uppercase;
}

.email-form, .withdraw-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.email-form input, .withdraw-form input {
  padding: 14px 16px;
  border: 1px solid #333;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.05);
  color: #fff;
  font-size: 16px;
}

.email-form input:focus, .withdraw-form input:focus {
  outline: none;
  border-color: #667eea;
}

.auth-note {
  margin: 20px 0 0;
  font-size: 12px;
  color: #666;
  text-align: center;
}

.settings-panel {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: linear-gradient(145deg, #1a1a2e, #16213e);
  border-radius: 16px;
  width: 90%;
  max-width: 450px;
  max-height: 85vh;
  overflow-y: auto;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.1);
  z-index: 10000;
}

.settings-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 24px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  background: #1a1a2e;
}

.settings-header h2 { margin: 0; color: #fff; font-size: 20px; }

.settings-close {
  background: none;
  border: none;
  color: #888;
  font-size: 28px;
  cursor: pointer;
}

.settings-section {
  padding: 20px 24px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.settings-section h3 {
  margin: 0 0 16px;
  color: #888;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.settings-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
}

.settings-row label { color: #aaa; font-size: 14px; }
.settings-row span { color: #fff; font-size: 14px; }

.settings-hint { color: #666; font-size: 12px; margin: 8px 0 0; }

.username-edit { display: flex; gap: 8px; }

.username-edit input {
  padding: 8px 12px;
  border: 1px solid #333;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.05);
  color: #fff;
  font-size: 14px;
  width: 140px;
}

.username-edit button {
  padding: 8px 16px;
  background: #4ade80;
  border: none;
  border-radius: 6px;
  color: #000;
  font-weight: 600;
  cursor: pointer;
}

.wallet-balance-display {
  background: rgba(0, 0, 0, 0.3);
  border-radius: 12px;
  padding: 20px;
  text-align: center;
  margin-bottom: 20px;
}

.balance-amount {
  display: block;
  font-size: 36px;
  font-weight: bold;
  color: #4ade80;
}

.balance-sol {
  display: block;
  font-size: 14px;
  color: #888;
  margin-top: 4px;
}

.address-copy {
  display: flex;
  gap: 8px;
  align-items: center;
}

.address-copy code {
  flex: 1;
  padding: 10px;
  background: rgba(0, 0, 0, 0.3);
  border-radius: 6px;
  font-size: 11px;
  color: #aaa;
  overflow: hidden;
  text-overflow: ellipsis;
}

.address-copy button {
  padding: 10px 16px;
  background: rgba(255, 255, 255, 0.1);
  border: none;
  border-radius: 6px;
  color: #fff;
  cursor: pointer;
}

.wallet-actions { display: flex; gap: 12px; margin-top: 16px; }

.btn-primary {
  flex: 1;
  padding: 12px;
  background: linear-gradient(135deg, #667eea, #764ba2);
  border: none;
  border-radius: 8px;
  color: #fff;
  font-weight: 600;
  cursor: pointer;
}

.btn-primary:disabled { opacity: 0.5; cursor: not-allowed; }

.btn-secondary {
  flex: 1;
  padding: 12px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 8px;
  color: #fff;
  font-weight: 600;
  cursor: pointer;
}

.btn-danger {
  width: 100%;
  padding: 12px;
  background: rgba(239, 68, 68, 0.2);
  border: 1px solid rgba(239, 68, 68, 0.4);
  border-radius: 8px;
  color: #ef4444;
  font-weight: 600;
  cursor: pointer;
}

.withdraw-form label { color: #888; font-size: 12px; }
.withdraw-form .available { color: #666; font-size: 12px; margin: 0; }

#authButton {
  background: linear-gradient(135deg, #667eea, #764ba2);
  border: none;
  border-radius: 8px;
  padding: 10px 20px;
  color: #fff;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
}

#walletInfo { display: none; text-align: right; font-size: 14px; }
.wallet-balance { color: #4ade80; font-weight: bold; }
.sol-price { color: #666; font-size: 11px; }

.sol-ticker {
  position: fixed;
  top: 10px;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(0, 0, 0, 0.6);
  padding: 6px 16px;
  border-radius: 20px;
  font-size: 12px;
  color: #888;
  z-index: 100;
}

.sol-ticker .price { color: #4ade80; font-weight: bold; }
