/* ProfileOverlayView's 20px card and authored theme brushes; shell actions stay in the shell. */
.nexus-profile-menu {
  --profile-surface: var(--shell-card);
  --profile-muted: var(--shell-muted);
  position: fixed;
  z-index: 220;
  box-sizing: border-box;
  width: 300px;
  max-width: calc(100vw - 16px);
  max-height: calc(100dvh - 16px);
  overflow: auto;
  overscroll-behavior: contain;
  scrollbar-width: thin;
  scrollbar-color: var(--shell-accent) transparent;
  border: 1px solid color-mix(in srgb, var(--profile-muted) 32%, transparent);
  border-radius: 20px;
  padding: 8px;
  background: var(--profile-surface);
  color: var(--shell-text);
  box-shadow: 0 18px 54px #0005, 0 3px 12px #0003;
  font: 14px/1.4 "Segoe UI", Tahoma, Arial, "Noto Sans", "Nexus Sans Fallback", "Nexus Arabic Fallback", "Nexus Devanagari Fallback", "Nexus CJK Fallback", sans-serif;
  text-align: start;
  animation: nexus-profile-menu-enter 140ms ease-out;
  transform-origin: top right;
  isolation: isolate;
}
.nexus-profile-menu[hidden] { display: none !important; }
.nexus-profile-menu *, .nexus-profile-menu *::before, .nexus-profile-menu *::after { box-sizing: border-box; }
.nexus-profile-menu__account { display: flex; align-items: center; gap: 12px; min-height: 76px; padding: 12px 10px 16px; }
.nexus-profile-menu__avatar { display: grid; place-items: center; width: 42px; height: 42px; flex: none; border-radius: 50%; color: var(--shell-text); background: color-mix(in srgb, var(--shell-accent) 26%, var(--profile-surface)); border: 1px solid color-mix(in srgb, var(--shell-accent) 46%, transparent); }
.nexus-profile-menu__avatar svg { width: 22px; height: 22px; }
.nexus-profile-menu__account-copy { min-width: 0; }
.nexus-profile-menu__name { font-size: 15px; font-weight: 650; line-height: 1.4; overflow-wrap: anywhere; }
.nexus-profile-menu__email { color: var(--profile-muted); font-size: 12px; margin-top: 3px; overflow-wrap: anywhere; unicode-bidi: plaintext; }
.nexus-profile-menu__group { display: grid; gap: 2px; padding: 7px 0; border-top: 1px solid color-mix(in srgb, var(--profile-muted) 22%, transparent); }
.nexus-profile-menu__group:last-child { padding-bottom: 0; }
.nexus-profile-menu__item {
  display: flex; align-items: center; gap: 12px; width: 100%; min-width: 0; min-height: 44px;
  padding: 10px 12px; border: 1px solid transparent; border-radius: 10px; background: transparent;
  color: inherit; text-align: start; font: inherit;
  transition: color 120ms ease, background-color 120ms ease, border-color 120ms ease;
}
button.nexus-profile-menu__item { cursor: pointer; touch-action: manipulation; }
button.nexus-profile-menu__item:hover { color: var(--profile-accent-foreground, var(--shell-text)); background: color-mix(in srgb, var(--shell-accent) 12%, transparent); }
button.nexus-profile-menu__item:focus-visible { outline: 2px solid var(--shell-accent); outline-offset: -2px; background: color-mix(in srgb, var(--shell-accent) 14%, transparent); }
button.nexus-profile-menu__item:active { background: color-mix(in srgb, var(--shell-accent) 20%, transparent); }
.nexus-profile-menu__icon { display: grid; place-items: center; flex: none; width: 20px; height: 20px; color: var(--profile-muted); }
button.nexus-profile-menu__item:hover .nexus-profile-menu__icon { color: inherit; }
.nexus-profile-menu svg { display: block; flex: none; pointer-events: none; }
.nexus-profile-menu__label { flex: 1; min-width: 0; overflow-wrap: anywhere; font-weight: 500; }
.nexus-profile-menu__value { max-width: 50%; color: var(--profile-muted); font-size: 12px; overflow-wrap: anywhere; text-align: end; }
.nexus-profile-menu__item--danger { color: #ffb4b0; }
.nexus-profile-menu__item--danger .nexus-profile-menu__icon { color: inherit; }
.nexus-profile-menu__item--danger:hover { color: #ffd4d1; background: #ef44441a; }
:root[data-theme="WhiteTheme"] .nexus-profile-menu__item--danger { color: #b42318; }
:root[data-theme="WhiteTheme"] .nexus-profile-menu__item--danger:hover { color: #912018; background: #b4231810; }
.nexus-profile-menu[dir="rtl"] { transform-origin: top left; }
@keyframes nexus-profile-menu-enter { from { opacity: 0; transform: translateY(-4px) scale(.985); } to { opacity: 1; transform: none; } }
@media (max-width: 479px) { .nexus-profile-menu { width: min(320px, calc(100vw - 16px)); border-radius: 18px; } .nexus-profile-menu__item { min-height: 48px; padding-block: 12px; } }
@media (prefers-reduced-motion: reduce) { .nexus-profile-menu { animation: none; } .nexus-profile-menu__item { transition: none; } }
@media (forced-colors: active) { .nexus-profile-menu { border-color: CanvasText; box-shadow: none; } .nexus-profile-menu__item--danger { color: ButtonText; } button.nexus-profile-menu__item:focus-visible { outline-color: Highlight; } }
