/* ============================================
   ECOFACTOR - Resources Section Styles
   "Ресурси" (Blog/Articles)
   ============================================ */

/* ============================================
   RESOURCES SECTION
   ============================================ */

.resources {
  background-color: var(--color-gray-95);
  padding: 80px 0;
  width: 100%;
}

.resources__content {
  max-width: 1148px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 40px;
  align-items: center;
}

/* ============================================
   SECTION HEADER
   ============================================ */

.resources__title {
  width: 100%;
  font-family: var(--font-primary);
  font-size: var(--h2-size);
  font-weight: var(--font-bold);
  line-height: var(--h2-line-height);
  color: var(--color-gray-20);
  margin: 0;
}

/* ============================================
   POSTS GRID
   ============================================ */

.resources__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 22px 30px;
  width: 100%;
}

/* ============================================
   POST CARD
   ============================================ */

.post-card {
  display: flex;
  flex-direction: column;
  padding-top: 8px;
  min-width: 264px;
  overflow: hidden;
  text-decoration: none;
  transition: transform var(--transition-fast);
}

.post-card:hover {
  transform: translateY(-4px);
}

.post-card__inner {
  background-color: var(--color-white);
  border: 1px solid var(--color-gray-95);
  border-radius: var(--radius-xl);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

/* Post image */
.post-card__image {
  position: relative;
  height: 162px;
  overflow: hidden;
}

.post-card__image img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.post-card__image::after {
  content: '';
  position: absolute;
  inset: 0;
  background-color: rgba(58, 58, 58, 0.3);
  pointer-events: none;
}

/* Post content */
.post-card__content {
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

/* Category tag */
.post-card__category {
  font-family: var(--font-primary);
  font-size: var(--caption-size); /* 10px */
  font-weight: 600;
  line-height: 1.55;
  letter-spacing: 0.5px;
  color: #23A859;
  text-transform: uppercase;
}

/* Post title */
.post-card__title {
  font-family: var(--font-primary);
  font-size: var(--body-size);
  font-weight: 600;
  line-height: 1.4;
  color: var(--color-gray-20);
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Post date */
.post-card__date {
  font-family: var(--font-primary);
  font-size: var(--body-xs-size); /* 12px */
  font-weight: var(--font-regular);
  line-height: 1.55;
  color: var(--color-gray-30);
}

/* ============================================
   CTA BUTTON
   ============================================ */

.resources__cta {
  margin-top: 0;
}

/* ============================================
   RESPONSIVE - Tablet
   ============================================ */

@media (max-width: 1200px) {
  .resources__content {
    padding: 0 40px;
  }
  
  .resources__grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 1024px) {
  .resources {
    padding: 60px 0;
  }
  
  .resources__grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
  }
}

/* ============================================
   RESPONSIVE - Mobile
   ============================================ */

@media (max-width: 768px) {
  .resources {
    padding: 40px 0;
  }
  
  .resources__content {
    padding: 0 20px;
    gap: 24px;
  }
  
  .resources__grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }
  
  .post-card {
    min-width: 0;
  }
}

