/* =====================================================
   MindMix BC — Insights Filter Plugin Styles
   Font: Manrope | Design: exact match to screenshot
   ===================================================== */

@import url('https://fonts.googleapis.com/css2?family=Manrope:wght@300;400;500;600;700;800&display=swap');

/* ── Root Variables ── */
.mm-insights-wrap {
  --mm-gold:      #B08D57;
  --mm-white:     #FFFFFF;
  --mm-grey:      #8A8A8A;
  --mm-dark-grey: #5A5A5A;
  --mm-card-bg:   #1A1A1A;
  --mm-line:      #2A2A2A;
  --mm-black:     #0D0D0D;
  font-family: 'Manrope', sans-serif;
  color: var(--mm-white);
}

/* ══════════════════════════════════════════
   FILTER BAR
══════════════════════════════════════════ */
.mm-filter-bar {
  display: flex;
  align-items: center;
  gap: 20px;
  flex-wrap: wrap;
  padding-bottom: 28px;
  margin-bottom: 40px;
  border-bottom: 1px solid var(--mm-line);
}

.mm-filter-label {
  font-family: 'Manrope', sans-serif;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  color: var(--mm-gold);
  white-space: nowrap;
}

.mm-filter-tags {
  display: flex;
  gap: 0;
  flex-wrap: wrap;
}

/* All filter buttons share base style */
.mm-tag {
  font-family: 'Manrope', sans-serif;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.3px;
  text-transform: none;
  color: var(--mm-white) !important;
  background: transparent !important;
  border: 1px solid #3A3A3A;
  border-left: none;
      padding: 10px 22px !important;
    margin-left: 10px !important;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
  line-height: 1;
  outline: none;
  appearance: none;
  -webkit-appearance: none;
  white-space: nowrap;
}

/* First tag gets left border */
.mm-filter-tags .mm-tag:first-child {
  border-left: 1px solid #3A3A3A;
}

/* Hover state */
.mm-tag:hover {
  color: var(--mm-gold);
  border-color: var(--mm-gold);
  background: transparent;
  z-index: 1;
  position: relative;
}

/* Active "All" — gold fill */
.mm-tag.mm-tag--active {
  background: var(--mm-gold) !important;
  color: #0D0D0D !important;
  border-color: var(--mm-gold);
  font-weight: 700;
  position: relative;
  z-index: 1;
}

.mm-tag.mm-tag--active:hover {
  background: var(--mm-gold);
  color: #0D0D0D;
}

/* ══════════════════════════════════════════
   GRID
══════════════════════════════════════════ */
.mm-insights-grid {
  display: grid;
  gap: 0;
}

.mm-cols-3 { grid-template-columns: repeat(3, 1fr); }
.mm-cols-2 { grid-template-columns: repeat(2, 1fr); }
.mm-cols-1 { grid-template-columns: 1fr; }

@media (max-width: 1024px) {
  .mm-cols-3 { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 640px) {
  .mm-cols-3,
  .mm-cols-2 { grid-template-columns: 1fr; }
  .mm-filter-bar {
    flex-direction: column;
    align-items: flex-start;
    gap: 14px;
  }
  .mm-filter-tags { flex-wrap: wrap; }
  .mm-filter-tags .mm-tag:first-child { border-left: 1px solid #3A3A3A; }
}

/* ══════════════════════════════════════════
   CARD — image top, content bottom (screenshot)
══════════════════════════════════════════ */
.mm-insight-card {
  background: var(--mm-card-bg);
  border: 1px solid var(--mm-line);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  /* Collapse double borders */
  margin-right: -1px;
  margin-bottom: -1px;
  transition: border-color 0.25s ease;
  animation: mm-fade-in 0.35s ease both;
}

.mm-insight-card:hover {
  border-color: #4A4A4A;
  z-index: 1;
  position: relative;
}

/* ── Image (top portion, tall) ── */
.mm-insight-image-wrap {
  display: block;
  overflow: hidden;
  flex-shrink: 0;
}

.mm-insight-image {
  width: 100%;
  height: 260px;
  object-fit: cover;
  display: block;
  transition: transform 0.45s ease;
}

.mm-insight-card:hover .mm-insight-image {
  transform: scale(1.04);
}

/* Placeholder when no featured image */
.mm-insight-image--placeholder {
  width: 100%;
  height: 260px;
  display: block;
  background: linear-gradient(160deg, #232323 0%, #141414 100%);
}

/* ── Content (bottom portion) ── */
.mm-insight-content {
  padding: 28px 28px 32px;
  display: flex;
  flex-direction: column;
  flex: 1;
  background: var(--mm-card-bg);
  border-top: 1px solid var(--mm-line);
}

/* ── Meta: CATEGORY · X MIN READ ── */
.mm-insight-date {
  font-family: 'Manrope', sans-serif;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  color: var(--mm-gold);
  margin-bottom: 14px;
  line-height: 1;
}

/* ── Title ── */
.mm-insight-title {
  font-family: 'Manrope', sans-serif !important;
  font-size: 18px !important;
  font-weight: 700;
  line-height: 1.3;
  color: var(--mm-white) !important;
  margin: 0 0 16px;
}

.mm-insight-title a {
  color: inherit !important;
  text-decoration: none;
  transition: color 0.2s ease;
}

.mm-insight-title a:hover {
  color: #fff;
}

/* ── Excerpt ── */
.mm-insight-excerpt {
  font-family: 'Manrope', sans-serif;
  font-size: 15px;
  font-weight: 400;
  color: #fff;
  line-height: 1.7;
  margin: 0 0 24px;
  flex: 1;
}

/* ── Read More ── */
.mm-insight-link {
  font-family: 'Manrope', sans-serif;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--mm-white) !important;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: auto;
  transition: color 0.2s ease, gap 0.2s ease;
}

.mm-insight-link:hover {
  color: var(--mm-gold) !important;
  gap: 10px;
}

/* ══════════════════════════════════════════
   LOADING
══════════════════════════════════════════ */
.mm-insights-loader {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 56px 0;
}

.mm-spinner {
  width: 30px;
  height: 30px;
  border: 2px solid #2A2A2A;
  border-top-color: var(--mm-gold);
  border-radius: 50%;
  animation: mm-spin 0.65s linear infinite;
  display: inline-block;
}

@keyframes mm-spin {
  to { transform: rotate(360deg); }
}

.mm-insights-grid.mm-loading {
  opacity: 0.25;
  pointer-events: none;
  transition: opacity 0.15s ease;
}

.mm-insights-grid.mm-loaded {
  opacity: 1;
  transition: opacity 0.3s ease;
}

/* Card stagger */
@keyframes mm-fade-in {
  from { opacity: 0; transform: translateY(14px); }
  to   { opacity: 1; transform: translateY(0); }
}

.mm-insight-card:nth-child(1) { animation-delay: 0.00s; }
.mm-insight-card:nth-child(2) { animation-delay: 0.06s; }
.mm-insight-card:nth-child(3) { animation-delay: 0.12s; }
.mm-insight-card:nth-child(4) { animation-delay: 0.18s; }
.mm-insight-card:nth-child(5) { animation-delay: 0.24s; }
.mm-insight-card:nth-child(6) { animation-delay: 0.30s; }
.mm-insight-card:nth-child(7) { animation-delay: 0.36s; }
.mm-insight-card:nth-child(8) { animation-delay: 0.42s; }
.mm-insight-card:nth-child(9) { animation-delay: 0.48s; }

/* ── No results ── */
.mm-no-results,
.mm-no-posts {
  padding: 64px 0;
  text-align: center;
  color: var(--mm-dark-grey);
  font-family: 'Manrope', sans-serif;
  font-size: 15px;
  letter-spacing: 0.5px;
}
