/* Mp Asociados — Insights / Publicaciones LinkedIn */

/* CONTROLES (buscador + filtros) */
.insights-controles { margin: var(--space-8) 0 var(--space-12); }

.insights-search {
  position: relative;
  max-width: 640px;
  margin: 0 auto var(--space-6);
}
.insights-search__icon {
  position: absolute;
  left: 16px;
  top: 50%;
  transform: translateY(-50%);
  width: 18px; height: 18px;
  color: var(--gray-500);
  pointer-events: none;
}
.insights-search input {
  width: 100%;
  padding: 14px 16px 14px 46px;
  font-family: inherit;
  font-size: 1rem;
  border: 1px solid var(--gray-300);
  border-radius: 4px;
  background: var(--white);
  transition: all 200ms ease;
}
.insights-search input:focus {
  outline: none;
  border-color: var(--mp-blue-800);
  box-shadow: 0 0 0 3px rgba(46, 93, 166, 0.1);
}

.insights-filtros {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-6);
  justify-content: center;
  margin-bottom: var(--space-6);
}
.insights-filtros__grupo {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  flex-wrap: wrap;
}
.insights-filtros__label {
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gray-500);
}
.insights-filtros__opciones {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.insights-filtros__btn {
  font-family: inherit;
  font-size: 0.8125rem;
  font-weight: 500;
  padding: 6px 14px;
  background: var(--white);
  color: var(--gray-700);
  border: 1px solid var(--gray-300);
  border-radius: 999px;
  cursor: pointer;
  transition: all 200ms ease;
}
.insights-filtros__btn:hover {
  border-color: var(--mp-blue-800);
  color: var(--mp-blue-800);
}
.insights-filtros__btn.active {
  background: var(--mp-blue-800);
  border-color: var(--mp-blue-800);
  color: var(--white);
  font-weight: 600;
}

.insights-contador {
  text-align: center;
  font-size: 0.875rem;
  color: var(--gray-500);
  margin: 0;
  font-style: italic;
}

/* GRILLA */
.insights-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: var(--space-6);
  margin-top: var(--space-8);
}

.insight-card {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: 4px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: all 250ms ease;
  text-decoration: none;
  color: inherit;
}
.insight-card:hover {
  border-color: var(--mp-blue-800);
  transform: translateY(-2px);
  box-shadow: 0 10px 25px -5px rgba(0,0,0,0.08);
}

.insight-card__image {
  width: 100%;
  height: 140px;
  background: linear-gradient(135deg, var(--mp-blue-900), var(--mp-blue-600));
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
}
.insight-card__image img {
  width: 100%; height: 100%; object-fit: cover;
}
.insight-card__image-placeholder {
  font-family: var(--font-serif);
  font-size: 2.5rem;
  color: rgba(200, 169, 90, 0.65);
  font-style: italic;
  font-weight: 600;
}

.insight-card__body {
  padding: var(--space-6);
  flex: 1;
  display: flex;
  flex-direction: column;
}

.insight-card__meta {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  font-size: 0.75rem;
  letter-spacing: 0.05em;
  margin-bottom: var(--space-3);
}
.insight-card__cat {
  font-weight: 700;
  padding: 3px 8px;
  background: var(--mp-blue-100);
  color: var(--mp-blue-800);
  border-radius: 2px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}
.insight-card__date {
  color: var(--gray-500);
  text-transform: capitalize;
}

.insight-card__title {
  font-size: 1.0625rem;
  font-weight: 700;
  color: var(--mp-blue-900);
  line-height: 1.35;
  margin-bottom: var(--space-3);
  letter-spacing: -0.01em;
}

.insight-card__excerpt {
  font-size: 0.9375rem;
  color: var(--gray-600);
  flex: 1;
  line-height: 1.55;
  margin-bottom: var(--space-4);
}

.insight-card__cta {
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--mp-blue-800);
  display: flex;
  align-items: center;
  gap: var(--space-2);
  padding-top: var(--space-4);
  border-top: 1px solid var(--gray-200);
}
.insight-card__cta svg { width: 14px; height: 14px; fill: currentColor; }

/* Color por categoría */
.insight-card__cat[data-cat="Jurisprudencia"] { background: #FCE7D5; color: #8B3A1A; }
.insight-card__cat[data-cat="FIP"] { background: #DCFCE7; color: #166534; }
.insight-card__cat[data-cat="SII"] { background: #D6E4F0; color: #1A3A6B; }
.insight-card__cat[data-cat="CMF"] { background: #FEF3C7; color: #92400E; }
.insight-card__cat[data-cat="DT"] { background: #FEE2E2; color: #991B1B; }
.insight-card__cat[data-cat="IFRS"] { background: #E0F2FE; color: #075985; }
.insight-card__cat[data-cat="Ley"] { background: #EDE9FE; color: #5B21B6; }
.insight-card__cat[data-cat="Tributario"] { background: #D6E4F0; color: #1A3A6B; }

@media (max-width: 768px) {
  .insights-filtros { flex-direction: column; gap: var(--space-4); }
  .insights-filtros__grupo { justify-content: center; }
}
