/* ================================================
   SHOP BY SECTIONS - Inside Account Dropdown
   For Shop by Occasion, Recipient, and Gift Type
   ================================================ */
:root {
  --primary-color: #54ad99;
}

/* Dropdown menu container - prevent overflow */
.dropdown-menu {
  max-height: 70vh;
  overflow-y: auto;
  overflow-x: hidden;
}

/* Mobile menu container - prevent overflow */
.navbar-menu {
  max-height: 100vh;
  overflow-y: auto;
  overflow-x: hidden;
}

/* Custom scrollbar for dropdown menu */
.dropdown-menu::-webkit-scrollbar,
.navbar-menu::-webkit-scrollbar {
  width: 6px;
}

.dropdown-menu::-webkit-scrollbar-track,
.navbar-menu::-webkit-scrollbar-track {
  background: #f3f4f6;
  border-radius: 3px;
}

.dropdown-menu::-webkit-scrollbar-thumb,
.navbar-menu::-webkit-scrollbar-thumb {
  background: #d1d5db;
  border-radius: 3px;
}

.dropdown-menu::-webkit-scrollbar-thumb:hover,
.navbar-menu::-webkit-scrollbar-thumb:hover {
  background: #9ca3af;
}

.navbar-menu-header {
  display: flex;
  justify-content: end;
  align-items: center;
}
/* Shop by sections container */
.shop-by-section {
  margin-bottom: 0px;
}
.navbar-menu-divider {
  height: 1px;
  background-color: #e0e0e0;
  margin: 8px 0;
}
/* Individual shop by item */
.shop-by-item {
  margin-bottom: 8px;
}
.mobile-meue-close-button {
  color: var(--primary-color);
}
.shop-by-item:last-child {
  margin-bottom: 0;
}

/* Shop by trigger button */
.shop-by-trigger {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 8px;
  background: #f9f9f9;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  color: #1e1515;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  text-align: left;
}

.shop-by-trigger:hover {
  border-color: var(--primary-color);
  color: var(--primary-color);
}

.shop-by-trigger svg {
  flex-shrink: 0;
  transition: transform 0.3s ease;
  color: currentColor;
}

.shop-by-trigger.active svg {
  transform: rotate(180deg);
}

/* Categories container (collapsible) */
.shop-by-categories {
  max-height: 0 !important;
  overflow: hidden !important;
  transition: max-height 0.3s ease;
  margin-top: 8px;
  display: block !important;
}

.shop-by-item .shop-by-categories.show,
.shop-by-categories.show {
  max-height: 500px !important;
  overflow-y: auto !important;
  display: block !important;
}

/* Category items */
.dropdown-menu-item {
  display: block;
  padding: 10px 16px;
  color: #4b4b4b;
  text-decoration: none;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 500;
  transition: all 0.2s ease;
  background: white;
  margin-bottom: 4px;
}

.dropdown-menu-item:last-child {
  margin-bottom: 0;
}

.dropdown-menu-item:hover {
  background-color: #8080801c;
  color: var(--primary-color);
}

.dropdown-menu-item-text {
  display: block;
}

/* Scrollbar for categories */
.shop-by-categories::-webkit-scrollbar {
  width: 5px;
}

.shop-by-categories::-webkit-scrollbar-track {
  background: #f3f4f6;
  border-radius: 3px;
}

.shop-by-categories::-webkit-scrollbar-thumb {
  background: #d1d5db;
  border-radius: 3px;
}

.shop-by-categories::-webkit-scrollbar-thumb:hover {
  background: #9ca3af;
}

/* Animation */
@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateY(-5px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.shop-by-categories.show .dropdown-menu-item {
  animation: slideDown 0.2s ease forwards;
}

/* Responsive */
@media screen and (max-width: 767px) {
  .shop-by-trigger {
    padding: 10px 14px;
    font-size: 14px;
  }

  .dropdown-menu-item {
    padding: 8px 12px;
    font-size: 13px;
  }
}
