/* =========================================
    NEWS / POSTS ARCHIVE
    ========================================= */

.posts-archive {
  max-width: 1400px;
  margin: 0 auto;
  padding: 80px 40px 100px;
}

/* Grid */

.posts-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  column-gap: 28px;
  row-gap: 64px;
}

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

.post-card {
  min-width: 0;
}

.post-image {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  border-radius: 16px;
  background: #f1f1f1;
  margin-bottom: 22px;
}

.post-image picture { display: block; width: 100%; height: 100%; }

.post-image img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s cubic-bezier(0.2, 0.65, 0.3, 1);
}

.post-card:hover .post-image img {
  transform: scale(1.035);
}

.post-card .post-title a {
    text-decoration: none;
    background-image: linear-gradient(currentColor, currentColor);
    background-repeat: no-repeat;
    background-position: left bottom;
    background-size: 0% 1px;
    transition: background-size 0.3s ease;
}

.post-card:hover .post-title a {
    background-size: 100% 1px;
}


/* =========================================
   POST CONTENT
   ========================================= */

.post-content {
  display: flex;
  flex-direction: column;
}

.post-date {
  margin-bottom: 10px;

  font-size: 13px;
  line-height: 1.2;
  font-weight: 400;
  letter-spacing: 0.02em;
  color: #777;
}

.post-title {
  margin: 0 0 14px;

  font-size: 25px;
  line-height: 1.12;
  font-weight: 500;
  letter-spacing: -0.035em;
}

.post-title a {
  color: #111;
  text-decoration: none;
  transition: opacity 0.25s ease;
}



/* =========================================
   EXCERPT
   ========================================= */

.post-excerpt {
  max-width: 520px;

  font-size: 16px;
  line-height: 1.5;
  font-weight: 400;
  color: #555;
}

.post-excerpt p {
  margin: 0;
}

/* =========================================
   PAGINATION
   ========================================= */

.posts-archive .page-numbers {
  display: inline-flex;
  align-items: center;
  justify-content: center;

  min-width: 44px;
  height: 44px;
  padding: 0 14px;

  border-radius: 999px;

  background: #f3f3f3;
  color: #111;

  text-decoration: none;

  font-size: 14px;
  line-height: 1;

  transition:
    background-color 0.25s ease,
    color 0.25s ease,
    transform 0.25s ease;
}

.posts-archive .page-numbers:hover {
  background: #111;
  color: #fff;
  transform: translateY(-2px);
}

.posts-archive .page-numbers.current {
  background: #111;
  color: #fff;
}

.posts-archive .nav-links {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 80px;
}

.pagination-posts {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 30px;
}

/* =========================================
   TABLET
   ========================================= */

@media (max-width: 1100px) {
  .posts-archive {
    padding: 64px 32px 80px;
  }

  .posts-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    column-gap: 24px;
    row-gap: 52px;
  }

  .post-title {
    font-size: 23px;
  }
}

/* =========================================
   MOBILE
   ========================================= */

@media (max-width: 700px) {
  .posts-archive {
    padding: 48px 20px 64px;
  }

  .posts-grid {
    grid-template-columns: 1fr;
    row-gap: 48px;
  }

  .post-image {
    border-radius: 12px;
    margin-bottom: 18px;
  }

  .post-date {
    margin-bottom: 8px;
    font-size: 12px;
  }

  .post-title {
    margin-bottom: 10px;
    font-size: 22px;
    line-height: 1.16;
  }

  .post-excerpt {
    font-size: 15px;
    line-height: 1.5;
  }

  .posts-archive .nav-links {
    margin-top: 56px;
    gap: 6px;
  }

  .posts-archive .page-numbers {
    min-width: 40px;
    height: 40px;
    padding: 0 11px;
  }
}

/* =========================================
   SMALL MOBILE
   ========================================= */

@media (max-width: 420px) {
  .posts-archive {
    padding-left: 16px;
    padding-right: 16px;
  }

  .posts-grid {
    row-gap: 40px;
  }

  .post-image {
    border-radius: 10px;
  }

  .post-title {
    font-size: 20px;
  }
}
