.grid-container {
  display: grid;
  grid-template-columns: repeat(
    3,
    minmax(390px, 1fr)
  ); /* 3 cột, mỗi cột ít nhất 380px */
  gap: 30px;
  width: 100%;
  margin: auto;
}

.page-hero {
  margin-bottom: 3rem;
}
.page-title-container {
  width: 50%;
  padding: 0 5%;
}
/* Tiêu đề của trang */
.page-title {
  font-size: 70px;
  max-height: 70%;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 5;
  -webkit-box-orient: vertical;
}
.page-thumbnail {
  width: 50%;
}
/* Các item trong grid */
.grid-item {
  position: relative;
  overflow: hidden;
  height: 180px;
  background-color: transparent;
  border: none;
  text-decoration: none;
  color: #333333;
  transition: transform 0.3s ease;
}

.grid-item .full-link {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
}

.grid-item img {
  height: 15rem;
  width: 100%;
  display: block;
  object-fit: cover;
  transition: filter 0.3s ease-in-out, opacity 0.3s ease-in-out;
  filter: brightness(85%) sepia(30%) hue-rotate(-5deg) saturate(180%);
}

.grid-item:hover img {
  filter: brightness(65%) sepia(30%) hue-rotate(-5deg) saturate(180%);
}

/* Overlay text */
.overlay-text {
  position: absolute;
  top: 10px;
  left: 10px;
  background: white;
  padding: 0 10px;
  font-size: 14px;
  font-weight: 600;
  z-index: 2;
  max-width: 300px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
/* Base */
.page-title {
  font-size: 60px;
}

.section-title {
  font-size: 32px;
}

/* ≤1200px (lg) */
@media (max-width: 1300px) {
  .page-title {
    font-size: 40px;
  }

  .section-title {
    font-size: 28px;
  }

  .grid-container {
    grid-template-columns: repeat(2, minmax(280px, 1fr));
  }
}

/* ≤992px (md) */
@media (max-width: 992px) {
  .page-title {
    font-size: 44px;
  }

  .section-title {
    font-size: 24px;
  }
  .page-header-container {
    flex-direction: row;
    gap: 2rem;
    margin-left: 0 !important;
    justify-content: center;
    align-items: center;
  }

  .page-title-container,
  .page-thumbnail {
    width: 90%;
    padding: 0;
    text-align: center;
  }
}

/* ≤768px (sm) */
@media (max-width: 768px) {
  .page-title {
    font-size: 36px;
  }

  .section-title {
    font-size: 25px;
    padding: 10px !important;
  }
  .grid-container {
    grid-template-columns: repeat(1, minmax(250px, 1fr));
  }

  .overlay-text {
    font-size: 0.95rem;
    max-width: 200px;
  }
}

/* ≤576px (xs - mobile) */
@media (max-width: 576px) {
  .page-header-container {
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 0.5rem !important ;
    margin-left: 0 !important;
    text-align: center;
  }

  .page-title-container,
  .page-thumbnail {
    width: 100% !important;
    padding: 0 !important;
    margin: 0 !important;
  }
  .page-title {
    font-size: 18px;
    max-height: 80%;
    -webkit-line-clamp: 3;
  }

  .section-title {
    font-size: 15px;
  }
  .grid-item img {
    height: 11rem;
  }

  .overlay-text {
    font-size: 0.9rem;
  }
}
