.messages {
  position: relative;
  top: 20px;
  right: 20px;
  width: fit-content;
  z-index: 9999;
  margin-left: 10px;
  font-size: 14px;
}

.msg-box {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: white;
  padding: 10px 14px;
  border-top-left-radius: 12px;
  border-top-right-radius: 12px;
  margin-bottom: 12px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.15);
  border-bottom: 3px solid transparent;
  animation: fadeSlide 0.3s ease-out;
}


/* ✅ Success style */
.msg-box.success {
  border-color: #8BC34A;
  color: #388E3C;
}

/* ✅ Left checkmark icon */
.msg-box.success .msg-icon::before {
  content: "✔";
  font-size: 14px;
  margin-right: 10px;
  font-weight: bold;
}

/* ✅ Error style */
.msg-box.error {
  border-color: red;
  color: red;
  
}

.msg-box.error .msg-icon {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: 2px solid #d9381e;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #d9381e;
}

.msg-box.error .msg-icon::before {
  content: '!';
  font-weight: bold;
  font-size: 14px;
}

.msg-box.error .msg-text {
  flex: 1;
  margin-left: 8px;
  text-align: left;
  color: #d9381e;
  font-weight: 600;
}


/* ✅ Close (X) */
.msg-close {
  background: none;
  border: none;
  font-size: 20px;
  line-height: 10px;
  cursor: pointer;
  color: #555;
}

.msg-close:hover {
  color: #000;
}

/* ✅ Nice fade-in animation */
@keyframes fadeSlide {
  from {
    opacity: 0;
    transform: translateY(-8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
