/* =============================================
   ALLNATURALS — INLINE STYLED MESSAGES
   Messages always visible; JS adds animation class
   ============================================= */

/* ── Wrapper ─────────────────────────────────── */
.messages-list { margin: 0 !important; padding: 0 !important; }
.messages__wrapper { padding: 12px 0 4px !important; }

/* ── Base message ────────────────────────────── */
.messages-list__item.messages {
  display: flex !important;
  align-items: flex-start !important;
  gap: 14px !important;
  padding: 18px 20px 18px 22px !important;
  border-radius: 14px !important;
  margin-bottom: 10px !important;
  position: relative !important;
  overflow: hidden !important;
  border: none !important;
  box-shadow:
    0 8px 32px rgba(0, 0, 0, 0.35),
    0 2px 10px rgba(0, 0, 0, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 0.1) !important;
  /* Visible by default — no opacity trick */
  opacity: 1;
}

/* ── Slide-in animation (added by JS) ─────────── */
@keyframes an-slide-in {
  from { transform: translateY(-20px); opacity: 0; }
  to   { transform: translateY(0);     opacity: 1; }
}
.messages-list__item.messages.an-animate {
  animation: an-slide-in 0.5s cubic-bezier(0.34, 1.4, 0.64, 1) forwards;
}

/* Shine sweep (added by JS) */
@keyframes an-shine {
  from { transform: translateX(-110%); }
  to   { transform: translateX(110%);  }
}
.messages-list__item.messages.an-animate::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(110deg, transparent 20%, rgba(255,255,255,0.07) 50%, transparent 80%);
  pointer-events: none;
  animation: an-shine 0.9s ease 0.3s both;
}

/* Warning glow pulse (added by JS) */
@keyframes an-pulse-warning {
  0%,100% { box-shadow: 0 8px 32px rgba(0,0,0,0.35), 0 2px 10px rgba(0,0,0,0.2), inset 0 1px 0 rgba(255,255,255,0.1); }
  50%     { box-shadow: 0 8px 32px rgba(245,166,35,0.4), 0 0 30px rgba(245,166,35,0.25), inset 0 1px 0 rgba(255,255,255,0.1); }
}
.messages--warning.an-animate {
  animation: an-slide-in 0.5s cubic-bezier(0.34, 1.4, 0.64, 1) forwards,
             an-pulse-warning 2.5s ease 0.9s 2;
}

/* Error shake (added by JS) */
@keyframes an-shake {
  0%   { transform: translateX(0); }
  15%  { transform: translateX(-7px); }
  30%  { transform: translateX(6px); }
  45%  { transform: translateX(-5px); }
  60%  { transform: translateX(4px); }
  75%  { transform: translateX(-2px); }
  100% { transform: translateX(0); }
}
.messages--error.an-animate {
  animation: an-slide-in 0.5s cubic-bezier(0.34, 1.4, 0.64, 1) forwards,
             an-shake 0.55s ease 0.55s both;
}

/* Dismiss slide-out */
@keyframes an-slide-out {
  0%   { transform: translateX(0);    opacity: 1; max-height: 200px; margin-bottom: 10px; padding-top: 18px; padding-bottom: 18px; }
  50%  { transform: translateX(50px); opacity: 0; }
  100% { transform: translateX(70px); opacity: 0; max-height: 0; margin-bottom: 0; padding-top: 0; padding-bottom: 0; }
}
.messages-list__item.messages.an-dismissing {
  animation: an-slide-out 0.38s ease forwards !important;
  pointer-events: none;
}

/* ── STATUS — deep forest green ──────────────── */
.messages--status {
  background: linear-gradient(135deg, #082516 0%, #0f4028 60%, #166234 100%) !important;
  color: #c3f7d4 !important;
  border-left: 5px solid #34d870 !important;
}
.messages--status .an-msg-icon {
  background: radial-gradient(circle, #34d870, #1db954);
  color: #051a0e;
  box-shadow: 0 0 14px rgba(52, 216, 112, 0.5);
}
.messages--status a { color: #7fffa8 !important; }

/* ── WARNING — deep amber ────────────────────── */
.messages--warning {
  background: linear-gradient(135deg, #1e0d00 0%, #4a2200 60%, #6b3300 100%) !important;
  color: #ffe8a0 !important;
  border-left: 5px solid #f5a623 !important;
}
.messages--warning .an-msg-icon {
  background: radial-gradient(circle, #f5a623, #d4880e);
  color: #1e0d00;
  box-shadow: 0 0 14px rgba(245, 166, 35, 0.5);
}
.messages--warning a { color: #ffd066 !important; }

/* ── ERROR — deep crimson ────────────────────── */
.messages--error {
  background: linear-gradient(135deg, #1c0004 0%, #4a000e 60%, #7a0018 100%) !important;
  color: #ffb0be !important;
  border-left: 5px solid #ff2244 !important;
}
.messages--error .an-msg-icon {
  background: radial-gradient(circle, #ff2244, #cc0033);
  color: #fff;
  box-shadow: 0 0 14px rgba(255, 34, 68, 0.55);
}
.messages--error a { color: #ff8fa3 !important; }

/* ── INFO — deep navy ────────────────────────── */
.messages--info {
  background: linear-gradient(135deg, #00102e 0%, #002060 60%, #003494 100%) !important;
  color: #a8d4ff !important;
  border-left: 5px solid #4fa6ff !important;
}
.messages--info .an-msg-icon {
  background: radial-gradient(circle, #4fa6ff, #1a7de0);
  color: #00102e;
  box-shadow: 0 0 14px rgba(79, 166, 255, 0.5);
}
.messages--info a { color: #8ecfff !important; }

/* ── Icon circle ─────────────────────────────── */
.an-msg-icon {
  flex-shrink: 0;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.05rem;
  font-weight: 900;
  margin-top: 1px;
  position: relative;
  z-index: 2;
}

/* Hide the original Solo icon/header */
.messages__header { display: none !important; }

/* ── Type label ──────────────────────────────── */
.an-msg-label {
  display: block;
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  opacity: 0.65;
  margin-bottom: 4px;
}

/* ── Content ─────────────────────────────────── */
.messages__container {
  display: contents !important;
}
.messages__content {
  flex: 1 !important;
  font-size: 0.97rem !important;
  line-height: 1.55 !important;
  color: inherit !important;
  padding-top: 6px !important;
  position: relative;
  z-index: 2;
  min-width: 0;
}
.messages__content ul  { margin: 4px 0 0 0; padding-left: 18px; }
.messages__content li  { margin-bottom: 3px; }

/* ── Close button ────────────────────────────── */
.an-msg-close {
  flex-shrink: 0;
  align-self: flex-start;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: inherit;
  opacity: 0.55;
  cursor: pointer;
  font-size: 1rem;
  font-weight: 700;
  width: 26px;
  height: 26px;
  padding: 0;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.2s, background 0.2s, transform 0.25s;
  margin-top: 3px;
  line-height: 1;
  z-index: 2;
  position: relative;
}
.an-msg-close:hover {
  opacity: 1;
  background: rgba(255, 255, 255, 0.22);
  transform: rotate(90deg) scale(1.15);
}

/* ── Mobile ──────────────────────────────────── */
@media (max-width: 600px) {
  .messages-list__item.messages {
    padding: 14px 14px 14px 16px !important;
    border-radius: 12px !important;
    gap: 12px !important;
  }
}
