.rm-trigger-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: linear-gradient(135deg, #3b82f6, #7c3aed);
  border: none;
  border-radius: 10px;
  padding: 13px 44px;
  cursor: pointer;
  transition: all 0.2s ease;
  position: relative;
  overflow: hidden;
}
.rm-trigger-btn::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, #60a5fa, #a78bfa);
  opacity: 0;
  transition: opacity 0.2s ease;
  border-radius: 10px;
}
.rm-trigger-btn:hover::before {
  opacity: 1;
}
.rm-trigger-btn:active {
  transform: scale(0.97);
}
.rm-trigger-btn > * {
  position: relative;
  z-index: 1;
}
.rm-trigger-btn span {
  color: #fff;
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 0.5px;
}

.rm-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(4, 6, 18, 0.75);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  z-index: 9999;
  justify-content: center;
  align-items: center;
  padding: 20px;
  animation: rmFadeIn 0.2s ease;
}
.rm-overlay.active {
  display: flex;
}
@keyframes rmFadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}
@keyframes rmSlideUp {
  from {
    opacity: 0;
    transform: translateY(24px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.rm-modal {
  background: #1a1f2e;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  width: 100%;
  max-width: 520px;
  max-height: 90vh;
  overflow-y: auto;
  animation: rmSlideUp 0.25s ease;
}

.rm-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px 0;
}
.rm-modal-title-row {
  display: flex;
  align-items: center;
  gap: 10px;
}
.rm-modal-icon {
  width: 32px;
  height: 32px;
  background: linear-gradient(135deg, #3b82f6, #7c3aed);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.rm-modal-title {
  color: #f1f5f9;
  font-size: 18px;
  font-weight: 700;
}

.rm-close-btn {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  border: none;
  background: rgba(255, 255, 255, 0.06);
  color: #8892b8;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s;
  flex-shrink: 0;
}
.rm-close-btn:hover {
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
}

.rm-notice {
  margin: 16px 24px 0;
  background: rgba(234, 179, 8, 0.08);
  border: 1px solid rgba(234, 179, 8, 0.2);
  border-radius: 10px;
  padding: 12px 14px;
  display: flex;
  gap: 10px;
  align-items: flex-start;
}
.rm-notice svg {
  flex-shrink: 0;
  margin-top: 1px;
}
.rm-notice p {
  color: #c9a84c;
  font-size: 12px;
  line-height: 1.5;
}

.rm-modal-body {
  padding: 20px 24px 24px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.rm-field {
  display: flex;
  flex-direction: column;
  gap: 7px;
}
.rm-field-label {
  color: #c8cfe0;
  font-size: 13px;
  font-weight: 600;
}
.rm-field-label .rm-req {
  color: #f87171;
  margin-left: 2px;
}
.rm-field-label .rm-opt {
  color: #6b7aaa;
  font-weight: 400;
  font-size: 11px;
  margin-left: 6px;
}

.rm-field input,
.rm-field textarea {
  background: #0f1322;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 10px;
  padding: 12px 14px;
  color: #e2e8f0;
  font-size: 14px;
  outline: none;
  transition:
    border-color 0.2s,
    box-shadow 0.2s;
  width: 100%;
  font-family: inherit;
}
.rm-field input::placeholder,
.rm-field textarea::placeholder {
  color: #4a5578;
}
.rm-field input:focus,
.rm-field textarea:focus {
  border-color: #3b82f6;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.15);
}
.rm-field textarea {
  resize: vertical;
  min-height: 72px;
}
.rm-field-hint {
  color: #5a6590;
  font-size: 11px;
  line-height: 1.4;
}

.rm-divider {
  border: none;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  margin: 4px 0;
}

.rm-modal-actions {
  display: flex;
  gap: 12px;
  padding: 0 24px 24px;
}
.rm-btn-cancel,
.rm-btn-submit {
  flex: 1;
  padding: 13px 16px;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s;
  border: none;
}
.rm-btn-cancel {
  background: rgba(255, 255, 255, 0.06);
  color: #94a3b8;
  border: 1px solid rgba(255, 255, 255, 0.1);
}
.rm-btn-cancel:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #e2e8f0;
}
.rm-btn-submit {
  background: linear-gradient(135deg, #3b82f6, #7c3aed);
  color: #fff;
  position: relative;
  overflow: hidden;
}
.rm-btn-submit::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, #60a5fa, #a78bfa);
  opacity: 0;
  transition: opacity 0.2s;
}
.rm-btn-submit:hover::before {
  opacity: 1;
}
.rm-btn-submit span {
  position: relative;
  z-index: 1;
}
.rm-btn-submit:active {
  transform: scale(0.98);
}

.rm-success-content {
  display: none;
  flex-direction: column;
  align-items: center;
  padding: 48px 24px;
  gap: 16px;
  text-align: center;
}
.rm-success-content.show {
  display: flex;
}
.rm-success-icon {
  width: 56px;
  height: 56px;
  background: rgba(34, 197, 94, 0.1);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}
.rm-success-content h3 {
  color: #f1f5f9;
  font-size: 17px;
  font-weight: 700;
}
.rm-success-content p {
  color: #8892b8;
  font-size: 13px;
  line-height: 1.5;
}

.rm-error-shake {
  animation: rmShake 0.3s ease;
}
@keyframes rmShake {
  20%,
  60% {
    transform: translateX(-4px);
  }
  40%,
  80% {
    transform: translateX(4px);
  }
}
.rm-field-error input {
  border-color: #f87171 !important;
  box-shadow: 0 0 0 3px rgba(248, 113, 113, 0.15) !important;
}
.rm-error-msg {
  color: #f87171;
  font-size: 11px;
  display: none;
}
.rm-field-error .rm-error-msg {
  display: block;
}

.rm-btn-wrap {
  padding: 16px 0;
  text-align: center;
}
