/* ==========================================================================
   Platform Al-Fath (منصة الفتح) - Islamic Blog & Articles Styles
   Matches the luxury aesthetic of the dedicated Blog page cards
   ========================================================================== */

/* ==========================================================================
   Islamic Blog / Articles Section Grid & Cards
   ========================================================================== */
.articles-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(310px, 1fr));
  gap: 26px;
}

.article-card {
  background: #ffffff;
  border: 1.5px solid rgba(205, 159, 92, 0.28);
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 8px 24px rgba(205, 159, 92, 0.08), 0 2px 6px rgba(0, 0, 0, 0.02);
  display: flex;
  flex-direction: column;
  transition: all 0.35s cubic-bezier(0.2, 0.8, 0.2, 1);
  position: relative;
}

.article-card:hover {
  transform: translateY(-7px);
  border-color: #CD9F5C;
  box-shadow: 0 16px 36px rgba(205, 159, 92, 0.22), 0 4px 12px rgba(2, 54, 56, 0.06);
}

/* Card Thumbnail */
.article-thumb {
  height: 205px;
  position: relative;
  overflow: hidden;
  cursor: pointer;
  display: block;
  text-decoration: none;
}

.article-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.article-card:hover .article-thumb img {
  transform: scale(1.08);
}

.thumb-glow-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0) 55%, rgba(0, 0, 0, 0.5) 100%);
  pointer-events: none;
}

.card-category-tag {
  position: absolute;
  top: 14px;
  right: 14px;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  color: #8c6020;
  border: 1px solid rgba(205, 159, 92, 0.5);
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 0.76rem;
  font-weight: 800;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  z-index: 2;
}

/* Card Body Content */
.article-content {
  padding: 22px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.article-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

.article-date {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #8c6020;
  font-size: 0.82rem;
  font-weight: 700;
}

/* Title */
.article-title {
  font-size: 1.16rem;
  font-weight: 800;
  color: #023638;
  line-height: 1.5;
  margin-bottom: 12px;
  cursor: pointer;
  transition: color 0.25s ease;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.article-title a {
  color: inherit;
  text-decoration: none;
  transition: color 0.25s ease;
}

.article-card:hover .article-title,
.article-card:hover .article-title a {
  color: #CD9F5C;
}

/* Excerpt */
.article-excerpt {
  font-size: 0.9rem;
  color: #557072;
  line-height: 1.7;
  margin-bottom: 20px;
  flex-grow: 1;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* Footer with Author and Button */
.article-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid rgba(205, 159, 92, 0.18);
  padding-top: 16px;
  margin-top: auto;
}

.article-author-box {
  display: flex;
  align-items: center;
  gap: 7px;
  color: #023638;
  font-size: 0.84rem;
  font-weight: 700;
}

.article-author-box .author-icon {
  flex-shrink: 0;
}

.btn-read-article {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: rgba(205, 159, 92, 0.1);
  border: 1.5px solid rgba(205, 159, 92, 0.4);
  color: #8c6020;
  padding: 8px 16px;
  border-radius: 12px;
  font-family: inherit;
  font-size: 0.82rem;
  font-weight: 800;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.25s ease;
}

.btn-read-article:hover {
  background: linear-gradient(135deg, #CD9F5C, #b68541);
  color: #ffffff;
  border-color: #CD9F5C;
  box-shadow: 0 4px 14px rgba(205, 159, 92, 0.35);
}

.btn-read-article .read-arrow {
  transition: transform 0.25s ease;
}

.btn-read-article:hover .read-arrow {
  transform: translateX(-4px);
}

@media (max-width: 768px) {
  .articles-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .article-thumb {
    height: 190px;
  }

  .article-content {
    padding: 18px;
  }

  .article-footer {
    flex-wrap: wrap;
    gap: 12px;
  }
}