/* Favorite Items Front CSS */
.fi-fav-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(255,255,255,0.9);
  border: none;
  cursor: pointer;
  transition: all 0.25s ease;
  box-shadow: 0 1px 4px rgba(0,0,0,0.15);
  text-decoration: none;
  position: relative;
  z-index: 5;
}

.fi-fav-btn i {
  font-size: 14px;
  color: #999;
  transition: all 0.25s ease;
}

.fi-fav-btn:hover {
  background: #fff;
  transform: scale(1.15);
}

.fi-fav-btn:hover i {
  color: #e74c3c;
}

.fi-fav-btn.is-fav i {
  color: #e74c3c;
}

.fi-fav-btn.is-fav {
  background: rgba(231,76,60,0.1);
}

/* Animation on toggle */
@keyframes fi-heart-pop {
  0% { transform: scale(1); }
  30% { transform: scale(1.35); }
  60% { transform: scale(0.9); }
  100% { transform: scale(1); }
}

.fi-fav-btn.fi-animating {
  animation: fi-heart-pop 0.4s ease;
}

/* Counter badge */
.fi-fav-count {
  position: absolute;
  top: -4px;
  right: -4px;
  background: #e74c3c;
  color: #fff;
  font-size: 9px;
  font-weight: 700;
  min-width: 16px;
  height: 16px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 3px;
  line-height: 1;
}

/* User dashboard favorites link */
.fi-dashboard-link {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  color: inherit;
  text-decoration: none;
  transition: background 0.2s;
}

.fi-dashboard-link:hover {
  background: rgba(0,0,0,0.05);
}

.fi-dashboard-link i {
  color: #e74c3c;
}

/* My Favorites page */
.fi-favorites-page {
  max-width: 800px;
  margin: 0 auto;
  padding: 20px;
}

.fi-favorites-page h1 {
  font-size: 24px;
  margin-bottom: 20px;
}

.fi-fav-item {
  display: flex;
  align-items: center;
  padding: 12px;
  border-bottom: 1px solid #eee;
  gap: 12px;
}

.fi-fav-item-img {
  width: 80px;
  height: 60px;
  object-fit: cover;
  border-radius: 6px;
  flex-shrink: 0;
}

.fi-fav-item-info {
  flex: 1;
}

.fi-fav-item-title {
  font-weight: 600;
  margin-bottom: 4px;
}

.fi-fav-item-title a {
  color: inherit;
  text-decoration: none;
}

.fi-fav-item-title a:hover {
  text-decoration: underline;
}

.fi-fav-item-price {
  color: #e74c3c;
  font-weight: 700;
}

.fi-fav-item-remove {
  color: #999;
  cursor: pointer;
  padding: 6px;
  border: none;
  background: none;
  font-size: 16px;
  transition: color 0.2s;
}

.fi-fav-item-remove:hover {
  color: #e74c3c;
}

/* RTL support */
html[dir="rtl"] .fi-fav-item {
  direction: rtl;
}

/* Empty state */
.fi-empty-state {
  text-align: center;
  padding: 40px 20px;
  color: #999;
}

.fi-empty-state i {
  font-size: 48px;
  margin-bottom: 12px;
  display: block;
  color: #ddd;
}

/* Toast notification */
.fi-toast {
  position: fixed;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%) translateY(80px);
  background: #333;
  color: #fff;
  padding: 10px 20px;
  border-radius: 8px;
  font-size: 14px;
  z-index: 99999;
  opacity: 0;
  transition: all 0.3s ease;
  pointer-events: none;
}

.fi-toast.fi-show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

/* Mobile responsive */
@media (max-width: 768px) {
  .fi-fav-btn {
    width: 28px;
    height: 28px;
  }
  .fi-fav-btn i {
    font-size: 12px;
  }
}