/*
 * Stable admin viewport: the shell stays in place while long data lists get
 * their own scroll container. This prevents the whole page from moving when
 * scanning users, models, purchases, or requests.
 */
html,body{height:100%;overflow:hidden}
.layout{height:100dvh;min-height:0;overflow:hidden}
.sidebar{min-height:0;overflow-y:auto;overscroll-behavior:contain}
.main{min-height:0;overflow:hidden;display:flex;flex-direction:column}
#content{min-height:0;flex:1;overflow:hidden;display:flex;flex-direction:column}
#content:not(.data-view){display:block;overflow:auto}
#content.data-view>.panel{min-height:0;height:100%;margin-bottom:0;display:flex;flex-direction:column;overflow:hidden}
#content.data-view>.panel>.table-wrap{min-height:0;flex:1;overflow:auto;overscroll-behavior:contain;border-radius:10px}
#content.data-view .table{min-width:1100px}
#content.data-view .table th{position:sticky;top:0;z-index:2;background:#1a211d;box-shadow:0 1px 0 #354139}
#content.data-view .section-head{flex:0 0 auto}

@media(max-width:1000px){
  html,body{height:auto;min-height:100%;overflow:auto}
  .layout{height:auto;min-height:100dvh;overflow:visible}
  .main{min-height:calc(100dvh - 112px);overflow:visible}
  #content{overflow:visible;display:block}
  #content.data-view>.panel{height:calc(100dvh - 230px);min-height:360px}
}

@media(max-width:520px){
  #content.data-view>.panel{height:calc(100dvh - 260px);min-height:320px}
  #content.data-view .table{min-width:980px}
}
