/* ================================================================
   Brimedge Admin Panel - Standard Shell
   ================================================================ */
:root{
  --adm-font:          "Segoe UI", -apple-system, BlinkMacSystemFont, "Inter", Roboto, "Helvetica Neue", Arial, sans-serif;
  --adm-sidebar-bg:    #1f2433;
  --adm-sidebar-border:rgba(255,255,255,.08);
  --adm-sidebar-text:  #b7bdce;
  --adm-sidebar-muted: #7d8498;
  --adm-accent:        #70167e;
  --adm-accent-dark:   #4a2559;
  --adm-bg:            #f3f5f9;
  --adm-surface:       #ffffff;
  --adm-border:        #e4e8ef;
  --adm-text:          #2b3244;
  --adm-muted:         #6b7280;
  --adm-danger:        #d64545;
  --adm-radius:        10px;
  --adm-shadow:        0 1px 3px rgba(20,24,40,.07), 0 1px 2px rgba(20,24,40,.04);
  --adm-sidebar-w:     260px;
}

.be-admin{
  background: var(--adm-bg);
  min-height: 100vh;
  font-family: var(--adm-font);
  font-size: 14px;
  line-height: 1.55;
  color: var(--adm-text);
  -webkit-font-smoothing: antialiased;
}
.be-admin h1, .be-admin h2, .be-admin h3, .be-admin h4, .be-admin h5, .be-admin h6{ font-weight: 600; }

/* ----------------------------------------------------------------
   SIDEBAR
   ---------------------------------------------------------------- */
.be-sidebar{
  position: fixed;
  inset: 0 auto 0 0;
  width: var(--adm-sidebar-w);
  z-index: 1045;
  background: var(--adm-sidebar-bg);
  color: #fff;
  display: flex;
  flex-direction: column;
  /* A fixed sidebar ignores the padding on the shell, so it is inset here to
     keep its brand and footer clear of the status and navigation bars. */
  top: env(safe-area-inset-top, 0px);
  bottom: env(safe-area-inset-bottom, 0px);
  height: auto;
}

.be-sidebar__brand{
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 18px 18px 16px;
  border-bottom: 1px solid var(--adm-sidebar-border);
}
.be-sidebar__brand img{ height: 38px; }
.be-sidebar__brand-text{ min-width: 0; }
.be-sidebar__brand-text b{ display: block; font-size: .92rem; font-weight: 600; line-height: 1.25; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.be-sidebar__brand-text span{ font-size: .7rem; color: var(--adm-sidebar-muted); }

.be-sidebar__nav{ flex: 1; overflow-y: auto; padding: 12px 12px 18px; }
.be-sidebar__nav::-webkit-scrollbar{ width: 6px; }
.be-sidebar__nav::-webkit-scrollbar-track{ background: transparent; }
.be-sidebar__nav::-webkit-scrollbar-thumb{ background: #fff; border-radius: 3px; }

.be-nav__group{
  font-size: .68rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--adm-sidebar-muted);
  padding: 16px 12px 6px;
}
.be-nav__item{
  position: relative;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 12px;
  margin-bottom: 2px;
  border-radius: 8px;
  color: var(--adm-sidebar-text);
  text-decoration: none;
  font-size: .84rem;
  font-weight: 500;
  transition: background .15s ease, color .15s ease;
}
.be-nav__item i{
  width: 16px;
  text-align: center;
  font-size: .85rem;
  color: var(--adm-sidebar-muted);
  transition: color .15s ease;
}
.be-nav__item:hover{ background: rgba(255,255,255,.06); color: #fff; }
.be-nav__item:hover i{ color: #fff; }
.be-nav__item.active{
  background: rgba(112,22,126,.32);
  color: #fff;
  box-shadow: inset 3px 0 0 var(--adm-accent);
}
.be-nav__item.active i{ color: #fff; }
.be-nav__badge{
  margin-left: auto;
  flex-shrink: 0;
  min-width: 20px;
  height: 20px;
  padding: 0 6px;
  border-radius: 50%;
  background: #c0392b;
  color: #fff;
  font-size: .68rem;
  font-weight: 700;
  line-height: 20px;
  text-align: center;
  display: inline-block;
}

.be-sidebar__footer{
  padding: 14px 16px;
  border-top: 1px solid var(--adm-sidebar-border);
  display: flex;
  align-items: center;
  gap: 10px;
}
.be-sidebar__avatar{
  width: 34px; height: 34px;
  border-radius: 50%;
  background: rgba(255,255,255,.12);
  display: flex; align-items: center; justify-content: center;
  font-weight: 600; font-size: .74rem; color: #fff;
  flex-shrink: 0;
}
.be-sidebar__who{ flex: 1; min-width: 0; }
.be-sidebar__who b{ display: block; font-size: .8rem; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.be-sidebar__who span{ font-size: .68rem; color: var(--adm-sidebar-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; display: block; }
.be-sidebar__logout{
  width: 32px; height: 32px;
  border: 1px solid rgba(255,255,255,.18);
  border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  color: var(--adm-sidebar-text);
  text-decoration: none;
  transition: background .15s ease, color .15s ease;
  flex-shrink: 0;
}
.be-sidebar__logout:hover{ background: rgba(255,255,255,.1); color: #fff; }

/* ----------------------------------------------------------------
   MAIN + TOPBAR
   ---------------------------------------------------------------- */
.be-main{
  margin-left: var(--adm-sidebar-w);
  /* Reduced by the insets because the shell in res/css/style.css pads itself
     by the same two amounts, which would otherwise leave the page a full inset
     taller than the screen and show a scrollbar that never goes away. */
  min-height: calc(100vh - env(safe-area-inset-top, 0px) - env(safe-area-inset-bottom, 0px));
  display: flex;
  flex-direction: column;
}
.be-topbar{
  position: sticky;
  top: env(safe-area-inset-top, 0px);
  z-index: 1030;
  display: flex;
  align-items: center;
  gap: 14px;
  height: 60px;
  padding: 0 24px;
  background: rgba(255,255,255,.95);
  border-bottom: 1px solid var(--adm-border);
  min-width: 0;
}
.be-topbar__toggle{
  display: none;
  align-items: center;
  justify-content: center;
  width: 36px; height: 36px;
  border: 1px solid var(--adm-border);
  background: #fff;
  border-radius: 8px;
  cursor: pointer;
  color: var(--adm-text);
  font-size: .9rem;
}
.be-topbar__title{
  font-size: .98rem;
  font-weight: 600;
  margin: 0;
  flex: 1 1 auto;
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.be-topbar__right{ margin-left: auto; display: flex; align-items: center; gap: 14px; flex: 0 0 auto; }
.be-topbar__pill{
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 5px 10px 5px 5px;
  border: 1px solid var(--adm-border);
  border-radius: 50rem;
  background: #fff;
}
.be-topbar__pill .be-sidebar__avatar{ width: 28px; height: 28px; font-size: .68rem; background: var(--adm-accent); }
.be-topbar__pill b{ display: block; font-size: .78rem; font-weight: 600; line-height: 1.2; }
.be-topbar__pill span{ display: block; font-size: .68rem; color: var(--adm-muted); line-height: 1.2; }
.be-topbar__logout{
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 7px 12px;
  border: 1px solid var(--adm-border);
  border-radius: 8px;
  background: #fff;
  color: var(--adm-muted);
  font-size: .8rem;
  font-weight: 500;
  text-decoration: none;
  transition: color .15s ease, border-color .15s ease, background .15s ease;
}
.be-topbar__logout:hover{ color: var(--adm-danger); border-color: var(--adm-danger); background: #fff7f7; }

.be-content{ padding: 24px; flex: 1; }
.be-content > .container{ max-width: none; padding: 0; }

.be-footer{
  padding: 14px 24px;
  border-top: 1px solid var(--adm-border);
  color: var(--adm-muted);
  font-size: .76rem;
  background: #fff;
  text-align: center;
}

/* ----------------------------------------------------------------
   OVERLAY (mobile)
   ---------------------------------------------------------------- */
.be-overlay{
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(18,20,30,.5);
  z-index: 1040;
}
.be-overlay.show{ display: block; }

/* ----------------------------------------------------------------
   CONTENT COMPONENTS
   ---------------------------------------------------------------- */
.be-content .card{
  border: none;
  border-radius: var(--adm-radius);
  box-shadow: var(--adm-shadow);
}
.be-content .card-header{
  background: #fff;
  border-bottom: 1px solid var(--adm-border);
  border-radius: var(--adm-radius) var(--adm-radius) 0 0 !important;
  padding: 14px 18px;
}
.be-content .card-header h5{ font-size: .92rem; margin: 0; }
.be-content .card-body{ padding: 18px; }

.be-content .table thead th{
  background: #f7f9fc;
  color: var(--adm-muted);
  font-size: .72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .04em;
  border-bottom: 1px solid var(--adm-border);
  white-space: nowrap;
}
.be-content .table td{ vertical-align: middle; padding: .65rem .75rem; }
.be-content .table-hover tbody tr:hover{ background: #fafbff; }
.be-content .thumb-cell{
  width: 52px;
  height: 38px;
  object-fit: cover;
  border-radius: 4px;
  border: 1px solid var(--adm-border);
  background: #f1f3f8;
}

.be-content .btn{ border-radius: 7px; font-weight: 500; font-size: .84rem; }
.be-content .btn-primary{ background: var(--adm-accent); border-color: var(--adm-accent); }
.be-content .btn-primary:hover,
.be-content .btn-primary:focus{ background: var(--adm-accent-dark); border-color: var(--adm-accent-dark); box-shadow: none; }
.be-content .btn-warning{ background: #f8b400; border-color: #f8b400; color: #3b3000; }
.be-content .btn-warning:hover{ background: #e0a400; border-color: #e0a400; color: #3b3000; }

.be-content .badge{ border-radius: 50rem; font-weight: 500; padding: .42em .68em; font-size: .74em; }

.be-content .form-control,
.be-content .form-select{
  border-radius: 7px;
  border-color: var(--adm-border);
  padding: .45rem .75rem;
  font-size: .86rem;
  font-family: var(--adm-font);
}
.be-content .form-control:focus,
.be-content .form-select:focus{
  border-color: var(--adm-accent);
  box-shadow: 0 0 0 .18rem rgba(112,22,126,.12);
}
.be-content .form-label{ font-size: .8rem; color: var(--adm-muted); font-weight: 500; margin-bottom: .35rem; }

.be-content .alert{ border: none; border-radius: 8px; font-size: .86rem; }
.be-content .alert-info{ background: #eef2ff; color: #3b4bdb; }

/* ----------------------------------------------------------------
   BOOTBOX
   ---------------------------------------------------------------- */
.bootbox .modal-content{
  border: none;
  border-radius: 12px;
  box-shadow: 0 24px 60px -18px rgba(20,24,40,.35);
  overflow: hidden;
}
.bootbox .modal-header{ border-bottom: 1px solid var(--adm-border); padding: 16px 20px; }
.bootbox .modal-title{ font-weight: 600; font-size: .98rem; }
.bootbox .modal-body{ padding: 20px; }
.bootbox .modal-footer{ border-top: 1px solid var(--adm-border); padding: 12px 20px; }
.bootbox .btn{ border-radius: 7px; font-weight: 500; font-size: .84rem; padding: .48rem 1.05rem; }
.bootbox .btn-primary{ background: var(--adm-accent); border-color: var(--adm-accent); }
.bootbox .btn-primary:hover{ background: var(--adm-accent-dark); border-color: var(--adm-accent-dark); }
.bootbox .modal-content .form-control,
.bootbox .modal-content .form-select{ border-radius: 7px; border-color: var(--adm-border); }

/* ----------------------------------------------------------------
   LOGIN
   ---------------------------------------------------------------- */
.be-login{
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 24px;
  padding: 24px;
  background: var(--adm-bg);
}
.be-login__card{
  width: 100%;
  flex: 1 1 340px;
  max-width: 400px;
  background: #fff;
  border: 1px solid var(--adm-border);
  border-radius: 12px;
  padding: 36px 34px 30px;
  box-shadow: 0 18px 50px -22px rgba(20,24,40,.3);
}
.be-login__brand{ text-align: center; margin-bottom: 26px; }
.be-login__brand img{ height: 52px; }
.be-login__brand b{ display: block; margin-top: 10px; font-size: 1rem; font-weight: 600; color: var(--adm-text); }
.be-login__brand span{ font-size: .72rem; color: var(--adm-muted); }
.be-login__card .form-control{ border-radius: 8px; border-color: var(--adm-border); padding: .55rem .8rem; font-size: .88rem; }
.be-login__card .form-control:focus{ border-color: var(--adm-accent); box-shadow: 0 0 0 .18rem rgba(112,22,126,.12); }
.be-login__card .form-label{ font-weight: 500; font-size: .8rem; color: var(--adm-muted); }
.be-login__card .btn{ border-radius: 8px; padding: .6rem 1rem; font-weight: 600; font-size: .88rem; }
.be-login__card .btn-primary{ background: var(--adm-accent); border-color: var(--adm-accent); }
.be-login__card .btn-primary:hover{ background: var(--adm-accent-dark); border-color: var(--adm-accent-dark); }
.be-login__back{
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--adm-muted);
  text-decoration: none;
  font-size: .8rem;
  transition: color .15s ease;
}
.be-login__back:hover{ color: var(--adm-accent); }

/* ----------------------------------------------------------------
   DASHBOARD WIDGETS
   ---------------------------------------------------------------- */
.dash-stat{
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 18px 16px;
  background: #fff;
  border: 1px solid var(--adm-border);
  border-radius: 12px;
  box-shadow: 0 8px 24px -18px rgba(20,24,40,.35);
  transition: transform .15s ease, box-shadow .15s ease;
}
.dash-stat:hover{ transform: translateY(-3px); box-shadow: 0 16px 30px -18px rgba(20,24,40,.45); }
.dash-stat__icon{
  width: 46px;
  height: 46px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  flex-shrink: 0;
}
.dash-stat__icon i{ font-size: 1.15rem; }
.dash-stat__value{ font-size: 1.25rem; font-weight: 700; line-height: 1.1; color: var(--adm-text); }
.dash-stat__label{ font-size: .72rem; color: var(--adm-muted); text-transform: uppercase; letter-spacing: .05em; }

.dash-card{ border: 1px solid var(--adm-border); border-radius: 12px; box-shadow: 0 8px 24px -20px rgba(20,24,40,.4); }
.dash-card .card-header{
  background: #fff;
  border-bottom: 1px solid var(--adm-border);
  font-weight: 600;
  font-size: .9rem;
  color: var(--adm-text);
  border-radius: 12px 12px 0 0;
}
.dash-card .card-header a{ font-weight: 500; }
.dash-feed-item{
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 8px 0;
  border-bottom: 1px solid rgba(20,24,40,.05);
}
.dash-feed-item:last-child{ border-bottom: none; }
.dash-feed-item__dot{
  width: 9px;
  height: 9px;
  border-radius: 50%;
  margin-top: 6px;
  flex-shrink: 0;
}

/* ----------------------------------------------------------------
   RESPONSIVE
   ---------------------------------------------------------------- */
@media (max-width: 991.98px){
  .be-sidebar{
    transform: translateX(-100%);
    transition: transform .25s ease;
    box-shadow: none;
  }
  .be-sidebar.open{ transform: translateX(0); box-shadow: 0 0 40px rgba(0,0,0,.35); }
  .be-main{ margin-left: 0; }
  .be-topbar__toggle{ display: inline-flex; }
  .be-content{ padding: 16px 14px; }
  .be-topbar{ padding: 0 16px; }
  .be-topbar__pill b,
  .be-topbar__pill span{ display: none; }
  .be-topbar__pill{ padding: 4px; border: none; }
}
@media (max-width: 575.98px){
  .be-topbar__role{ display: none; }
  .be-topbar__logout span{ display: none; }
  .be-topbar__logout{ padding: 7px 10px; }
  .be-topbar__right{ gap: 8px; }
  .be-topbar__title{ font-size: .9rem; }
  .be-topbar .be-cal-badge{ padding: 7px 10px; }
  .be-topbar .be-cal-label{ display: none; }
  /* Notification dropdown: never wider than the viewport */
  .be-notif .dropdown-menu{
    width: min(360px, calc(100vw - 24px)) !important;
    right: -60px;
  }
  .be-notif__item{ padding-left: 12px !important; padding-right: 12px !important; }
  .be-content{ padding: 14px 12px; }
  /* Keep Bootstrap rows inside the content padding on narrow screens so the
     -x/2 negative margins can never produce a horizontal scrollbar. */
  .be-content .row{ --bs-gutter-x: 1rem; }
}
/* Grading & Result: on a phone each grade band becomes its own labelled card
   instead of seven columns in a sideways-scrolling table. The Remark box is the
   one an admin types into most, so it gets a full-width row and a taller,
   easier-to-hit target rather than the few characters of width the horizontal
   scroll used to leave it. */
@media (max-width:767.98px){
  #gradeBandTable{ display: block; }
  #gradeBandTable tbody{ display: block; }
  #gradeBandTable tbody > tr{
    display: block;
    border:1px solid var(--adm-border);
    border-radius:10px;
    padding:.25rem .75rem .5rem;
    margin-bottom:.75rem;
    background:#fff;
  }
  #gradeBandTable tbody > tr > td{
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:.75rem;
    padding:.4rem 0;
    border:0;
    text-align:right;
  }
  /* The label comes from each cell's data-label, so a band always says what
     every value on its card means even with the header hidden. */
  #gradeBandTable tbody > tr > td::before{
    content: attr(data-label);
    flex:0 0 auto;
    font-size:.72rem;
    font-weight:600;
    text-transform:uppercase;
    letter-spacing:.04em;
    color:var(--adm-muted);
    text-align:left;
  }
  #gradeBandTable tbody > tr > td > .form-control,
  #gradeBandTable tbody > tr > td > .form-check-input{ width:100%; max-width:60%; margin-left:auto; }
  #gradeBandTable .gb-remark{ min-height:44px; font-size:1rem; padding:.6rem .75rem; }
  #gradeBandTable .gb-remove{ justify-content:flex-end; }
  #gradeBandTable .gb-remove::before{ content: none; }
  body.be-admin--dark #gradeBandTable tbody > tr{ background:#1c212e; }
}

/* Backup download history: six columns -- a long file name, a type badge, a
   size, a timestamp and two buttons -- have no room on a phone, and the
   sideways scroll it fell back on still squashed the buttons into each other.
   Each backup becomes its own labelled card instead: the header row goes, the
   redundant "#" goes with it, the file name gets a full-width line of its own,
   and the two actions sit side by side with a thumb-sized target. Labels come
   from each cell's data-label, so a card always says what its values mean. */
@media (max-width:767.98px){
  #backupHistoryTable{ display:block; }
  #backupHistoryTable thead{ display:none; }
  #backupHistoryTable tbody{ display:block; }
  #backupHistoryTable tbody > tr{
    display:block;
    border:1px solid var(--adm-border);
    border-radius:10px;
    padding:.25rem .75rem .5rem;
    margin-bottom:.75rem;
    background:#fff;
  }
  #backupHistoryTable tbody > tr > td{
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:.75rem;
    padding:.4rem 0;
    border:0;
    text-align:right;
  }
  #backupHistoryTable tbody > tr > td::before{
    content:attr(data-label);
    flex:0 0 auto;
    font-size:.72rem;
    font-weight:600;
    text-transform:uppercase;
    letter-spacing:.04em;
    color:var(--adm-muted);
    text-align:left;
  }
  #backupHistoryTable .bh-num{ display:none; }
  #backupHistoryTable .bh-file{
    display:block;
    text-align:left;
    font-weight:600;
    word-break:break-word;
  }
  #backupHistoryTable .bh-file::before{ display:block; margin-bottom:.15rem; }
  #backupHistoryTable .bh-actions{ flex-wrap:wrap; gap:.5rem; }
  #backupHistoryTable .bh-actions::before{ flex:1 0 100%; }
  #backupHistoryTable .bh-actions .btn{
    flex:1 1 calc(50% - .25rem);
    justify-content:center;
    min-height:44px;
  }
  #backupHistoryTable .bh-empty{ display:block; text-align:center; }
  #backupHistoryTable .bh-empty::before{ content:none; }
  body.be-admin--dark #backupHistoryTable tbody > tr{ background:#1c212e; }
}

/* Frozen first columns on wide tables (gradebook, results) */
.sticky-col{ position: sticky; left: 0; z-index: 1; background: #fff; }
.table-striped > tbody > tr:nth-of-type(odd) > .sticky-col{ background: #f9fafb; }
.table-hover tbody tr:hover > .sticky-col{ background: #f1f5f9; }
body.be-admin--dark .sticky-col{ background: #1c212e; }
body.be-admin--dark .table-hover tbody tr:hover > .sticky-col{ background: #2a3140; }
body.be-admin--dark .sticky-col.thead,
body.be-admin--dark thead .sticky-col{ background: #2a3140; }
thead .sticky-col{ background: #f8f9fa; z-index: 2; }

/* ----------------------------------------------------------------
   Wide data tables on small screens (student + dormant student)
   The table keeps its real column layout and the wrapper scrolls
   instead of squashing 11 columns into a phone. A min-width stops
   cells collapsing, the header sticks while scrolling down, and the
   student name stays frozen on the left so rows remain identifiable
   as you scroll across. The redundant "#" column is dropped, since
   once the name is frozen the sequence number adds nothing.
   ---------------------------------------------------------------- */
.be-rtable{ width: 100%; }
.be-rtable th,
.be-rtable td{ word-break: break-word; }
@media screen and (max-width: 767.98px){
  /* Both axes scroll, so the header has something to stick inside. */
  .be-rtable__scroll{
    max-height: 75vh;
    overflow: auto;
    -webkit-overflow-scrolling: touch;
  }
  .be-rtable{
    min-width: 900px;
    table-layout: fixed;
  }
  .be-rtable .be-rtable__num{ display: none; }
  /* give the two columns that need room a fair share of the width */
  .be-rtable th:nth-child(2),
  .be-rtable td:nth-child(2){ width: 170px; }
  .be-rtable th:last-child,
  .be-rtable td:last-child{ width: 86px; }
  /* frozen identifier column */
  .be-rtable .be-rtable__name{
    position: sticky;
    left: 0;
    z-index: 1;
    background: #fff;
    font-weight: 600;
  }
  .be-rtable.table-striped > tbody > tr:nth-of-type(odd) > .be-rtable__name{ background: #f9fafb; }
  .be-rtable tbody tr:hover > .be-rtable__name{ background: #f1f5f9; }
  /* sticky header row */
  .be-rtable thead th{ position: sticky; top: 0; z-index: 2; background: #f8f9fa; }
  .be-rtable thead th.be-rtable__name{ z-index: 3; }
}

/* ================================================================
   Dark Mode
   ================================================================ */
body.be-admin--dark{
  --adm-bg:            #12151d;
  --adm-surface:       #1c212e;
  --adm-border:        #2a3140;
  --adm-text:          #e6e9f0;
  --adm-muted:         #98a0b3;
  --adm-shadow:        0 1px 3px rgba(0,0,0,.5);
}
body.be-admin--dark .card,
body.be-admin--dark .dash-card{ background: var(--adm-surface); border-color: var(--adm-border); color: var(--adm-text); }
body.be-admin--dark .table,
body.be-admin--dark .table-hover tbody tr:hover,
body.be-admin--dark .table-striped > tbody > tr:nth-of-type(odd){ color: var(--adm-text); }
body.be-admin--dark .table-striped > tbody > tr:nth-of-type(odd){ background: rgba(255,255,255,.02); }
body.be-admin--dark .table-hover tbody tr:hover{ background: rgba(255,255,255,.06); }
body.be-admin--dark .table-light,
body.be-admin--dark .table-light th,
body.be-admin--dark thead.table-light{ background: #2a3140; color: var(--adm-text); }
body.be-admin--dark .be-rtable .be-rtable__name{ background: #1c212e; }
body.be-admin--dark .be-rtable.table-striped > tbody > tr:nth-of-type(odd) > .be-rtable__name,
body.be-admin--dark .be-rtable tbody tr:hover > .be-rtable__name{ background: #2a3140; }
body.be-admin--dark .be-rtable thead th{ background: #2a3140; }
body.be-admin--dark .form-control,
body.be-admin--dark .form-select,
body.be-admin--dark .input-group-text{ background: #161a24; border-color: #2a3140; color: var(--adm-text); }
body.be-admin--dark .form-control:focus,
body.be-admin--dark .form-select:focus{ background: #161a24; color: var(--adm-text); }
body.be-admin--dark .text-muted{ color: #98a0b3 !important; }
body.be-admin--dark .bg-light,
body.be-admin--dark .bg-white{ background-color: #1c212e !important; }
body.be-admin--dark .be-topbar{ background: #181c26; border-color: #2a3140; }
body.be-admin--dark .be-footer{ color: #7d8498; }
body.be-admin--dark .modal-content{ background: var(--adm-surface); color: var(--adm-text); border-color: var(--adm-border); }
body.be-admin--dark .modal-header{ border-color: var(--adm-border); }
body.be-admin--dark .list-group-item{ background: var(--adm-surface); color: var(--adm-text); border-color: var(--adm-border); }
body.be-admin--dark .dropdown-menu{ background: var(--adm-surface); border-color: var(--adm-border); }
body.be-admin--dark .dropdown-item{ color: var(--adm-text); }
body.be-admin--dark .dropdown-item:hover{ background: #2a3140; color: #fff; }

/* topbar role + theme toggle */
.be-topbar__role{
  font-size: .72rem;
  font-weight: 600;
  letter-spacing: .03em;
  text-transform: uppercase;
  color: var(--adm-muted);
  background: rgba(112,22,126,.10);
  border: 1px solid var(--adm-border);
  padding: 6px 10px;
  border-radius: 999px;
  white-space: nowrap;
}
.be-topbar__btn{
  background: transparent;
  border: 1px solid var(--adm-border);
  color: var(--adm-muted);
  width: 38px;
  height: 38px;
  border-radius: 8px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}
.be-topbar__btn:hover{ color: var(--adm-accent); border-color: var(--adm-accent); }

/* notification bell */
.be-notif__btn{
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  padding: 0;
  border: 1px solid var(--adm-border);
  background: #fff;
  color: var(--adm-text);
  border-radius: 50rem;
  line-height: 1;
}
.be-notif__btn:hover{ color: var(--adm-accent); border-color: var(--adm-accent); }
body.be-admin--dark .be-notif__btn{
  background: rgba(255,255,255,.10);
  border-color: rgba(255,255,255,.28);
  color: #fff;
}
body.be-admin--dark .be-notif__btn:hover{ color: #fff; border-color: #fff; }
