/* ===== Main ===== */
main {
  background-color: #32353a; /* رمادي صلب خلف كل المحتوى */
}

/* ===== Map Container ===== */
#map-container {
  position: relative;
  width: 100%;
  height: 100vh;
  overflow: hidden;
}

#map-slider {
  width: 100%;
  height: 100%;
  position: relative;
}

.map {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-size: cover;
  background-position: top center;
  background-repeat: no-repeat;
  opacity: 1; /* تظهر مباشرة */
  transform: scale(1);
  animation: mapZoom 10s infinite alternate; /* مجرد زوم لو تحبي */
}

@keyframes mapZoom {
  0% { transform: scale(1); }
  100% { transform: scale(1.5); }
}

/* ===== بطاقة الترحيب ===== */
.welcome-wrapper {
  position: absolute;
  top: 45%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 90%;
  max-width: 720px;
  padding: 22px;
  background: rgba(95, 59, 1, 0.65);
  border-radius: 18px;
  text-align: center;
  color: #fff7e6;
  direction: rtl; /* من اليمين إلى اليسار */
  font-family: 'Cairo', 'Amiri', 'Tajawal', sans-serif; /* خط عربي جميل */
  z-index: 10; /* فوق الخريطة */
}

.welcome-text {
  margin: 0 0 12px;
  font-size: 2rem;
}

.welcome-subtext {
  margin: 0 0 10px;
  font-size: 1.2rem;
  line-height: 1.6;
}

/* ===== الدوائر ===== */
.circle {
 width: 100px;
  aspect-ratio: 1 / 1;
  border-radius: 50%;
  background: radial-gradient(circle at 30% 30%, #f6c77b, #6f4c14);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  color: #000;
  font-weight: bold;
  cursor: pointer;
  box-shadow: 0 6px 14px rgba(0,0,0,0.25);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.circle img {
  width: 34px;
}

.circle:hover {
  transform: translateY(-6px);
  box-shadow: 0 10px 18px rgba(0,0,0,0.35);
}

/* ===== الدوائر الجانبية Desktop ===== */
.circle-left,
.circle-right {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  flex-direction: column;
  gap: 40px;
  z-index: 5;
}

.circle-left { left: 30px; }
.circle-right { right: 30px; }

/* ===== الدوائر للهواتف ===== */
.circle-mobile {
  display: none; /* يتم تفعيله في Media Query */
  flex-direction: column;
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  gap: 10px;
  z-index: 15; /* فوق البطاقة */
}

.circle-mobile .circle {
  width: 60px;
  height: 60px;
}

.circle-mobile .circle img { width: 25px; height: 25px; }
.circle-mobile .circle span { font-size: 14px; text-align: center; }

/* ===== Social Media ===== */
.social-trigger {
  position: relative;
  z-index: 40; /* فوق كل شيء */
  margin-top: 10px; /* مسافة داخل البطاقة */
  cursor: pointer;
}

.social-menu {
  position: absolute;
  top: 50%;
  right: 120%;
  transform: translateY(-50%) scale(0.8);
  display: flex;
  gap: 12px;
  opacity: 0;
  pointer-events: none;
  transition: all 0.25s ease;
  z-index: 40; /* فوق البطاقة */
}

.social-trigger:hover .social-menu,
.social-trigger.active .social-menu {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(-50%) scale(1);
}

.social-circle {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background: radial-gradient(circle at 20% 20%, #9f9f9f, #32353a);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 12px rgba(0,0,0,0.25);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.social-circle img {
  width: 30px;
  height: 30px;
}

.social-circle:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 16px rgba(0,0,0,0.35);
}

/* ===== النص التنبيهي ===== */
.site-notice-wrapper {
  position: relative;   /* نقدر نخليه fixed لو حبيتي يثبت فوق الصفحة */
  z-index: 1000;        /* أعلى من كل العناصر الأخرى */
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  direction: rtl;
  unicode-bidi: embed;
  font-family: 'Cairo', 'Amiri', 'Tajawal', sans-serif;
  border: 2px solid #c18a32;
  border-radius: 12px;
  padding: 16px 24px;
  margin: 20px auto;
  max-width: 960px;
  box-sizing: border-box;
  color: #fff7e6;
  font-size: 1rem;
  line-height: 1.5;
  background-color: rgba(50, 53, 58, 0.85); /* خلفية شفافة لتبرز النص فوق الخريطة */
}

.site-notice-wrapper p {
  margin: 6px 0;
}

.site-notice-wrapper a {
  color: #ffd780;
  text-decoration: underline;
}

.site-attribution {
  font-size: 0.75rem;
  margin-top: 12px;
  color: #fff7e6;
  text-align: center;
}

/* ===== الاحصاء ===== */
#stats {
  width: 100%;
  background-color: #c18a3228;
  color: #fff7e6;
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 20px;
  padding: 8px 0;
  font-weight: 0.3;
  font-size: 1rem;
  text-align: center;
  direction: rtl; /* من اليمين إلى اليسار */
  unicode-bidi: embed; /* لضمان عرض النص العربي بشكل صحيح */
  font-family: 'Cairo', 'Amiri', 'Tajawal', sans-serif; /* خط عربي جميل */
}

#stats p {
  display: flex;
  align-items: center;
  gap: 6px;
  margin: 0;
  white-space: normal;
  word-break: break-word;
}

#stats img.icon-color {
  width: 28px;
  height: 28px;
  filter: invert(50%) sepia(100%) saturate(500%) hue-rotate(180deg);
}

/* ===== Media Queries ===== */

/* الهاتف */
@media (max-width: 768px) {

  #map-container { height: 70vh; min-height: 400px; }

  .welcome-wrapper {
    width: 65%;
    left: 40%;
    top: 50%;
    
    transform: translate(-50%, -50%);
    padding: 16px 18px;
    z-index: 15;
  }
  .welcome-text {
  margin: 0 0 12px;
  font-size: 1.5rem;
}

.welcome-subtext {
  margin: 0 0 10px;
  font-size: 1rem;
  line-height: 1.6;
}

  .site-notice-wrapper {
    width: 90%;           /* يقلل العرض ليترك هامش على الجانبين */
    padding: 12px 16px;   /* padding أصغر للهاتف */
    margin: 12px auto;    /* هامش أعلى وأسفل ويترك مسافة على الجانبين */
    box-sizing: border-box; /* لضمان أن padding لا يزيد العرض */
  }

  .circle-left, .circle-right { display: none; }

  .circle-mobile {
    display: flex;
    flex-direction: column; /* عمودي */
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    gap: 10px;
    z-index: 1000; /* مهم جداً */
  }

  .circle-mobile .circle {
    width: 60px;
    height: 60px;
    position: relative;
    z-index: 1000; /* كل دائرة فوق البطاقة */
  }

  .circle-mobile .social-trigger {
    z-index: 1100; /* فوق البطاقة */
  }

  /* السوشيال ميديا في آخر زر عمودياً فوق البطاقة */
  .circle-mobile .social-menu {
    top: -200%;          
    left: -100%;          
    transform: translateX(-50%);
    flex-direction: column; /* عمودي */
    gap: 10px;
    opacity: 0;
    pointer-events: none;
    transition: all 0.3s ease;
    z-index: 1200; /* أعلى شيء */
  }

  .circle-mobile .social-trigger.active .social-menu {
    opacity: 1;
    pointer-events: auto;
  }
}

/* iPad */
@media (max-width: 1024px) and (min-width: 769px) {
  .welcome-wrapper {
    width: 55%;
    max-width: 700px;
    padding: 20px 24px;
    z-index: 15;
  }
}
