/**
 * Card Stats Styles - Likes & Downloads
 * /app/stats/stats.css
 */

/* Stats Footer Container */
.card-stats-footer {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0;
  padding: 0;
  background: var(--bg-secondary, #f8fafc);
  border-top: 1px solid var(--border-color, #e2e8f0);
  border-radius: 0 0 12px 12px;
  font-size: 0.85rem;
}

/* Stat Button Base */
.stat-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  flex: 1;
  padding: 0.4rem 0.75rem;
  border: none;
  background: transparent;
  border-radius: 0;
  cursor: default;
  transition: all 0.2s ease;
  font-family: inherit;
  font-size: 0.85rem;
  color: var(--text-secondary, #64748b);
}

/* Separator between stats */
.stat-like {
  border-right: 1px solid var(--border-color, #e2e8f0);
}

/* Like Button - Clickable */
.stat-like {
  cursor: pointer;
}

.stat-like:hover:not(.liked) {
  background: rgba(0, 0, 0, 0.03);
}

.stat-like:active:not(.liked) {
  background: rgba(0, 0, 0, 0.05);
}

/* Download Stat - Display Only */
.stat-download {
  /* No background - inherits from parent */
}

/* Icons */
.stat-icon {
  font-size: 0.95rem;
  line-height: 1;
  display: inline-flex;
  align-items: center;
}

/* Heart Icon - Rouge du logo */
.stat-like .stat-icon {
  color: var(--accent, #ec7063);
}

/* Download Icon - Gray matching download button */
.stat-download .stat-icon {
  color: var(--primary, #48c9b0);
}

/* Stat Count */
.stat-count {
  font-weight: 500;
  color: var(--text-secondary, #64748b);
  min-width: 2rem;
}

/* Liked State */
.stat-like.liked {
  opacity: 0.7;
  cursor: default;
  /*pointer-events: none;*/
}

.stat-like.liked .stat-icon {
  color: var(--accent-dark, #d45a4e);
}

/* Liking Animation State */
.stat-like.liking {
  pointer-events: none;
}

/* Heart Beat Animation */
@keyframes heartBeat {
  0%,
  100% {
    transform: scale(1);
  }
  25% {
    transform: scale(1.3);
  }
  50% {
    transform: scale(1.1);
  }
  75% {
    transform: scale(1.25);
  }
}

/* Toast Notifications */
.stats-toast {
  position: fixed;
  bottom: 30px;
  right: 30px;
  padding: 12px 24px;
  border-radius: 8px;
  color: white;
  font-size: 14px;
  font-weight: 500;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
  z-index: 10000;
  opacity: 0;
  transform: translateY(20px);
  transition: all 0.3s ease;
  max-width: 300px;
}

.stats-toast.show {
  opacity: 1;
  transform: translateY(0);
}

.stats-toast-success {
  background: linear-gradient(135deg, #27ae60, #2ecc71);
}

.stats-toast-error {
  background: linear-gradient(135deg, #c0392b, #e74c3c);
}

.stats-toast-info {
  background: linear-gradient(135deg, #2980b9, #3498db);
}

/* Mobile Responsive */
@media (max-width: 768px) {
  .card-stats-footer {
    font-size: 0.8rem;
  }

  .stat-btn {
    padding: 0.4rem 0.5rem;
    gap: 0.3rem;
  }

  .stat-icon {
    font-size: 0.85rem;
  }

  .stats-toast {
    bottom: 20px;
    right: 20px;
    left: 20px;
    max-width: none;
    text-align: center;
  }
}

/* Dark mode support (if needed later) */
@media (prefers-color-scheme: dark) {
  .card-stats-footer {
    background: #2a2a2a;
    border-top-color: rgba(255, 255, 255, 0.1);
  }

  .stat-count {
    color: #ccc;
  }

  .stat-btn {
    color: #aaa;
  }

  .stat-like {
    border-right-color: #444;
  }

  .stat-like:hover:not(.liked) {
    background: rgba(255, 255, 255, 0.05);
  }
}
