/* ================================================================
   NextWeb OS — Unified Navigation & Mobile Responsiveness
   Sections: Variables · Desktop Nav · Mobile Nav · Accordion
   ================================================================ */

:root {
  --primary: #1b2955;
  --secondary: #e81f76;
  --accent: #cddd00;
  --bg-dark: #0d1835;
  --white: #ffffff;
  --glass: rgba(255, 255, 255, 0.95);
  --border: #e8eaf0;
  --shadow: 0 20px 60px rgba(27, 41, 85, 0.15);
}

/* ── NAV BASE ── */
nav {
  display: flex !important;
  align-items: center;
  justify-content: space-between;
  padding: 0 4rem;
  background: var(--white);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 9000;
  min-height: 90px;
  gap: 2rem;
  width: 100%;
}

.logo {
  display: flex;
  align-items: center;
  gap: 1.2rem;
  text-decoration: none;
  flex-shrink: 0;
}

.ltxt {
  font-size: 2rem;
  font-weight: 800;
  color: var(--primary);
  white-space: nowrap;
}

.ltxt em {
  color: var(--secondary);
  font-style: normal;
}

.nlinks {
  display: flex;
  align-items: center;
  gap: 2.5rem;
  flex: 1;
  justify-content: center;
}

.nlinks a {
  font-size: 1.4rem;
  font-weight: 600;
  color: var(--primary);
  transition: color 0.2s;
  white-space: nowrap;
  text-decoration: none;
}

.nlinks a:hover {
  color: var(--secondary);
}

/* ── DESKTOP DROPDOWNS ── */
.nav-dropdown {
  position: relative;
  display: inline-block;
}

.nav-has-dropdown {
  display: flex !important;
  align-items: center;
  gap: 0.3rem;
  cursor: pointer;
}

.nav-dropdown-menu {
  display: none;
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  padding-top: 1.2rem;
  z-index: 9999;
}

.nav-dropdown.is-open .nav-dropdown-menu {
  display: block;
}

.nav-dropdown-menu-inner {
  background: var(--white);
  border-radius: 2rem;
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
  padding: 2rem;
  min-width: 600px;
}

.nav-dropdown-grid {
  display: grid;
  gap: 0.8rem;
}

.nav-dd-item {
  display: flex !important;
  align-items: center !important;
  gap: 1.2rem !important;
  padding: 1rem 1.2rem !important;
  border-radius: 1rem !important;
  text-decoration: none !important;
  color: var(--primary) !important;
  background: transparent !important;
  transition: all 0.2s !important;
  border: 1px solid transparent !important;
}

.nav-dd-item:hover {
  background: #f4f6fb !important;
  border-color: var(--border) !important;
  color: var(--secondary) !important;
}

.nav-dd-icon {
  width: 3.6rem !important;
  height: 3.6rem !important;
  border-radius: 0.8rem !important;
  flex-shrink: 0 !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
}

.nav-dd-item strong {
  font-size: 1.4rem !important;
  font-weight: 700 !important;
  display: block !important;
  margin-bottom: 2px !important;
}

.nav-dd-item em {
  font-size: 1.2rem !important;
  color: #888 !important;
  font-style: normal !important;
  display: block !important;
}

/* ── HAMBURGER ── */
.hamburger {
  display: none;
  flex-direction: column;
  gap: 0.5rem;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
  z-index: 9100;
}

.hamburger span {
  display: block;
  width: 2.4rem;
  height: 2px;
  background: var(--primary);
  border-radius: 2px;
  transition: 0.3s;
}

.hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger.open span:nth-child(2) { opacity: 0; }
.hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ── MOBILE RESPONSIVE ── */
@media (max-width: 1024px) {
  nav {
    padding: 0 2rem;
  }
  
  .ndemo.nav-demo-desktop {
    display: none;
  }
  
  .hamburger {
    display: flex;
  }
  
  .nlinks {
    position: fixed;
    top: 90px;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--white);
    flex-direction: column;
    padding: 2rem;
    gap: 0;
    justify-content: flex-start;
    align-items: stretch;
    overflow-y: auto;
    display: none;
    z-index: 8999;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
  }
  
  .nlinks.open {
    display: flex;
  }
  
  .nlinks > a, 
  .nav-dropdown > a {
    font-size: 1.6rem;
    padding: 1.8rem 0;
    border-bottom: 1px solid var(--border);
    display: block;
    width: 100%;
    color: var(--primary);
  }
  
  .nav-dropdown {
    display: block;
    width: 100%;
  }
  
  .nav-has-dropdown {
    justify-content: space-between;
  }
  
  .nav-has-dropdown svg {
    transition: transform 0.3s;
  }
  
  .nav-dropdown.is-open .nav-has-dropdown svg {
    transform: rotate(180deg);
  }
  
  .nav-dropdown-menu {
    display: none !important;
    position: static !important;
    transform: none !important;
    left: 0 !important;
    right: 0 !important;
    margin: 1rem 0 !important;
    padding: 0 !important;
    box-shadow: none !important;
    border: none !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    float: none !important;
  }
  
  .nav-dropdown.is-open .nav-dropdown-menu {
    display: block !important;
    background: #f9fafc !important;
    border-radius: 1.2rem !important;
    margin: 1rem 0 !important;
    padding: 1.5rem !important;
    visibility: visible !important;
    opacity: 1 !important;
  }
  
  .nav-dropdown-menu-inner {
    padding: 0 !important;
    min-width: 0 !important;
    box-shadow: none !important;
    border: none !important;
    background: transparent !important;
    width: 100% !important;
  }
  
  .nav-dropdown-grid {
    grid-template-columns: 1fr !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 0.5rem !important;
  }
  
  .nav-dd-item {
    padding: 1.2rem !important;
  }
  
  /* Book Demo in Mobile Menu */
  .nlinks::after {
    content: 'Book Free Demo →';
    display: block;
    background: var(--secondary);
    color: var(--white);
    text-align: center;
    padding: 1.6rem;
    border-radius: 0.8rem;
    font-size: 1.6rem;
    font-weight: 700;
    margin-top: 2rem;
    cursor: pointer;
  }
}

/* ── ADDITIONAL FIXES ── */
.platform-nav {
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}
.platform-nav::-webkit-scrollbar {
  display: none;
}
