/* ec-mbf.css — §MBF-2026-11-09 (Master-Bugfix 09.11.). Loads LAST (after ec-aura-dashboard.css).
   The mobile shell cascade stacks 6-fold #ec-mobile-shell IDs with !important; these rules use 7 IDs so they win
   without touching the older files. One block per brief item; each block is self-contained and removable. */

/* ── 2A · Chats ⋮ menu + 7 · Contacts "+" menu: Obsidian glass list, icon LEFT (20 px), text right ───────────── */
html body.ec-mobile-shell-active #ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell .ec-mobile-chat-action-menu,
html body.ec-mobile-shell-active #ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell .ec-mobile-contact-add-menu {
  background: rgba(18, 18, 20, 0.95) !important;
  -webkit-backdrop-filter: blur(20px) saturate(1.1) !important; backdrop-filter: blur(20px) saturate(1.1) !important;
  border: 1px solid rgba(255, 255, 255, 0.12) !important;
  border-radius: 14px !important;
  box-shadow: 0 18px 44px rgba(0, 0, 0, 0.62) !important;
  padding: 6px !important;
}
html body.ec-mobile-shell-active #ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell .ec-mobile-chat-action-menu:not([hidden]),
html body.ec-mobile-shell-active #ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell .ec-mobile-contact-add-menu:not([hidden]) {
  display: flex !important; flex-direction: column !important; gap: 2px !important;
  width: 220px !important; min-width: 220px !important; max-width: calc(100vw - 32px) !important;
  z-index: 1000 !important;
}
/* 7 · Root cause of the broken Kontakte header: the contacts sheet (.ec-pp-contacts) is NOT inside
   [data-ecm-panel="rooms"], so the older absolute-position rules never matched there and the open menu
   joined the header's flex row (title + TLS pill collapsed). Anchor it to its own shell everywhere. */
html body.ec-mobile-shell-active #ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell .ec-mobile-contact-add-shell {
  position: relative !important;
}
html body.ec-mobile-shell-active #ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell .ec-mobile-contact-add-menu:not([hidden]) {
  position: absolute !important; top: calc(100% + 8px) !important; right: 0 !important; left: auto !important; bottom: auto !important;
  margin: 0 !important; grid-template-columns: none !important;
}
html body.ec-mobile-shell-active #ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell .ec-mobile-chat-action-menu:not([hidden]) > button,
html body.ec-mobile-shell-active #ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell .ec-mobile-contact-add-menu:not([hidden]) > button {
  display: flex !important; flex-direction: row !important; align-items: center !important; justify-content: flex-start !important;
  gap: 12px !important; width: 100% !important; min-height: 44px !important; height: auto !important;
  padding: 0 12px !important; margin: 0 !important; grid-column: auto !important;
  border: 0 !important; border-radius: 10px !important; background: transparent !important; box-shadow: none !important;
  color: #f4f4f5 !important; text-align: left !important;
}
html body.ec-mobile-shell-active #ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell .ec-mobile-chat-action-menu:not([hidden]) > button:active,
html body.ec-mobile-shell-active #ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell .ec-mobile-contact-add-menu:not([hidden]) > button:active { background: rgba(255, 255, 255, 0.08) !important; }
@media (hover: hover) and (pointer: fine) {
  html body.ec-mobile-shell-active #ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell .ec-mobile-chat-action-menu:not([hidden]) > button:hover,
  html body.ec-mobile-shell-active #ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell .ec-mobile-contact-add-menu:not([hidden]) > button:hover { background: rgba(255, 255, 255, 0.06) !important; }
}
/* icon slot: always first, fixed 20 × 20, platinum */
html body.ec-mobile-shell-active #ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell .ec-mobile-chat-action-menu > button > span,
html body.ec-mobile-shell-active #ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell .ec-mobile-contact-add-menu > button > span {
  order: 0 !important; flex: 0 0 20px !important; display: inline-flex !important; align-items: center !important; justify-content: center !important;
  width: 20px !important; height: 20px !important; min-width: 20px !important; margin: 0 !important; padding: 0 !important;
  border: 0 !important; border-radius: 0 !important; background: none !important; box-shadow: none !important;
  color: #d4d4d8 !important; font-size: 16px !important; line-height: 1 !important;
}
html body.ec-mobile-shell-active #ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell .ec-mobile-chat-action-menu > button > span svg,
html body.ec-mobile-shell-active #ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell .ec-mobile-contact-add-menu > button > span svg {
  width: 20px !important; height: 20px !important; min-width: 20px !important; display: block !important;
}
html body.ec-mobile-shell-active #ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell .ec-mobile-chat-action-menu > button > strong,
html body.ec-mobile-shell-active #ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell#ec-mobile-shell .ec-mobile-contact-add-menu > button > strong {
  order: 1 !important; flex: 1 1 auto !important; min-width: 0 !important;
  font-size: 15px !important; font-weight: 500 !important; line-height: 1.25 !important; letter-spacing: -0.005em !important;
  color: #f4f4f5 !important; text-align: left !important; white-space: normal !important;
}

/* ── 2B · Chat-Info sheet: neutral platinum rows · amber "Gruppe verwalten" · crimson danger zone at the bottom ── */
html body #room-options-modal#room-options-modal#room-options-modal .ec-gm-row:not(.ec-gm-row--manage):not(.ec-gm-row--danger):not(.ec-gm-row--close) {
  background: rgba(255, 255, 255, 0.03) !important; border: 1px solid rgba(255, 255, 255, 0.08) !important; color: #e4e4e7 !important;
}
html body #room-options-modal#room-options-modal#room-options-modal .ec-gm-row:not(.ec-gm-row--manage):not(.ec-gm-row--danger):not(.ec-gm-row--close) .ec-gm-row-icon {
  background: rgba(255, 255, 255, 0.06) !important; color: #d4d4d8 !important;
}
@media (hover: hover) and (pointer: fine) {
  html body #room-options-modal#room-options-modal#room-options-modal .ec-gm-row:not(.ec-gm-row--manage):not(.ec-gm-row--danger):not(.ec-gm-row--close):hover {
    background: rgba(255, 255, 255, 0.07) !important; border-color: rgba(255, 255, 255, 0.18) !important; box-shadow: none !important; color: #fff !important;
  }
}
html body #room-options-modal#room-options-modal#room-options-modal .ec-gm-row--manage {
  border: 1px solid rgba(166, 166, 166, 0.4) !important; background: rgba(166, 166, 166, 0.1) !important; color: #c1c1c1 !important; box-shadow: none !important;
}
html body #room-options-modal#room-options-modal#room-options-modal .ec-gm-row--manage .ec-gm-row-icon { background: rgba(166, 166, 166, 0.14) !important; color: #c1c1c1 !important; }
html body #room-options-modal#room-options-modal#room-options-modal .ec-gm-row--manage .ec-gm-row-chev { color: rgba(193, 193, 193, 0.7) !important; }
html body #room-options-modal#room-options-modal#room-options-modal .ec-gm-row--manage:hover { background: rgba(166, 166, 166, 0.16) !important; border-color: rgba(166, 166, 166, 0.55) !important; color: #d2d2d2 !important; box-shadow: none !important; }
html body #room-options-modal#room-options-modal#room-options-modal .ec-gm-row--danger {
  border: 1px solid rgba(239, 68, 68, 0.45) !important; background: rgba(239, 68, 68, 0.12) !important; color: #f87171 !important; box-shadow: none !important;
}
html body #room-options-modal#room-options-modal#room-options-modal .ec-gm-row--danger .ec-gm-row-icon { background: rgba(239, 68, 68, 0.16) !important; color: #f87171 !important; }
html body #room-options-modal#room-options-modal#room-options-modal .ec-gm-row--danger .ec-gm-row-chev { color: rgba(248, 113, 113, 0.7) !important; }
html body #room-options-modal#room-options-modal#room-options-modal .ec-gm-row--danger:hover { background: rgba(239, 68, 68, 0.18) !important; border-color: rgba(239, 68, 68, 0.6) !important; color: #fca5a5 !important; box-shadow: none !important; }
html body #room-options-modal#room-options-modal#room-options-modal .ec-gm-danger-sep {
  height: 1px; margin: 6px 4px 2px; background: rgba(239, 68, 68, 0.22); flex: none;
}

/* ── 6 · Avatar camera badge always above the photo ───────────────────────────────────────────────────────── */
html body #ec-profile-editor-modal#ec-profile-editor-modal .ec-pe-cam {
  position: absolute !important; bottom: 4px !important; right: 4px !important; z-index: 10 !important;
  box-shadow: 0 0 0 2px #000000, 0 4px 12px rgba(0, 0, 0, 0.5) !important;
}

/* ── 8 · Aura on phones (< 768 px): full-height native sheet, ✕ visible, no traffic lights ──────────────────── */
@media (max-width: 767px) {
  html body #aura-chat-window#aura-chat-window#aura-chat-window.aura-obsidian {
    top: 0 !important; left: 0 !important; right: 0 !important; bottom: 0 !important;
    width: 100% !important; max-width: none !important;
    height: 100vh !important; height: 100dvh !important; max-height: 100dvh !important; min-height: 0 !important;
    margin: 0 !important; border-radius: 0 !important;
    padding-top: env(safe-area-inset-top, 0px) !important; padding-bottom: env(safe-area-inset-bottom, 0px) !important;
    box-sizing: border-box !important;
  }
  html body #aura-chat-window#aura-chat-window#aura-chat-window.aura-obsidian .aura-chrome { display: none !important; }
  html body #aura-chat-window#aura-chat-window#aura-chat-window.aura-obsidian .aura-sheet-grip { display: none !important; }
  html body #aura-chat-window#aura-chat-window#aura-chat-window.aura-obsidian .aura-close { display: grid !important; }
}
