/* ============================
   NAVBAR BASE
============================= */
.navbar {
  position: fixed;
  top: 0;
  width: 100%;
  z-index: 1050;
  backdrop-filter: blur(8px);
  background-color: rgba(255, 255, 255, 0.15);
  transition: background-color 0.3s ease;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
}

/* Brand Logo */
.brand_logo {
  height: 65px;
  width: auto;
  margin-right: 12px;
}

/* Nav container alignment */
.navbar .container,
.navbar .container-fluid {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

/* Toggler placement */
.navbar-toggler {
  margin-left: auto;
  border-color: rgba(255, 255, 255, 0.6);
}

.navbar-toggler-icon {
  background-color: rgba(255, 255, 255, 0.4);
}

/* ============================
   NAVBAR LINKS
============================= */
.navbar-nav .nav-link {
  color: #222;
  text-decoration: none;
  font-size: 16px;
  font-weight: 500;
  text-transform: uppercase;
  padding: 10px 15px;
  border-radius: 6px;
  transition: all 0.3s ease;
  display: inline-block;
}

.navbar-nav .nav-link:hover {
  background-color: rgba(255, 255, 255, 0.25);
  transform: scale(1.08);
  animation: pulse 0.5s ease-in-out infinite;
}

/* Pulse Effect */
@keyframes pulse {
  0%   { transform: scale(1); }
  50%  { transform: scale(1.08); }
  100% { transform: scale(1); }
}

/* ============================
   DROPDOWN MENU
============================= */
.dropdown-menu {
  opacity: 0;
  transform: scale(0);
  transform-origin: top;
  transition: all 0.3s ease;
  display: block;
  pointer-events: none;
}

.nav-item.dropdown:hover .dropdown-menu {
  opacity: 1;
  transform: scale(1);
  pointer-events: auto;
}

/* Mobile View Fix */
@media (max-width: 992px) {
  .dropdown-menu {
    opacity: 1;
    transform: scale(1);
    position: static;
    float: none;
    box-shadow: none;
  }

  .nav-item.dropdown:hover .dropdown-menu {
    transform: scale(1);
  }

  .nav-item.dropdown .dropdown-toggle::after {
    display: none;
  }
}

/* ============================
   CART BADGE
============================= */
.cart-badge {
  position: absolute;
  top: 0;
  right: -8px;
  background: #dc3545;
  color: #fff;
  font-size: 0.75rem;
  border-radius: 50%;
  padding: 4px 6px;
  font-weight: bold;
}

/* ============================
   RESPONSIVE ALIGNMENT
============================= */
@media (max-width: 768px) {
  .navbar-nav {
    text-align: center;
  }

  .nav-link {
    width: 100%;
    padding: 12px;
  }
}


/* ============================
   RESPONSIVE SEARCH ON MOBILE
============================= */
/* Search toggle button */
  .mobile-search-btn {
    position: fixed;
    top: 28px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 1050;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background-color: #0d6efd;
    color: #fff;
    border: none;
    display: flex;
    justify-content: center;
    align-items: center;
    box-shadow: 0 2px 6px rgba(0,0,0,0.2);
  }

  /* Panel default state (hidden) */
  .mobile-search-panel {
    position: fixed;
    top: -220px;
    left: 50%;
    transform: translateX(-50%);
    width: 90%;
    max-width: 500px;
    background: #fff;
    z-index: 1049;
    box-shadow: 0 8px 24px rgba(0,0,0,0.1);
    border-radius: 20px;
    border: 0.5px solid #ddd;
    transition: top 0.3s ease;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
  }

  /* Panel open state */
  .mobile-search-panel.open {
    top: 66px;
    animation: fadeBounceIn 0.5s ease-out;
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
  }

  /* Fade & bounce animation */
  @keyframes fadeBounceIn {
    0% {
      opacity: 0;
      transform: translateX(-50%) translateY(-40px);
    }
    60% {
      opacity: 1;
      transform: translateX(-50%) translateY(8px);
    }
    80% {
      transform: translateX(-50%) translateY(-4px);
    }
    100% {
      transform: translateX(-50%) translateY(0);
    }
  }

  /* Hide on desktop */
  @media (min-width: 992px) {
    .mobile-search-btn,
    .mobile-search-panel {
      display: none !important;
    }

    .d-lg-flex {
      display: flex !important;
    }
  }