/*
 * KaziCollect – realtime.css
 * Styles for live / real-time UI elements.
 */

/* ── Live badge pulse ── */
.kc-live-dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #e03a3a;
  margin-right: 6px;
  animation: kcPulse 1.4s infinite;
}

@keyframes kcPulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50%       { opacity: 0.5; transform: scale(1.3); }
}

/* ── Activity feed ── */
.activity-timeline {
  background: #fafcfe;
  border-radius: 24px;
  padding: 20px 22px;
  border: 1px solid #edf2f7;
  margin-bottom: 24px;
  max-height: 180px;
  overflow-y: auto;
}

.activity-item {
  display: flex;
  justify-content: space-between;
  padding: 10px 0;
  border-bottom: 1px solid #eef3f8;
  flex-wrap: wrap;
  animation: kcFadeSlide 0.3s ease;
}

.activity-item:last-child { border-bottom: none; }

.activity-text {
  font-weight: 500;
  color: #0b1e1a;
}

.activity-text i {
  color: #1f8b6e;
  margin-right: 10px;
}

.activity-time {
  color: #567184;
  font-size: 14px;
}

@keyframes kcFadeSlide {
  0%   { opacity: 0.4; transform: translateY(-6px); }
  100% { opacity: 1;   transform: translateY(0); }
}

/* ── Toast notifications ── */
.kc-toast {
  position: fixed;
  bottom: 24px;
  right: 24px;
  background: #0b4d3c;
  color: #fff;
  padding: 14px 22px;
  border-radius: 16px;
  font-size: 14px;
  font-weight: 500;
  box-shadow: 0 8px 24px rgba(0,0,0,0.18);
  z-index: 9999;
  animation: kcSlideUp 0.3s ease;
  max-width: 320px;
}

.kc-toast.error   { background: #c0392b; }
.kc-toast.warning { background: #d68910; }
.kc-toast.info    { background: #2471a3; }

@keyframes kcSlideUp {
  from { opacity: 0; transform: translateY(20px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ── Spinner ── */
.kc-spinner {
  display: inline-block;
  width: 20px;
  height: 20px;
  border: 3px solid rgba(255,255,255,0.3);
  border-top-color: #fff;
  border-radius: 50%;
  animation: kcSpin 0.7s linear infinite;
  vertical-align: middle;
  margin-right: 8px;
}

@keyframes kcSpin {
  to { transform: rotate(360deg); }
}

/* ── Status badges ── */
.kc-badge {
  display: inline-block;
  padding: 3px 12px;
  border-radius: 30px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.3px;
}

.kc-badge.pending    { background: #fef3cd; color: #856404; }
.kc-badge.active     { background: #d1ecf1; color: #0c5460; }
.kc-badge.completed  { background: #d4edda; color: #155724; }
.kc-badge.cancelled  { background: #f8d7da; color: #721c24; }
.kc-badge.dispatched { background: #e2d9f3; color: #4a235a; }
