#flash-container {
  position: fixed;
  display: flex;
  flex-direction: column;
  gap: 10px;
  z-index: 9999;
}

#flash-container.top-right   { top: 20px; right: 20px; align-items: flex-end; }
#flash-container.top-left    { top: 20px; left: 20px; align-items: flex-start; }
#flash-container.bottom-right{ bottom: 20px; right: 20px; align-items: flex-end; }
#flash-container.bottom-left { bottom: 20px; left: 20px; align-items: flex-start; }

.flashbag {
  position: relative;
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 260px;
  max-width: 360px;
  padding: 12px 40px 12px 16px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 500;
  color: #fff;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
  opacity: 0;
  transform: translateX(100%);
  animation: slideIn 0.4s forwards;
  overflow: hidden;
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.flashbag .icon { font-size: 18px; flex-shrink: 0; }

.flashbag .close-btn {
  position: absolute;
  top: 8px;
  right: 10px;
  cursor: pointer;
  font-size: 16px;
  font-weight: bold;
  color: inherit;
  background: none;
  border: none;
  opacity: 0.8;
  transition: opacity 0.2s;
}
.flashbag .close-btn:hover { opacity: 1; }

.flashbag .progress-bar {
  position: absolute;
  bottom: 0;
  left: 0;
  height: 4px;
  background: rgba(255, 255, 255, 0.7);
  width: 100%;
  animation: shrink linear forwards;
}

.flashbag.success { background-color: rgba(15, 95, 48, 0.95); }
.flashbag.error   { background-color: rgba(231, 76, 60, 0.95); }
.flashbag.warning { background-color: rgba(241, 196, 15, 0.95); color: #222; }
.flashbag.info    { background-color: rgba(52, 152, 219, 0.95); }

@keyframes slideIn { to { opacity: 1; transform: translateX(0); } }
@keyframes slideOut { to { opacity: 0; transform: translateX(100%); } }
@keyframes shrink { from { width: 100%; } to { width: 0; } }
