html {
  height: 100%;
}
body {
  font-family: Arial, sans-serif;
  direction: rtl;
  margin: 0;
  padding: 0;
  background: #f9f9f9;
  color: #333;
  min-height: 100%;
  display: flex;
  flex-direction: column;
}
header {
  background: #005baa;
  color: white;
  padding: 20px;
  text-align: center;
}
main {
  padding: 20px;
  max-width: 800px;
  margin: auto;
  flex: 1;
}
section {
  margin-bottom: 30px;
}
footer {
  background: #eee;
  text-align: center;
  padding: 10px;
  font-size: 0.9em;
}

/* Navigation Styles */
.main-nav {
  width: 100%;
}

.main-menu {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  background-color: #005baa;
}

.main-menu > li {
  margin: 0;
  position: relative; /* Needed for absolute positioning of sub-menu */
}

.main-menu > li > a {
  color: white;
  text-decoration: none;
  font-weight: bold;
  padding: 15px 20px;
  display: block;
}

.submenu-toggle {
  cursor: pointer;
}

.submenu-toggle::after {
  content: ' ▼';
  font-size: 0.7em;
  display: inline-block;
  margin-right: 5px;
}

/* Sub-menu styles */
.sub-menu {
  display: none;
  position: absolute;
  background-color: #f1f1f1;
  min-width: 200px;
  box-shadow: 0px 8px 16px 0px rgba(0,0,0,0.2);
  z-index: 1;
  list-style: none;
  padding: 0;
  margin: 0;
  border-radius: 0 0 5px 5px;
}

.sub-menu.show {
  display: block;
}

.sub-menu li a {
  color: black;
  padding: 12px 16px;
  text-decoration: none;
  display: block;
  text-align: right;
}

.sub-menu li a:hover {
  background-color: #ddd;
}

/* Mobile Navigation */
.hamburger {
  display: none; /* Hidden by default on larger screens */
  background: none;
  border: none;
  color: white;
  font-size: 2em;
  cursor: pointer;
  padding: 10px;
  position: absolute;
  top: 10px;
  left: 10px;
  z-index: 1000;
}

@media (max-width: 768px) {
  .hamburger {
    display: block; /* Show hamburger on small screens */
  }

  .main-menu {
    display: none; /* Hide menu by default on small screens */
    flex-direction: column;
    width: 100%;
    position: absolute;
    top: 0;
    left: 0;
    background-color: #005baa;
    padding-top: 60px; /* Space for hamburger */
  }

  body.menu-open .main-menu {
    display: flex; /* Show menu when menu-open class is active */
  }

  .main-menu > li {
    width: 100%;
    text-align: center;
  }

  .main-menu > li > a {
    padding: 10px 20px;
  }

  .sub-menu {
    position: static; /* Submenu flows naturally */
    width: 100%;
    background-color: #f1f1f1;
    box-shadow: none;
    border-radius: 0;
  }

  .sub-menu li a {
    text-align: center;
  }
}

.social-media {
  margin-top: 10px;
}

.social-media a {
  color: #333;
  margin: 0 10px;
  font-size: 24px;
  text-decoration: none;
}

.social-media a:hover {
  color: #005baa;
}