/* ========== Header Styles ========== */
header {
  width: 100%;
  position: absolute;
  top: 0;
  display: flex;
  z-index: 1000;
  padding: 22px 0;
  align-items: center;
  background: #222e39;
  justify-content: space-between;
  border-top: solid #30404e;
}

.logo {
    margin-left: 10%;
}
.logo img {
  height: 65px;
  /* width: 215px; */
  margin-top: -15px;
  margin-bottom: -15px;
  vertical-align: text-top;
}

.logo img:hover {
  transform: scale(1.02);
}

.logo a {
  text-decoration: none;
  font-size: 24px;
  font-weight: bold;
  color: #3498db;
}

/* Navbar desktop */
.navbar {
  display: flex;
  gap: 25px;
  justify-content: center;
  align-items: center;
  flex: 1;
  flex-wrap: wrap;
}

.navbar a {
  text-decoration: none;
  color: #fff;
  font-weight: 500;
  transition: color 0.3s ease;
}

.navbar a:hover {
  color: #3498db;
}

.menu-toggle {
  width: 30px;
  height: 25px;
  cursor: pointer;
  position: relative;
  z-index: 1001;
  display: flex;
  margin-right: 25px;
  flex-direction: column;
  justify-content: space-between;
}

.menu-toggle span {
  display: block;
  height: 3px;
  background: #fff;
  border-radius: 2px;
  transition: 0.4s;
}

/* عند تفعيل القائمة */
.menu-toggle.open span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}

.menu-toggle.open span:nth-child(2) {
  opacity: 0;
}

.menu-toggle.open span:nth-child(3) {
  transform: rotate(-45deg) translate(6px, -6px);
}

/* إخفاء زر الهامبرغر في الشاشات الكبيرة */
.menu-toggle {
  display: none;
}

/* إظهاره فقط في الشاشات الصغيرة */
@media (max-width: 768px) {
  .menu-toggle {
    display: flex;
  }
  .navbar {
    flex-direction: column;
    position: absolute;
    top: 65px; /* Adjust depending on header height */
    left: 0;
    width: 100%;
    background: #222e39;
    overflow: hidden;
    max-height: 0;
    transition: max-height 0.4s ease;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
  }

  .navbar.open {
    max-height: 400px; /* Adjust to fit all menu items */
  }

  .navbar a {
    padding: 15px 20px;
    border-bottom: 1px solid #eee;
  }
}
.navbar a.active {
  padding: 7px 25px;
  font-weight: bold;
  background: #30404e;
  border-top-right-radius: 10px;
  border-bottom: 2px solid #ffff;
}
.subscribe-btn {
  margin-right: 10%;
}

.subscribe-now {
  color: white;
  padding: 10px 20px;
  border-radius: 6px;
  text-decoration: none;
  background-color: #30404e;  
  transition: background 0.3s;
}

.subscribe-now:hover {
  background-color: #30404eba;
}

/* إخفاء الزر في الهاتف */
@media (max-width: 768px) {
  .subscribe-btn {
    display: none;
  }
}