/**
 * CSS bổ sung cho form đăng ký (không sửa style.css gốc của template).
 */

/* Honeypot: ẩn khỏi người dùng nhưng bot vẫn "nhìn thấy" */
.lf-honeypot {
  position: absolute !important;
  left: -9999px !important;
  top: auto !important;
  width: 1px !important;
  height: 1px !important;
  overflow: hidden !important;
  opacity: 0 !important;
  pointer-events: none !important;
}

/* Khung thông báo chung */
.lf-message {
  margin: 0 0 15px;
  padding: 10px 14px;
  border-radius: 4px;
  font-size: 13px;
  line-height: 1.5;
  border: 1px solid transparent;
}

.lf-message--success {
  background: #e8f6ed;
  border-color: #b7e0c4;
  color: #1c6b35;
}

.lf-message--error {
  background: #fdecec;
  border-color: #f5c2c2;
  color: #a12020;
}

.lf-message--info {
  background: #eef4fb;
  border-color: #c3d9f0;
  color: #1f4e79;
}

/* Thông báo lỗi dưới từng ô nhập */
.lf-error {
  display: none;
  margin-top: 4px;
  font-size: 12px;
  color: #c0392b;
  line-height: 1.4;
}

.form-group.has-error .lf-error {
  display: block;
}

.form-group.has-error input {
  border-color: #c0392b !important;
  outline: 1px solid #c0392b;
}

/* Trạng thái đang gửi */
.btn[disabled] {
  opacity: .65;
  cursor: not-allowed;
  pointer-events: none;
}

.subscriber-form.is-loading {
  position: relative;
}

.subscriber-form.is-loading::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(255, 255, 255, .45);
  cursor: progress;
}

/* Toast hiển thị trên mobile khi gửi thành công */
.lf-toast {
  position: fixed;
  left: 50%;
  bottom: 24px;
  transform: translate(-50%, 20px);
  max-width: min(92vw, 420px);
  padding: 12px 18px;
  border-radius: 6px;
  background: #1a2b49;
  color: #fff;
  font-size: 14px;
  line-height: 1.5;
  text-align: center;
  box-shadow: 0 8px 24px rgba(0, 0, 0, .25);
  opacity: 0;
  z-index: 9999;
  transition: opacity .25s ease, transform .25s ease;
}

.lf-toast.is-show {
  opacity: 1;
  transform: translate(-50%, 0);
}

.lf-toast--error {
  background: #a12020;
}
