/* AdminMind 6.9.89 — même header global sur Family et Home. */

#familySheet .familyRootHeader.amFamilyGlobalHeaderV664{
  position:sticky!important;
  top:0!important;
  z-index:40!important;
  width:auto!important;
  min-height:calc(68px + env(safe-area-inset-top))!important;
  height:auto!important;
  margin:0 -16px 14px!important;
  padding:max(15px,env(safe-area-inset-top)) 18px 10px!important;
  display:flex!important;
  align-items:center!important;
  justify-content:space-between!important;
  gap:12px!important;
  background:rgba(245,246,250,.92)!important;
  border-bottom:1px solid rgba(218,222,233,.72)!important;
  box-shadow:0 5px 16px rgba(34,45,72,.035)!important;
  -webkit-backdrop-filter:blur(18px)!important;
  backdrop-filter:blur(18px)!important;
}

/* Exactement la même identité de marque que le header principal. */
#familySheet .amFamilyGlobalBrandV664{
  min-width:0!important;
  display:flex!important;
  align-items:center!important;
  gap:10px!important;
  color:var(--text)!important;
  font-weight:900!important;
  font-size:21px!important;
  line-height:1!important;
  letter-spacing:-.5px!important;
  cursor:pointer!important;
  -webkit-tap-highlight-color:transparent!important;
}
#familySheet .amFamilyGlobalBrandV664 .logo{
  width:35px!important;
  height:35px!important;
  flex:0 0 35px!important;
  border-radius:12px!important;
  overflow:hidden!important;
}
#familySheet .amFamilyGlobalBrandV664 .logo img{
  display:block!important;
  width:100%!important;
  height:100%!important;
  object-fit:cover!important;
}

/* Même trio de boutons : thème / voix / + */
#familySheet .amFamilyGlobalActionsV664{
  display:flex!important;
  align-items:center!important;
  gap:8px!important;
  flex:0 0 auto!important;
}
#familySheet .amFamilyGlobalActionsV664 .iconbtn{
  width:40px!important;
  height:40px!important;
  min-width:40px!important;
  padding:0!important;
  border-radius:14px!important;
  display:grid!important;
  place-items:center!important;
  line-height:1!important;
}
#familySheet .amFamilyGlobalActionsV664 .quickThemeBtn{
  font-size:20px!important;
}
#familySheet .amFamilyGlobalActionsV664 .voiceTopBtn{
  font-size:18px!important;
}
#familySheet .amFamilyGlobalActionsV664 .addTopBtn{
  font-size:20px!important;
}

/* Le logo sert aussi de retour discret : aucun bouton Retour supplémentaire. */
#familySheet .amFamilyGlobalBrandV664:active{
  opacity:.72!important;
  transform:scale(.99)!important;
}

/* Dark = exactement le même fond que la topbar globale. */
html[data-theme="dark"] #familySheet .familyRootHeader.amFamilyGlobalHeaderV664{
  background:rgba(13,16,23,.92)!important;
  border-bottom-color:#242b3a!important;
  box-shadow:0 7px 18px rgba(0,0,0,.14)!important;
}

/* Sur iOS on respecte l’optimisation GPU existante tout en gardant le rendu identique. */
html[data-ios] #familySheet .familyRootHeader.amFamilyGlobalHeaderV664{
  -webkit-backdrop-filter:none!important;
  backdrop-filter:none!important;
}
html[data-ios]:not([data-theme="dark"]) #familySheet .familyRootHeader.amFamilyGlobalHeaderV664{
  background:rgba(245,246,250,.98)!important;
}
html[data-ios][data-theme="dark"] #familySheet .familyRootHeader.amFamilyGlobalHeaderV664{
  background:rgba(13,16,23,.98)!important;
}

/* Petit iPhone : conserve les 3 actions sans compresser AdminMind. */
@media(max-width:350px){
  #familySheet .familyRootHeader.amFamilyGlobalHeaderV664{
    padding-left:14px!important;
    padding-right:14px!important;
    gap:8px!important;
  }
  #familySheet .amFamilyGlobalBrandV664{
    gap:8px!important;
    font-size:19px!important;
  }
  #familySheet .amFamilyGlobalBrandV664 .logo{
    width:33px!important;
    height:33px!important;
    flex-basis:33px!important;
  }
  #familySheet .amFamilyGlobalActionsV664{
    gap:6px!important;
  }
  #familySheet .amFamilyGlobalActionsV664 .iconbtn{
    width:38px!important;
    height:38px!important;
    min-width:38px!important;
  }
}
