/* === Reset & Global Styles === */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Poppins', sans-serif;
  background: #0d0d2b; /* خلفية داكنة */
  color: #fff;
}

/* === Bubbles Background === */
.bubble-bg {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  pointer-events: none;
  z-index: -1;
}
.bubble {
  position: absolute;
  bottom: -100px;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 50%;
  animation: rise 20s infinite linear;
  will-change: transform, opacity;
}
.bubble:nth-child(1) { width: 40px; height: 40px; left: 10%; animation-duration: 18s; }
.bubble:nth-child(2) { width: 60px; height: 60px; left: 30%; animation-duration: 22s; animation-delay: 2s; }
.bubble:nth-child(3) { width: 30px; height: 30px; left: 50%; animation-duration: 16s; animation-delay: 4s; }
.bubble:nth-child(4) { width: 50px; height: 50px; left: 70%; animation-duration: 20s; animation-delay: 1s; }
.bubble:nth-child(5) { width: 45px; height: 45px; left: 85%; animation-duration: 25s; animation-delay: 3s; }

@keyframes rise {
  0%   { transform: translateY(0) scale(0.8); opacity: 0.8; }
  100% { transform: translateY(-120vh) scale(1.2); opacity: 0; }
}

/* === Header with Glass Effect === */
.site-header {
  position: relative;
  min-height: 180px;
  background: none; /* شفاف لتظهر الفقاعات تحته */
  overflow: hidden;
}
.header-overlay {
  position: relative;
  width: 100%;
  height: 100%;
  /* تأثير الزجاج */
  backdrop-filter: saturate(150%) blur(10px);
  background-color: rgba(13, 13, 43, 0.4); /* طبقة شبه شفافة (يمكن تعديلها) */
}
.site-title {
  font-size: 2.3rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  color: #fff;
  text-shadow: 0 2px 6px rgba(0,0,0,0.3);
}
.site-subtitle {
  font-size: 1rem;
  color: #f0f0f0;
  opacity: 0.9;
}

/* حقل البحث بالهيدر */
.input-group-lg .form-control {
  border-radius: 0.5rem 0 0 0.5rem;
  border: none;
  box-shadow: none;
  background-color: rgba(255, 255, 255, 0.8);
  color: #333;
}
.input-group-lg .input-group-text {
  border: none;
  background-color: rgba(255, 255, 255, 0.8);
  border-radius: 0 0.5rem 0.5rem 0;
  box-shadow: none;
}
.searchIcon path {
  fill: #333;
}

/* === Footer === */
.site-footer {
  background: #1b1b3a; 
  text-align: center;
}
/* رابط zappr.org */
.zappr-link {
  color: #fff;
  text-decoration: underline;
}
.zappr-link:hover {
  color: #9d4edd;
}

/* === Main Container === */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 40px 20px;
}

/* === فاصل بين قسم المميز والقسم العادي === */
.section-divider {
  width: 100%;
  text-align: center;
  position: relative;
  margin: 40px 0; 
}
.section-divider .divider-text {
  display: inline-block;
  font-size: 1.25rem;
  background: #0d0d2b; /* نفس لون خلفية الموقع */
  padding: 0 10px;
  color: #9d4edd;
  letter-spacing: 1px;
  position: relative;
}
.section-divider::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 5%;
  right: 5%;
  height: 2px;
  background: #444;
  transform: translateY(-50%);
  z-index: -1;
}

/* === Cards Container === */
.cards-container {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
  justify-items: center;
}

/* === Card Design === */
.card {
  position: relative; 
  width: 100%;
  max-width: 190px;
  margin: 0 auto;
  background: #7209b7;
  border-radius: 15px;
  box-shadow: 1px 5px 60px 0px rgba(16, 10, 136, 0.42);
  cursor: pointer;
  transition: transform 0.3s ease;
}
.card:hover {
  transform: scale(1.05);
}
.card .card-border-top {
  width: 60%;
  height: 3%;
  margin: auto;
  background: #9d4edd;
  border-radius: 0 0 15px 15px;
}
.card .img {
  width: 70px;
  height: 80px;
  margin: 25px auto 0;
  border-radius: 15px;
  background: #9d4edd center/cover no-repeat;
}
.card-body {
  padding: 10px;
}
.card span.fw-semibold {
  display: block;
  padding-top: 10px;
  font-size: 16px;
  font-weight: 600;
  color: #fff;
  text-align: center;
}
.card .job {
  display: block;
  padding-top: 3px;
  font-size: 12px;
  font-weight: 400;
  color: #fff;
  text-align: center;
}
.card button {
  display: block;
  margin: 20px auto 0;
  padding: 8px 25px;
  border: none;
  border-radius: 8px;
  background: #9d4edd;
  color: #fff;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.3s ease;
}
.card button:hover {
  background: #7400b8;
}

/* بطاقات المميزة (Featured) */
.featured-card {
  border: 2px solid #ffd700;
}

/* === شريط الشارة (Ribbon) === */
.card-ribbon {
  position: absolute;
  top: 10px;
  left: -20px;
  width: 80px;
  height: 22px;
  font-weight: 600;
  text-align: center;
  line-height: 22px;
  transform: rotate(-45deg) scale(0.9);
  box-shadow: 0 3px 6px rgba(0,0,0,0.3);
  color: #fff;
}
.card-ribbon::before,
.card-ribbon::after {
  content: "";
  position: absolute;
  bottom: -6px; 
  border-top: 6px solid transparent;
  border-bottom: 0 solid transparent;
}
.card-ribbon::before {
  left: 0;
  border-left: 10px solid rgba(0,0,0,0.15); 
  border-right: 10px solid transparent;
}
.card-ribbon::after {
  right: 0;
  border-right: 10px solid rgba(0,0,0,0.15);
  border-left: 10px solid transparent;
}

/* ألوان مختلفة للشارات */
.ribbon-mod {
  background: linear-gradient(45deg, #76dd76 0%, #2fa52f 100%); 
}
.ribbon-new {
  background: linear-gradient(45deg, #4acfff 0%, #006bb3 100%);
}
.ribbon-hot {
  background: linear-gradient(45deg, #ff5c5c 0%, #cc0000 100%);
}
.ribbon-sale {
  background: linear-gradient(45deg, #ff9bbb 0%, #ff6397 100%);
}
.ribbon-default {
  background: linear-gradient(45deg, #ffcf40 0%, #ffac00 100%);
  color: #000;
}

/* === Carousel Featured Cards - أكبر للتمييز === */
.featured-carousel-card {
  max-width: 250px;
  margin-bottom: 20px;
}

/* === تأثير ثلاثي الأبعاد للعنوان (#header) === */
#header {
  display: inline-block;
  font-size: 3rem;
  font-weight: 700;
  background: linear-gradient(90deg, #ff8e53, #fe6b8b);
  -webkit-background-clip: text;
  color: transparent;
  transform-origin: top center;
  perspective: 1000px;
  margin: 20px 0;
  text-shadow: 0 4px 6px rgba(0, 0, 0, 0.3);
}
#header span {
  display: inline-block;
  opacity: 0;
}

/* تحسينات بسيطة للهواتف */
@media (max-width: 576px) {
  .site-title {
    font-size: 2rem;
  }
  .site-subtitle {
    font-size: 0.9rem;
  }
  .cards-container {
    gap: 15px;
  }
  .card, .featured-carousel-card {
    max-width: 160px; 
  }
}
