/* ===========================================================
   FINAL FIX
   1. ALTE Bubble verstecken (ai-bubble.js Output)
   2. ALTE Sprach-Switcher in Header verstecken
   3. Admin-Sidebar-Item verstecken
   4. Analyse-Bereich: Text in Rahmen bringen
   5. Neue Bubble draggable
   =========================================================== */

/* === 1. ALTE BUBBLE VERSTECKEN (ai-bubble.js) === */
/* Bekannte Selektoren der alten Bubble */
.ai-bubble,
.ai-bub,
#aiBubble,
#aiBub,
.help-bubble,
#helpBubble,
.chat-bubble:not(.azn-bub-btn):not(.azn-bub-panel),
#chatBubble,
.bot-bubble,
#botBubble,
.tutor-bubble,
#tutorBubble,
[class*="ai-bubble"]:not([class*="azn"]),
[id*="ai-bubble"]:not([id*="azn"]){
  display:none!important;
  visibility:hidden!important;
  opacity:0!important;
  pointer-events:none!important
}

/* === 2. ALTE SPRACH-SWITCHER IN HEADER VERSTECKEN === */
/* Bekannte alte Selektoren */
.lang-switcher:not(.azn-lang),
.language-switcher:not(.azn-lang),
.lang-toggle,
#langSwitcher:not(.azn-lang),
#languageSwitcher,
.translate-btn:not(.azn-lang-btn),
.lang-dropdown:not(.azn-lang-menu),
[class*="lang-"]:not([class*="azn-"]):not(.ak-lang),
.ak-nav-r .lang:not(.azn-lang),
.ak-nav-r [class*="DE"]:not(.azn-lang-btn):not(.azn-lang-menu *),
.ak-nav-r > button:not(.ak-cta):not(.azn-lang-btn):not([class*="azn"]){
  display:none!important
}
/* Spezial: "DE DE ▾" Text-Knopf in der Topbar */
.ak-nav-r button[onclick*="lang"]:not(.azn-lang-btn),
.ak-nav-r button[onclick*="trans"]:not(.azn-lang-btn),
.ak-nav-r a[onclick*="lang"]:not(.azn-lang-btn){
  display:none!important
}

/* === 3. ADMIN AUS SIDEBAR === */
.s-item[data-panel="admin"],
#adminBtn,
button[data-panel="admin"]{
  display:none!important
}

/* === 4. ANALYSE-BEREICH: Inhalte in Rahmen === */
/* App.js rendert in #mainContent rohe Text-Elemente fuer Analyse.
   Wir wrappen die direkten Text-Inhalte in Cards. */
#mainContent .analyse-section,
#mainContent .analytics-content,
#mainContent [class*="analyse"],
#mainContent [class*="analytics"]{
  background:rgba(20,20,32,.6)!important;
  border:1px solid rgba(255,255,255,.08)!important;
  border-radius:18px!important;
  padding:24px!important;
  margin-bottom:18px!important;
  backdrop-filter:blur(14px)
}

/* Wenn Analyse-Panel aktiv: alle direkten div-children mit Stats in Cards */
#mainContent > div > div:not(.pp-hero):not(.pp-audit):not(.pp-filters):not(.dm-hero):not(.pd-hero):not(.pd-stats):not(.pd-bento):not(.pd-berufe):not(.pd-banner):not(.pd-sec){
  background:rgba(20,20,32,.4);
  border:1px solid rgba(255,255,255,.05);
  border-radius:14px;
  padding:16px 20px;
  margin-bottom:14px;
  transition:all .25s
}

/* === 5. NEUE BUBBLE DRAGGABLE === */
.azn-bub-btn{
  cursor:grab!important;
  user-select:none;
  touch-action:none
}
.azn-bub-btn:active{cursor:grabbing!important}
.azn-bub-btn.dragging{
  animation:none!important;
  transition:none!important;
  box-shadow:0 24px 60px -10px rgba(0,245,255,.7),0 12px 30px rgba(0,0,0,.6)!important
}
.azn-bub-btn.was-dragged::before{
  content:"";position:absolute;inset:-3px;border-radius:50%;
  background:linear-gradient(135deg,rgba(0,245,255,.4),rgba(255,0,110,.4));
  z-index:-1;opacity:0;
  animation:bubDropPing .6s ease-out
}
@keyframes bubDropPing{
  0%{opacity:1;transform:scale(1)}
  100%{opacity:0;transform:scale(1.4)}
}
