/* PE-Class v1.15.65 — 설정 카드 비대칭 2열·하단 기준선 정렬 */
.adminOpsLeftStack{
  display:grid;
  grid-template-columns:minmax(0,1fr);
  align-content:start;
  gap:16px;
  min-width:0;
}
.adminOpsLeftStack>.adminCard{
  width:100%;
  min-width:0;
  height:auto!important;
  box-sizing:border-box;
}

@media(min-width:1001px) and (hover:hover) and (pointer:fine){
  html:not(.pe87Ipad):not(.pe87IpadRuntime):not(.pe87FoldWide) .adminOpsGridWithSchool{
    display:grid!important;
    grid-template-columns:minmax(300px,.76fr) minmax(0,1.34fr)!important;
    gap:16px!important;
    align-items:start!important;
  }
  html:not(.pe87Ipad):not(.pe87IpadRuntime):not(.pe87FoldWide) .adminOpsLeftStack{
    height:clamp(520px,68dvh,690px);
    grid-template-rows:auto minmax(0,1fr);
    align-content:stretch;
  }
  html:not(.pe87Ipad):not(.pe87IpadRuntime):not(.pe87FoldWide) .adminOpsLeftStack>.adminSchoolCard{
    height:100%!important;
    min-height:0;
    align-self:stretch;
  }
  html:not(.pe87Ipad):not(.pe87IpadRuntime):not(.pe87FoldWide) .adminOpsGridWithSchool>.adminSubjectCard{
    width:100%;
    min-width:0;
    height:clamp(520px,68dvh,690px)!important;
    max-height:690px;
    align-self:start;
    box-sizing:border-box;
  }
  html:not(.pe87Ipad):not(.pe87IpadRuntime):not(.pe87FoldWide) .adminSubjectCard #adminSubjectRows{
    flex:1 1 auto;
    min-height:0;
    overflow-x:hidden;
    overflow-y:auto;
    overscroll-behavior:contain;
    padding-right:5px;
    scrollbar-gutter:stable;
  }
  html:not(.pe87Ipad):not(.pe87IpadRuntime):not(.pe87FoldWide) .adminSubjectCard>.adminAddRow{
    flex:0 0 auto;
    margin:12px 0 0;
    padding-top:12px;
    border-top:1px solid #e3ebf2;
  }
}

/* iPad·모바일은 기존 한 열 흐름을 유지하고 종목 목록만 적당한 높이에서 스크롤 */
@media(max-width:1000px), (hover:none), (pointer:coarse){
  .adminOpsGridWithSchool{
    grid-template-columns:minmax(0,1fr)!important;
    align-items:start!important;
  }
  .adminOpsGridWithSchool>.adminSubjectCard,
  .adminOpsLeftStack>.adminCard{
    width:100%;
    min-width:0;
    height:auto!important;
  }
  .adminSubjectCard #adminSubjectRows{
    max-height:520px;
    overflow-x:hidden;
    overflow-y:auto;
    overscroll-behavior:contain;
    padding-right:4px;
  }
}
