/* ============ 美化对话框（替代原生 alert/confirm/prompt） ============ */
.nice-dialog-mask {
  position: fixed; inset: 0; z-index: 9999;
  background: rgba(0, 0, 0, 0.55);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
  animation: nd-fade-in 0.18s ease;
}
.nice-dialog-mask.show { display: flex; }
@keyframes nd-fade-in { from { opacity: 0; } to { opacity: 1; } }

.nice-dialog {
  background: linear-gradient(160deg, #1a1125 0%, #150d1f 100%);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 16px;
  width: 100%;
  max-width: 420px;
  padding: 28px 26px 24px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5), 0 0 0 1px rgba(168, 85, 247, 0.15);
  position: relative;
  animation: nd-pop 0.22s cubic-bezier(0.16, 1, 0.3, 1);
}
@keyframes nd-pop {
  from { transform: translateY(12px) scale(0.96); opacity: 0; }
  to { transform: translateY(0) scale(1); opacity: 1; }
}

.nice-dialog-icon {
  width: 48px; height: 48px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  margin: 0 auto 14px;
  flex-shrink: 0;
}
.nice-dialog-icon.info    { background: rgba(99, 102, 241, 0.15); color: #818cf8; }
.nice-dialog-icon.success { background: rgba(34, 197, 94, 0.15);  color: #4ade80; }
.nice-dialog-icon.warning { background: rgba(251, 191, 36, 0.15); color: #fbbf24; }
.nice-dialog-icon.danger  { background: rgba(244, 63, 94, 0.15);  color: #fb7185; }

.nice-dialog-title {
  font-size: 18px;
  font-weight: 700;
  color: #fff;
  text-align: center;
  margin: 0 0 10px;
}

.nice-dialog-msg {
  font-size: 14px;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.78);
  text-align: center;
  margin: 0 0 20px;
  word-break: break-word;
}

.nice-dialog-input {
  width: 100%;
  padding: 11px 14px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 10px;
  color: #fff;
  font-size: 14px;
  box-sizing: border-box;
  margin-bottom: 20px;
  outline: none;
  transition: border-color 0.2s;
}
.nice-dialog-input:focus {
  border-color: #a855f7;
  box-shadow: 0 0 0 3px rgba(168, 85, 247, 0.18);
}

.nice-dialog-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
}

.nice-dialog-btn {
  flex: 1;
  padding: 11px 20px;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  border: none;
  transition: all 0.18s;
  max-width: 160px;
}
.nice-dialog-btn-primary {
  background: linear-gradient(90deg, #ff6b9d, #a855f7);
  color: #fff;
  box-shadow: 0 4px 14px rgba(168, 85, 247, 0.35);
}
.nice-dialog-btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(168, 85, 247, 0.45);
}
.nice-dialog-btn-ghost {
  background: rgba(255, 255, 255, 0.07);
  color: rgba(255, 255, 255, 0.8);
  border: 1px solid rgba(255, 255, 255, 0.12);
}
.nice-dialog-btn-ghost:hover {
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
}
.nice-dialog-btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
}
