/* Reset */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: 'Segoe UI', sans-serif;
}
a {
  text-decoration: none;
  color: #111;
}
ul {
  list-style: none;
}

/* Header */
.adv-header {
  background: #e5f2f9; /* Dark navy from SaasTargo */
  color: #181818;
  position: sticky;
  top: 0;
  z-index: 9999999;
}
.adv-header-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 20px;
  flex-wrap: wrap;
}

/* Logo */
.adv-logo img {
  height: 50px;
}

/* Navigation */
.adv-nav {
  flex: 1;
  margin-left: 40px;
}
.adv-menu {
  display: flex;
  gap: 20px;
  align-items: center;
  flex-wrap: wrap;
}
.adv-menu > li {
  position: relative;
}
.adv-menu > li > a {
  padding: 10px 15px;
  display: flex;
  align-items: center;
  gap: 5px;
  color: #1e1e1e;
  font-weight: 600;
  font-size: 1.05rem;
  letter-spacing: 0.02em;
  transition: color 0.3s ease;
}
.adv-menu > li > a:hover {
  color: #194479; /* SaasTargo accent pink/red */
}

/* Submenu - default column layout */
.adv-submenu {
  display: none;
  position: absolute;
  top: 100%;
  left: 50%; /* Center horizontally */
  transform: translateX(-50%); /* Shift to the left half of its width */
  background: #ffffff;
  color: #273347;
  padding: 20px;
  gap: 15px;
  border-radius: 12px;
  box-shadow: 0 12px 32px rgba(15, 32, 88, 0.15);
  min-width: 250px;
  max-width: 90vw; /* Prevent overflow of viewport */
  overflow-x: auto; /* Scroll horizontally if too wide */
  z-index: 999999;
  flex-direction: column; /* Default column */
  flex-wrap: nowrap;
  box-sizing: border-box;
}


/* Mega menus with multiple submenu cards in row */
.adv-submenu.adv-row {
  min-width: 500px;
  flex-direction: row;
  flex-wrap: nowrap;
  max-width: 90vw; /* Also limit max-width here */
}




.adv-sub-card {
 
  padding: 15px;
  border-radius: 8px;
  transition: 0.3s;
  width: 100%;
  box-sizing: border-box;
  
}

/* For mega menu cards, set fixed width to allow row layout */
.adv-submenu.adv-row .adv-sub-card {
  width: 220px; /* fixed width for horizontal layout */
  
}

.adv-sub-card:hover {
  
  color: #194479;
}
.adv-sub-card a {
  display: block;
  margin: 10px 0;
  color: #273347;
  font-weight: 500;
  font-size: 1em;
  transition: color 0.2s ease;
}
.adv-sub-card a:hover {
  color: #194479;
  font-weight: 700;
}

/* Submenu heading with icon */
.adv-sub-card h4 {
  font-weight: 700;
  font-size: 1.2rem;
  color: #0a1a37;
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 15px;
  text-transform: uppercase;
}
.adv-sub-card h4 i {
  color: #194479; /* Accent pink/red */
  font-size: 1.5rem;
  flex-shrink: 0;
}

/* Show submenu on hover or active */
.adv-has-sub:hover .adv-submenu,
.adv-has-sub.active .adv-submenu {
  display: flex;
}

/* Contact Button */
.adv-contact-btn a {
  background: #194479;
  color: #fff;
  font-weight: 700;
  padding: 8px 20px;
  border-radius: 30px;
  transition: background 0.3s ease;
  font-size: 1rem;
}
.adv-contact-btn a:hover {
  background: #e26c0c;
}

/* Mobile Menu */
.adv-menu-toggle {
  display: none;
  flex-direction: column;
  cursor: pointer;
  gap: 5px;
}
.adv-menu-toggle span {
  width: 25px;
  height: 3px;
  background: #fff;
  border-radius: 2px;
  transition: 0.3s;
}

.top-contact-bar{
  display: flex; 
  justify-content: space-between; 
  align-items: center; 
  background-color: #0a1a37; /* Match your header dark navy background */ 
  padding: 8px 20px; 
  font-size: 0.9rem; 
  color: #f7f6f6;


}

.top-contact-info span,
.top-contact-info a 
{ color: #f7f6f6; 
  font-weight: 500; 
} 
.top-contact-info a:hover { 
  text-decoration: underline; 
} 
.top-social-links a { 
  color: #f7f6f6; 
  margin-left: 12px; 
  font-size: 1.1rem; 
  text-decoration: none; 
  transition: color 0.3s ease; } 
.top-social-links a:hover { color: #ff5a5f; /* Accent color */ }


/* ================================
   FINAL MOBILE FIXES (ADD LAST)
   ================================ */
@media (max-width: 1024px) {

  /* Simplify top bar */
  .top-contact-bar {
    flex-direction: column;
    align-items: flex-start;
    font-size: 0.85rem;
    gap: 5px;
  }

  /* Header layout */
  .adv-header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    position: relative;
  }

  /* Logo resize */
  .adv-logo img {
    height: 45px;
    width: auto;
  }

  /* Hide contact button on mobile */
  .adv-contact-btn {
    display: none;
  }

  /* Menu container */
  .adv-nav {
    width: 100%;
  }

  /* Menu hidden by default */
  .adv-menu {
    display: none;
    flex-direction: column;
    width: 100%;
    background: #ffffff;
    border-top: 1px solid #ddd;
    position: absolute;
    top: 100%;
    left: 0;
    z-index: 9999999;
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
  }

  /* Show when active */
  .adv-menu.active {
    display: flex;
  }

  /* Menu items */
  .adv-menu > li {
    width: 100%;
    border-bottom: 1px solid #eee;
  }

  .adv-menu > li > a {
    padding: 14px 18px;
    font-size: 1rem;
    color: #222;
    font-weight: 600;
    justify-content: space-between;
  }

  /* Submenus stacked and hidden by default */
  .adv-submenu {
    display: none;
    position: relative;
    background: #f9f9f9;
    box-shadow: none;
    padding: 0 18px 10px;
    border-top: 1px solid #eee;
  }

  /* Show submenu when active */
  .adv-submenu.active {
    display: flex;
    flex-direction: column;
  }

  .adv-sub-card {
    padding: 10px 0;
  }

  .adv-sub-card a {
    padding: 6px 0;
    font-size: 0.95rem;
    color: #333;
  }

  /* Make mega menu single column */
  .adv-submenu.adv-row {
    flex-direction: column !important;
  }

  /* Hamburger icon styling */
  .adv-menu-toggle {
    display: flex !important;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    cursor: pointer;
  }

  .adv-menu-toggle span {
    width: 25px;
    height: 3px;
    background: #181818;
    border-radius: 2px;
    transition: 0.3s;
  }

  /* Toggle active animation (optional) */
  .adv-menu.active + .adv-menu-toggle span:nth-child(1) {
    transform: rotate(45deg) translateY(8px);
  }
  .adv-menu.active + .adv-menu-toggle span:nth-child(2) {
    opacity: 0;
  }
  .adv-menu.active + .adv-menu-toggle span:nth-child(3) {
    transform: rotate(-45deg) translateY(-8px);
  }

  /* Icon alignment fix */
  .adv-has-sub > a i {
    margin-left: auto;
    transition: transform 0.3s;
  }

  .adv-has-sub > a.active i {
    transform: rotate(180deg);
  }
}


@media (max-width: 1024px) {
  /* Ensure submenu fits screen */
  .adv-submenu {
    position: relative !important;
    left: 0 !important;
    transform: none !important;
    width: 100% !important;
    background: #f9f9f9;
    border-left: 3px solid #194479;
    padding: 10px 15px;
    box-sizing: border-box;
  }

  /* Prevent cutoff at screen edges */
  .adv-sub-card,
  .adv-submenu.adv-row .adv-sub-card {
    width: 100% !important;
  }

  /* Indent submenu links slightly */
  .adv-sub-card a {
    display: block;
    padding-left: 10px;
  }

  /* Fix dropdown icon rotation */
  .adv-has-sub > a.active i {
    transform: rotate(180deg);
    transition: transform 0.3s ease;
  }
}


/* ============================================================
   FIX ONLY FOR "ABOUT US" SUBMENU (li:nth-child(2))
   Keeps other menus SAME
============================================================ */
.adv-menu > li:nth-child(2) .adv-submenu {
  padding: 10px 16px !important;   /* Reduce empty space top/bottom */
  gap: 8px !important;             /* Reduce spacing between items */
  min-width: 220px !important;     /* Smaller width */
  left: 0 !important;              /* Better alignment */
  transform: none !important;      /* Remove center shift */
}

/* Submenu card spacing (About Us only) */
.adv-menu > li:nth-child(2) .adv-sub-card {
  padding: 6px 0 !important;
}

/* About Us item style */
.adv-menu > li:nth-child(2) .adv-sub-card a {
  margin: 4px 0 !important;
  padding: 4px 0 !important;
  font-size: 0.96rem !important;
  font-weight: 600;
  color: #273347 !important;
}

/* Hover effect */
.adv-menu > li:nth-child(2) .adv-sub-card a:hover {
  color: #194479 !important;
  transform: translateX(4px);
}




/* ============================================================
   FIX ONLY FOR "RESOURCES" SUBMENU (li:nth-child(6))
   Same compact spacing as About Us
============================================================ */
.adv-menu > li:nth-child(6) .adv-submenu {
  padding: 10px 16px !important;    /* Reduce empty space */
  gap: 8px !important;              /* Reduce vertical spacing */
  min-width: 220px !important;      /* Smaller width */
  left: 0 !important;               /* Align directly below */
  transform: none !important;
}

/* Resources cards spacing */
.adv-menu > li:nth-child(6) .adv-sub-card {
  padding: 6px 0 !important;
}

/* Resources link style */
.adv-menu > li:nth-child(6) .adv-sub-card a {
  margin: 4px 0 !important;
  padding: 4px 0 !important;
  font-size: 0.96rem !important;
  font-weight: 600;
  color: #273347 !important;
}

/* Hover */
.adv-menu > li:nth-child(6) .adv-sub-card a:hover {
  color: #194479 !important;
  transform: translateX(4px);
}


.adv-menu-toggle.active span:nth-child(1){
  transform: rotate(45deg) translateY(8px);
}
.adv-menu-toggle.active span:nth-child(2){
  opacity: 0;
}
.adv-menu-toggle.active span:nth-child(3){
  transform: rotate(-45deg) translateY(-8px);
}


@media (max-width:1024px){
  .adv-menu-toggle{
    position: relative;
    z-index: 10000001000  !important;
  }
  .adv-menu{
    z-index: 100000000000  !important;
  }
}





/* ===== HEADER ALWAYS ON TOP ===== */
.adv-header {
  position: sticky;
  top: 0;
  z-index: 99999999;
}

/* ===== MOBILE MENU FIX ===== */
@media (max-width: 1024px) {

  .adv-menu-toggle {
    display: flex;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
    z-index: 999999999;
  }

  .adv-menu-toggle span {
    width: 25px;
    height: 3px;
    background: #181818;
    border-radius: 2px;
    transition: 0.3s;
  }

  .adv-nav {
    width: 100%;
  }

  .adv-menu {
    display: none;
    flex-direction: column;
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    background: #fff;
    z-index: 999999;
  }

  .adv-menu.active {
    display: flex;
  }

  /* Hamburger animation */
  .adv-menu-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translateY(8px);
  }
  .adv-menu-toggle.active span:nth-child(2) {
    opacity: 0;
  }
  .adv-menu-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translateY(-8px);
  }

  /* Submenus */
  .adv-submenu {
    display: none;
    position: relative;
    padding: 10px 16px;
    background: #f9f9f9;
  }

  .adv-submenu.active {
    display: block;
  }
}

/* Prevent overlays blocking menu */
.hero::before,
.hero::after {
  pointer-events: none;
}

