/* AlpenPuls Portal 3.1.3
   Server-Fade switch visual/click fix + clear active state. */

/* Background area: same functions, less vertical space. */
.background-manager{
  grid-template-columns:148px minmax(0,1fr);
  gap:12px;
  padding:11px 12px;
  margin-bottom:10px;
}
.background-preview-wrap{border-radius:11px}
.background-manager-head h3{font-size:15px}
.background-manager-note{
  margin:4px 0 7px;
  font-size:10px;
  line-height:1.35;
  display:-webkit-box;
  -webkit-line-clamp:2;
  -webkit-box-orient:vertical;
  overflow:hidden;
}
.background-upload-info{margin-top:5px;font-size:8px}
.background-opt-badge{padding:4px 7px;font-size:8px}
.background-manager-actions .compact{min-height:31px;padding:6px 10px}
.season-quick-entry{
  margin-top:7px!important;
  padding-top:7px!important;
  gap:9px!important;
}
.season-quick-entry>div{
  display:flex!important;
  align-items:center;
  gap:8px!important;
  flex-wrap:wrap;
}
.season-quick-entry .eyebrow{margin:0}
.season-quick-entry strong{font-size:11px!important}
.season-quick-entry small{font-size:8px!important}
.season-quick-entry .ghost-button{min-height:29px;padding:5px 9px}

/* Replace native <details> behaviour with an explicit, reliable panel. */
.season-panel{
  display:block!important;
  margin:0 12px 10px;
  overflow:hidden;
}
.season-panel-toggle{
  width:100%;
  min-height:58px;
  padding:10px 14px;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  appearance:none;
  border:0;
  background:transparent;
  color:inherit;
  text-align:left;
  cursor:pointer;
}
.season-panel-toggle:hover{background:rgba(255,255,255,.018)}
.season-panel-toggle:focus-visible{outline:2px solid rgba(61,216,255,.65);outline-offset:-2px}
.season-toggle-right{display:flex;align-items:center;gap:11px;flex:0 0 auto}
.season-chevron{
  width:9px;
  height:9px;
  border-right:2px solid #8fb3c9;
  border-bottom:2px solid #8fb3c9;
  transform:rotate(45deg);
  transition:transform .18s ease,border-color .18s ease;
}
.season-panel.is-open .season-chevron{transform:rotate(-135deg)}
.season-panel.is-open .season-panel-toggle{border-bottom:1px solid rgba(255,255,255,.055)}
.season-panel .season-settings-body{padding:0 14px 14px;border-top:0}
.season-panel .season-settings-body[hidden]{display:none!important}

/* The old native-details summary rules must never interfere with the custom panel. */
.season-panel>summary{display:none!important}
.season-panel .season-summary-copy::after{display:none!important}

@media(max-width:760px){
  .background-manager{
    grid-template-columns:104px minmax(0,1fr);
    gap:9px;
    padding:9px;
  }
  .background-preview-wrap{max-height:72px}
  .background-manager-note{-webkit-line-clamp:2;font-size:8.5px}
  .season-quick-entry>div{gap:5px!important}
  .season-quick-entry small{display:none}
  .season-panel{margin:0 8px 9px;border-radius:14px}
  .season-panel-toggle{min-height:54px;padding:9px 11px}
  .season-panel .season-settings-body{padding:0 10px 10px}
}

@media(max-width:520px){
  .background-manager{grid-template-columns:92px minmax(0,1fr)}
  .background-preview-wrap{max-height:64px}
  .background-manager-head h3{font-size:12px}
  .background-manager-note{display:none}
  .background-upload-info{display:none}
  .season-quick-entry{grid-column:1/-1}
}

/* V3.1.2 - Server-Fade controls live inside the compact background manager.
   This avoids the admin grid swallowing the standalone season panel. */
.background-manager{
  align-items:start;
}
.background-manager > .season-panel{
  grid-column:1 / -1;
  width:100%;
  margin:0!important;
  border:0!important;
  border-radius:0!important;
  background:transparent!important;
  box-shadow:none!important;
  overflow:visible!important;
}
.background-manager > .season-panel .season-panel-toggle{
  display:none!important;
}
.background-manager > .season-panel .season-settings-body{
  margin-top:9px;
  padding:12px!important;
  border:1px solid rgba(58,211,255,.15)!important;
  border-radius:14px;
  background:linear-gradient(135deg,rgba(5,30,48,.60),rgba(4,18,29,.88));
  box-shadow:inset 0 1px rgba(255,255,255,.025),0 12px 28px rgba(0,0,0,.12);
}
.background-manager > .season-panel .season-settings-body[hidden]{display:none!important}
.background-manager > .season-panel.is-open .season-settings-body{display:block!important}
.background-manager:has(> .season-panel.is-open){padding-bottom:12px}
.season-quick-entry{margin-bottom:0!important}
.season-quick-entry .ghost-button[aria-expanded="true"]{
  border-color:rgba(57,216,255,.34);
  background:rgba(24,122,166,.14);
  color:#dff8ff;
}
@media(max-width:760px){
  .background-manager > .season-panel .season-settings-body{padding:10px!important;margin-top:7px}
}


/* V3.1.3 - Server-Fade switch: same behavior as the other portal switches. */
.season-enable{
  cursor:pointer;
  user-select:none;
  -webkit-user-select:none;
}
.season-enable>input{
  position:absolute;
  width:1px;
  height:1px;
  margin:-1px;
  padding:0;
  opacity:0;
  overflow:hidden;
  clip:rect(0 0 0 0);
  clip-path:inset(50%);
  white-space:nowrap;
  pointer-events:auto;
}
.season-enable>input:checked + .animation-switch{
  background:rgba(35,176,232,.28);
  border-color:rgba(67,208,255,.38);
  box-shadow:0 0 12px rgba(51,209,255,.12);
}
.season-enable>input:checked + .animation-switch::after{
  transform:translateX(15px);
  background:#81e7ff;
  box-shadow:0 0 8px rgba(129,231,255,.55),0 1px 4px rgba(0,0,0,.34);
}
.season-enable>input:focus-visible + .animation-switch{
  outline:2px solid rgba(61,216,255,.72);
  outline-offset:3px;
}
.season-enabled-state{
  margin-left:auto;
  min-width:48px;
  text-align:center;
  border-radius:999px;
  padding:4px 8px;
  border:1px solid rgba(255,255,255,.10);
  background:rgba(255,255,255,.04);
  color:#93a7b5;
  font-size:9px;
  line-height:1;
  letter-spacing:.08em;
  font-weight:800;
}
.season-enabled-state::before{content:'AUS'}
.season-enable>input:checked ~ .season-enabled-state{
  color:#82e8b8;
  border-color:rgba(68,222,160,.25);
  background:rgba(68,222,160,.07);
}
.season-enable>input:checked ~ .season-enabled-state::before{content:'AKTIV'}
