/**
 * Navigation fix for Sohob Solutions website
 * Ensures desktop navigation displays correctly
 */

/* Force desktop navigation to display horizontally */
@media (min-width: 1024px) {
  #mobile-menu-2 ul {
    display: flex;
    flex-direction: row !important;
  }
  
  #mobile-menu-2 > ul > li {
    margin-right: 0; /* Remove extra spacing */
  }
  
  #mobile-menu-2 a,
  #mobile-menu-2 button {
    border-bottom: none;
    padding: 0;
    font-size: 16px;
    color: #4B5563;
  }
  
  /* Products dropdown styling */
  #products-dropdown {
    margin-top: 0.5rem;
    min-width: 200px;
    left: 0;
  }
  
  /* Dropdown wrapper positioning */
  .dropdown-wrapper {
    position: relative;
  }
}

/* Ensure mobile menu stays vertical on small screens */
@media (max-width: 1023px) {
  #mobile-menu-2 ul {
    flex-direction: column !important;
  }
  
  /* Mobile dropdown styling */
  #products-dropdown {
    margin-left: 1rem;
    width: 100%;
    box-shadow: none;
    position: static;
  }
  
  #products-dropdown-button {
    width: 100%;
    display: flex;
    justify-content: space-between;
  }
}

/* Common dropdown styles */
#products-dropdown-button {
  cursor: pointer;
  display: inline-flex;
  align-items: center;
}

/* Dropdown menu styling */
#products-dropdown {
  border-radius: 0.5rem;
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
  margin-top: 0.5rem;
  width: 180px;
}

#products-dropdown .divide-y > a {
  border-bottom-width: 1px;
  border-color: #E5E7EB;
}

#products-dropdown .divide-y > a:last-child {
  border-bottom: none;
}

#products-dropdown a {
  transition: background-color 0.2s ease;
  font-size: 15px;
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  display: block;
  width: 100%;
  text-align: left;
  color: #4B5563;
  white-space: nowrap !important;
  overflow: visible;
  line-height: 1.25;
}

#products-dropdown a:hover {
  background-color: #F3F4F6;
}

/* Mobile dropdown adjustments */
@media (max-width: 1023px) {
  #products-dropdown {
    position: static !important;
    width: 100% !important;
    box-shadow: none !important;
    margin-left: 1rem !important;
  }
}

/* Active states */
.active-tab[aria-selected="true"] {
  color: #2563EB;
}

/* Dropdown arrow animation */
#products-dropdown-button svg {
  transition: transform 0.2s ease;
}

#products-dropdown-button[aria-expanded="true"] svg {
  transform: rotate(180deg);
}
