/* Mega Menu Styles - Professional Design */

/* ==================== */
/* Top Navigation Bar   */
/* ==================== */

.top-nav-bar {
  background: linear-gradient(135deg, #102a43 0%, #1e3a5f 50%, #102a43 100%);
  padding: 10px 0;
  border-bottom: 1px solid rgba(147, 197, 253, 0.15);
  position: relative;
  overflow: hidden;
}

.top-nav-bar::before {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(191, 219, 254, 0.4), transparent);
}

.top-nav-item {
  display: flex;
  align-items: center;
  gap: 8px;
  color: rgba(255, 255, 255, 0.9);
  font-size: 0.8rem;
  font-weight: 400;
  letter-spacing: 0.3px;
  text-decoration: none;
  transition: all 0.25s ease;
}

.top-nav-separator {
  width: 1px;
  height: 16px;
  background: linear-gradient(180deg, transparent, rgba(147, 197, 253, 0.4), transparent);
  margin: 0 6px;
}

.top-nav-link:hover {
  color: #bfdbfe;
}

.top-nav-link:hover .top-nav-icon {
  background: rgba(191, 219, 254, 0.2);
  transform: translateY(-1px);
}

.top-nav-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  background: rgba(147, 197, 253, 0.1);
  border-radius: 50%;
  border: 1px solid rgba(147, 197, 253, 0.15);
  color: #93c5fd;
  transition: all 0.25s ease;
}

.top-nav-icon svg {
  width: 14px;
  height: 14px;
  stroke-width: 1.5;
}

.top-nav-icon-phone {
  background: rgba(134, 239, 172, 0.1);
  border-color: rgba(134, 239, 172, 0.2);
  color: #86efac;
  animation: soft-pulse 3s ease-in-out infinite;
}

@keyframes soft-pulse {
  0%, 100% {
    box-shadow: 0 0 0 0 rgba(134, 239, 172, 0.3);
  }
  50% {
    box-shadow: 0 0 0 6px rgba(134, 239, 172, 0);
  }
}

.top-nav-phone {
  font-weight: 500;
  color: #86efac;
  letter-spacing: 0.3px;
}

.top-nav-cta {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  background: transparent;
  color: white;
  font-weight: 500;
  font-size: 0.75rem;
  letter-spacing: 0.5px;
  text-decoration: none;
  border-radius: 20px;
  border: 1px solid rgba(191, 219, 254, 0.4);
  transition: all 0.25s ease;
}

.top-nav-cta:hover {
  background: rgba(191, 219, 254, 0.15);
  border-color: rgba(191, 219, 254, 0.6);
  transform: translateY(-1px);
}

.top-nav-cta svg {
  width: 14px;
  height: 14px;
  stroke-width: 1.5;
}

@media (max-width: 1023px) {
  .top-nav-bar {
    padding: 8px 0;
  }
  
  .top-nav-item {
    font-size: 0.8rem;
  }
  
  .top-nav-icon {
    width: 28px;
    height: 28px;
  }
  
  .top-nav-icon svg {
    width: 14px;
    height: 14px;
  }
}

@media (max-width: 640px) {
  .top-nav-bar {
    display: none;
  }
}

/* ==================== */
/* Main Navigation Bar  */
/* ==================== */

.main-nav-bar {
  background: rgba(255, 255, 255, 0.98);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  padding: 14px 0;
  border-bottom: 1px solid rgba(30, 58, 95, 0.06);
  position: relative;
}

.main-nav-bar::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(37, 99, 235, 0.15), transparent);
}

.main-nav-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.main-nav-logo {
  display: flex;
  align-items: center;
  transition: opacity 0.2s ease;
}

.main-nav-logo:hover {
  opacity: 0.85;
}

.main-nav-links {
  gap: 4px;
}

.main-nav-link {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 8px 14px;
  color: #334155;
  font-size: 0.85rem;
  font-weight: 500;
  letter-spacing: 0.2px;
  text-decoration: none;
  border-radius: 8px;
  border: none;
  background: transparent;
  cursor: pointer;
  transition: all 0.2s ease;
  position: relative;
}

.main-nav-link::before {
  content: '';
  position: absolute;
  bottom: 4px;
  left: 50%;
  width: 0;
  height: 2px;
  background: linear-gradient(90deg, #2563eb, #3b82f6);
  border-radius: 2px;
  transform: translateX(-50%);
  transition: width 0.2s ease;
}

.main-nav-link:hover {
  color: #1e3a5f;
  background: rgba(37, 99, 235, 0.06);
}

.main-nav-link:hover::before {
  width: 60%;
}

.main-nav-link .chevron {
  width: 14px;
  height: 14px;
  color: #94a3b8;
  transition: transform 0.2s ease, color 0.2s ease;
}

.main-nav-link:hover .chevron {
  color: #2563eb;
}

.main-nav-link.active .chevron {
  transform: rotate(180deg);
  color: #2563eb;
}

.main-nav-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.main-nav-cta {
  display: none;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  background: linear-gradient(135deg, #1e3a5f 0%, #2d4a6f 100%);
  color: white;
  font-size: 0.8rem;
  font-weight: 500;
  letter-spacing: 0.3px;
  text-decoration: none;
  border-radius: 25px;
  border: 1px solid rgba(147, 197, 253, 0.2);
  box-shadow: 0 2px 8px rgba(30, 58, 95, 0.15);
  transition: all 0.25s ease;
}

@media (min-width: 1024px) {
  .main-nav-cta {
    display: inline-flex;
  }
}

.main-nav-cta:hover {
  background: linear-gradient(135deg, #2d4a6f 0%, #3d5a7f 100%);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(30, 58, 95, 0.2);
}

.main-nav-cta svg {
  width: 15px;
  height: 15px;
  stroke-width: 2;
}

.mobile-menu-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background: rgba(30, 58, 95, 0.05);
  border: 1px solid rgba(30, 58, 95, 0.1);
  border-radius: 10px;
  color: #1e3a5f;
  cursor: pointer;
  transition: all 0.2s ease;
}

@media (max-width: 1023px) {
  .mobile-menu-toggle {
    display: flex;
  }
}

.mobile-menu-toggle:hover {
  background: rgba(30, 58, 95, 0.1);
}

/* ==================== */
/* Mega Menu Container  */
/* ==================== */

/* Container */
.mega-menu-container {
  position: fixed;
  left: 0;
  right: 0;
  width: 100vw;
  top: 0;
  background: rgba(255, 255, 255, 0.97);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  box-shadow: 
    0 20px 50px -15px rgba(15, 23, 42, 0.2),
    0 8px 20px -10px rgba(15, 23, 42, 0.1),
    inset 0 1px 0 rgba(255, 255, 255, 0.8);
  border-top: 2px solid #2563eb;
  border-radius: 0 0 16px 16px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-8px);
  transition: opacity 0.25s cubic-bezier(0.4, 0, 0.2, 1), 
              visibility 0.25s cubic-bezier(0.4, 0, 0.2, 1), 
              transform 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  z-index: 9999;
  overflow: visible;
  pointer-events: none;
}

.mega-menu-container.active {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
  pointer-events: auto;
}

/* Inner Container */
.mega-menu-inner {
  max-width: 1300px;
  margin: 0 auto;
  padding: 28px 32px 32px;
}

/* Header */
.mega-menu-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 24px;
  padding-bottom: 16px;
  border-bottom: 1px solid #e5e7eb;
}

.mega-menu-header h3 {
  font-size: 0.75rem;
  font-weight: 700;
  color: #475569;
  margin: 0;
  text-transform: uppercase;
  letter-spacing: 1.5px;
}

.mega-menu-header .icon {
  width: 28px;
  height: 28px;
  background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  box-shadow: 0 2px 8px rgba(37, 99, 235, 0.3);
}

.mega-menu-header .icon svg {
  width: 14px;
  height: 14px;
}

/* Grid Layout */
.mega-menu-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
}

@media (max-width: 1200px) {
  .mega-menu-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 900px) {
  .mega-menu-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 640px) {
  .mega-menu-grid {
    grid-template-columns: 1fr;
  }
  
  .mega-menu-inner {
    padding: 20px 16px 24px;
  }
}

/* Menu Items */
.mega-menu-item {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 14px 16px;
  border-radius: 10px;
  text-decoration: none;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  background: transparent;
  border: 1px solid transparent;
}

.mega-menu-item:hover {
  background: #f8fafc;
  border-color: #e2e8f0;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(15, 23, 42, 0.08);
}

/* Icon Wrapper */
.mega-menu-item .icon-wrapper {
  flex-shrink: 0;
  width: 44px;
  height: 44px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  transition: transform 0.2s cubic-bezier(0.4, 0, 0.2, 1), 
              box-shadow 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 3px 10px -2px rgba(0, 0, 0, 0.15);
}

.mega-menu-item:hover .icon-wrapper {
  transform: scale(1.05);
  box-shadow: 0 6px 16px -3px rgba(0, 0, 0, 0.2);
}

.mega-menu-item .icon-wrapper svg {
  width: 22px;
  height: 22px;
}

/* Content */
.mega-menu-item .content {
  flex: 1;
  min-width: 0;
  padding-top: 2px;
}

.mega-menu-item .title {
  font-size: 0.9rem;
  font-weight: 600;
  color: #0f172a;
  margin: 0 0 4px 0;
  transition: color 0.2s ease;
  line-height: 1.3;
}

.mega-menu-item:hover .title {
  color: #2563eb;
}

.mega-menu-item .description {
  font-size: 0.8rem;
  color: #64748b;
  margin: 0;
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* Professional Color Palette - Harmonized Blues & Teals */
.icon-blue { 
  background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%); 
}
.icon-green { 
  background: linear-gradient(135deg, #059669 0%, #047857 100%); 
}
.icon-purple { 
  background: linear-gradient(135deg, #7c3aed 0%, #6d28d9 100%); 
}
.icon-pink { 
  background: linear-gradient(135deg, #0891b2 0%, #0e7490 100%); 
}
.icon-indigo { 
  background: linear-gradient(135deg, #4f46e5 0%, #4338ca 100%); 
}
.icon-cyan { 
  background: linear-gradient(135deg, #0891b2 0%, #0e7490 100%); 
}
.icon-amber { 
  background: linear-gradient(135deg, #d97706 0%, #b45309 100%); 
}
.icon-teal { 
  background: linear-gradient(135deg, #0d9488 0%, #0f766e 100%); 
}
.icon-red { 
  background: linear-gradient(135deg, #dc2626 0%, #b91c1c 100%); 
}
.icon-violet { 
  background: linear-gradient(135deg, #7c3aed 0%, #6d28d9 100%); 
}
.icon-sky { 
  background: linear-gradient(135deg, #0284c7 0%, #0369a1 100%); 
}
.icon-emerald { 
  background: linear-gradient(135deg, #059669 0%, #047857 100%); 
}
.icon-rose { 
  background: linear-gradient(135deg, #e11d48 0%, #be123c 100%); 
}
.icon-lime { 
  background: linear-gradient(135deg, #65a30d 0%, #4d7c0f 100%); 
}
.icon-fuchsia { 
  background: linear-gradient(135deg, #c026d3 0%, #a21caf 100%); 
}
.icon-orange { 
  background: linear-gradient(135deg, #ea580c 0%, #c2410c 100%); 
}

/* Navigation Button States */
.nav-dropdown-btn {
  position: relative;
}

.nav-dropdown-btn::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  width: 0;
  height: 2px;
  background: linear-gradient(90deg, #2563eb, #1d4ed8);
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  transform: translateX(-50%);
  border-radius: 2px;
}

.nav-dropdown-btn.active::after {
  width: 70%;
}

.nav-dropdown-btn.active {
  color: #1d4ed8 !important;
  background: #eff6ff !important;
}

/* Chevron Animation */
.nav-dropdown-btn .chevron {
  transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1),
              color 0.25s ease;
}

.nav-dropdown-btn.active .chevron {
  transform: rotate(180deg);
  color: #2563eb;
}

/* Footer */
.mega-menu-footer {
  margin-top: 24px;
  padding-top: 20px;
  border-top: 1px solid #e5e7eb;
  display: flex;
  justify-content: center;
  gap: 32px;
  flex-wrap: wrap;
}

.mega-menu-footer a {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #475569;
  text-decoration: none;
  font-weight: 500;
  font-size: 0.85rem;
  padding: 10px 20px;
  border-radius: 8px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.mega-menu-footer a:hover {
  color: #1d4ed8;
  background: #eff6ff;
  border-color: #bfdbfe;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.15);
}

.mega-menu-footer a svg {
  width: 16px;
  height: 16px;
  color: #2563eb;
}

/* Backdrop */
.mega-menu-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.4);
  opacity: 0;
  visibility: hidden;
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  z-index: 9998;
  pointer-events: none;
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
}

.mega-menu-backdrop.active {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

/* Mobile Optimizations */
@media (max-width: 768px) {
  .mega-menu-container {
    border-radius: 0;
    max-height: 80vh;
    overflow-y: auto;
  }
  
  .mega-menu-item {
    padding: 16px;
  }
  
  .mega-menu-item .icon-wrapper {
    width: 40px;
    height: 40px;
  }
  
  .mega-menu-item .icon-wrapper svg {
    width: 20px;
    height: 20px;
  }
  
  .mega-menu-footer {
    flex-direction: column;
    gap: 12px;
    align-items: stretch;
  }
  
  .mega-menu-footer a {
    justify-content: center;
  }
}

/* ==================== */
/* Mobile Menu Styles   */
/* ==================== */

.mobile-menu-panel {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: white;
  box-shadow: 0 10px 40px rgba(15, 23, 42, 0.15);
  z-index: 9999;
  transform: translateX(100%);
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  overflow-y: auto;
  padding-top: 60px;
}

.mobile-menu-panel.active {
  transform: translateX(0);
}

.mobile-menu-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 60px;
  background: white;
  border-bottom: 1px solid #e5e7eb;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 16px;
  z-index: 10000;
}

.mobile-menu-close {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  background: #f1f5f9;
  border: none;
  border-radius: 10px;
  color: #475569;
  cursor: pointer;
  transition: all 0.2s ease;
}

.mobile-menu-close:hover {
  background: #e2e8f0;
  color: #1e293b;
}

.mobile-menu-content {
  padding: 16px;
  padding-bottom: 100px;
}

.mobile-menu-link {
  display: block;
  padding: 14px 16px;
  color: #1e293b;
  text-decoration: none;
  font-weight: 500;
  font-size: 1rem;
  border-radius: 8px;
  transition: all 0.2s ease;
}

.mobile-menu-link:hover,
.mobile-menu-link:active {
  background: #f1f5f9;
  color: #2563eb;
}

.mobile-menu-section {
  border-top: 1px solid #f1f5f9;
  margin-top: 8px;
  padding-top: 8px;
}

.mobile-menu-accordion {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 14px 16px;
  color: #1e293b;
  font-weight: 500;
  font-size: 1rem;
  background: transparent;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.mobile-menu-accordion:hover {
  background: #f1f5f9;
  color: #2563eb;
}

.mobile-menu-accordion.active {
  background: #eff6ff;
  color: #2563eb;
}

.accordion-chevron {
  transition: transform 0.3s ease;
  color: #94a3b8;
}

.mobile-menu-accordion.active .accordion-chevron {
  transform: rotate(180deg);
  color: #2563eb;
}

.mobile-accordion-content {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  background: #f8fafc;
  border-radius: 8px;
  margin: 4px 8px 8px;
}

.mobile-accordion-content.active {
  max-height: 500px;
}

.mobile-submenu-link {
  display: block;
  padding: 12px 20px;
  color: #475569;
  text-decoration: none;
  font-size: 0.95rem;
  transition: all 0.2s ease;
  border-left: 3px solid transparent;
}

.mobile-submenu-link:hover,
.mobile-submenu-link:active {
  color: #2563eb;
  background: #eff6ff;
  border-left-color: #2563eb;
}

.mobile-menu-cta {
  margin-top: 20px;
  padding-top: 20px;
  border-top: 1px solid #e5e7eb;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.mobile-cta-button {
  display: block;
  text-align: center;
  padding: 14px 24px;
  background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
  color: white;
  text-decoration: none;
  font-weight: 600;
  font-size: 1rem;
  border-radius: 10px;
  box-shadow: 0 4px 14px rgba(37, 99, 235, 0.35);
  transition: all 0.2s ease;
}

.mobile-cta-button:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(37, 99, 235, 0.4);
}

.mobile-cta-phone {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 14px 24px;
  background: #f8fafc;
  color: #1e293b;
  text-decoration: none;
  font-weight: 500;
  font-size: 1rem;
  border-radius: 10px;
  border: 1px solid #e2e8f0;
  transition: all 0.2s ease;
}

.mobile-cta-phone:hover {
  background: #eff6ff;
  border-color: #bfdbfe;
  color: #2563eb;
}

.mobile-cta-phone svg {
  color: #2563eb;
}

/* Toggle button icon states */
.mobile-menu-toggle .close-icon {
  display: none;
}

.mobile-menu-toggle.active .menu-icon {
  display: none;
}

.mobile-menu-toggle.active .close-icon {
  display: block;
}

/* Hide mobile menu on large screens */
@media (min-width: 1024px) {
  .mobile-menu-panel {
    display: none !important;
  }
}
