.modal {
  position: fixed;
  inset: 0;
  z-index: 1000;
  background-color: rgba(0, 0, 0, 0.65);
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 2rem;
}

.modal.hidden {
  display: none;
}

.modal-content {
  position: relative;
  background: white;
  max-width: 1400px;
  width: 100%;
  border-radius: 12px;
  position: relative;
  overflow-y: auto;
  max-height: 90vh;
}

.modal-header {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  position: sticky;
  top: 0;
  background: #fff; 
  z-index: 3;
  padding: 0.5rem;
}

.modal-close {
  background: none;
  font-size: 1.5rem;
  border: none;
  cursor: pointer;
  line-height: 1;
}

.modal-open {
  overflow: hidden;
  position: relative;
  height: 100vh;
  touch-action: none;
  overscroll-behavior: none;
}

.spinner {
  display: inline-block;
  width: 1rem;
  height: 1rem;
  border: 2px solid transparent;
  border-top: 2px solid #ffffff; /* spinner color */
  border-radius: 50%;
  animation: spin 0.6s linear infinite;
  vertical-align: middle;
}

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

.form-feedback {
  position: sticky;         
  top: 0;
  z-index: 4;
  display: flex;
  align-items: center;
  justify-content: center;

  min-height: 48px;
  padding: 0.75rem 1rem;
  border-radius: 8px;
  margin: 0.75rem auto 0.75rem;  
  width: calc(100% - 2rem);      
  max-width: 900px;

  opacity: 0;
  transform: translateY(-12px);
  transition: opacity 220ms ease, transform 220ms ease;
  box-shadow: 0 6px 18px rgba(0,0,0,0.08);
}

.form-feedback.show {
  opacity: 1;
  transform: translateY(0);
}

.form-feedback.success {
  background: #dff0d8;
  color: #2b542c;
  border: 1px solid #c8e5bc;
}

.form-feedback.error {
  background: #f2dede;
  color: #a94442;
  border: 1px solid #ebccd1;
}

.form-feedback .msg {
  flex: 1;
  text-align: center;
  font-weight: 600;
}

.form-feedback .close {
  margin-left: 0.75rem;
  border: 0;
  background: transparent;
  font-size: 1.1rem;
  line-height: 1;
  cursor: pointer;
}
