/* right_side.css */

/* ── Featured Ads sidebar wrapper ─────────────────────── */
.search-featured {
  min-width: 15%;
}

.search-featured h2 {
  font-size: 0.95rem;
  font-weight: 700;
  color: #1a1a1a;
  margin: 0 0 14px;
  padding-bottom: 10px;
  border-bottom: 2px solid #e5e7eb;
}

/* ── Featured ad cards ────────────────────────────────── */
.latest-ads {
  display: grid;
  gap: 12px;
  grid-template-columns: 1fr;
}

.latest-ad {
  border-radius: 10px;
  border: 1px solid #e5e7eb;
  background: #fff;
  overflow: hidden;
  transition: box-shadow 0.18s, border-color 0.18s, transform 0.15s;
}

.latest-ad:hover {
  box-shadow: 0 4px 16px rgba(85, 107, 47, 0.14);
  border-color: #a8c060;
  transform: translateY(-2px);
}

.latest-ad a {
  color: inherit;
  text-decoration: none;
  display: flex;
  flex-direction: column;
}

/* Image */
.latest-ad .latest-ad-img-wrap {
  aspect-ratio: 4 / 3;
  background: #f3f4f6;
  overflow: hidden;
}

.latest-ad img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.2s;
  border-radius: 0;
  margin: 0;
  max-width: none;
  max-height: none;
}

.latest-ad:hover img {
  transform: scale(1.04);
}

/* Body */
.latest-ad-body {
  padding: 9px 11px 10px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
  overflow: hidden;
}

.latest-ad .latest-title {
  font-size: 0.82rem;
  font-weight: 600;
  color: #1a1a1a;
  line-height: 1.35;
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.latest-ad .latest-price {
  font-size: 0.85rem;
  font-weight: 700;
  color: #3d5020;
  margin: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.latest-ad .latest-transaction {
  font-size: 0.72rem;
  color: #6b7280;
  margin: 0;
  text-transform: capitalize;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.latest-ad .latest-username {
  font-size: 0.72rem;
  color: #9ca3af;
  margin: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* ── Pagination ───────────────────────────────────────── */
.pagination {
  text-align: center;
  margin-top: 20px;
}

.pagination .page-link {
  display: inline-block;
  padding: 8px 12px;
  margin: 0 4px;
  border: 1px solid #ccc;
  border-radius: 4px;
  text-decoration: none;
  color: inherit;
  transition: background-color 0.3s;
}

.pagination .page-link.active,
.pagination .page-link:hover {
  background-color: var(--primary-color);
  color: var(--secondary-color);
}

/* ── Misc ─────────────────────────────────────────────── */
.prize-draw-list {
  display: grid;
  gap: 15px;
  grid-template-columns: 1fr;
}

.left-column h2 {
  text-align: center;
}

/* ── Responsive ───────────────────────────────────────── */
@media (max-width: 1200px) {
  .latest-ads {
    grid-template-columns: repeat(2, 1fr);
  }

  .search-featured {
    order: 2;
    width: 100%;
  }
}

@media (max-width: 768px) {
  .latest-ads {
    grid-template-columns: repeat(1, 1fr);
  }
}
