/* Tipografía y base */
.ch-reco, .ch-card { font-family: "Montserrat", system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif; }
.ch-reco h2.ch-cat { font-size: 22px; margin: 18px 0 10px; color: #1B5E20; border-left: 6px solid #1B5E20; padding-left: 10px; }
.ch-title { font-size: 20px; margin: 0 0 6px; line-height: 1.25; }
.ch-asin { color: #555; font-size: 14px; }

/* Grid responsive */
.ch-grid { display: grid; grid-template-columns: repeat(12, 1fr); gap: 16px; margin-bottom: 24px; }
.ch-card { grid-column: span 12; display: grid; grid-template-columns: 260px 1fr 360px; gap: 16px; border: 1px solid #e6ece4; border-radius: 14px; padding: 14px; background: #fff; }
.ch-card__media img { width: 100%; height: auto; display: block; border-radius: 10px; }
.ch-card__aside { background: #FAFAFA; border: 1px solid #e4ede2; border-radius: 12px; padding: 12px; }

/* Botones */
.ch-btn { background: #2E7D32; color: #fff; border: 0; border-radius: 10px; padding: 10px 14px; cursor: pointer; font-weight: 600; }
.ch-btn:hover { background: #1B5E20; }
.ch-actions { margin-top: 8px; }

/* Autor */
.ch-author { color: #555; }

/* Responsive */
@media (max-width: 1024px){
  .ch-card { grid-template-columns: 220px 1fr; }
  .ch-card__aside { grid-column: 1 / -1; }
}
@media (max-width: 700px){
  .ch-card { grid-template-columns: 1fr; }
}

.ch-top5 {
  margin: 40px auto;
  padding: 20px;
  background: #f9fafb;
  border-radius: 12px;
  max-width: 1200px;
}

.ch-top5-title {
  text-align: center;
  font-size: 28px;
  margin-bottom: 25px;
  font-weight: 600;
  color: #1a1a1a;
}

.ch-top5-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 20px;
}

.ch-top5-item {
  background: #fff;
  border: 1px solid #e2e2e2;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0,0,0,0.05);
  display: flex;
  flex-direction: column;
  transition: transform .2s ease;
}

.ch-top5-item:hover {
  transform: translateY(-4px);
}

.ch-top5-img img {
  width: 100%;
  height: auto;
  display: block;
}

.ch-top5-content {
  padding: 15px;
  flex: 1;
}

.ch-top5-content h3 {
  font-size: 18px;
  margin: 0 0 5px;
}

.ch-top5-cat {
  font-size: 13px;
  color: #666;
  margin: 0 0 10px;
}

.ch-top5-reason {
  font-size: 14px;
  line-height: 1.5;
  color: #444;
}

.ch-top5-votes {
  margin-top: 10px;
  font-weight: 600;
  color: #1c7c3f;
}

/* Bloque Top (configurable) */
.ch-top { margin: 40px auto; padding: 20px; background: #f9fafb; border-radius: 12px; max-width: 1200px; }
.ch-top-title { text-align: center; font-size: 28px; margin-bottom: 22px; font-weight: 600; color: #1a1a1a; }

.ch-top-grid {
  display: grid;
  gap: 20px;
}

/* Por defecto adaptamos columnas en desktop según BEM modifier */
.ch-top--cols-3 .ch-top-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.ch-top--cols-4 .ch-top-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.ch-top--cols-5 .ch-top-grid { grid-template-columns: repeat(5, minmax(0, 1fr)); }

/* Tarjeta */
.ch-top-item {
  background: #fff;
  border: 1px solid #e2e2e2;
  border-radius: 12px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: 0 2px 8px rgba(0,0,0,.05);
  transition: transform .2s ease;
}
.ch-top-item:hover { transform: translateY(-3px); }

/* Imagen con relación 1:1 y recorte elegante */
.ch-top-img { display: block; aspect-ratio: 1 / 1; background: #fff; }
.ch-top-img img { width: 100%; height: 100%; object-fit: contain; display: block; }

/* Contenido */
.ch-top-content { padding: 12px 14px 16px; display: flex; flex-direction: column; gap: 8px; }
.ch-top-cat { font-size: 12px; color: #2E7D32; margin: 0; font-weight: 600; }

/* Títulos: clamp a 2 líneas para evitar roturas */
.ch-top-h3 { font-size: 16px; line-height: 1.35; margin: 0; }
.ch-top-h3 a { color: #1b1b1b; text-decoration: none; }
.ch-top-h3 a:hover { text-decoration: underline; }
.ch-top-h3 { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

.ch-top-votes { margin-top: auto; font-weight: 600; color: #1c7c3f; }

/* Responsivo */
@media (max-width: 1100px){
  .ch-top--cols-5 .ch-top-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
@media (max-width: 900px){
  .ch-top--cols-5 .ch-top-grid,
  .ch-top--cols-4 .ch-top-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 680px){
  .ch-top--cols-5 .ch-top-grid,
  .ch-top--cols-4 .ch-top-grid,
  .ch-top--cols-3 .ch-top-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 420px){
  .ch-top-grid { grid-template-columns: 1fr; }
}
