/* Header Variables for gradient effects and animations */
:host {
  --primary-color: #3a86ff;
  --primary-hover: #2563eb;
  --secondary-color: #8338ec;
}

/* Brand/Logo gradient effects */
.brand-icon {
  background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.brand-text {
  background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* User Avatar styling */
.user-avatar {
  width: 32px;
  height: 32px;
  background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
  color: white;
}

/* Animation for dropdown menu */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.dropdown-menu {
  animation: fadeIn 0.2s ease-out;
}

/* Fix for clickable links */
.nav-link,
.dropdown-item,
.action-button,
.navbar-brand {
  cursor: pointer;
  position: relative;
  z-index: 1;
}

/* Hover Effects */
.navbar-brand:hover .brand-icon {
  transform: rotate(-10deg);
}

.action-button:hover i,
.dropdown-toggle:hover i {
  transform: scale(1.1);
}

.dropdown-item:hover i {
  transform: translateX(2px);
}

/* Transitions for smooth interactions */
.navbar-brand,
.brand-icon,
.nav-link,
.dropdown-item,
.dropdown-item i,
.navbar-toggler,
.btn {
  transition: all 0.3s ease;
}

/* Active link styling */
.navbar-nav .nav-link.active,
.mobile-account-links .nav-link:hover {
  background-color: rgba(58, 134, 255, 0.1); /* Light blue background using your primary color */
  color: var(--primary-color); /* Use your primary color variable */
  font-weight: 500;
  border-radius: 0.375rem;
}

.navbar-nav .nav-link.active i {
  color: var(--primary-color);
  transform: scale(1.1); /* Slightly larger icon */
}

/* Enhance regular nav links for better hover states */
.navbar-nav .nav-link,
.mobile-account-links .nav-link {
  padding: 0.5rem 0.75rem;
  transition: all 0.3s ease;
  border-radius: 0.375rem;
}

.navbar-nav .nav-link:hover:not(.active) {
  background-color: rgba(0, 0, 0, 0.05); /* Subtle hover effect for non-active links */
}

.nav-pointer {
  cursor: pointer;
}

.counter {
  top: 20%;
  left: 75%;
}

/* Style dropdown menu items with primary color */
.dropdown-menu .dropdown-item {
  color: var(--primary-color);
}

/* Keep the hover effect but make it use the primary color with opacity */
.dropdown-menu .dropdown-item:hover {
  background-color: rgba(58, 134, 255, 0.1);
  color: var(--primary-hover);
}

/* Style the dropdown menu icons with primary color */
.dropdown-menu .dropdown-item i {
  color: var(--primary-color);
}

/* Special handling for the logout item to keep it red */
.dropdown-menu .dropdown-item.text-danger,
.dropdown-menu .dropdown-item.text-danger i,
.text-danger,
.text-danger i {
  color: #dc3545 !important;
}

.dropdown-menu .dropdown-item.text-danger:hover,
.mobile-account-links .nav-link.text-danger:hover {
  background-color: rgba(220, 53, 69, 0.1);
}

/* Ensure all clickable elements are actually clickable */
a,
button {
  position: relative;
  z-index: 2;
}

/* Fix for notification component */
.notification-wrapper {
  position: relative;
  z-index: 3;
}

/* Notification mobile styling updated */
.notification-mobile-wrapper {
  position: relative;
  z-index: 3;
  display: flex;
  align-items: center;
}

/* Mobile menu improvements */
.mobile-menu-content {
  padding-bottom: 1rem;
}

.menu-section-header {
  color: var(--primary-color);
  font-weight: 500;
  font-size: 0.95rem;
  display: flex;
  align-items: center;
  margin-bottom: 0.5rem;
}

.mobile-section {
  background-color: rgba(0, 0, 0, 0.02);
  border-radius: 0.5rem;
  padding: 0.75rem 0.75rem;
}

/* Mobile-specific styles */
@media (max-width: 991.98px) {
  .navbar-collapse {
    max-height: calc(100vh - 70px);
    overflow-y: auto;
    padding: 0.5rem 0;
  }

  .mobile-account-links {
    margin-bottom: 1rem;
  }

  .mobile-account-links .nav-link {
    margin-bottom: 0.25rem;
    padding: 0.6rem 0.75rem;
    transition: all 0.2s ease;
  }

  /* Improve visual feedback on touch */
  .mobile-account-links .nav-link:active {
    background-color: rgba(58, 134, 255, 0.15);
    transform: translateY(1px);
  }

  .navbar-nav .nav-item {
    justify-content: space-between;
    width: 100%;
  }

  .navbar-nav .nav-link {
    flex: 1;
  }

  /* Make the header more compact on very small screens */
  @media (max-width: 360px) {
    .navbar-brand .brand-text {
      font-size: 1.25rem !important;
    }

    .navbar-brand .brand-icon {
      font-size: 1.5rem !important;
    }
  }
}
