/* Main container styling */
.container {
  width: 95%;
  margin: 0 20px;
  padding: 20px;
  padding-top: 180px;
  background-color: #fdfdfd;
  display: flex;
  flex-direction: column;
  align-items: center;
  flex: 1 0 auto;
}

/* Container for article cards */
.articles-container {
  width: 95%;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 20px;
}

/* Article Preview Card */
/* Article Preview Card */
.article-preview {
  cursor: pointer;
  width: 400px;
  height: 320px;
  display: flex;
  flex-direction: column;
  border: 2px solid #ddd;
  border-radius: 0;
  overflow: hidden;
  background: #fff;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease;
}

.article-preview:hover {
  transform: scale(1.03);
}

/* Image Styling */
.article-preview img {
  width: 100%;
  height: 180px;
  object-fit: cover;
}

/* Content Section */
.article-content {
  padding: 6px;
  display: flex;
  flex-direction: column;
  /* This ensures that the top (title) and bottom (date) are separated */
  justify-content: space-between;
  gap: 0;
  flex: 1;
}

/* Title (h5) Styling */
.article-content h5 {
  color: #555;
  font-size: 20px;
  line-height: 1.4;
  /* Adjusts vertical spacing to prevent clipping */
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  /* Limits to 3 lines */
  -webkit-box-orient: vertical;
  /* Specifies vertical orientation */
  padding-bottom: 2px;
  /* Optional extra spacing */
  line-clamp: 3;
}

/* Date Styling: Push it to the bottom */
.article-date {
  font-size: 14px;
  color: #888;
  margin: 0;
  margin-top: auto;
  /* This ensures the date stays at the bottom */
}



/* Read More Button */
.read-more {
  text-align: center;
  padding: 8px;
  font-size: 16px;
  font-weight: bold;
  background: linear-gradient(45deg, #ff4229, #ff9f32);
  color: white;
  text-decoration: none;
  border-radius: 5px;
  transition: background 0.3s ease;
}

.read-more:hover {
  background: linear-gradient(45deg, #ff9f32, #ff4229);
}


/* ====================== */
/* MAIN LAYOUT - MEDIA */
/* ====================== */

@media only screen and (max-width: 768px) {
  .container {
    padding: 30px 10px 20px;
    width: 100%;
    margin: 0 auto;
  }

  .articles-container {
    /*flex-direction: column;*/
    align-items: center;
    width: 100%;
    gap: 10px;
  }

  .article-preview {
    width: 48%;
    height: 200px;
    border: 1px solid #ddd;
  }

  .article-preview img {
    height: 100px;
    width: 100%;
    display: block;
    object-fit: cover;
  }

  .article-content h5 {
    font-size: 14px;
  }
}


/* Hide the Google Translate banner and other widget elements */
.goog-te-banner-frame.skiptranslate,
.goog-te-gadget-icon,
.goog-te-menu-frame,
.goog-te-menu-frame * {
  display: none !important;
}

.skiptranslate,
.skiptranslate iframe {
  display: none !important;
}

body {
  top: 0px !important;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}


/* pagination --------------------------------------------- */
.pagination {
  display: flex;
  justify-content: center;
  gap: .25rem;
  margin: 2rem 0;
}

.page-btn {
  padding: .5rem .75rem;
  border: 1px solid #ddd;
  background: #fff;
  cursor: pointer;
  font-size: .875rem;
  border-radius: 4px;
  transition: background .15s;
}

.page-btn:hover:not(.active):not(.disabled) {
  background: #f3f3f3;
}

.page-btn.active {
  background: #333;
  color: #fff;
  cursor: default;
}

.page-btn.disabled {
  opacity: .45;
  cursor: default;
}