.mf-stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 1rem;
}

.mf-stat-card {
  background: hsl(0 0% 100%);
  border: 1px solid hsl(240 5.9% 85%);
  border-radius: 0.5rem;
  padding: 1rem;
  text-align: center;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.mf-stat-card:hover {
  border-color: hsl(240 5.9% 70%);
  box-shadow: 0 2px 4px 0 rgba(0, 0, 0, 0.05);
}

.mf-stat-card__icon {
  width: 2.5rem;
  height: 2.5rem;
  margin: 0 auto 0.75rem;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 0.5rem;
  font-size: 1.25rem;
}

.mf-stat-card__icon--streak {
  background: hsl(25 95% 95%);
  color: hsl(25 95% 45%);
}

.mf-stat-card__icon--day {
  background: hsl(262 83% 95%);
  color: hsl(262 83% 45%);
}

.mf-stat-card__icon--category {
  background: hsl(142 76% 95%);
  color: hsl(142 76% 35%);
}

.mf-stat-card__icon--engagement {
  background: hsl(221.2 83.2% 95%);
  color: hsl(221.2 83.2% 45%);
}

.mf-stat-card__icon--total {
  background: hsl(240 4.8% 95%);
  color: hsl(240 5.9% 35%);
}

.mf-stat-card__icon--likes {
  background: hsl(0 72% 95%);
  color: hsl(0 72% 45%);
}

.mf-stat-card__value {
  font-size: 1.5rem;
  font-weight: 700;
  color: hsl(240 10% 3.9%);
  line-height: 1.2;
  letter-spacing: -0.025em;
}

.mf-stat-card__value--small {
  font-size: 1rem;
}

.mf-stat-card__label {
  font-size: 0.75rem;
  color: hsl(240 5.3% 45%);
  font-weight: 500;
  margin-top: 0.25rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

@media (max-width: 600px) {
  .mf-stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 400px) {
  .mf-stats-grid {
    grid-template-columns: 1fr;
  }
}

/* ── Dark Mode — Stat Cards ── */
[data-theme="dark"] .mf-stat-card {
  background: #0f172a;
  border-color: #334155;
}
[data-theme="dark"] .mf-stat-card:hover {
  border-color: #7cb8f7;
}
[data-theme="dark"] .mf-stat-card__value {
  color: #f1f5f9;
}
[data-theme="dark"] .mf-stat-card__label {
  color: #a8b5c4;
}
/* Icon backgrounds in dark mode */
[data-theme="dark"] .mf-stat-card__icon--streak { background: rgba(250,170,22,0.12); color: #fbbf24; }
[data-theme="dark"] .mf-stat-card__icon--day { background: rgba(168,85,247,0.12); color: #c084fc; }
[data-theme="dark"] .mf-stat-card__icon--category { background: rgba(34,197,94,0.12); color: #4ade80; }
[data-theme="dark"] .mf-stat-card__icon--engagement { background: rgba(96,165,250,0.12); color: #93c5fd; }
[data-theme="dark"] .mf-stat-card__icon--total { background: rgba(148,163,184,0.12); color: #94a3b8; }
[data-theme="dark"] .mf-stat-card__icon--likes { background: rgba(244,114,182,0.12); color: #f472b6; }
