/* ============================================================
   H2B V87 — interface compacte et cohérente
   - pas d'états vides affichés inutilement
   - actions admin replacées sous menu/recherche
   - panneaux plus courts et lisibles
   - photo optionnelle dans le Top 3 du profil adhérent
   ============================================================ */

/* Direction artistique compacte sur les espaces connectés. */
#adminView .page-head,
#memberView .page-head{
  align-items:flex-start;
  margin-bottom:12px;
  gap:12px;
}
#adminView .page-head h2,
#memberView .page-head h2{
  font-size:clamp(30px,3.4vw,46px);
  margin:7px 0 4px;
  line-height:1;
}
#adminView .page-head p,
#memberView .page-head p{
  font-size:11px;
  line-height:1.35;
  max-width:760px;
}

#adminView .admin-grid,
#memberView .member-grid{
  gap:10px;
}
#adminView .stats-grid,
#memberView .stats-grid{
  gap:10px;
  margin-bottom:10px;
}
#adminView .stat-card,
#memberView .stat-card{
  padding:13px 14px;
  border-radius:14px;
}
#adminView .stat-card strong,
#memberView .stat-card strong{
  font-size:25px;
  margin:5px 0 2px;
}

#adminView .card.panel,
#memberView .card.panel{
  padding:12px 14px;
  border-radius:15px;
}
#adminView .panel-head,
#memberView .panel-head{
  gap:10px;
  margin-bottom:9px;
}
#adminView .panel-head h3,
#memberView .panel-head h3{
  font-size:15px;
  margin-bottom:2px;
  line-height:1.15;
}
#adminView .panel-head p,
#memberView .panel-head p{
  font-size:10.5px;
  line-height:1.35;
}
#adminView .panel-tools,
#memberView .panel-tools{
  gap:6px;
}
#adminView .table-wrap,
#memberView .table-wrap{
  border-radius:10px;
}
#adminView th,#adminView td,
#memberView th,#memberView td{
  padding:9px 10px;
}

/* Aucun texte "Aucune..." dans les espaces connectés. */
#adminView .empty,
#memberView .empty{
  display:none!important;
}
#adminView .h2b-v87-empty-panel,
#memberView .h2b-v87-empty-panel{
  display:none!important;
}

/* Les actions administratives ne flottent plus sur la photo de fond. */
#adminView .page-head>.page-actions{
  display:none!important;
}
#adminView .h2b-v87-context-actions{
  width:max-content;
  max-width:100%;
  display:flex;
  align-items:flex-end;
  gap:7px;
  margin:7px 0 12px;
  padding:6px;
  border:1px solid rgba(255,255,255,.085);
  border-radius:12px;
  background:#080d13;
  box-shadow:0 8px 24px rgba(0,0,0,.18);
}
#adminView .h2b-v87-context-actions .btn{
  min-height:36px;
  padding:8px 11px;
  border-radius:9px;
  font-size:11px;
  white-space:nowrap;
}
#adminView .h2b-v87-context-actions .season-box{
  width:142px;
  min-width:142px;
}
#adminView .h2b-v87-context-actions .season-box label{
  margin:0 0 3px;
  font-size:9px;
  letter-spacing:.05em;
}
#adminView .h2b-v87-context-actions .season-box input{
  min-height:36px;
  padding:7px 9px;
  border-radius:9px;
  font-size:11px;
}

/* Navigation admin encore plus compacte. */
#adminView .h2b-admin-nav-bar{
  margin-bottom:7px;
  gap:7px;
}
#adminView .h2b-admin-menu-toggle,
#adminView .h2b-admin-quick-search input{
  min-height:40px;
}

/* Centre de notifications : barre courte, jamais un gros pavé. */
#adminNotificationsPanel .notification-settings-card,
#memberNotificationsPanel .notification-settings-card{
  padding:9px 11px!important;
}
#adminNotificationsPanel .notification-settings-card .panel-head,
#memberNotificationsPanel .notification-settings-card .panel-head{
  display:flex;
  flex-direction:row;
  align-items:center;
  justify-content:space-between;
  margin:0;
  gap:8px;
}
#adminNotificationsPanel .notification-settings-card .eyebrow,
#memberNotificationsPanel .notification-settings-card .eyebrow,
#adminNotificationsPanel .notification-settings-card .panel-head p,
#memberNotificationsPanel .notification-settings-card .panel-head p{
  display:none;
}
#adminNotificationsPanel .notification-settings-card .panel-head h3,
#memberNotificationsPanel .notification-settings-card .panel-head h3{
  margin:0;
  font-size:13px;
}
#adminNotificationsPanel .notification-actions,
#memberNotificationsPanel .notification-actions{
  gap:5px;
  flex-wrap:wrap;
  justify-content:flex-end;
}
#adminNotificationsPanel .notification-actions .btn,
#memberNotificationsPanel .notification-actions .btn{
  min-height:34px;
  padding:7px 9px;
  font-size:10px;
  border-radius:9px;
}
#adminNotificationsPanel .notification-permission-state,
#memberNotificationsPanel .notification-permission-state{
  margin-top:5px;
  padding:0!important;
  border:0!important;
  background:transparent!important;
  font-size:9px;
  line-height:1.2;
  opacity:.7;
}
#adminNotificationsPanel>.card.panel+ .card.panel,
#memberNotificationsPanel>.card.panel+ .card.panel{
  margin-top:8px;
}

/* Top 3 : photo affichée uniquement lorsqu'elle existe réellement. */
.h2b-profile-top3-row{
  gap:7px!important;
}
.h2b-profile-top3-row.has-photo{
  grid-template-columns:24px 30px minmax(0,1fr) auto;
}
.h2b-profile-top3-photo{
  width:30px;
  height:30px;
  flex:0 0 30px;
  border-radius:999px;
  overflow:hidden;
  border:1px solid rgba(255,255,255,.16);
  background:#080c12;
}
.h2b-profile-top3-photo img{
  width:100%;
  height:100%;
  display:block;
  object-fit:cover;
}
.h2b-profile-top3-row .medal{
  flex:0 0 auto;
}
.h2b-profile-top3-row b{
  min-width:0;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}

/* Compactage des gros blocs secondaires. */
#adminView .connection-stat,
#adminView .attendance-summary-card,
#adminView .competition-stat-card,
#memberView .attendance-summary-card,
#memberView .competition-stat-card{
  padding:10px 11px;
  border-radius:12px;
}

@media(max-width:980px){
  #adminView .panel-head,
  #memberView .panel-head{
    gap:7px;
  }
  #adminNotificationsPanel .notification-settings-card .panel-head,
  #memberNotificationsPanel .notification-settings-card .panel-head{
    flex-direction:column;
    align-items:flex-start;
  }
  #adminNotificationsPanel .notification-actions,
  #memberNotificationsPanel .notification-actions{
    width:100%;
    justify-content:flex-start;
  }
}

@media(max-width:620px){
  #adminView .app-shell,#memberView.app-shell{padding-left:12px;padding-right:12px}
  #adminView .h2b-v87-context-actions{
    width:100%;
    display:grid;
    grid-template-columns:minmax(0,1fr) 126px;
    align-items:end;
  }
  #adminView .h2b-v87-context-actions .season-box{
    width:126px;
    min-width:0;
  }
  #adminView .card.panel,
  #memberView .card.panel{
    padding:11px 12px;
  }
  .h2b-profile-top3-photo{width:28px;height:28px;flex-basis:28px}
}
