@import url('https://fonts.googleapis.com/css2?family=Kanit&display=swap');

.research-article-page {
  font-family: 'Kanit', sans-serif;
  margin: 0;
  padding: 0;
  color: #222;
  background: #fff;
}

.research-article-background {
  background: url('../images/1.jpg') no-repeat center center;
  background-size: cover;
  padding: 40px 0;
  box-sizing: border-box;
}

.research-article-section {
  width: 100%;
  max-width: none;
  margin: 0 auto 40px;
  padding: 0 20px;
  text-align: center;
  color: #fff;
  position: relative;
}

.research-article-section h2 {
  font-weight: 700;
  font-size: 28px;
  margin-bottom: 10px;
  display: inline-block;
  position: relative;
  padding-bottom: 10px;
  letter-spacing: 0.05cm;
}

.research-article-section h2::after {
  content: "";
  width: 60px;
  height: 3px;
  background: #a68dff;
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  border-radius: 2px;
}

.research-article-section h2 a {
  color: #d1c5ff;
  font-weight: 400;
  font-size: 18px;
  text-decoration: none;
  border-left: 1px solid #d1c5ff;
  padding-left: 12px;
  margin-left: 10px;
  transition: color 0.3s ease;
  vertical-align: middle;
}

.research-article-section h2 a:hover {
  color: #fff;
  text-decoration: underline;
}


.research-article-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  padding: 0 20px;
  box-sizing: border-box;
  overflow-x: visible;
}

.research-article-link {
  text-decoration: none;
  color: inherit;
  display: block;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.research-article-link:hover {
  transform: translateY(-5px);
  box-shadow: 0 15px 30px rgb(0 0 0 / 0.25);
}

.research-article-link:hover img {
  transform: scale(1.05);
}

.research-article-card {
  background: #fff;
  border-radius: 18px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  color: #222;
  padding-bottom: 20px;
}

.research-article-card img {
  width: calc(100% - 30px);
  height: 200px;
  object-fit: cover;
  margin: 10px 15px 0;
  display: block;
  transition: transform 0.3s ease;
}

.research-category-tag {
  background-color: #ecb638;
  color: #422d00;
  font-size: 13px;
  font-weight: 700;
  padding: 5px 14px;
  border-radius: 20px;
  display: inline-block;
  margin: 12px 15px 0;
  max-width: max-content;
  box-shadow: 0 3px 6px rgb(236 182 56 / 0.5);
}

.research-no-image {
  width: 100%;
  height: 160px;
  background: #ccc;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #777;
}

.research-article-content {
  flex-grow: 1;
  padding: 0 15px;
  display: flex;
  flex-direction: column;
}

.research-date {
  font-size: 12px;
  color: #666;
  margin-bottom: 5px;
}

.research-article-title {
  font-size: 20px;
  font-weight: 700;
  margin: 0 0 10px;
  line-height: 1.3;
}

.research-article-summary {
  font-size: 15px;
  color: #444;
  flex-grow: 1;
  margin-bottom: 10px;
  line-height: 1.4;
}

.research-views {
  font-size: 14px;
  color: #444;
  margin-top: auto;
  margin-bottom: 10px;
  display: none;
}

/* Responsive */
@media (max-width: 480px) {
  .research-article-grid {
    grid-template-columns: 1fr;
    gap: 15px;
    padding: 0 10px;
  }

  .research-article-card img {
    height: 150px;
  }

  .research-article-title {
    font-size: 18px;
  }

  .research-article-summary {
    font-size: 14px;
  }
}

@media (min-width: 481px) and (max-width: 768px) {
  .research-article-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    padding: 0 15px;
  }

  .research-article-card img {
    height: 180px;
  }

  .research-article-title {
    font-size: 19px;
  }

  .research-article-summary {
    font-size: 15px;
  }
}

@media (min-width: 769px) and (max-width: 1024px) {
  .research-article-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    padding: 0 20px;
  }

  .research-article-card img {
    height: 190px;
  }

  .research-article-title {
    font-size: 20px;
  }

  .research-article-summary {
    font-size: 15px;
  }
}

@media (min-width: 1025px) {
  .research-article-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    padding: 0 20px;
  }

  .research-article-card img {
    height: 200px;
  }

  .research-article-title {
    font-size: 20px;
  }

  .research-article-summary {
    font-size: 15px;
  }
}
