/* ============================================================================
   PROFESSIONAL NAVBAR - Enhanced Professional Styles
   ============================================================================ */

.navbar {
  background: rgba(10, 15, 22, 0.95);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
  padding: 0;
  position: sticky;
  top: 0;
  z-index: 1000;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.navbar::before {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--brand-accent), transparent);
  opacity: 0;
  transition: var(--transition);
}

.navbar.scrolled {
  background: rgba(10, 15, 22, 0.98);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.35);
  border-bottom-color: var(--brand-accent);
}

.navbar.scrolled::before {
  opacity: 1;
}

/* === NAV CONTAINER === */
.nav-container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 1rem 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: relative;
}

/* === PROFESSIONAL LOGO === */
.nav-logo {
  display: flex;
  align-items: center;
  gap: 1rem;
  text-decoration: none;
  color: var(--text-primary);
  font-weight: 800;
  font-size: 1.5rem;
  transition: var(--transition);
  position: relative;
  z-index: 2;
}

.nav-logo:hover {
  transform: scale(1.02);
}

.logo-icon {
  width: 45px;
  height: 45px;
  background: linear-gradient(135deg, var(--brand) 0%, var(--brand-light) 100%);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 8px 25px rgba(236, 116, 0, 0.35);
  position: relative;
  overflow: hidden;
  transition: var(--transition);
}

.logo-icon::before {
  content: '';
  position: absolute;
  inset: -2px;
  background: linear-gradient(45deg, var(--brand), var(--brand-light), var(--brand));
  border-radius: 50%;
  z-index: -1;
  opacity: 0;
  transition: var(--transition);
}

.logo-icon:hover {
  transform: rotate(10deg) scale(1.1);
  box-shadow: 0 0 30px rgba(236, 116, 0, 0.5);
}

.logo-icon:hover::before {
  opacity: 1;
  animation: logoGlow 2s linear infinite;
}

.logo-icon i {
  color: white;
  font-size: 1.5rem;
  z-index: 1;
  position: relative;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.3));
}

.logo-text {
  font-weight: 900;
  background: linear-gradient(135deg, var(--text-primary), var(--brand));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  letter-spacing: -0.02em;
}

/* === NAVIGATION MENU === */
.nav-menu {
  display: flex;
  list-style: none;
  align-items: center;
  gap: 0.5rem;
  margin: 0;
  padding: 0;
}

.nav-menu li {
  position: relative;
}

/* === PROFESSIONAL NAV LINKS === */
.nav-link {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 1rem 1.5rem;
  text-decoration: none;
  color: var(--text-muted);
  border-radius: var(--radius-lg);
  transition: var(--transition);
  font-weight: 600;
  position: relative;
  overflow: hidden;
  backdrop-filter: blur(10px);
  border: 1px solid transparent;
  font-size: 0.95rem;
}

.nav-link::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, var(--brand-pale), var(--brand-semi));
  opacity: 0;
  transition: var(--transition);
  z-index: -1;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%) scaleX(0);
  width: 70%;
  height: 2px;
  background: var(--brand);
  border-radius: 1px;
  transition: var(--transition);
}

.nav-link:hover,
.nav-link.active {
  color: var(--brand);
  transform: translateY(-2px);
  border-color: var(--brand-accent);
  box-shadow: 0 4px 12px rgba(236, 116, 0, 0.2);
}

.nav-link:hover::before,
.nav-link.active::before {
  opacity: 1;
}

.nav-link:hover::after,
.nav-link.active::after {
  transform: translateX(-50%) scaleX(1);
}

.nav-link i {
  font-size: 1.1rem;
  opacity: 0.9;
  transition: var(--transition);
}

.nav-link:hover i,
.nav-link.active i {
  opacity: 1;
  transform: scale(1.1);
  filter: drop-shadow(0 2px 4px rgba(236, 116, 0, 0.3));
}

/* === SPECIAL BUTTON STYLES === */
.nav-link.btn-style {
  background: linear-gradient(135deg, var(--brand) 0%, var(--brand-light) 100%);
  color: white !important;
  box-shadow: 0 8px 25px rgba(236, 116, 0, 0.35);
  border: 1px solid var(--brand-accent);
  font-weight: 700;
  position: relative;
}

.nav-link.btn-style::before {
  background: linear-gradient(135deg, var(--brand-light), var(--brand));
}

.nav-link.btn-style:hover {
  transform: translateY(-3px);
  box-shadow: 0 0 30px rgba(236, 116, 0, 0.5);
  color: white !important;
}

.nav-link.btn-style::after {
  display: none;
}

.nav-link.btn-outline {
  background: transparent;
  color: var(--brand) !important;
  border: 2px solid var(--brand);
  backdrop-filter: blur(10px);
}

.nav-link.btn-outline::before {
  background: var(--brand);
}

.nav-link.btn-outline:hover {
  background: var(--brand);
  color: white !important;
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(236, 116, 0, 0.35);
}

/* === USER MENU === */
.user-menu-wrapper {
  position: relative;
}

.user-toggle {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 1.25rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  color: var(--text-primary);
  cursor: pointer;
  transition: var(--transition);
  font-weight: 600;
  backdrop-filter: blur(10px);
}

.user-toggle:hover {
  background: var(--brand-pale);
  border-color: var(--brand-accent);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(236, 116, 0, 0.2);
}

.user-avatar {
  width: 35px;
  height: 35px;
  background: linear-gradient(135deg, var(--brand), var(--brand-light));
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 0.9rem;
  font-weight: 800;
  box-shadow: 0 4px 12px rgba(236, 116, 0, 0.3);
  flex-shrink: 0;
}

.user-info {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.125rem;
}

.user-name {
  font-size: 0.95rem;
  color: var(--text-primary);
  line-height: 1.2;
}

.user-role {
  font-size: 0.75rem;
  color: var(--brand);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  font-weight: 700;
}

.dropdown-icon {
  color: var(--brand);
  font-size: 0.9rem;
  transition: var(--transition);
}

.user-toggle.active .dropdown-icon {
  transform: rotate(180deg);
}

/* === DROPDOWN MENU === */
.user-dropdown {
  position: absolute;
  top: calc(100% + 1rem);
  right: 0;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 1.5rem;
  min-width: 280px;
  backdrop-filter: blur(20px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.35);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-20px);
  transition: var(--transition);
  z-index: 1001;
}

.user-dropdown::before {
  content: '';
  position: absolute;
  top: -8px;
  right: 2rem;
  width: 16px;
  height: 16px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-bottom: none;
  border-right: none;
  transform: rotate(45deg);
  border-radius: 2px 0 0 0;
}

.user-dropdown.active {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.dropdown-header {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding-bottom: 1.5rem;
  margin-bottom: 1.5rem;
  border-bottom: 1px solid var(--border);
}

.dropdown-avatar {
  width: 50px;
  height: 50px;
  background: linear-gradient(135deg, var(--brand), var(--brand-light));
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 1.2rem;
  font-weight: 800;
  box-shadow: 0 8px 25px rgba(236, 116, 0, 0.35);
}

.dropdown-info {
  flex: 1;
}

.dropdown-name {
  font-weight: 700;
  color: var(--text-primary);
  margin: 0 0 0.25rem 0;
  font-size: 1rem;
}

.dropdown-email {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin: 0;
}

.dropdown-items {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.dropdown-item {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.875rem 1rem;
  text-decoration: none;
  color: var(--text-secondary);
  border-radius: var(--radius);
  transition: var(--transition);
  font-weight: 500;
  position: relative;
  overflow: hidden;
  border: 1px solid transparent;
}

.dropdown-item::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--brand-pale);
  opacity: 0;
  transition: var(--transition);
}

.dropdown-item:hover {
  color: var(--brand);
  transform: translateX(4px);
  border-color: var(--brand-accent);
}

.dropdown-item:hover::before {
  opacity: 1;
}

.dropdown-item i {
  font-size: 1.1rem;
  width: 20px;
  text-align: center;
  position: relative;
  z-index: 1;
}

.dropdown-item span {
  position: relative;
  z-index: 1;
}

.dropdown-item.logout {
  margin-top: 0.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border);
  color: #ef4444;
}

.dropdown-item.logout:hover {
  background: rgba(239, 68, 68, 0.1);
  color: #ef4444;
  border-color: rgba(239, 68, 68, 0.3);
}

.dropdown-item.logout::before {
  background: rgba(239, 68, 68, 0.1);
}

/* === HAMBURGER MENU === */
.hamburger {
  display: none;
  flex-direction: column;
  cursor: pointer;
  padding: 0.75rem;
  gap: 5px;
  border-radius: var(--radius);
  transition: var(--transition);
  background: var(--bg-card);
  border: 1px solid var(--border);
  backdrop-filter: blur(10px);
}

.hamburger:hover {
  background: var(--brand-pale);
  border-color: var(--brand-accent);
  transform: scale(1.05);
}

.hamburger span {
  width: 28px;
  height: 3px;
  background: var(--text-primary);
  border-radius: 2px;
  transition: var(--transition);
  transform-origin: center;
}

.hamburger.active span:nth-child(1) {
  transform: rotate(45deg) translate(8px, 8px);
  background: var(--brand);
}

.hamburger.active span:nth-child(2) {
  opacity: 0;
  transform: scaleX(0);
}

.hamburger.active span:nth-child(3) {
  transform: rotate(-45deg) translate(8px, -8px);
  background: var(--brand);
}

/* === FLOATING ACTION BUTTON === */
.floating-nav-cta {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  width: 60px;
  height: 60px;
  background: linear-gradient(135deg, var(--brand), var(--brand-light));
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 1.5rem;
  box-shadow: 0 8px 25px rgba(236, 116, 0, 0.35);
  cursor: pointer;
  transition: var(--transition);
  z-index: 999;
  border: none;
  text-decoration: none;
  opacity: 0;
  transform: translateY(100px);
}

.floating-nav-cta.show {
  opacity: 1;
  transform: translateY(0);
}

.floating-nav-cta:hover {
  transform: translateY(-3px) scale(1.1);
  box-shadow: 0 0 30px rgba(236, 116, 0, 0.5);
}

/* === RESPONSIVE DESIGN === */
@media (max-width: 1024px) {
  .nav-container {
    padding: 1rem 1.5rem;
  }
  
  .nav-menu {
    gap: 0.25rem;
  }
  
  .nav-link {
    padding: 0.875rem 1.25rem;
  }
  
  .user-dropdown {
    min-width: 260px;
  }
}

@media (max-width: 768px) {
  .hamburger {
    display: flex;
  }
  
  .nav-menu {
    position: fixed;
    top: 100%;
    left: 0;
    width: 100%;
    background: rgba(10, 15, 22, 0.98);
    backdrop-filter: blur(20px);
    flex-direction: column;
    padding: 2rem;
    transform: translateY(-100%);
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
    border-top: 1px solid var(--border);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.35);
    gap: 1rem;
  }
  
  .nav-menu::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--brand), var(--brand-light));
  }
  
  .nav-menu.active {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
  }
  
  .nav-link {
    justify-content: center;
    padding: 1.5rem;
    width: 100%;
    border-radius: var(--radius-xl);
    font-size: 1.1rem;
    background: var(--bg-card);
    border: 1px solid var(--border);
    margin: 0;
  }
  
  .nav-link::after {
    display: none;
  }
  
  .nav-container {
    padding: 1rem;
  }
  
  .user-dropdown {
    right: 1rem;
    width: calc(100% - 2rem);
    max-width: 320px;
  }
  
  .user-toggle {
    padding: 0.625rem 1rem;
  }
  
  .user-avatar {
    width: 30px;
    height: 30px;
    font-size: 0.8rem;
  }
  
  .user-info {
    display: none;
  }
  
  .floating-nav-cta {
    bottom: 1rem;
    right: 1rem;
    width: 50px;
    height: 50px;
    font-size: 1.2rem;
  }
}

@media (max-width: 480px) {
  .nav-logo {
    font-size: 1.25rem;
  }
  
  .logo-icon {
    width: 40px;
    height: 40px;
    font-size: 1.25rem;
  }
  
  .nav-menu {
    padding: 1.5rem;
    gap: 0.75rem;
  }
  
  .nav-link {
    padding: 1.25rem;
    font-size: 1rem;
  }
  
  .user-dropdown {
    right: 0.5rem;
    width: calc(100% - 1rem);
    padding: 1.25rem;
  }
  
  .dropdown-header {
    flex-direction: column;
    text-align: center;
    gap: 0.75rem;
  }
  
  .dropdown-avatar {
    width: 45px;
    height: 45px;
  }
}

/* === ANIMATIONS === */
@keyframes logoGlow {
  0%, 100% { 
    transform: rotate(0deg); 
    filter: hue-rotate(0deg);
  }
  50% { 
    transform: rotate(180deg); 
    filter: hue-rotate(180deg);
  }
}

@keyframes navSlideIn {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.nav-menu li {
  animation: navSlideIn 0.5s ease forwards;
}

.nav-menu li:nth-child(1) { animation-delay: 0.1s; }
.nav-menu li:nth-child(2) { animation-delay: 0.2s; }
.nav-menu li:nth-child(3) { animation-delay: 0.3s; }
.nav-menu li:nth-child(4) { animation-delay: 0.4s; }
.nav-menu li:nth-child(5) { animation-delay: 0.5s; }

/* === ACCESSIBILITY === */
@media (prefers-reduced-motion: reduce) {
  .nav-link,
  .logo-icon,
  .hamburger span,
  .user-dropdown,
  .floating-nav-cta {
    transition: none !important;
    animation: none !important;
  }
}

/* Focus styles for better accessibility */
.nav-link:focus-visible,
.hamburger:focus-visible,
.dropdown-item:focus-visible,
.user-toggle:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: 2px;
}

/* === SCROLL INDICATOR === */
.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 3px;
  background: rgba(255, 255, 255, 0.1);
  z-index: 9999;
  pointer-events: none;
}

.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--brand), var(--brand-light));
  width: 0%;
  transition: width 0.3s ease;
  border-radius: 0 2px 2px 0;
  box-shadow: 0 0 10px var(--brand);
}

/* === LOADING STATE === */
.navbar.loading {
  opacity: 0.8;
}

.navbar.loading * {
  pointer-events: none;
}