/* =============================================================
 * گپیار — استایل حرفه‌ای بلاگ و آرشیو (۳ ستونه با تصویر شاخص)
 * ============================================================= */

/* ── محیط لیست (۲۰px فاصله از هدر) ── */
.gpy-blog-wrap {
  max-width: 1200px;
  margin: 0 auto;
  padding: 20px clamp(1rem, 4vw, 2rem) clamp(2.5rem, 6vw, 4rem);
}

/* عنوان سبک برای آرشیو/جست‌وجو (بدون بنر تیره) */
.gpy-blog-headline { margin-bottom: clamp(1.25rem, 3vw, 2rem); }
.gpy-blog-headline h1 {
  font-size: clamp(1.5rem, 3.5vw, 2.2rem);
  font-weight: 900;
  margin: 0;
  color: #14233b;
}
.gpy-blog-headline h1 span { color: #e05520; }
.gpy-blog-headline-desc { margin-top: 0.5rem; color: #66718a; line-height: 1.9; }

/* ── شبکه ۳ ستونه ── */
.gpy-posts-grid {
  display: grid;
  gap: clamp(1.1rem, 2.5vw, 1.75rem);
  grid-template-columns: 1fr;
}
@media (min-width: 600px) { .gpy-posts-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 992px) { .gpy-posts-grid { grid-template-columns: repeat(3, 1fr); } }

/* ── کارت نوشته ── */
.gpy-card {
  position: relative;
  display: flex;
  flex-direction: column;
  background: #fff;
  border: 1px solid #eef1f6;
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(14, 28, 48, 0.07);
  transition: transform 0.4s cubic-bezier(0.22,1,0.36,1), box-shadow 0.4s, border-color 0.4s;
}
.gpy-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 22px 48px rgba(14, 28, 48, 0.16);
  border-color: rgba(255,107,44,0.35);
}

.gpy-card-thumb {
  position: relative;
  display: block;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: linear-gradient(150deg, #1e3d62, #0e1c30);
}
.gpy-card-thumb img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform 0.6s cubic-bezier(0.22,1,0.36,1);
}
.gpy-card:hover .gpy-card-thumb img { transform: scale(1.06); }

/* جای‌گزین تصویر شاخص (وقتی نوشته تصویر ندارد) */
.gpy-card-thumb--ph {
  display: grid;
  place-items: center;
}
.gpy-card-thumb--ph::before {
  content: "";
  position: absolute; inset: 0;
  background:
    radial-gradient(circle at 75% 20%, rgba(255,107,44,0.4), transparent 45%),
    radial-gradient(circle at 20% 85%, rgba(74,158,255,0.18), transparent 40%);
}
.gpy-card-thumb--ph span {
  position: relative;
  font-size: 2.6rem;
  font-weight: 900;
  color: rgba(255,255,255,0.92);
  letter-spacing: 0.04em;
}

/* برچسب دسته روی تصویر */
.gpy-card-cat {
  position: absolute;
  top: 0.85rem; right: 0.85rem;
  z-index: 2;
  display: inline-block;
  padding: 0.32rem 0.8rem;
  font-size: 0.72rem;
  font-weight: 800;
  color: #fff;
  background: rgba(255, 107, 44, 0.92);
  border-radius: 999px;
  backdrop-filter: blur(4px);
  box-shadow: 0 6px 16px rgba(255,107,44,0.35);
}

.gpy-card-body {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  padding: 1.15rem 1.3rem 1.4rem;
  flex: 1;
}
.gpy-card-meta {
  display: flex; align-items: center; gap: 0.5rem;
  font-size: 0.76rem; color: #8a93a3;
}
.gpy-card-meta svg { width: 14px; height: 14px; color: #ff6b2c; }
.gpy-card-body h3 {
  font-size: 1.1rem;
  line-height: 1.5;
  margin: 0;
  color: #14233b;
}
.gpy-card-body h3 a { color: inherit; transition: color 0.25s; }
.gpy-card-body h3 a:hover { color: #e05520; }
.gpy-card-excerpt {
  font-size: 0.86rem;
  color: #66718a;
  line-height: 1.85;
  margin: 0;
  flex: 1;
}
.gpy-card-more {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.82rem;
  font-weight: 800;
  color: #e05520;
  margin-top: 0.35rem;
}
.gpy-card-more svg { width: 16px; height: 16px; transition: transform 0.3s; }
.gpy-card:hover .gpy-card-more svg { transform: translateX(-4px); }

/* ── برگه‌بندی ── */
.gpy-pagination { margin-top: clamp(2rem, 5vw, 3rem); text-align: center; }
.gpy-pagination .nav-links { display: inline-flex; flex-wrap: wrap; gap: 0.4rem; justify-content: center; }
.gpy-pagination .page-numbers {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 42px; height: 42px; padding: 0 0.6rem;
  border-radius: 12px;
  background: #f1f4f9;
  color: #14233b;
  font-weight: 700;
  transition: background 0.25s, color 0.25s, transform 0.25s;
}
.gpy-pagination .page-numbers:hover { transform: translateY(-2px); background: #e7ecf4; }
.gpy-pagination .page-numbers.current {
  background: linear-gradient(135deg, #ff6b2c, #e05520);
  color: #fff;
  box-shadow: 0 8px 20px rgba(255,107,44,0.35);
}

/* ── حالت خالی ── */
.gpy-no-results {
  max-width: 620px;
  margin: 0 auto;
  text-align: center;
  background: #fff;
  border: 1px solid #eef1f6;
  border-radius: 20px;
  padding: clamp(2rem, 5vw, 3rem);
  box-shadow: 0 10px 30px rgba(14,28,48,0.06);
}
.gpy-no-results .gpy-entry-title { margin-bottom: 0.5rem; }
.gpy-no-results p { color: #66718a; margin-bottom: 1.25rem; }
