/* Profile application menus. Member-authored preview styling stays intact. */
.ml-profile-menus-ready {
  --ml-menu-bg: #151022;
  --ml-menu-panel: #1e1831;
  --ml-menu-line: #3e345b;
  --ml-menu-text: #f3efff;
  --ml-menu-muted: #b4aad0;
  --ml-menu-blue: #88a8ff;
  --ml-menu-mint: #79d3df;
}
body.ml-profile-modal-open { overflow: hidden !important; overscroll-behavior: none; }
.ml-profile-menus-ready :is(.muze-profile__tools-panel, .muze-profile__settings-window, .muze-profile__edit-help-window, .muze-widget-drawer__window, .muze-widget-editor__window),
.ml-profile-menus-ready :is(.muze-profile__tools-panel, .muze-profile__settings-window, .muze-profile__edit-help-window, .muze-widget-drawer__window, .muze-widget-editor__window) :not(:where(.muze-profile__live-preview, .muze-profile__live-preview *)) {
  box-sizing: border-box;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif !important;
  text-shadow: none !important;
  letter-spacing: normal;
}
.ml-profile-menus-ready :is(.muze-profile__tools-panel, .muze-profile__settings-window, .muze-profile__edit-help-window, .muze-widget-drawer__window, .muze-widget-editor__window) :is(button, a[href], summary, input, select, textarea):not(:where(.muze-profile__live-preview *)):focus-visible {
  outline: 3px solid var(--ml-menu-blue) !important;
  outline-offset: 3px !important;
}
.ml-profile-menus-ready :is(.muze-profile__tools-panel, .muze-profile__settings-window, .muze-profile__edit-help-window, .muze-widget-drawer__window, .muze-widget-editor__window) [hidden] {
  display: none !important;
}

/* Native top-layer wrappers prevent page widgets or navigation covering menus. */
.ml-profile-menus-ready dialog.ml-profile-modal {
  position: fixed !important;
  inset: auto 0 auto 0 !important;
  top: var(--ml-menu-top, 0px) !important;
  width: 100% !important;
  max-width: none !important;
  height: var(--ml-menu-height, 100dvh) !important;
  max-height: none !important;
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  background: transparent !important;
  overflow: hidden !important;
  color: var(--ml-menu-text);
}
.ml-profile-menus-ready dialog.ml-profile-modal:not([open]),
.ml-profile-menus-ready dialog.muze-profile__tools-dialog:not([open]) { display: none !important; }
.ml-profile-menus-ready dialog.ml-profile-modal::backdrop,
.ml-profile-menus-ready dialog.muze-profile__tools-dialog::backdrop {
  background: rgba(7,4,17, .78) !important;
  backdrop-filter: blur(8px) !important;
}
.ml-profile-menus-ready:has(dialog[open]) :is(.muze-widget-studio__toolbar, .muze-profile__edit-assistant) {
  visibility: hidden !important;
  pointer-events: none !important;
}

/* My tools: a stationary title and close button above a single scrolling list. */
.ml-profile-menus-ready.muze-profile[data-muze-profile] dialog.muze-profile__tools-dialog {
  inset: auto 0 auto !important;
  top: calc(var(--ml-menu-top, 0px) + 20px) !important;
  display: flex;
  flex-direction: column;
  width: min(720px, calc(100% - 40px)) !important;
  max-width: calc(100% - 40px) !important;
  height: fit-content !important;
  max-height: calc(var(--ml-menu-height, 100dvh) - 40px) !important;
  margin: 0 auto !important;
  padding: 0 !important;
  border: 1px solid var(--ml-menu-line) !important;
  border-radius: 24px !important;
  background: var(--ml-menu-bg) !important;
  box-shadow: 0 32px 110px rgba(0, 0, 0, .52) !important;
  overflow: hidden !important;
}
.ml-profile-menus-ready.muze-profile[data-muze-profile] .muze-profile__tools-dialog .muze-profile__tools-panel {
  display: flex !important;
  flex-direction: column;
  min-height: 0;
  max-height: inherit;
  width: 100%;
  padding: 0 !important;
  border: 0 !important;
  border-radius: inherit !important;
  background: var(--ml-menu-bg) !important;
  overflow: hidden;
}
.ml-profile-menus-ready.muze-profile[data-muze-profile] .muze-profile__tools-heading {
  align-items: center !important;
  flex: 0 0 auto;
  gap: 18px !important;
  margin: 0 !important;
  padding: 22px 24px !important;
  border-bottom: 1px solid var(--ml-menu-line) !important;
  background: linear-gradient(120deg, #241a40, #18112b) !important;
}
.ml-profile-menus-ready.muze-profile[data-muze-profile] .muze-profile__tools-heading h2 {
  margin: 0 0 5px !important;
  font-size: 23px !important;
  line-height: 1.25 !important;
  color: var(--ml-menu-text) !important;
}
.ml-profile-menus-ready.muze-profile[data-muze-profile] .muze-profile__tools-heading p { color: var(--ml-menu-muted) !important; font-size: 13px !important; }
.ml-profile-menus-ready.muze-profile[data-muze-profile] .muze-profile__tools-links {
  display: grid !important;
  align-content: start !important;
  flex: 1 1 auto;
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  gap: 10px !important;
  min-height: 0;
  padding: 18px 24px 24px !important;
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-gutter: stable;
  scrollbar-width: thin;
  scrollbar-color: #69589a transparent;
}
.ml-profile-menus-ready.muze-profile[data-muze-profile] .muze-profile__tools-links > .ml-profile-tools-section-title {
  grid-column: 1 / -1 !important;
  width: auto !important;
  color: var(--ml-menu-mint) !important;
  font-size: 11px !important;
  letter-spacing: .12em !important;
  margin: 12px 2px 2px !important;
}
.ml-profile-menus-ready.muze-profile[data-muze-profile] .muze-profile__tools-links > .ml-profile-tools-section-title:first-child { margin-top: 0 !important; }
.ml-profile-menus-ready.muze-profile[data-muze-profile] .muze-profile__tools-links :is(.ml-profile-tool-action, a.muze-profile__portal-link) {
  display: flex !important;
  flex-direction: row !important;
  justify-content: flex-start !important;
  width: 100% !important;
  max-width: none !important;
  text-align: left !important;
  text-decoration: none !important;
  align-items: center !important;
  min-width: 0 !important;
  min-height: 88px !important;
  height: auto !important;
  padding: 14px !important;
  gap: 12px !important;
  border: 1px solid var(--ml-menu-line) !important;
  border-radius: 15px !important;
  background: linear-gradient(140deg, #231b3a, #1d172f) !important;
  color: var(--ml-menu-text) !important;
  white-space: normal !important;
  transition: background .16s ease, border-color .16s ease !important;
  transform: none !important;
}
.ml-profile-menus-ready.muze-profile[data-muze-profile] .muze-profile__tools-links :is(.ml-profile-tool-action, a.muze-profile__portal-link):hover {
  border-color: #6c87d0 !important;
  background: #30254f !important;
}
.ml-profile-menus-ready.muze-profile[data-muze-profile] .muze-profile__tools-links :is(.ml-profile-tool-action, a.muze-profile__portal-link) > svg {
  box-sizing: border-box !important;
  box-sizing: border-box !important;
  flex: 0 0 38px !important;
  width: 38px !important;
  height: 38px !important;
  padding: 9px !important;
  background: #2f2354 !important;
  color: var(--ml-menu-blue) !important;
  fill: none !important;
  stroke: currentColor !important;
  stroke-width: 1.8 !important;
  stroke-linecap: round !important;
  stroke-linejoin: round !important;
  border-radius: 11px !important;
}
.ml-profile-menus-ready.muze-profile[data-muze-profile] .muze-profile__tools-links :is(.ml-profile-tool-action, a.muze-profile__portal-link) :is(strong, small, span) {
  background: transparent !important;
  box-shadow: none !important;
  border: 0 !important;
}
.ml-profile-menus-ready.muze-profile[data-muze-profile] .muze-profile__tools-links :is(.ml-profile-tool-action, a.muze-profile__portal-link) strong {
  font-weight: 700 !important;
  color: var(--ml-menu-text) !important;
  font-size: 14px !important;
  line-height: 1.35 !important;
  overflow-wrap: anywhere;
}
.ml-profile-menus-ready.muze-profile[data-muze-profile] .muze-profile__tools-links :is(.ml-profile-tool-action, a.muze-profile__portal-link) small {
  font-weight: 400 !important;
  display: block !important;
  color: var(--ml-menu-muted) !important;
  font-size: 12px !important;
  line-height: 1.45 !important;
  overflow-wrap: anywhere;
}
.ml-profile-menus-ready.muze-profile[data-muze-profile] .muze-profile__tools-links .ml-profile-tool-copy {
  display: block !important;
  flex: 1 1 0% !important;
  width: auto !important;
  min-width: 0 !important;
  max-width: none !important;
  padding: 0 !important;
  margin: 0 !important;
  height: auto !important;
  min-height: 0 !important;
  max-height: none !important;
  text-align: left !important;
  white-space: normal !important;
}
.ml-profile-menus-ready.muze-profile[data-muze-profile] .muze-profile__tools-links .ml-profile-tool-copy strong { text-align: left !important; }
.ml-profile-menus-ready.muze-profile[data-muze-profile] .muze-profile__tools-links :is(.ml-profile-tool-copy, a.muze-profile__portal-link > span) > :is(strong, small) {
  display: block !important;
  width: auto !important;
  max-width: none !important;
  margin: 0 !important;
  padding: 0 !important;
  white-space: normal !important;
  word-break: normal !important;
  overflow-wrap: break-word !important;
}
.ml-profile-menus-ready.muze-profile[data-muze-profile] .muze-profile__tools-links a.muze-profile__portal-link > span { flex: 1 1 0% !important; min-width: 0 !important; }
.ml-profile-menus-ready.muze-profile[data-muze-profile] .muze-profile__tools-links :is(.ml-profile-tool-copy, a.muze-profile__portal-link > span) > small { margin-top: 4px !important; }
.ml-profile-menus-ready.muze-profile[data-muze-profile] .muze-profile__tools-links .ml-profile-tool-action::after,
.ml-profile-menus-ready .muze-profile__tools-links :is(.muze-profile__edit-profile-open, .muze-profile__edit-mode-toggle) strong::after { content: none !important; display: none !important; }

/* Profile editor: one bounded shell, separate sidebar/content, persistent save. */
.ml-profile-menus-ready .ml-profile-modal > :is(.muze-profile__settings, .muze-profile__edit-help, .muze-widget-drawer, .muze-widget-editor) {
  position: absolute !important;
  inset: 0 !important;
  display: flex;
  align-items: center !important;
  justify-content: center !important;
  width: 100% !important;
  height: 100% !important;
  padding: 20px !important;
  pointer-events: auto !important;
  overflow: hidden !important;
}
.ml-profile-menus-ready .ml-profile-modal > [hidden] { display: none !important; }
.ml-profile-menus-ready .muze-profile__settings-window,
.ml-profile-menus-ready .muze-profile__settings.is-quick-edit .muze-profile__settings-window {
  display: flex !important;
  flex-direction: column !important;
  position: relative !important;
  inset: auto !important;
  width: min(1180px, 100%) !important;
  min-width: 0 !important;
  max-width: 100% !important;
  height: min(880px, 100%) !important;
  min-height: 0 !important;
  max-height: 100% !important;
  margin: 0 !important;
  padding: 0 !important;
  border: 1px solid var(--ml-menu-line) !important;
  border-radius: 22px !important;
  background: var(--ml-menu-bg) !important;
  color: var(--ml-menu-text) !important;
  resize: none !important;
  overflow: hidden !important;
  transform: none !important;
}
.ml-profile-menus-ready .muze-profile__settings.is-quick-edit .muze-profile__settings-window { width: min(840px, 100%) !important; }
.ml-profile-menus-ready .muze-profile__settings-header {
  flex: 0 0 auto !important;
  align-items: center !important;
  gap: 16px;
  min-height: 76px !important;
  padding: 16px 22px !important;
  border-bottom: 1px solid var(--ml-menu-line) !important;
  background: linear-gradient(120deg, #241a40, #18112b) !important;
  box-shadow: none !important;
}
.ml-profile-menus-ready .muze-profile__settings-header h2 {
  color: var(--ml-menu-text) !important;
  font-size: 22px !important;
  line-height: 1.3 !important;
  background: none !important;
  -webkit-text-fill-color: currentColor !important;
  border: 0 !important;
}
.ml-profile-menus-ready .muze-profile__settings-header h2::after { content: none !important; }
.ml-profile-menus-ready .muze-profile__settings-header > div { flex: 1 1 auto; min-width: 0; }
.ml-profile-menus-ready .muze-profile__settings-header .muze-profile__eyebrow { color: var(--ml-menu-mint) !important; font-size: 11px !important; }
.ml-profile-menus-ready :is(.muze-profile__tools-close, .muze-profile__settings-close, .muze-profile__edit-help-window > header > button, .muze-widget-drawer__window > header > button, .muze-widget-editor__window > header > button) {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  flex: 0 0 44px !important;
  width: 44px !important;
  height: 44px !important;
  min-width: 44px !important;
  min-height: 44px !important;
  padding: 0 !important;
  border: 1px solid #55487b !important;
  border-radius: 12px !important;
  background: #2e244b !important;
  color: #f7f4ff !important;
  transform: none !important;
  box-shadow: none !important;
}
.ml-profile-menus-ready :is(.muze-profile__settings-header, .muze-profile__edit-help-window > header, .muze-widget-drawer__window > header, .muze-widget-editor__window > header) > .ml-profile-tools-back {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  flex: 0 0 auto !important;
  gap: 6px !important;
  width: auto !important;
  min-width: 86px !important;
  height: 44px !important;
  min-height: 44px !important;
  padding: 10px 12px !important;
  border: 1px solid #55487b !important;
  border-radius: 12px !important;
  background: #2b204a !important;
  box-shadow: none !important;
  color: #e0d5ff !important;
  font-size: 12px !important;
  font-weight: 700 !important;
  line-height: 1.2 !important;
  white-space: nowrap !important;
  cursor: pointer;
}
.ml-profile-menus-ready .ml-profile-tools-back::before { content: "\2190"; font-size: 15px; }
.ml-profile-menus-ready .ml-profile-tools-back:hover { border-color: #8baaff !important; background: #2a3860 !important; }
.ml-profile-menus-ready .muze-profile__settings-layout {
  display: grid !important;
  grid-template-columns: 228px minmax(0, 1fr) !important;
  flex: 1 1 auto !important;
  min-height: 0 !important;
  overflow: hidden !important;
}
.ml-profile-menus-ready .muze-profile__settings.is-quick-edit .muze-profile__settings-layout { display: block !important; }
.ml-profile-menus-ready .muze-profile__settings-menu {
  display: flex !important;
  flex-direction: column !important;
  gap: 6px !important;
  padding: 16px 12px !important;
  min-height: 0;
  overflow: auto !important;
  overscroll-behavior: contain;
  scrollbar-width: thin;
  scrollbar-color: #69589a transparent;
  border-right: 1px solid var(--ml-menu-line) !important;
  background: #161029 !important;
}
.ml-profile-menus-ready .muze-profile__settings.is-quick-edit .muze-profile__settings-menu { display: none !important; }
.ml-profile-menus-ready .muze-profile__settings-menu-label { color: var(--ml-menu-mint) !important; font-size: 11px !important; letter-spacing: .1em !important; }
.ml-profile-menus-ready .muze-profile__settings-menu button {
  flex: 0 0 auto !important;
  min-height: 60px !important;
  padding: 10px !important;
  background: transparent !important;
  border: 1px solid transparent !important;
  transform: none !important;
}
.ml-profile-menus-ready .muze-profile__settings-menu button strong { color: #efeaff !important; font-size: 13px !important; line-height: 1.35 !important; }
.ml-profile-menus-ready .muze-profile__settings-menu button small { color: var(--ml-menu-muted) !important; font-size: 11px !important; line-height: 1.4 !important; }
.ml-profile-menus-ready .muze-profile__settings-menu button:hover { background: #281e44 !important; }
.ml-profile-menus-ready .muze-profile__settings-menu button[aria-pressed=true] { background: #2d2054 !important; border-color: #5d7aca !important; }
.ml-profile-menus-ready .muze-profile__settings-menu button[aria-pressed=true]::before { content: none !important; }
.ml-profile-menus-ready .muze-profile__settings-menu button > span { background: #2e244b !important; color: var(--ml-menu-blue) !important; }
.ml-profile-menus-ready .muze-profile__settings-content,
.ml-profile-menus-ready .muze-profile__settings.is-quick-edit .muze-profile__settings-content {
  height: 100% !important;
  min-width: 0 !important;
  min-height: 0 !important;
  padding: 22px !important;
  overflow-x: hidden !important;
  overflow-y: auto !important;
  overscroll-behavior: contain;
  scroll-padding-block: 18px;
  scrollbar-width: thin;
  scrollbar-color: #69589a transparent;
}
.ml-profile-menus-ready .muze-profile__settings-content .muze-profile__studio-actions { position: static !important; bottom: auto !important; }
.ml-profile-menus-ready .muze-profile__settings-resize-hint { display: none !important; }
.ml-profile-menus-ready .muze-profile__settings-mobile-actions {
  position: relative !important;
  inset: auto !important;
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) auto !important;
  align-items: center !important;
  flex: 0 0 auto !important;
  gap: 16px !important;
  width: 100%;
  min-height: 74px !important;
  padding: 12px 22px !important;
  border-top: 1px solid var(--ml-menu-line) !important;
  background: #1d1533 !important;
  box-shadow: none !important;
}
.ml-profile-menus-ready .muze-profile__settings-mobile-actions p { margin: 0 !important; max-width: none !important; color: var(--ml-menu-muted) !important; font-size: 12px !important; line-height: 1.4 !important; white-space: normal !important; }
.ml-profile-menus-ready .muze-profile__settings-mobile-actions button {
  min-width: 145px !important;
  min-height: 46px !important;
  padding: 12px 18px !important;
  border: 1px solid #7c98e4 !important;
  border-radius: 12px !important;
  background: linear-gradient(125deg, #325dd5, #248996) !important;
  box-shadow: 0 7px 20px rgba(17,50,140, .2) !important;
  color: #fff !important;
  font-size: 14px !important;
  line-height: 1.25 !important;
  font-weight: 750 !important;
  white-space: normal !important;
}

/* Widget and help layers share the same bounded application surface. */
.ml-profile-menus-ready .ml-profile-modal :is(.muze-widget-drawer__backdrop, .muze-profile__edit-help-backdrop, .muze-profile__settings-backdrop) {
  display: block !important;
  position: absolute !important;
  inset: 0 !important;
  width: 100% !important;
  height: 100% !important;
  min-height: 0 !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  backdrop-filter: none !important;
}
.ml-profile-menus-ready :is(.muze-widget-drawer__window, .muze-widget-editor__window, .muze-profile__edit-help-window) {
  position: relative !important;
  inset: auto !important;
  width: min(760px, 100%) !important;
  max-width: 100% !important;
  min-width: 0 !important;
  height: auto !important;
  min-height: 0 !important;
  max-height: 100% !important;
  margin: 0 !important;
  padding: 20px 24px !important;
  border: 1px solid var(--ml-menu-line) !important;
  border-radius: 22px !important;
  background: var(--ml-menu-bg) !important;
  color: var(--ml-menu-text) !important;
  resize: none !important;
  transform: none !important;
  animation: none !important;
  overflow: auto !important;
  overscroll-behavior: contain;
  scrollbar-width: thin;
  scrollbar-color: #69589a transparent;
  pointer-events: auto !important;
}
.ml-profile-menus-ready :is(.muze-widget-drawer__window, .muze-widget-editor__window, .muze-profile__edit-help-window) > header {
  position: sticky !important;
  top: -20px !important;
  z-index: 5 !important;
  display: flex !important;
  align-items: center !important;
  gap: 16px !important;
  margin: -20px -24px 20px !important;
  padding: 18px 24px !important;
  border-bottom: 1px solid var(--ml-menu-line) !important;
  background: #1e1538 !important;
  cursor: default !important;
  touch-action: auto !important;
}
.ml-profile-menus-ready :is(.muze-widget-drawer__window, .muze-widget-editor__window, .muze-profile__edit-help-window) > header > div { min-width: 0; flex: 1 1 auto; }
.ml-profile-menus-ready :is(.muze-widget-drawer__window, .muze-widget-editor__window, .muze-profile__edit-help-window) > header h2 { margin: 2px 0 4px !important; background: none !important; border: 0 !important; color: #f3efff !important; -webkit-text-fill-color: currentColor !important; font-size: 21px !important; line-height: 1.3 !important; }
.ml-profile-menus-ready :is(.muze-widget-drawer__window, .muze-widget-editor__window, .muze-profile__edit-help-window) > header p { color: var(--ml-menu-muted) !important; font-size: 12px !important; line-height: 1.4 !important; }
.ml-profile-menus-ready .muze-widget-library-list { gap: 20px !important; margin-top: 20px !important; }
.ml-profile-menus-ready .muze-widget-library-list h3 { position: static !important; background: transparent !important; color: var(--ml-menu-mint) !important; font-size: 12px !important; }
.ml-profile-menus-ready .muze-widget-drawer .muze-widget-library-list button[data-widget-add] { min-height: 94px !important; padding: 13px !important; border-color: var(--ml-menu-line) !important; border-radius: 14px !important; background: #241c3d !important; }
.ml-profile-menus-ready .muze-widget-drawer .muze-widget-library-list button[data-widget-add] strong { font-size: 13px !important; line-height: 1.35 !important; }
.ml-profile-menus-ready .muze-widget-drawer .muze-widget-library-list button[data-widget-add] small { display: block !important; -webkit-line-clamp: unset !important; overflow: visible !important; color: var(--ml-menu-muted) !important; font-size: 11px !important; line-height: 1.4 !important; }
.ml-profile-menus-ready :is(.muze-widget-drawer__search input, .muze-widget-editor__fields input, .muze-widget-editor__fields textarea, .muze-widget-editor__fields select) { min-height: 44px !important; height: auto !important; border: 1px solid #55487b !important; background: #130d25 !important; color: #f3efff !important; font-size: 16px !important; }
.ml-profile-menus-ready .muze-widget-editor__window > footer { position: sticky !important; bottom: -20px !important; z-index: 4; margin: 20px -24px -20px !important; padding: 14px 24px !important; background: #1e1538 !important; border-top: 1px solid var(--ml-menu-line); }
.ml-profile-menus-ready :is(.muze-widget-editor__window > footer button, .muze-widget-zone-choice button) { min-height: 44px !important; height: auto !important; font-size: 13px !important; padding: 10px 14px !important; white-space: normal !important; }
.ml-profile-menus-ready .muze-profile__edit-help-content { padding: 0 !important; }
.ml-profile-menus-ready .muze-profile__edit-help-content li strong { font-size: 14px !important; }
.ml-profile-menus-ready .muze-profile__edit-help-content li span { color: var(--ml-menu-muted) !important; font-size: 13px !important; line-height: 1.5 !important; }

@media (min-width: 701px) and (max-width: 1099px) {
  .ml-profile-menus-ready .muze-profile__settings-content > .muze-profile__settings-editor { grid-template-areas: "panels" "preview" !important; grid-template-columns: minmax(0, 1fr) !important; }
  .ml-profile-menus-ready .muze-profile__settings-content > .muze-profile__settings-editor > .muze-profile__live-preview { position: relative !important; top: auto !important; }
}
@media (max-width: 700px) {
  .ml-profile-menus-ready.muze-profile[data-muze-profile] dialog.muze-profile__tools-dialog {
    top: calc(var(--ml-menu-top, 0px) + 8px) !important;
    width: calc(100% - 16px) !important;
    max-width: calc(100% - 16px) !important;
    max-height: calc(var(--ml-menu-height, 100dvh) - 16px) !important;
    border-radius: 20px !important;
  }
  .ml-profile-menus-ready.muze-profile[data-muze-profile] .muze-profile__tools-heading { gap: 12px !important; padding: 18px 16px !important; }
  .ml-profile-menus-ready.muze-profile[data-muze-profile] .muze-profile__tools-heading h2 { font-size: 21px !important; }
  .ml-profile-menus-ready.muze-profile[data-muze-profile] .muze-profile__tools-links { grid-template-columns: minmax(0, 1fr) !important; padding: 14px 16px max(18px, env(safe-area-inset-bottom, 0px)) !important; }
  .ml-profile-menus-ready.muze-profile[data-muze-profile] .muze-profile__tools-links :is(.ml-profile-tool-action, a.muze-profile__portal-link) { min-height: 78px !important; }
  .ml-profile-menus-ready .ml-profile-modal > :is(.muze-profile__settings, .muze-profile__edit-help, .muze-widget-drawer, .muze-widget-editor) { padding: 0 !important; }
  .ml-profile-menus-ready .muze-profile__settings-window,
  .ml-profile-menus-ready .muze-profile__settings.is-quick-edit .muze-profile__settings-window { height: 100% !important; border: 0 !important; border-radius: 0 !important; }
  .ml-profile-menus-ready .muze-profile__settings-header { min-height: 66px !important; padding: max(10px, env(safe-area-inset-top, 0px)) 14px 10px !important; }
  .ml-profile-menus-ready .muze-profile__settings-header h2 { font-size: 19px !important; }
  .ml-profile-menus-ready .muze-profile__settings-layout,
  .ml-profile-menus-ready .muze-profile__settings.is-quick-edit .muze-profile__settings-layout { display: block !important; }
  .ml-profile-menus-ready .muze-profile__settings-menu { display: none !important; }
  .ml-profile-menus-ready .muze-profile__settings-mobile-toolbar { padding: 10px 14px !important; gap: 10px !important; background: #1d1533 !important; border-bottom: 1px solid var(--ml-menu-line) !important; }
  .ml-profile-menus-ready .muze-profile__settings-mobile-picker > span { color: var(--ml-menu-muted) !important; font-size: 12px !important; }
  .ml-profile-menus-ready .muze-profile__settings-mobile-picker select { background: #2b204b !important; color: #f3efff !important; border-color: #55487b !important; }
  .ml-profile-menus-ready .muze-profile__settings-content,
  .ml-profile-menus-ready .muze-profile__settings.is-quick-edit .muze-profile__settings-content { padding: 16px 14px !important; }
  .ml-profile-menus-ready .muze-profile__settings.is-mobile-preview-open .muze-profile__settings-content { overflow-y: auto !important; }
  .ml-profile-menus-ready .muze-profile__settings.is-mobile-preview-open .muze-profile__settings-panels { display: none !important; }
  .ml-profile-menus-ready .muze-profile__settings.is-mobile-preview-open .muze-profile__settings-content > .muze-profile__settings-editor > .muze-profile__live-preview {
    position: relative !important;
    inset: auto !important;
    display: block !important;
    width: 100% !important;
    margin: 0 !important;
    max-height: none !important;
    box-shadow: 0 12px 30px rgba(0, 0, 0, .2) !important;
    overflow: visible !important;
  }
  .ml-profile-menus-ready .muze-profile__settings-mobile-actions { min-height: 72px !important; gap: 10px !important; padding: 10px 14px max(10px, env(safe-area-inset-bottom, 0px)) !important; }
  .ml-profile-menus-ready .muze-profile__settings-mobile-actions button { min-width: 126px !important; font-size: 13px !important; padding: 11px 13px !important; }
  .ml-profile-menus-ready :is(.muze-widget-drawer__window, .muze-widget-editor__window, .muze-profile__edit-help-window) { width: 100% !important; max-height: 100% !important; border: 0 !important; border-radius: 0 !important; padding: 16px !important; }
  .ml-profile-menus-ready :is(.muze-widget-drawer__window, .muze-widget-editor__window, .muze-profile__edit-help-window) > header { top: -16px !important; margin: -16px -16px 16px !important; padding: max(14px, env(safe-area-inset-top, 0px)) 16px 14px !important; }
  .ml-profile-menus-ready :is(.muze-widget-drawer__window, .muze-widget-editor__window, .muze-profile__edit-help-window) > header h2 { font-size: 19px !important; }
  .ml-profile-menus-ready :is(.muze-widget-drawer__window, .muze-profile__edit-help-window) > header {
    display: grid !important;
    grid-template-columns: minmax(0,1fr) 44px !important;
    gap: 12px !important;
  }
  .ml-profile-menus-ready :is(.muze-widget-drawer__window, .muze-profile__edit-help-window) > header > div { grid-column: 1; grid-row: 1; }
  .ml-profile-menus-ready :is(.muze-widget-drawer__window, .muze-profile__edit-help-window) > header > button:last-child { grid-column: 2; grid-row: 1; align-self: start; }
  .ml-profile-menus-ready :is(.muze-widget-drawer__window, .muze-profile__edit-help-window) > header > .ml-profile-tools-back { grid-column: 1 / -1; grid-row: 2; justify-self: start; margin: 0 !important; }
  .ml-profile-menus-ready .muze-widget-editor__window > footer { bottom: -16px !important; margin: 16px -16px -16px !important; padding: 12px 16px max(12px, env(safe-area-inset-bottom, 0px)) !important; }
  .ml-profile-menus-ready .muze-widget-library-list section > div { grid-template-columns: minmax(0, 1fr) !important; }
}
.ml-profile-menus-ready.muze-profile[data-muze-profile] :is(.muze-profile__tools-panel, .muze-profile__settings-window, .muze-profile__edit-help-window, .muze-widget-drawer__window, .muze-widget-editor__window) [hidden],
.ml-profile-menus-ready.muze-profile[data-muze-profile] .ml-profile-modal > [hidden] { display: none !important; }
@media (prefers-reduced-motion: reduce) {
  .ml-profile-menus-ready :is(.muze-profile__tools-dialog, .ml-profile-modal) *:not(:where(.muze-profile__live-preview, .muze-profile__live-preview *)) { scroll-behavior: auto !important; transition: none !important; animation: none !important; }
}

/* Compact owner commands stay clear and tappable without making the profile
 * header tall. Their original live controllers continue to own each action. */
.muze-profile[data-muze-profile] .muze-profile__share-button.ml-profile-share-icon {
  align-items:center !important; display:inline-flex !important; flex:0 0 44px !important;
  width:44px !important; min-width:44px !important; height:44px !important;
  justify-content:center !important; padding:0 !important;
}
.muze-profile[data-muze-profile] .muze-profile__share-button.ml-profile-share-icon > span {
  clip:rect(0 0 0 0) !important; clip-path:inset(50%) !important; position:absolute !important;
  width:1px !important; height:1px !important; overflow:hidden !important; white-space:nowrap !important;
}
.muze-profile[data-muze-profile] .ml-profile-quick-action {
  align-items:center !important; display:inline-flex !important; flex:0 0 44px !important;
  width:44px !important; min-width:44px !important; height:44px !important;
  justify-content:center !important; margin:0 !important; padding:0 !important;
  border:1px solid rgba(128,145,190,.38) !important; border-radius:12px !important;
  background:linear-gradient(145deg,rgba(55,47,78,.96),rgba(33,28,48,.98)) !important;
  box-shadow:inset 0 1px 0 rgba(255,255,255,.06),0 8px 20px rgba(8,4,20,.18) !important;
  color:#e5dcff !important; cursor:pointer !important;
  transition:border-color .18s ease,box-shadow .18s ease,color .18s ease,transform .18s ease !important;
}
.muze-profile[data-muze-profile] .ml-profile-quick-action > svg {
  width:19px !important; height:19px !important; fill:none !important; stroke:currentColor !important;
  stroke-width:1.8 !important; stroke-linecap:round !important; stroke-linejoin:round !important;
}
.muze-profile[data-muze-profile] .ml-profile-quick-action--edit { color:#8fadff !important; }
.muze-profile[data-muze-profile] .ml-profile-quick-action--widgets { color:#7fd6e1 !important; }
.muze-profile[data-muze-profile] .ml-profile-quick-action--friends { color:#8fadff !important; }
.muze-profile[data-muze-profile] .ml-profile-quick-action--inline { color:#99b4ff !important; }
.muze-profile[data-muze-profile] .ml-profile-quick-action--inline[aria-pressed="true"] { background:#213671 !important; border-color:#a4bcff !important; box-shadow:0 0 0 3px rgba(120,156,255,.15) !important; }
.muze-profile[data-muze-profile] .ml-profile-quick-action:hover { border-color:currentColor !important; transform:translateY(-1px) !important; }
.muze-profile[data-muze-profile] .ml-profile-quick-action:focus-visible { outline:2px solid #82a3ff !important; outline-offset:2px !important; }
.muze-profile[data-muze-profile] .muze-profile__owner-actions[data-ml-profile-actions-relocated="1"] { display:none !important; }

@media (max-width:600px) {
  .muze-profile[data-muze-profile] .muze-profile__profile-tools { gap:6px !important; }
  .muze-profile[data-muze-profile] :is(.muze-profile__share-button.ml-profile-share-icon,.ml-profile-quick-action) {
    flex-basis:44px !important; width:44px !important; min-width:44px !important;
    height:44px !important; min-height:44px !important;
  }
  .muze-profile[data-muze-profile] .muze-profile__tools-menu { flex:1 1 104px !important; min-width:104px !important; }
  .muze-profile[data-muze-profile] .muze-profile__tools-trigger {
    width:100% !important; height:44px !important; min-height:44px !important;
    justify-content:center !important; padding-left:10px !important; padding-right:10px !important;
  }
}

/* Desktop owner identity uses a compact right-side command/social column.
 * Mobile keeps the natural stacked order above. */
@media (min-width:900px) {
  .muze-profile[data-muze-profile] .muze-profile__identity:has(.muze-profile__tools-menu) {
    align-items:start !important; display:grid !important; column-gap:clamp(24px,3vw,52px) !important;
    grid-template-columns:minmax(240px,1fr) minmax(300px,360px) !important;
    grid-template-rows:repeat(5,auto) !important;
  }
  .muze-profile[data-muze-profile] .muze-profile__identity:has(.muze-profile__tools-menu) > .muze-profile__eyebrow { grid-column:1 !important; grid-row:1 !important; }
  .muze-profile[data-muze-profile] .muze-profile__identity:has(.muze-profile__tools-menu) > h1 { grid-column:1 !important; grid-row:2 !important; }
  .muze-profile[data-muze-profile] .muze-profile__identity:has(.muze-profile__tools-menu) > .muze-profile__handle { grid-column:1 !important; grid-row:3 !important; }
  .muze-profile[data-muze-profile] .muze-profile__identity:has(.muze-profile__tools-menu) > .muze-profile__tagline { grid-column:1 !important; grid-row:4 !important; }
  .muze-profile[data-muze-profile] .muze-profile__identity:has(.muze-profile__tools-menu) > .muze-profile__bio { grid-column:1 !important; grid-row:5 !important; max-width:100% !important; }
  .muze-profile[data-muze-profile] .muze-profile__identity:has(.muze-profile__tools-menu) > .muze-profile__profile-tools {
    align-content:start !important; align-self:start !important; grid-column:2 !important; grid-row:1 / 4 !important;
    justify-content:flex-end !important; margin:0 !important; width:100% !important;
  }
  .muze-profile[data-muze-profile] .muze-profile__identity:has(.muze-profile__tools-menu) > .muze-profile__profile-tools .muze-profile__tools-hint { text-align:right !important; }
  .muze-profile[data-muze-profile] .muze-profile__identity:has(.muze-profile__tools-menu) > .muze-profile__social-links {
    align-self:start !important; grid-column:2 !important; grid-row:4 / 6 !important;
    justify-content:flex-end !important; margin:8px 0 0 !important; width:100% !important;
  }
}

/* Visitor actions have their own row below the identity. They must never use
 * the owner's two-column identity grid or compete with its minimum widths. */
.muze-profile[data-muze-profile] .muze-profile__header:has(> .ml-profile-visitor-header-actions) {
  row-gap:12px !important;
}
.muze-profile[data-muze-profile] .muze-profile__header:has(> .ml-profile-visitor-header-actions) > .muze-profile__identity {
  grid-column:2 / -1 !important;
  min-width:0 !important;
}
.muze-profile[data-muze-profile] .ml-profile-visitor-header-actions {
  align-items:start !important; display:grid !important; gap:8px !important;
  grid-column:2 / -1 !important; grid-template-columns:auto minmax(0,1fr) auto !important;
  min-width:0 !important; max-width:100% !important; width:100% !important;
  margin:0 !important; padding:0 !important; overflow:visible !important;
}
.muze-profile[data-muze-profile] .ml-profile-visitor-header-actions > .muze-profile__profile-tools {
  display:contents !important;
}
.muze-profile[data-muze-profile] .ml-profile-visitor-header-actions .muze-profile__share-button {
  grid-column:1 !important; grid-row:1 !important;
}
.muze-profile[data-muze-profile] .ml-profile-visitor-header-actions [data-muze-profile-share-status] {
  grid-column:1 / -1 !important; grid-row:2 !important; margin:0 !important;
}
.muze-profile[data-muze-profile] .ml-profile-visitor-header-actions .muze-profile__share-fallback {
  grid-column:1 / -1 !important; grid-row:3 !important;
}
.muze-profile[data-muze-profile] .ml-profile-visitor-header-actions > .muze-profile__visitor-actions {
  display:contents !important;
}
.muze-profile[data-muze-profile] .ml-profile-visitor-header-actions .muze-profile__actions {
  display:flex !important; flex-wrap:wrap !important; align-items:center !important;
  grid-column:2 !important; grid-row:1 !important; gap:8px !important;
  min-width:0 !important; width:auto !important; margin:0 !important;
}
.muze-profile[data-muze-profile] .ml-profile-visitor-header-actions .muze-profile__copy-style {
  grid-column:3 !important; grid-row:1 !important; width:auto !important;
}
.muze-profile[data-muze-profile] .ml-profile-visitor-header-actions :is(.muze-profile__relationship-button,.muze-profile__copy-style,.muze-profile__share-button) {
  box-sizing:border-box !important; min-height:44px !important; border-radius:12px !important;
}
.muze-profile[data-muze-profile] .ml-profile-visitor-header-actions :is([data-muze-relationship-status],[data-muze-profile-share-status]) {
  min-width:0 !important; max-width:100% !important; overflow-wrap:anywhere;
}
.muze-profile[data-muze-profile] .ml-profile-visitor-header-actions [data-muze-relationship-status]:not(:empty) {
  flex-basis:100% !important;
}
.muze-profile[data-muze-profile] .ml-profile-visitor-header-actions .muze-profile__share-fallback,
.muze-profile[data-muze-profile] .ml-profile-visitor-header-actions .muze-profile__share-fallback input {
  box-sizing:border-box !important; min-width:0 !important; max-width:100% !important;
}
.muze-profile[data-muze-profile] .ml-profile-visitor-header-actions [hidden] { display:none !important; }

@media (max-width:700px) {
  .muze-profile[data-muze-profile] .muze-profile__header:has(> .ml-profile-visitor-header-actions) > .muze-profile__identity,
  .muze-profile[data-muze-profile] .ml-profile-visitor-header-actions {
    grid-column:1 / -1 !important;
  }
  .muze-profile[data-muze-profile] .ml-profile-visitor-header-actions {
    grid-template-columns:repeat(2,minmax(0,1fr)) !important; margin-top:12px !important;
    justify-self:stretch !important;
  }
  .muze-profile[data-muze-profile] .ml-profile-visitor-header-actions .muze-profile__actions {
    display:grid !important; grid-template-columns:repeat(3,minmax(0,1fr)) !important;
    grid-column:1 / -1 !important; grid-row:1 !important;
  }
  .muze-profile[data-muze-profile] .ml-profile-visitor-header-actions .muze-profile__relationship-button {
    min-width:0 !important; padding:8px 6px !important; gap:5px !important;
    white-space:normal !important; overflow-wrap:anywhere;
  }
  .muze-profile[data-muze-profile] .ml-profile-visitor-header-actions .muze-profile__relationship-button > svg { flex:0 0 17px; }
  .muze-profile[data-muze-profile] .ml-profile-visitor-header-actions .muze-profile__relationship-button--message {
    grid-column:auto !important; grid-row:auto !important;
  }
  .muze-profile[data-muze-profile] .ml-profile-visitor-header-actions .muze-profile__copy-style {
    grid-column:1 !important; grid-row:2 !important; width:100% !important;
    justify-content:center !important; white-space:normal !important;
  }
  .muze-profile[data-muze-profile] .ml-profile-visitor-header-actions .muze-profile__share-button.ml-profile-share-icon {
    grid-column:2 !important; grid-row:2 !important;
    flex:1 1 100% !important; width:100% !important; gap:7px !important; padding:8px !important;
  }
  .muze-profile[data-muze-profile] .ml-profile-visitor-header-actions .muze-profile__share-button.ml-profile-share-icon > span {
    clip:auto !important; clip-path:none !important; position:static !important;
    width:auto !important; height:auto !important; overflow:visible !important; white-space:normal !important;
  }
  .muze-profile[data-muze-profile] .ml-profile-visitor-header-actions :is([data-muze-friend-decline],[data-muze-relationship-status]) { grid-column:1 / -1 !important; }
  .muze-profile[data-muze-profile] .ml-profile-visitor-header-actions [data-muze-profile-share-status] { grid-row:3 !important; }
  .muze-profile[data-muze-profile] .ml-profile-visitor-header-actions .muze-profile__share-fallback { grid-row:4 !important; }
}
