/* STATBASKET CONSOLE UI V43 */
/* Tema chiaro completo: nessun pannello nero residuo */
html[data-sb-theme="light"],
html[data-sb-theme="light"] body,
body.sb-v37-light{
  background:#eef2f7!important;
  color:#111827!important;
}
html[data-sb-theme="light"] .header,
body.sb-v37-light .header{
  background:#fff!important;
  color:#0f172a!important;
  border-color:#f59e0b!important;
}
html[data-sb-theme="light"] .topbar,
body.sb-v37-light .topbar{
  background:#f8fafc!important;
  border-color:#cbd5e1!important;
}
html[data-sb-theme="light"] .guide,
html[data-sb-theme="light"] .last-action,
html[data-sb-theme="light"] .clock-box,
html[data-sb-theme="light"] .panel,
html[data-sb-theme="light"] #livePanel,
html[data-sb-theme="light"] #actionsPanel,
html[data-sb-theme="light"] #playersPanel,
html[data-sb-theme="light"] #sbProDashboard,
html[data-sb-theme="light"] .sbpro-tabs,
html[data-sb-theme="light"] .sbpro-body,
html[data-sb-theme="light"] .sbpro-footer,
html[data-sb-theme="light"] .sbpro-card,
html[data-sb-theme="light"] .sbpro-table-wrap,
html[data-sb-theme="light"] .sbpro-pbp,
body.sb-v37-light .guide,
body.sb-v37-light .last-action,
body.sb-v37-light .clock-box,
body.sb-v37-light .panel,
body.sb-v37-light #livePanel,
body.sb-v37-light #actionsPanel,
body.sb-v37-light #playersPanel,
body.sb-v37-light #sbProDashboard,
body.sb-v37-light .sbpro-tabs,
body.sb-v37-light .sbpro-body,
body.sb-v37-light .sbpro-footer,
body.sb-v37-light .sbpro-card,
body.sb-v37-light .sbpro-table-wrap,
body.sb-v37-light .sbpro-pbp{
  background:#fff!important;
  color:#111827!important;
  border-color:#cbd5e1!important;
}
html[data-sb-theme="light"] .qbox,
html[data-sb-theme="light"] .mini-team,
html[data-sb-theme="light"] .sbpro-pbp-row,
html[data-sb-theme="light"] .sbpro-stat,
body.sb-v37-light .qbox,
body.sb-v37-light .mini-team,
body.sb-v37-light .sbpro-pbp-row,
body.sb-v37-light .sbpro-stat{
  background:#f8fafc!important;
  color:#111827!important;
  border-color:#d8e0ea!important;
}
html[data-sb-theme="light"] .sbpro-pbp-row *,
body.sb-v37-light .sbpro-pbp-row *{color:#111827!important}

/* Popup azioni */
#actionsPanel{
  position:fixed!important;
  inset:12px!important;
  z-index:440000!important;
  width:auto!important;
  height:calc(100dvh - 24px)!important;
  max-height:calc(100dvh - 24px)!important;
  margin:0!important;
  padding:18px!important;
  overflow:hidden!important;
  border:4px solid var(--sb-action-team-color,var(--home-color))!important;
  border-radius:24px!important;
  background:#fff!important;
  color:#111827!important;
  box-shadow:0 30px 100px #000b!important;
}
body.sb-v40-home-selected #actionsPanel{--sb-action-team-color:var(--home-color)}
body.sb-v40-away-selected #actionsPanel{--sb-action-team-color:var(--away-color)}
.sb-v43-actions-head{
  display:grid!important;
  grid-template-columns:1fr auto!important;
  align-items:center!important;
  gap:12px!important;
  margin-bottom:14px!important;
}
#actionsPanel .panel-title{
  min-height:72px!important;
  display:flex!important;
  align-items:center!important;
  justify-content:center!important;
  margin:0!important;
  padding:14px 20px!important;
  border-radius:16px!important;
  background:var(--sb-action-team-color,var(--home-color))!important;
  color:#fff!important;
  font-size:clamp(32px,3.4vw,50px)!important;
  font-weight:1000!important;
}
.sb-v43-actions-close{
  min-width:150px!important;
  height:72px!important;
  border:0!important;
  border-radius:15px!important;
  background:#475569!important;
  color:#fff!important;
  padding:0 16px!important;
  font-size:15px!important;
  font-weight:1000!important;
}
#actionsPanel .actions{
  height:calc(100% - 100px)!important;
  display:grid!important;
  grid-template-columns:repeat(3,minmax(0,1fr))!important;
  grid-auto-rows:minmax(0,1fr)!important;
  gap:12px!important;
}
#actionsPanel .action{
  min-width:0!important;
  min-height:0!important;
  height:auto!important;
  font-size:clamp(32px,4.2vw,64px)!important;
  border-radius:20px!important;
}
#actionsPanel .staff-box{
  position:absolute!important;
  left:18px!important;
  right:18px!important;
  bottom:18px!important;
  display:flex!important;
  gap:10px!important;
}
#actionsPanel .staff-btn{height:48px!important}

/* Main sempre pulita dopo la registrazione */
body.sb-step-team #actionsPanel,
body.sb-step-team #playersPanel{display:none!important}

@media(max-width:700px),(orientation:portrait) and (max-width:900px){
  body:not(.sb-layout-desktop) #actionsPanel{
    inset:4px!important;
    height:calc(100dvh - 8px)!important;
    max-height:calc(100dvh - 8px)!important;
    padding:8px!important;
    border-radius:15px!important;
  }
  body:not(.sb-layout-desktop) .sb-v43-actions-head{gap:6px!important;margin-bottom:7px!important}
  body:not(.sb-layout-desktop) #actionsPanel .panel-title{min-height:50px!important;padding:8px!important;font-size:25px!important}
  body:not(.sb-layout-desktop) .sb-v43-actions-close{min-width:88px!important;height:50px!important;padding:0 6px!important;font-size:10px!important}
  body:not(.sb-layout-desktop) #actionsPanel .actions{height:calc(100% - 64px)!important;grid-template-columns:repeat(3,minmax(0,1fr))!important;gap:6px!important}
  body:not(.sb-layout-desktop) #actionsPanel .action{font-size:27px!important;border-radius:11px!important}
  body:not(.sb-layout-desktop) #actionsPanel .staff-box{left:8px!important;right:8px!important;bottom:8px!important}
  body:not(.sb-layout-desktop) #actionsPanel .staff-btn{height:38px!important;font-size:10px!important}
}
