.erm-modal {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.3s ease;
}
.erm-modal:not(.erm-hidden) {
  opacity: 1;
}
.erm-modal-overlay {
  position: absolute;
  inset: 0;
  background-color: rgba(0, 0, 0, 0.6);
}
.erm-modal-content {
  position: relative;
  width: 100%;
  max-width: 550px;
  margin: 20px;
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.25);
  padding: 24px;
  z-index: 2;
  overflow: auto;
}
.erm-modal-inner {
  max-height: calc(100vh - 120px);
  overflow-y: auto;
}
.erm-modal-close {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 36px;
  height: 36px;
  border: none;
  background: transparent;
  font-size: 22px;
  line-height: 1;
  color: #333;
  cursor: pointer;
}
.erm-hidden {
  visibility: hidden;
  opacity: 0;
  pointer-events: none;
  transition:
    opacity 0.23s ease,
    visibility 0.23s ease;
}
.erm-modal:not(.erm-hidden) {
  visibility: visible;
  opacity: 1;
  pointer-events: auto;
}
.erm-button {
  display: inline-block;
  border: 0;
  background: #0073aa;
  color: #fff;
  padding: 12px 24px;
  border-radius: 5px;
  cursor: pointer;
  transition:
    transform 0.2s ease,
    opacity 0.2s ease;
}
.erm-button:hover {
  transform: translateY(-1px);
}

@media (max-width: 1024px) {
  .erm-modal-content {
    width: 90%;
    max-width: 700px;
  }
}

@media (max-width: 768px) {
  .erm-modal-content {
    width: 95%;
    max-width: 92%;
    margin: 12px;
    padding: 18px;
  }
  .erm-button {
    padding: 10px 18px;
  }
}
