/* Form message styles */
.form-success,
.form-error {
  padding: 12px 16px;
  margin-bottom: 20px;
  border-radius: 8px;
  font-size: 14px;
  display: flex;
  align-items: center;
  animation: slideDown 0.3s ease-out;
  transition: opacity 0.5s ease;
}

.form-success {
  background-color: rgba(52, 211, 153, 0.15);
  color: #065f46;
  border-left: 4px solid #10b981;
}

.form-error {
  background-color: rgba(248, 113, 113, 0.15);
  color: #b91c1c;
  border-left: 4px solid #ef4444;
}

.form-success i,
.form-error i {
  margin-right: 8px;
  font-size: 16px;
}

@keyframes slideDown {
  from {
    transform: translateY(-20px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

.fade-out {
  opacity: 0;
}

/* Enhanced form styles */
.form-group {
  margin-bottom: 20px;
  position: relative;
}

.form-group input,
.form-group textarea {
  transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
  border-color: #3ebab1;
  box-shadow: 0 0 0 3px rgba(62, 186, 177, 0.2);
}

.form-group.loading::after {
  content: "";
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  width: 20px;
  height: 20px;
  border: 2px solid rgba(62, 186, 177, 0.3);
  border-top-color: #3ebab1;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to {
    transform: translateY(-50%) rotate(360deg);
  }
}

/* Button loading state */
.btn.loading {
  position: relative;
  color: transparent;
}

.btn.loading::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  width: 20px;
  height: 20px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-top-color: white;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to {
    transform: translate(-50%, -50%) rotate(360deg);
  }
}
