.obj-menu-sub-dropdown {
    position: absolute !important;
    z-index: 1000;
    right: 0;
    top: 100%;
    min-width: 200px;
    background-color: #ffffff;
    box-shadow: 0 0 50px 0 rgba(82,63,105,.15);
    border-radius: 0.475rem;
    display: none;
  }
  
  .obj-menu-sub-dropdown.show {
    display: block;
  }
  
  .obj-card-toolbar {
    position: relative;
  }
  
  .obj-menu-content {
    padding: 0.5rem 0;
  }
  
  .obj-menu-item {
    padding: 0.5rem 1rem;
  }
  
  .obj-menu-item a {
    display: block;
    text-decoration: none;
    color: inherit;
  }
  
  .obj-menu-link {
    display: block;
    padding: 0.65rem 1rem;
    color: #3f4254;
    transition: color 0.3s ease;
  }
  
  /* Aggiungi qui altri stili comuni ai widget */

/* ============================================================
   Action Menu — hover-expand inline buttons + overflow dropdown
   Used by: _widget-user, _widget-obj, _widget-sur-templates
   ============================================================ */

.action-menu-container {
  display: inline-flex;
  align-items: center;
  position: relative;
  transition: all 0.3s ease;
}

.action-menu-trigger {
  position: relative;
  z-index: 10;
  transition: all 0.3s ease;
  border-radius: 0.475rem;
}

.action-buttons-group {
  position: absolute;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
  border-radius: 0.375rem;
  margin-right: 0;
  white-space: nowrap;
  display: flex;
  align-items: center;
  gap: 0;
}

.action-menu-container:hover .action-buttons-group,
.action-menu-container.hovered .action-buttons-group {
  opacity: 1;
  visibility: visible;
  transform: translateY(-50%) translateX(0);
}

/* Hide the standalone dots button when the group is visible */
.action-menu-container:hover .action-menu-trigger-standalone,
.action-menu-container.hovered .action-menu-trigger-standalone {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

/* Style the in-group dots button when the group is visible */
.action-menu-container:hover .action-menu-trigger,
.action-menu-container.hovered .action-menu-trigger {
  background-color: var(--bs-gray-100);
  color: var(--bs-gray-700);
  border-top-left-radius: 0;
  border-bottom-left-radius: 0;
  border-left: none;
}

.action-btn {
  transition: all 0.2s ease;
  border-radius: 0;
  width: 2rem;
  height: 2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  background-color: var(--bs-gray-100);
  color: var(--bs-gray-700);
  border: 1px solid var(--bs-gray-300);
  border-right: none;
}

.action-btn:first-child {
  border-top-left-radius: 0.375rem;
  border-bottom-left-radius: 0.375rem;
}

.action-btn:last-child {
  border-right: 1px solid var(--bs-gray-300);
  border-top-right-radius: 0.375rem;
  border-bottom-right-radius: 0.375rem;
}

/* Single button: show full border on all sides */
.action-btn:only-child,
.action-btn:first-child:last-child {
  border-radius: 0.375rem !important;
  border-right: 1px solid var(--bs-gray-300) !important;
}

.action-btn:hover {
  box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.1);
  text-decoration: none;
  background-color: var(--bs-gray-200);
  color: var(--bs-gray-800);
  border-color: var(--bs-gray-400);
}

.action-btn:only-child:hover,
.action-btn:first-child:last-child:hover {
  border: 1px solid var(--bs-gray-400) !important;
}

/* Staggered entrance animation */
.action-btn:nth-child(1) { transition-delay: 0ms; }
.action-btn:nth-child(2) { transition-delay: 50ms; }
.action-btn:nth-child(3) { transition-delay: 100ms; }

/* Overflow dropdown */
.action-menu-dropdown {
  position: absolute;
  top: calc(100% + 0.5rem);
  right: 0;
  z-index: 1050;
  min-width: 12rem;
  display: none;
  background-color: #fff;
  border: 1px solid var(--bs-gray-200);
  border-radius: 0.475rem;
  box-shadow: 0 0.5rem 1.5rem 0.5rem rgba(0, 0, 0, 0.075);
  padding: 0.5rem 0;
  margin: 0;
  list-style: none;
}

.action-menu-dropdown.show {
  display: block !important;
}


.action-menu-dropdown .dropdown-item {
  display: block;
  width: 100%;
  padding: 0.5rem 1rem;
  clear: both;
  font-weight: 400;
  color: var(--bs-gray-700);
  text-align: inherit;
  text-decoration: none;
  white-space: nowrap;
  background-color: transparent;
  border: 0;
}

.action-menu-dropdown .dropdown-item:hover,
.action-menu-dropdown .dropdown-item:focus {
  color: var(--bs-gray-900);
  background-color: var(--bs-gray-100);
}

.action-menu-dropdown .dropdown-divider {
  height: 0;
  margin: 0.5rem 0;
  overflow: hidden;
  border-top: 1px solid var(--bs-gray-200);
}

/* Responsive: always show buttons on small screens */
@media (max-width: 768px) {
  .action-buttons-group {
    position: static;
    opacity: 1;
    visibility: visible;
    transform: none;
    margin-right: 0;
    margin-left: 0.5rem;
    box-shadow: none;
    background: transparent;
  }

  .action-menu-container {
    flex-direction: row-reverse;
  }
}