.uidm-wrapper {
  position: relative;
  display: inline-flex;
  align-items: center;
}

/* Admin layout helpers */
.uidm-menus-wrapper .uidm-menu-block {
  border: 1px solid #d9d9d9;
  border-radius: 8px;
  padding: 12px;
  background: #fff;
  margin-bottom: 16px;
}

.uidm-menu-block__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
}

.uidm-fields-inline {
  display: flex;
  gap: 12px;
  margin: 8px 0 12px;
}

.uidm-fields-inline label {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.uidm-icon-row {
  display: flex;
  gap: 8px;
  align-items: center;
}

.uidm-icon {
  border: none;
  background: transparent;
  padding: 0;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.uidm-icon img {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  object-fit: cover;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.12);
  transition:
    transform 150ms ease,
    box-shadow 150ms ease;
}

.uidm-wrapper:hover .uidm-icon img,
.uidm-wrapper.uidm-open .uidm-icon img,
.uidm-icon:focus-visible img {
  transform: translateY(-1px);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.18);
}

.uidm-menu {
  list-style: none;
  margin: 10px 0 0 0;
  padding: 8px 0;
  position: absolute;
  right: 0;
  top: 100%;
  min-width: 180px;
  background: #ffffff;
  border: 1px solid #d9d9d9;
  border-radius: 8px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
  display: none;
  z-index: 9999;
}

.uidm-menu li {
  margin: 0;
}

.uidm-menu a {
  display: block;
  padding: 10px 14px;
  color: #1f2933;
  text-decoration: none;
  transition:
    background 120ms ease,
    color 120ms ease;
}

.uidm-menu a:hover,
.uidm-menu a:focus-visible {
  background: #f3f4f6;
  color: #111827;
}

.uidm-wrapper:hover .uidm-menu,
.uidm-wrapper.uidm-open .uidm-menu {
  display: block;
}

/* Small touch adjustments */
@media (hover: none) {
  .uidm-menu {
    margin-top: 6px;
  }
}
