/* growl.css - Advanced RTL/LTR + Dynamic Animations + One-Line Header */
.growls {
  position: fixed;
  z-index: 50000;
  pointer-events: none;
}

.growls > .growl {
  pointer-events: auto;
  margin: 10px;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  overflow: hidden;
  max-width: 380px;
  color: #fff;
  opacity: 0;
  transform: translateY(-20px);
  will-change: transform, opacity;
  background: #667eea;
}

/* Sizes */
.growl.growl-small { width: 200px; padding: 8px; font-size: 13px; }
.growl.growl-medium { width: 280px; padding: 12px; font-size: 14px; }
.growl.growl-large { width: 350px; padding: 16px; font-size: 15px; }

/* Header: Title + Close in One Line */
.growl-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 6px;
  min-height: 20px;
}

.growl-title {
  font-weight: 600;
  font-size: 1.1em;
  margin: 0;
  flex: 1;
  word-wrap: break-word;
  line-height: 1.3;
}

.growl-close {
  margin-left: 10px;
  font-size: 20px;
  line-height: 1;
  opacity: 0.7;
  cursor: pointer;
  font-weight: bold;
  transition: opacity 0.2s ease;
  flex-shrink: 0;
  user-select: none;
}
.growl-close:hover { opacity: 1; }

/* Message */
.growl-message {
  line-height: 1.5;
  word-wrap: break-word;
  margin: 0;
}

/* Positions */
#growls-top-left    { top: 10px; left: 10px; }
#growls-top-center  { top: 10px; left: 50%; transform: translateX(-50%); text-align: center; }
#growls-top-right   { top: 10px; right: 10px; }
#growls-bottom-left { bottom: 10px; left: 10px; }
#growls-bottom-center { bottom: 10px; left: 50%; transform: translateX(-50%); text-align: center; }
#growls-bottom-right { bottom: 10px; right: 10px; }
#growls-center { top: 50%; left: 50%; transform: translate(-50%, -50%); text-align: center; }

/* RTL Support */
.rtl .growl-header { direction: rtl; }
.rtl .growl-close { margin-left: 0; margin-right: 10px; }
.rtl .growl-title { text-align: right; }
.rtl .growl-message { text-align: right; }

/* Hover Effect */
.growl.growl-hovered {
  transform: scale(1.03) !important;
  box-shadow: 0 8px 20px rgba(0,0,0,0.2) !important;
  z-index: 1;
}

/* Animation Classes (will be overridden by JS keyframes) */
.growl-in, .growl-out { animation-fill-mode: both; }