/* ======== GRID DE VÍDEOS ======== */
.videos-grid {
  margin-top: 12px;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 20px;
}

@media (min-width: 1200px) {
  .videos-grid {
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  }
}

@media (max-width: 600px) {
  .videos-grid {
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  }
}

.video-card {
  background: #fff;
  border: 1px solid #eee;
  padding: 8px;
  border-radius: 8px;
  display: flex;
  flex-direction: column;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.video-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 3px 6px rgba(0,0,0,0.1);
}

/* ======== MINIATURA ======== */
.thumb-wrap {
  position: relative;
  width: 100%;
  padding-top: 100%;
  overflow: hidden;
  border-radius: 6px;
  cursor: pointer;
}

.thumb-wrap img.thumb {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* ======== OVERLAY META (duración + fecha) ======== */
.meta-overlay {
  position: absolute;
  bottom: 6px;
  left: 6px;
  right: 6px;
  display: flex;
  justify-content: space-between;
  font-size: 13px;
  color: #fff;
  text-shadow: 0 0 3px rgba(0,0,0,0.7);
}

.meta-overlay .duration,
.meta-overlay .date-tag {
  background: rgba(0,0,0,0.6);
  padding: 2px 6px;
  border-radius: 4px;
}

/* ======== INFO DE TARJETA ======== */
.card-info {
  margin-top: 8px;
  font-size: 14px;
}

.card-info .title {
  font-weight: 600;
  margin-top: 4px;
}

.card-info .short {
  font-size: 13px;
  color: #444;
  margin-top: 6px;
}

/* ======== BOTONES DE AÑOS ======== */
#year-filters {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 10px;
}

.year-btn {
  background-color: #7b4bc1; /* morado base */
  color: #fff;
  border: none;
  padding: 8px 14px;
  border-radius: 6px;
  margin: 4px 0;
  cursor: pointer;
  font-weight: 500;
  transition: background-color 0.2s ease, transform 0.15s ease;
}

.year-btn:hover {
  background-color: #0073e6; /* azul hover */
  transform: translateY(-1px);
}

.year-btn.active {
  background-color: #0073e6; /* azul activo */
}

/* ======== MODAL ======== */
.video-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.85);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  padding: 20px;
}

.video-modal-inner {
  position: relative;
  width: 100%;
  max-width: 1100px;
  max-height: 90vh;
  background: #000;
  border-radius: 8px;
  padding: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.video-modal-inner .close-modal {
  position: absolute;
  top: 8px;
  right: 8px;
  background: transparent;
  color: #fff;
  border: 0;
  font-size: 28px;
  cursor: pointer;
  z-index: 10000;
}

.modal-video {
  width: 100%;
  height: auto;
  max-height: 80vh;
  display: block;
  background: #000;
  border-radius: 6px;
  object-fit: contain;
}
