.gallery-nav-editor-overlay {
  position: fixed;
  inset: 0;
  z-index: 1200;
  display: grid;
  place-items: center;
  padding: 16px;
  background: rgba(12, 23, 39, .55);
}
.gallery-nav-editor {
  width: min(680px, 100%);
  max-height: min(820px, 90vh);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border-radius: 8px;
  background: #fff;
  color: #263341;
  box-shadow: 0 20px 70px rgba(0, 0, 0, .24);
}
.gallery-nav-editor header,
.gallery-nav-editor footer {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 20px;
}
.gallery-nav-editor header { border-bottom: 1px solid #e5e9ed; }
.gallery-nav-editor h2 { margin: 0 0 4px; font-size: 18px; }
.gallery-nav-editor p { margin: 0; color: #667380; font-size: 12px; }
.gallery-nav-editor button {
  cursor: pointer;
  border: 1px solid #d5dce3;
  border-radius: 4px;
  background: #fff;
  color: inherit;
}
.gallery-nav-editor button:disabled { cursor: default; opacity: .4; }
.gallery-nav-close { margin-left: auto; padding: 4px 9px; font-size: 18px; }
.gallery-nav-editor-list { overflow-y: auto; padding: 10px 20px; }
.gallery-nav-editor-row { padding: 9px 0; border-bottom: 1px solid #eef0f2; }
.gallery-nav-editor-line { display: flex; align-items: center; gap: 10px; }
.gallery-nav-editor-line strong { flex: 1; font-size: 14px; }
.gallery-nav-editor-line button { width: 29px; height: 29px; }
.gallery-nav-grip { cursor: grab; color: #7d8995; font-size: 15px; }
.gallery-nav-editor-roles { display: flex; flex-wrap: wrap; gap: 6px 15px; margin: 7px 0 0 25px; }
.gallery-nav-editor-roles label { display: flex; align-items: center; gap: 5px; font-size: 12px; }
.gallery-nav-inherited { display: block; margin: 6px 0 0 25px; color: #a65d35; }
.gallery-nav-editor footer { justify-content: flex-end; border-top: 1px solid #e5e9ed; }
.gallery-nav-editor footer button { padding: 7px 13px; }
.gallery-nav-editor .gallery-nav-save { border-color: #cf4242; background: #d34b4b; color: #fff; }
.gallery-nav-error { margin-right: auto; color: #c33c3c; font-size: 12px; }
.sidebar .nav-item[hidden] { display: none !important; }
.gallery-nav-edit-trigger { margin: 12px; padding: 6px 10px; border: 1px solid #d5dce3; border-radius: 4px; background: transparent; cursor: pointer; }
.gallery-nav-add { margin: 10px 20px; padding: 7px 12px; align-self: flex-start; }
.gallery-nav-editor-line strong input, .gallery-nav-url { min-width: 0; width: 100%; padding: 6px; border: 1px solid #d5dce3; border-radius: 4px; }
.gallery-nav-url { margin: 7px 0 0 25px; width: calc(100% - 25px); }
.gallery-nav-group-header { display: flex; align-items: center; }
.gallery-nav-group-header > .nav-item { flex: 1; min-width: 0; }
.gallery-nav-group-header > button.nav-item { width: 100%; font: inherit; text-align: left; }
.sidebar .gallery-nav-group-header > button.nav-item {
  border: 0;
  background: transparent;
  color: var(--sidebar-text);
}
.sidebar .gallery-nav-group-header > button.nav-item:hover {
  background: #ffffff0f;
  color: var(--sidebar-text-white);
}
.sidebar .gallery-nav-group.active > .gallery-nav-group-header > .nav-item {
  background: var(--gradient-brand);
  color: var(--sidebar-text-white);
  font-weight: 600;
  box-shadow: 0 4px 12px #ef444440;
}
.gallery-nav-group-toggle { flex: none; margin-right: 6px; border: 0; background: transparent; color: inherit; cursor: pointer; }
.gallery-nav-children { margin-left: 14px; border-left: 1px solid currentColor; padding-left: 6px; }
.gallery-nav-children[hidden], .gallery-nav-group[hidden] { display: none !important; }
.gallery-nav-editor-child { margin-left: 22px; border-left: 2px solid #d5dce3; padding-left: 10px; }
.gallery-nav-parent-select { margin: 7px 0 0 25px; max-width: calc(100% - 25px); padding: 5px; }
.gallery-nav-add-actions { display: flex; gap: 8px; margin: 10px 20px; }
.gallery-nav-add-actions button { padding: 7px 12px; }
