/*
Theme Name: SuperNews Child
Theme URI: https://cazaytiro.es/supernews-child
Description: Tema hijo de SuperNews.
Author: Tu Nombre
Author URI: https://cazaytiro.es
Template: supernews
Version: 1.0.0
*/

/* Aquí puedes agregar tus estilos personalizados */

.ecs-event-list {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
  padding: 0;
  margin: 0 auto 50px;
  list-style: none;
  max-width: 1200px;
}

.ecs-event-list .ecs-event {
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 8px;
  padding: 15px;
  box-sizing: border-box;

  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 400px; /* altura uniforme para todos */
  transition: box-shadow 0.3s ease;
}

.ecs-event-list .ecs-event:hover {
  box-shadow: 0 6px 15px rgba(0,0,0,0.1);
}

.ecs-event .entry-title.summary {
  font-size: 1.1rem;
  font-weight: 600;
  margin: 0 0 10px 0;
  line-height: 1.3;
}

.ecs-event .entry-title.summary a {
  color: #222;
  text-decoration: none;
}

.ecs-event .entry-title.summary a:hover {
  color: #0073e6;
  text-decoration: underline;
}

.ecs-event img.attachment-medium {
  width: 100%;
  height: auto;
  border-radius: 5px;
  margin-bottom: 15px;
  object-fit: cover;
  flex-shrink: 0;
}

.ecs-event p.ecs-excerpt {
  font-size: 0.9rem;
  color: #555;
  margin-bottom: 15px;
  flex-grow: 1; /* Para que el texto crezca y empuje el footer */
  overflow: hidden;
  text-overflow: ellipsis;
  max-height: 4.5em; /* limitar a 3 líneas aproximadamente */
  line-height: 1.5em;
}

.ecs-event .duration.time {
  font-size: 0.9rem;
  font-weight: 600;
  color: #0073e6;
  margin-top: auto;
  display: block;
  text-align: right;
}

/* --- Responsive --- */

@media (max-width: 992px) {
  .ecs-event-list {
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    max-width: 90%;
  }
  .ecs-event-list .ecs-event {
    min-height: 380px;
  }
}

@media (max-width: 600px) {
  .ecs-event-list {
    grid-template-columns: 1fr;
    gap: 15px;
    max-width: 100%;
  }
  .ecs-event-list .ecs-event {
    min-height: auto;
  }
  .ecs-event .entry-title.summary {
    font-size: 1rem;
  }
  .ecs-event p.ecs-excerpt {
    max-height: none;
  }
}
