/* ============================================================
   مدونة دبرلي — تصميم فيغما (node 183:3706)
   كل القواعد مقيَّدة بـ.blog-v2 حتى لا تتسرّب لبقية الصفحات.
   ============================================================ */

.blog-v2 {
  --bv-teal: #089497;
  --bv-teal-fig: #07959a;
  --bv-navy: #00162a;
  --bv-body: #43474d;
  --bv-muted: #73777e;
  --bv-line: #c3c6ce;
  --bv-radius: 12px;
}

.blog-v2 .bv-wrap {
  width: min(100% - 32px, 1280px);
  margin-inline: auto;
  padding: 48px 0 40px;
}

/* ── الترويسة ───────────────────────────────────────────── */
.blog-v2 .bv-head { margin-bottom: 48px; }

.blog-v2 .bv-head h1 {
  margin: 0;
  color: var(--bv-teal-fig);
  font-size: clamp(30px, 4vw, 48px);
  line-height: 1.25;
  font-weight: 700;
}

.blog-v2 .bv-head p {
  margin: 16px 0 0;
  max-width: 672px;
  color: var(--bv-body);
  font-size: clamp(15px, 1.4vw, 18px);
  line-height: 1.55;
}

/* ── شريط البحث والتصفية ────────────────────────────────── */
.blog-v2 .bv-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
  padding: 24px 0;
  margin-bottom: 48px;
}

.blog-v2 .bv-search {
  position: relative;
  width: min(100%, 384px);
  flex: 0 1 384px;
}

.blog-v2 .bv-search input {
  width: 100%;
  padding: 15px 17px 15px 49px;
  border: 1px solid var(--bv-line);
  border-radius: 8px;
  background: #fff;
  font-family: inherit;
  font-size: 16px;
  color: var(--bv-navy);
  outline: none;
}

.blog-v2 .bv-search input::placeholder { color: #6b7280; }
.blog-v2 .bv-search input:focus { border-color: var(--bv-teal); }

/* الأيقونة على يسار الحقل كما في التصميم (RTL) */
.blog-v2 .bv-search button {
  position: absolute;
  inset-inline-start: 16px;
  top: 50%;
  transform: translateY(-50%);
  width: 18px;
  height: 18px;
  padding: 0;
  border: 0;
  background: none;
  color: var(--bv-muted);
  font-size: 16px;
  cursor: pointer;
  line-height: 1;
}

.blog-v2 .bv-pills {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  overflow-x: auto;
}

.blog-v2 .bv-pill {
  padding: 9px 25px;
  border: 1px solid var(--bv-line);
  border-radius: 8px;
  background: #fff;
  color: var(--bv-body);
  font-size: 16px;
  line-height: 24px;
  text-decoration: none;
  white-space: nowrap;
  transition: .2s;
}

.blog-v2 .bv-pill:hover { border-color: var(--bv-teal); color: var(--bv-teal); }

.blog-v2 .bv-pill.is-active {
  background: var(--bv-teal-fig);
  border-color: var(--bv-teal-fig);
  color: #fff;
}

/* ── شبكة البنتو ────────────────────────────────────────── */
.blog-v2 .bv-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

.blog-v2 .bv-card {
  display: flex;
  flex-direction: column;
  background: #fff;
  border-radius: var(--bv-radius);
  overflow: hidden;
  box-shadow: 0 1px 2px rgba(0, 0, 0, .05);
  text-decoration: none;
  color: inherit;
  transition: transform .25s, box-shadow .25s;
}

.blog-v2 .bv-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, .09);
}

.blog-v2 .bv-card__media {
  height: 192px;
  overflow: hidden;
  background: #edeeef;
  flex: none;
}

.blog-v2 .bv-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* الشريط الملوّن على حافة البطاقة — يمين في RTL */
.blog-v2 .bv-card__body {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 24px;
  border-inline-end: 4px solid var(--bv-accent, var(--bv-teal));
}

.blog-v2 .bv-cat {
  color: var(--bv-accent, var(--bv-teal));
  font-size: 16px;
  line-height: 24px;
}

.blog-v2 .bv-card__body h3 {
  margin: 0;
  color: var(--bv-navy);
  font-size: 20px;
  line-height: 1.25;
  font-weight: 600;
}

.blog-v2 .bv-card__body p {
  margin: 0;
  color: var(--bv-body);
  font-size: 14px;
  line-height: 20px;
}

.blog-v2 .bv-foot {
  margin-top: auto;
  padding-top: 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  color: var(--bv-muted);
  font-size: 12px;
  letter-spacing: .6px;
}

/* ── البطاقة المميّزة (عمودان × صفّان) ───────────────────── */
.blog-v2 .bv-feature { grid-column: span 2; grid-row: span 2; position: relative; }
.blog-v2 .bv-feature .bv-card__media { height: 544px; }
.blog-v2 .bv-feature .bv-card__body { padding: 32px; gap: 8px; }
.blog-v2 .bv-feature .bv-card__body h3 { font-size: 24px; line-height: 32px; }
.blog-v2 .bv-feature .bv-card__body p { font-size: 16px; line-height: 24px; }

.blog-v2 .bv-badge {
  position: absolute;
  top: 12px;
  inset-inline-end: 16px;
  padding: 3.5px 12px;
  border-radius: 9999px;
  background: #f97316;
  color: #fff;
  font-size: 12px;
  line-height: 16px;
  font-weight: 700;
  letter-spacing: .6px;
}

.blog-v2 .bv-meta {
  display: flex;
  gap: 8px;
  align-items: center;
  color: var(--bv-muted);
  font-size: 16px;
  line-height: 24px;
}

/* ── البطاقة العريضة الداكنة ────────────────────────────── */
.blog-v2 .bv-wide {
  grid-column: span 2;
  display: grid;
  grid-template-columns: 1fr 1fr;
  background: var(--bv-navy);
  border-radius: var(--bv-radius);
  overflow: hidden;
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, .1), 0 4px 6px -4px rgba(0, 0, 0, .1);
  text-decoration: none;
  transition: transform .25s;
}

.blog-v2 .bv-wide:hover { transform: translateY(-3px); }

.blog-v2 .bv-wide__media { overflow: hidden; opacity: .8; }
.blog-v2 .bv-wide__media img { width: 100%; height: 100%; object-fit: cover; display: block; }

.blog-v2 .bv-wide__body {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 32px;
}

.blog-v2 .bv-wide__kicker {
  color: #ffddb8;
  font-size: 16px;
  line-height: 24px;
  letter-spacing: .8px;
  margin-bottom: 8px;
}

.blog-v2 .bv-wide__body h3 {
  margin: 0 0 16px;
  color: #fff;
  font-size: 24px;
  line-height: 32px;
  font-weight: 600;
}

.blog-v2 .bv-wide__body p {
  margin: 0 0 24px;
  color: #aec9ea;
  font-size: 16px;
  line-height: 24px;
}

.blog-v2 .bv-wide__link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #78f6f1;
  font-size: 16px;
  line-height: 24px;
}

/* ── بطاقة النصيحة السريعة ──────────────────────────────── */
.blog-v2 .bv-tip {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: 24px;
  background: #fff;
  border-top: 4px solid #10b981;
  border-radius: var(--bv-radius);
  box-shadow: 0 1px 2px rgba(0, 0, 0, .05);
  text-decoration: none;
  color: inherit;
  transition: transform .25s;
}

.blog-v2 .bv-tip:hover { transform: translateY(-3px); }

.blog-v2 .bv-tip__head {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  color: #10b981;
  font-size: 16px;
  line-height: 24px;
}

.blog-v2 .bv-tip__icon {
  width: 40px;
  height: 40px;
  border-radius: 9999px;
  background: #e7e8e9;
  display: grid;
  place-items: center;
  color: #10b981;
  font-size: 18px;
  flex: none;
}

.blog-v2 .bv-tip h3 {
  margin: 0;
  color: var(--bv-navy);
  font-size: 20px;
  line-height: 28px;
  font-weight: 600;
}

.blog-v2 .bv-tip p { margin: 0; color: var(--bv-body); font-size: 16px; line-height: 24px; }

.blog-v2 .bv-tip__foot {
  margin-top: auto;
  padding-top: 17px;
  border-top: 1px solid var(--bv-line);
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: var(--bv-muted);
  font-size: 12px;
  line-height: 16px;
  letter-spacing: .6px;
  font-weight: 700;
}

/* ── النشرة البريدية ────────────────────────────────────── */
.blog-v2 .bv-news {
  position: relative;
  width: min(100%, 1005px);
  margin: 48px auto 0;
  padding: 32px;
  border-radius: 16px;
  background: var(--bv-teal);
  overflow: hidden;
}

/* الهالتان الضبابيتان في الزاويتين */
.blog-v2 .bv-news::before,
.blog-v2 .bv-news::after {
  content: '';
  position: absolute;
  width: 128px;
  height: 128px;
  border-radius: 9999px;
  filter: blur(32px);
  pointer-events: none;
}

.blog-v2 .bv-news::before { top: -48px; inset-inline-end: -64px; background: rgba(120, 246, 241, .2); }
.blog-v2 .bv-news::after { bottom: -64px; inset-inline-start: -64px; background: rgba(0, 22, 42, .1); }

.blog-v2 .bv-news__inner { position: relative; z-index: 1; max-width: 576px; margin-inline: auto; text-align: center; }

.blog-v2 .bv-news h2 {
  margin: 0 0 16px;
  color: #fff;
  font-size: 24px;
  line-height: 32px;
  font-weight: 600;
}

.blog-v2 .bv-news p { margin: 0; color: #ccc3d8; font-size: 16px; line-height: 24px; }

.blog-v2 .bv-news form {
  display: flex;
  gap: 16px;
  margin-top: 32px;
  flex-wrap: wrap;
}

.blog-v2 .bv-news input {
  flex: 1;
  min-width: 200px;
  padding: 14px 24px;
  border: 0;
  border-radius: 8px;
  background: #fff;
  font-family: inherit;
  font-size: 16px;
  outline: none;
  box-shadow: 0 1px 2px rgba(0, 0, 0, .05);
}

.blog-v2 .bv-news button {
  flex: none;
  min-width: 157px;
  padding: 12px 24px;
  border: 0;
  border-radius: 12px;
  background: #0f2b4b;
  color: #fff;
  font-family: inherit;
  font-size: 14px;
  line-height: 20px;
  font-weight: 700;
  cursor: pointer;
  transition: .2s;
}

.blog-v2 .bv-news button:hover { background: #143a63; }

/* ── حالة الفراغ والترقيم ───────────────────────────────── */
.blog-v2 .bv-empty {
  grid-column: 1 / -1;
  padding: 60px 20px;
  text-align: center;
  color: var(--bv-muted);
  background: #fff;
  border-radius: var(--bv-radius);
}

.blog-v2 .bv-pagination { margin-top: 32px; display: flex; justify-content: center; }

/* ── الاستجابة ──────────────────────────────────────────── */
@media (max-width: 1100px) {
  .blog-v2 .bv-grid { grid-template-columns: repeat(2, 1fr); }
  .blog-v2 .bv-feature { grid-column: span 2; grid-row: auto; }
  .blog-v2 .bv-feature .bv-card__media { height: 320px; }
  .blog-v2 .bv-wide { grid-column: span 2; }
}

@media (max-width: 720px) {
  .blog-v2 .bv-wrap { width: min(100% - 24px, 1280px); padding: 32px 0; }
  .blog-v2 .bv-head { margin-bottom: 28px; }
  .blog-v2 .bv-bar { padding: 0 0 8px; margin-bottom: 28px; gap: 14px; }
  .blog-v2 .bv-search { flex: 1 1 100%; width: 100%; }
  .blog-v2 .bv-grid { grid-template-columns: 1fr; }
  .blog-v2 .bv-feature,
  .blog-v2 .bv-wide { grid-column: auto; }
  .blog-v2 .bv-wide { grid-template-columns: 1fr; }
  .blog-v2 .bv-wide__media { height: 200px; }
  .blog-v2 .bv-feature .bv-card__media { height: 240px; }
  .blog-v2 .bv-news { padding: 24px; }
  .blog-v2 .bv-news button { width: 100%; }
}
