@charset "UTF-8";

.home-noticias-section {
  overflow-x: clip;
}

.home-noticias-widget {
  width: 100%;
  max-width: 100%;
  padding: 0 clamp(0.85rem, 2.5vw, 2rem);
  margin-top: 0.25rem;
}

.home-noticias-widget--empty {
  padding-top: 0.5rem;
  padding-bottom: 0.5rem;
}

.home-noticias-widget__empty {
  font-size: 0.95rem;
  line-height: 1.55;
}

.home-noticias-widget__grid {
  display: grid;
  gap: clamp(0.65rem, 1.4vw, 1.1rem);
  width: 100%;
  max-width: 100%;
}

@media (min-width: 992px) {
  .home-noticias-widget__grid {
    grid-template-columns: repeat(6, minmax(0, 1fr));
  }

  /* Fila 1: 3 tarjetas a ancho parejo (2/6 cada una) */
  .home-noticias-widget__card:nth-child(-n + 3) {
    grid-column: span 2;
  }

  /* Fila 2: 2 tarjetas a ancho parejo (3/6 cada una) */
  .home-noticias-widget__card:nth-child(n + 4) {
    grid-column: span 3;
  }

  .home-noticias-widget__card:nth-child(-n + 3) .home-noticias-widget__card-link {
    min-height: clamp(17.5rem, 20vw, 22.5rem);
  }

  .home-noticias-widget__card:nth-child(n + 4) .home-noticias-widget__card-link {
    min-height: clamp(16rem, 17vw, 19.5rem);
  }
}

.home-noticias-widget__card {
  min-width: 0;
}

.home-noticias-widget__card-link {
  position: relative;
  display: block;
  height: 100%;
  min-height: clamp(19.5rem, 34vw, 27rem);
  border-radius: 0.65rem;
  overflow: hidden;
  color: #fff;
  text-decoration: none;
  background: #0a1210;
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.06) inset,
    0 14px 36px rgba(6, 18, 14, 0.18);
  transition:
    transform 0.45s cubic-bezier(0.22, 1, 0.36, 1),
    box-shadow 0.45s ease;
}

.home-noticias-widget__card-link:hover,
.home-noticias-widget__card-link:focus-visible {
  color: #fff;
  transform: translateY(-4px);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.08) inset,
    0 22px 48px rgba(6, 18, 14, 0.28);
}

.home-noticias-widget__card-link:focus-visible {
  outline: 2px solid rgba(255, 255, 255, 0.85);
  outline-offset: 3px;
}

.home-noticias-widget__media {
  position: absolute;
  inset: 0;
  display: block;
}

.home-noticias-widget__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 38%;
  transform: scale(1.02);
  transition: transform 0.65s cubic-bezier(0.22, 1, 0.36, 1);
}

.home-noticias-widget__card-link:hover .home-noticias-widget__media img,
.home-noticias-widget__card-link:focus-visible .home-noticias-widget__media img {
  transform: scale(1.08);
}

.home-noticias-widget__media-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  font-size: 2.25rem;
  color: rgba(255, 255, 255, 0.35);
  background: linear-gradient(145deg, #0f2a22 0%, #061410 100%);
}

.home-noticias-widget__shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    180deg,
    rgba(6, 12, 10, 0.15) 0%,
    rgba(6, 12, 10, 0.35) 38%,
    rgba(6, 12, 10, 0.82) 72%,
    rgba(6, 12, 10, 0.94) 100%
  );
  transition: background 0.45s ease;
}

.home-noticias-widget__card-link:hover .home-noticias-widget__shade,
.home-noticias-widget__card-link:focus-visible .home-noticias-widget__shade {
  background: linear-gradient(
    180deg,
    rgba(6, 12, 10, 0.25) 0%,
    rgba(6, 12, 10, 0.55) 30%,
    rgba(6, 12, 10, 0.9) 68%,
    rgba(6, 12, 10, 0.97) 100%
  );
}

.home-noticias-widget__content {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 2;
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  padding: clamp(1rem, 2.2vw, 1.35rem);
}

.home-noticias-widget__category {
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.78);
}

.home-noticias-widget__title {
  display: block;
  font-family: inherit;
  font-size: clamp(1rem, 1.35vw, 1.2rem);
  font-weight: 600;
  line-height: 1.28;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.35);
  transition: transform 0.45s cubic-bezier(0.22, 1, 0.36, 1);
}

.home-noticias-widget__excerpt {
  display: block;
  font-size: clamp(0.82rem, 1vw, 0.92rem);
  line-height: 1.55;
  font-weight: 300;
  color: rgba(255, 255, 255, 0.9);
  max-height: 0;
  opacity: 0;
  overflow: hidden;
  transform: translateY(0.35rem);
  transition:
    max-height 0.5s cubic-bezier(0.22, 1, 0.36, 1),
    opacity 0.4s ease,
    transform 0.45s cubic-bezier(0.22, 1, 0.36, 1);
}

.home-noticias-widget__date {
  font-size: 0.72rem;
  letter-spacing: 0.04em;
  color: rgba(255, 255, 255, 0.68);
  margin-top: 0.15rem;
}

.home-noticias-widget__card-link:hover .home-noticias-widget__title,
.home-noticias-widget__card-link:focus-visible .home-noticias-widget__title {
  transform: translateY(-2px);
}

.home-noticias-widget__card-link:hover .home-noticias-widget__excerpt,
.home-noticias-widget__card-link:focus-visible .home-noticias-widget__excerpt {
  max-height: 6.5rem;
  opacity: 1;
  transform: translateY(0);
}

@media (max-width: 991.98px) {
  .home-noticias-widget {
    padding: 0 0.75rem;
  }

  .home-noticias-widget__grid {
    display: flex;
    gap: 0.75rem;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
    padding-bottom: 0.35rem;
  }

  .home-noticias-widget__card {
    flex: 0 0 min(78vw, 17.5rem);
    scroll-snap-align: start;
  }

  .home-noticias-widget__card-link {
    min-height: 21.5rem;
  }
}

@media (hover: none) {
  .home-noticias-widget__excerpt {
    max-height: 3.4rem;
    opacity: 1;
    transform: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .home-noticias-widget__card-link,
  .home-noticias-widget__media img,
  .home-noticias-widget__shade,
  .home-noticias-widget__title,
  .home-noticias-widget__excerpt {
    transition: none;
  }

  .home-noticias-widget__card-link:hover,
  .home-noticias-widget__card-link:focus-visible {
    transform: none;
  }

  .home-noticias-widget__excerpt {
    max-height: 6.5rem;
    opacity: 1;
    transform: none;
  }
}
