/* ===== العناوين ===== */
.section-label {
  max-width: 1000px;
  margin: 15px auto 8px;
  padding: 0 10px;
  font-size: 16px;
  font-weight: bold;
}

/* =========================
   📸 معرض الصور
========================= */

.gallery-container {
  max-width: 100%;
  margin: 0;
  padding: 0px;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-template-rows: 220px;
  gap: 8px;
}

.main-img {
  grid-row: unset;
  grid-column: unset;
}

.gallery-grid a {
  position: relative;
  overflow: hidden;
  cursor: pointer;
  border-radius: 12px;
  display: block;
}

.gallery-grid a,
.video-grid a {
  text-decoration: none;
  color: inherit;
  border: none;
  outline: none;
}

.gallery-grid img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  cursor: pointer;
  transition: 0.3s;
  display: block;
}

.gallery-grid img:hover {
  transform: scale(1.05);
}

.show-all {
  position: absolute;
  bottom: 10px;
  left: 10px;
  background: rgba(0,0,0,0.6);
  color: #fff;
  padding: 6px 10px;
  border-radius: 8px;
  font-size: 13px;
}

.hidden-img {
  display: none;
}

/* =========================
   🎥 قسم الفيديو (طولي)
========================= */

.video-section {
  max-width: 1000px;
  width: 100%;
  margin: auto;
  padding: 10px;
  box-sizing: border-box;
}

/* شبكة الفيديو */
.video-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  max-width: 600px;
  margin: 0 0 0 auto;
}

/* عنصر الفيديو */
.video-grid a {
  position: relative;
  width: 100%;
  aspect-ratio: 9 / 16;
  overflow: hidden;
  border-radius: 12px;
  display: block;
}

.video-grid img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  cursor: pointer;
  transition: 0.3s;
  display: block;
}

.video-grid img:hover {
  transform: scale(1.05);
}

.video-icon {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 50px;
  height: 50px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0,0,0,0.6);
  color: #fff;
  font-size: 20px;
  pointer-events: none;
  transition: 0.3s;
}

.video-grid a:hover .video-icon {
  transform: translate(-50%, -50%) scale(1.1);
}

/* =========================
   🧩 PhotoSwipe إصلاحات
========================= */

.pswp {
  z-index: 999999 !important;
}

.pswp__top-bar {
  direction: ltr;
}

/* =========================
   📱 موبايل
========================= */

@media (max-width: 768px) {

  .gallery-container {
    max-width: 100%;
    margin: 0;
    padding: 0 8px;
  }

  .gallery-grid {
    grid-template-columns: repeat(2, 1fr);
    grid-template-rows: 160px 160px;
  }

  .main-img {
    grid-column: unset;
    grid-row: unset;
  }

  .video-grid {
    grid-template-columns: 1fr 1fr;
    margin: 0 auto;
  }
}

/* =========================
   🖥️ شاشات متوسطة
========================= */

@media (max-width: 1300px) {
  .video-section {
    max-width: 540px;
    margin-left: auto;
    margin-right: 0;
  }
}

@media (max-width: 1100px) {
  .video-section {
    max-width: 480px;
  }
}

@media (max-width: 900px) {
  .video-section {
    max-width: 430px;
  }
}