* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Poppins", sans-serif;
}

body {
  background-color: #2f2d2d;
  color: #fff;
  overflow-x: hidden;
}

.he {
  position: relative;
  width: 100%;
  height: 200px;
  background-image: url("img/mm.jpg");
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  padding: 20px 0;
  z-index: 0;
}

.he::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.05);
  z-index: 1;
}

.he>* {
  position: relative;
  z-index: 3;
}

nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px 80px;
  position: relative;
  z-index: 5;
}

.hero img {
  height: 60px;
}

.nav-link {
  display: flex;
  list-style: none;
  gap: 25px;
  transition: all 0.4s ease;
}

.nav-link a,
.explore-toggle {
  color: #fff;
  text-decoration: none;
  font-weight: 500;
  transition: 0.3s;
  background: none;
  border: none;
  cursor: pointer;
  font-size: 16px;
}

.nav-link a:hover,
.explore-toggle:hover {
  color: #00ff9d;
}

.hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  cursor: pointer;
  gap: 5px;
  z-index: 3;
}

.hamburger span {
  width: 25px;
  height: 3px;
  background: #05c79a;
  border-radius: 3px;
  transition: 0.4s;
}

.hamburger.active span:nth-child(1) {
  transform: rotate(45deg) translateY(8px);
}

.hamburger.active span:nth-child(2) {
  opacity: 0;
}

.hamburger.active span:nth-child(3) {
  transform: rotate(-45deg) translateY(-8px);
}

.explore-window {
  position: absolute;
  top: 70px;
  right: 80px;
  background: rgba(0, 0, 0, 0.85);
  border-radius: 10px;
  padding: 10px 20px;
  width: 180px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
  transition: all 0.3s ease;
  z-index: 20;
}

.hidden {
  display: none;
}

.explore-window h3 {
  margin-bottom: 10px;
  color: #00ff9d;
  font-size: 18px;
}

.explore-window ul {
  list-style: none;
}

.explore-window a {
  color: #fff;
  text-decoration: none;
  display: block;
  padding: 5px 0;
  transition: color 0.3s;
}

.explore-window a:hover {
  color: #00ff9d;
}

nav,
.hero,
.hamburger {
  position: relative;
  z-index: 10;
}

.search {
  position: absolute;
  top: 65%;
  left: 50%;
  transform: translate(-50%, -50%);
  display: flex;
  align-items: center;
  background: rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(10px);
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.25);
  width: 500px;
  max-width: 90%;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
  z-index: 2;
  pointer-events: all;
}

.search:hover {
  background: rgba(255, 255, 255, 0.25);
}

.search input {
  flex: 1;
  border: none;
  background: transparent;
  padding: 14px 18px;
  font-size: 16px;
  color: #fff;
  outline: none;
  z-index: 16;
  position: relative;
}

.search-btn,
.clear-btn {
  background: none;
  border: none;
  color: #fff;
  padding: 12px 15px;
  cursor: pointer;
}

.search-btn svg {
  width: 30px;
  height: 15px;
  fill: currentColor;
}

@media (max-width: 768px) {
  header.ho {
    min-height: 140px;
    padding-top: 25px;
    padding-bottom: 25px;
  }

  nav {
    padding: 15px 20px;
    z-index: 5;
  }

  .hamburger {
    display: flex;
    z-index: 6;
  }

  .nav-link {
    flex-direction: column;
    position: absolute;
    top: 80px;
    right: 15px;
    background: rgba(0, 0, 0, 0.9);
    width: 180px;
    border-radius: 10px;
    overflow: hidden;
    max-height: 0;
    opacity: 0;
    transition: all 0.4s ease;
    z-index: 7;
  }

  .nav-link.active {
    padding: 10px 0;
    max-height: 300px;
    opacity: 1;
  }

  .search {
    top: 75%;
    width: 85%;
    z-index: 2;
  }

  .search-box {
    margin-top: 50px;
  }

  .nav-link a,
  .explore-toggle {
    color: white;
    padding: 10px;
    text-align: center;
    transition: background 0.3s ease;
  }

  .nav-link a:hover,
  header {
    min-height: 150px;
  }
}

.search input {
  pointer-events: all;
}

.search input:focus {
  background: rgba(255, 255, 255, 0.2);
  border-radius: 12px;
  transition: all 0.4s ease;
}

.search:focus-within {
  transform: translate(-50%, -50%) scale(1.03);
  border-color: rgba(0, 255, 157, 0.6);
  box-shadow: 0 0 20px rgba(0, 255, 157, 0.3);
  background: rgba(255, 255, 255, 0.25);
}

.search-btn {
  position: relative;
  transition: all 0.3s ease;
}

.search-btn::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 60%;
  width: 0;
  height: 1px;
  background: #00ff9d;
  transition: all 0.3s ease;
  transform: translateX(-50%);
  opacity: 0;
}

.search-btn:hover {
  color: #00ff9d;
  transform: scale(1.3);
}

.search-btn:hover::after {
  width: 30%;
  opacity: 1;
}

.search {
  transform-origin: center;
  animation: fadeSlideIn 0.6s ease both;
}

@keyframes fadeSlideIn {
  from {
    opacity: 0;
    transform: translate(-50%, -60%) scale(0.95);
  }

  to {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
  }
}

.search:focus-within {
  animation: pulseGlow 0.6s ease-in-out;
}

@keyframes pulseGlow {
  0% {
    box-shadow: 0 0 0 rgba(0, 255, 157, 0);
  }

  50% {
    box-shadow: 0 0 25px rgba(0, 255, 157, 0.4);
  }

  100% {
    box-shadow: 0 0 0 rgba(0, 255, 157, 0);
  }
}

/*

*/

.gallery {
  padding: 40px 10px;
  background-color: #0a0a0a;
}

.gallery-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 20px;
  max-width: 1200px;
  margin: auto;
}

.gallery-item {
  position: relative;
  overflow: hidden;
  border-radius: 15px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.6);
  transition: transform 0.3s ease;
}

.gallery-item:hover {
  transform: scale(1.05);
}

.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.download-btn {
  position: absolute;
  bottom: 10px;
  right: 10px;
  background: rgba(254, 254, 254, 0.112);
  color: #00ffcc;
  border: 2px solid rgba(255, 255, 255, 0);
  width: 38px;
  height: 38px;
  border-radius: 50%;
  display: flex;
  justify-content: center;
  align-items: center;
  text-decoration: none;
  font-size: 18px;
  transition: all 0.3s ease;
  opacity: 0;
  visibility: hidden;
}

.gallery-item:hover .download-btn {
  opacity: 1;
  visibility: visible;
}

.download-btn:hover {
  background: rgba(0, 255, 157, 0.3);
  transform: scale(1.1);
}

.gallery h2 {
  text-align: center;
  margin-top: 45px;
  color: #00ff9d;
  font-weight: 600;
  font-size: 26px;
  letter-spacing: 1px;
}

/* ✅ يظهر زر التحميل دايمًا على الموبايل */
@media (max-width: 768px) {
  .gallery-item .download-btn {
    opacity: 1 !important;
    visibility: visible !important;
    /* ← كان مخفي فده ضروري */
    pointer-events: auto !important;
    /* ← عشان يقدر المستخدم يضغط عليه */
  }
}


/* 📱 تحسين للهواتف */
@media (max-width: 600px) {
  #scrollTopBtn {
    width: 50px;
    height: 50px;
    font-size: 22px;
    right: 20px;
    bottom: 25px;
  }
}

/* 📱 عرض الموبايل */
@media (max-width: 768px) {
  .gallery-container {
    grid-template-columns: repeat(3, 1fr);
    /* 4 صور في الصف الواحد */
    gap: 8px;
    /* مسافة بسيطة بينهم */
  }

  .gallery-item img {
    width: 100%;
    border-radius: 6px;
  }
}

/* 📱 لو الشاشة صغيرة جدًا (موبايل صغير) */
@media (max-width: 480px) {
  .gallery-container {
    grid-template-columns: repeat(2, 1fr);
    /* يخليها 3 صور بدل 4 عشان المساحة */
    gap: 8px;
  }
}

.visually-hidden {
  position: absolute !important;
  height: 1px;
  width: 1px;
  overflow: hidden;
  clip: rect(1px, 1px, 1px, 1px);
  white-space: nowrap;
}

/* ============================
   🔝 زر الرجوع للأعلى الاحترافي
   ============================ */
#scrollTopBtn {
  position: fixed;
  bottom: 35px;
  right: 35px;
  z-index: 10000;
  width: 60px;
  height: 60px;
  border: none;
  border-radius: 15px;
  background: linear-gradient(135deg, #00ffcc, #0077ff);
  color: #fff;
  font-size: 26px;
  font-weight: bold;
  cursor: pointer;
  display: none;
  justify-content: center;
  align-items: center;
  transition: all 0.3s ease;
  box-shadow: 0 0 20px rgba(0, 255, 204, 0.5), 0 0 40px rgba(0, 119, 255, 0.3);
}

/* ✨ تأثير السهم */
#scrollTopBtn .arrow {
  position: relative;
  top: 0;
  animation: floatUp 1s infinite alternate;
}

@keyframes floatUp {
  0% {
    top: 3px;
  }

  100% {
    top: -3px;
  }
}

/* 💫 تأثير عند المرور */
#scrollTopBtn:hover {
  transform: translateY(-5px) scale(1.05);
  box-shadow: 0 0 30px rgba(0, 255, 204, 0.7), 0 0 60px rgba(0, 119, 255, 0.5);
  background: linear-gradient(135deg, #00ccff, #00ff88);
}

.site-footer {
  background: #070707;
  color: #bfc7c5;
  border-top: 1px solid rgba(255, 255, 255, 0.03);
  padding: 24px 16px;
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial;
}

.footer-inner {
  display: flex;
  gap: 20px;
  align-items: center;
  justify-content: space-between;
  max-width: 1200px;
  margin: 0 auto;
  flex-wrap: wrap;
}

.footer-brand {
  display: flex;
  gap: 12px;
  align-items: center;
}

.footer-brand img {
  border-radius: 6px;
  display: block;
}

.brand-text strong {
  display: block;
  color: #fff;
  font-size: 16px;
}

.brand-text small {
  color: #9aa7a3;
  font-size: 12px;
}

.footer-nav {
  display: flex;
  gap: 12px;
  align-items: center;
  flex-wrap: wrap;
}

.footer-nav a {
  color: #bfc7c5;
  text-decoration: none;
  font-size: 14px;
  padding: 6px 8px;
  border-radius: 6px;
  transition: background .15s, color .15s;
}

.footer-nav a:hover {
  background: rgba(255, 255, 255, 0.03);
  color: #fff;
}

.footer-social {
  display: flex;
  gap: 10px;
  align-items: center;
}

.footer-social a {
  color: #bfc7c5;
  display: inline-flex;
  padding: 6px;
  border-radius: 6px;
  transition: background .15s, color .15s;
}

.footer-social a:hover {
  background: rgba(255, 255, 255, 0.03);
  color: #fff;
}

.footer-meta {
  text-align: center;
  margin-top: 16px;
  color: #9aa7a3;
  font-size: 13px;
  max-width: 1200px;
  margin-left: auto;
  margin-right: auto;
}

.footer-meta .small {
  margin-top: 6px;
  font-size: 12px;
  color: #8b9b98;
}

.footer-meta a {
  color: #bfc7c5;
  text-decoration: underline;
  text-underline-offset: 3px;
}

@media (max-width:640px) {
  .footer-inner {
    flex-direction: column;
    align-items: flex-start;
  }

  .footer-nav {
    order: 3;
    width: 100%;
  }

  .footer-social {
    order: 2;
  }

  .footer-brand {
    order: 1;
  }

  .footer-meta {
    text-align: left;
  }
}

/* ===== قسم الوصف النصي ===== */
.page-description {
  background-color: #000;
  /* الخلفية سوداء */
  color: #fff;
  /* لون النص أبيض */
  /* min-height: 100vh;             يغطي طول الشاشة */
  display: flex;
  /* علشان نقدر نوسّط المحتوى */
  flex-direction: column;
  /* يخلي النص تحت العنوان */
  justify-content: center;
  /* محاذاة عمودية في المنتصف */
  align-items: center;
  /* محاذاة أفقية في المنتصف */
  text-align: center;
  /* توسيط النصوص */
  padding: 40px 20px;
  /* مسافة داخلية مناسبة */
}

/* ===== العنوان داخل القسم ===== */
.page-description h1 {
  font-size: 2.5rem;
  margin-bottom: 15px;
  color: #00ffcc;
  /* لون مميز للعناوين */
}

/* ===== النص داخل القسم ===== */
.page-description p {
  font-size: 1.2rem;
  line-height: 1.7;
  max-width: 700px;
  /* عرض النص ما يزيدش عن 700px */
  color: #ccc;
}

/* أنيميشن نزول لطيف */
@keyframes slideDownFade {
  0% {
    opacity: 0;
    transform: translateY(-20px);
  }

  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

.gallery-item {
  opacity: 0;
  transform: translateY(-20px);
  transition: all 3s ease;
}

.gallery-item.visible {
  animation: slideDownFade 5s ease forwards;
}

.quote {
  display: inline-block;
  background: rgba(255, 255, 255, 0.05);
  border-left: 3px solid #00ff9d;
  /* خط جانبي أنيق */
  color: #e0e0e0;
  font-style: italic;
  font-size: 0.9rem;
  line-height: 1.6;
  padding: 6px 10px;
  margin: 8px 0;
  border-radius: 8px;
  text-align: left;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.25);
  max-width: 420px;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.quote:hover {
  transform: translateY(-3px);
  box-shadow: 0 4px 10px rgba(0, 255, 157, 0.15);
}

.quote {
  opacity: 0;
  transform: translateY(10px);
  animation: fadeSlideUp 0.8s ease forwards;
}

@keyframes fadeSlideUp {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
.category-bar {
  display: flex;
  align-items: center;
  gap: 16px;
  overflow-x: auto;
  padding: 10px 24px;
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  scrollbar-width: none;
  margin: 0;           /* 🔹 فراغ بسيط فوق وتحت */
  height: 110px;           /* 🔹 ارتفاع مريح */
  background: transparent; /* 🔹 بدون خلفية سوداء */
}

.category-bar::-webkit-scrollbar {
  display: none;
}

/* ==== العناصر داخل الشريط ==== */
.category-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  flex-shrink: 0;
  cursor: pointer;
  text-align: center;
  transition: transform 0.25s ease;
  padding: 0;
  text-decoration: none;  /* 🔹 إزالة الخط الأزرق */
}

.category-item:hover {
  transform: scale(1.1);
}

/* إزالة الخط الأزرق من النص داخل الرابط */
.category-item:link,
.category-item:visited {
  text-decoration: none;
}

/* ==== الصور ==== */
.category-item img {
  width: 78px;
  height: 78px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid #00ffc3;
  box-shadow: 0 0 10px rgba(0, 255, 195, 0.4);
  transition: all 0.3s ease;
}

.category-item:hover img {
  border-color: #fff;
  box-shadow: 0 0 12px rgba(255, 255, 255, 0.5);
}

/* ==== النص ==== */
.category-item span {
  margin-top: 5px;
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  white-space: nowrap;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.6);
  line-height: 1;
}
/* 📱 تنسيق خاص بالموبايل */
@media (max-width: 768px) {
  .category-bar {
    gap: 10px;
    padding: 0;
    height: 100px; /* 🔹 أنحف قليلاً للموبايل */
  }

  .category-item img {
    width: 68px;
    height: 68px;
    border-width: 1.5px; /* 🔹 حدود أخف */
  }

  .category-item span {
    font-size: 12px;
    margin-top: 4px;
  }
}

/* 📱 شاشات صغيرة جدًا (أقل من 480px) */
@media (max-width: 480px) {
  .category-bar {
    gap: 8px;
    padding: 0;
    height: 100px;
  }

  .category-item img {
    width: 60px;
    height: 60px;
  }

  .category-item span {
    font-size: 11px;
  }
}
