/* =============================================================
   library-blogs-block.css — Bluworks
   Blog article grid with category chips + pagination.
   ============================================================= */

.blogs-tight-top {
  padding-top: var(--s-7) !important;
  background: var(--bg);
}

section.section.blogs-tight-top {
  padding-bottom: var(--s-10);
}

.blogs-tight-top .container {
  width: 100%;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 var(--gutter);
  box-sizing: border-box;
}

/* ── Section heading ──────────────────────────────────────── */
.blogs-tight-top .bg-section-head {
  text-align: center;
  margin-bottom: var(--s-6);
}

.blogs-tight-top .bg-section-head h2 {
  font-family: var(--font-display);
  font-size: clamp(28px, 3.4vw, 44px);
  font-weight: 600;
  letter-spacing: -0.015em;
  color: var(--ink);
  margin: 0;
}

/* ── Category chips ───────────────────────────────────────── */
.blogs-tight-top .bg-cats-inline {
  margin-bottom: var(--s-7);
}

.blogs-tight-top .bg-cats {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-2);
  justify-content: center;
}

.blogs-tight-top .bg-cat {
  padding: 8px 18px;
  background: var(--blu-soft);
  border: 1px solid transparent;
  border-radius: var(--r-full);
  color: var(--blu-primary);
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: background var(--dur) var(--ease),
              color var(--dur) var(--ease),
              border-color var(--dur) var(--ease);
}

.blogs-tight-top .bg-cat:hover {
  background: var(--blu-primary);
  border-color: var(--blu-primary);
  color: #fff;
}

.blogs-tight-top .bg-cat.is-active {
  background: var(--blu-primary);
  border-color: var(--blu-primary);
  color: #fff;
}

/* ── Article grid: 3 columns ──────────────────────────────── */
.blogs-tight-top .bg-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--s-4);
}

@media (max-width: 920px) {
  .blogs-tight-top .bg-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 600px) {
  .blogs-tight-top .bg-grid { grid-template-columns: 1fr; }
}

/* Pagination: hide cards not on current page */
/* ── Article card ─────────────────────────────────────────── */
.blogs-tight-top .bg-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-3);
  padding: var(--s-6);
  display: flex;
  flex-direction: column;
  text-decoration: none;
  color: inherit;
  position: relative;
  transition: border-color var(--dur) var(--ease),
              box-shadow var(--dur) var(--ease),
              transform var(--dur) var(--ease);
}

.blogs-tight-top .bg-card:hover {
  border-color: var(--blu-light);
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.blogs-tight-top .bg-card h3 {
  font-family: var(--font-display);
  font-size: var(--t-h3);
  font-weight: 600;
  margin: 0 0 var(--s-3);
  color: var(--ink);
  letter-spacing: -0.01em;
  line-height: 1.3;
}

.blogs-tight-top .bg-card p {
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 500;
  color: var(--ink-mid);
  line-height: 1.55;
  margin: 0;
  flex-grow: 1;
}

/* ── .bg-meta: date left, arrow right — same row ─────────── */
.blogs-tight-top .bg-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: var(--s-6);
  font-size: 14px;
  color: var(--ink-muted);
}

/* ── Arrow badge — inline inside .bg-meta ─────────────────── */
.blogs-tight-top .card-arrow-btn {
  /* Override any Kadence position/shape overrides */
  position: static !important;
  inset: auto !important;
  width: 32px !important;
  height: 32px !important;
  border-radius: var(--r-2) !important;      /* 8px — rounded rect, NOT circle */
  background: var(--blu-soft) !important;    /* #EEF3FF */
  color: var(--blu-primary) !important;
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  pointer-events: none;
  transition: background var(--dur) var(--ease),
              color var(--dur) var(--ease),
              transform var(--dur) var(--ease);
}

.blogs-tight-top .card-arrow-btn svg {
  width: 15px;
  height: 15px;
  display: block;
}

.blogs-tight-top .bg-card:hover .card-arrow-btn {
  background: var(--blu-primary) !important;
  color: #fff !important;
  transform: translateX(3px);
}

/* ── RTL: flip the arrow to point left, and nudge the other way on hover ── */
html[dir="rtl"] .blogs-tight-top .card-arrow-btn svg {
  transform: scaleX(-1);
}

html[dir="rtl"] .blogs-tight-top .bg-card:hover .card-arrow-btn {
  transform: translateX(-3px);
}

/* ── Pagination ───────────────────────────────────────────── */
.blogs-tight-top .bg-pagination-dots {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: var(--s-2);
  margin-top: var(--s-7);
}

.blogs-tight-top .bg-page {
  width: 36px;
  height: 36px;
  border-radius: var(--r-2);
  border: 1px solid var(--line);
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 14px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: background 180ms var(--ease),
              border-color 180ms var(--ease),
              color 180ms var(--ease);
}

.blogs-tight-top .bg-page:hover {
  border-color: var(--blu-primary);
  color: var(--blu-primary);
}

.blogs-tight-top .bg-page.is-active {
  background: var(--blu-primary);
  color: #fff;
  border-color: var(--blu-primary);
}

/* ── Reduced motion ───────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  .blogs-tight-top .bg-cat,
  .blogs-tight-top .bg-card,
  .blogs-tight-top .bg-page { transition: none; }
  .blogs-tight-top .bg-card:hover { transform: none; }
  .blogs-tight-top .bg-card:hover .card-arrow-btn { transform: none; }
}


@media screen and (max-width: 767px) {
.blogs-tight-top .bg-card h3{
font-size:16px;}


}
/* ── Arabic RTL font override (auto) ────────────────────────────── */
html[dir="rtl"] .blogs-tight-top .bg-section-head h2,
html[dir="rtl"] .blogs-tight-top .bg-cat,
html[dir="rtl"] .blogs-tight-top .bg-card h3,
html[dir="rtl"] .blogs-tight-top .bg-card p,
html[dir="rtl"] .blogs-tight-top .bg-page {
  font-family: 'Noto Sans Arabic', 'Segoe UI', sans-serif !important;
}