/* =========================================================
   Làng Ẩn Dật - REBUILD V2 BANG CHIẾN
   ========================================================= */

.bangchien-shell{
  background:linear-gradient(135deg,rgba(16,14,22,.74),rgba(42,24,20,.58));
}

.bangchien-scroll{
  min-height:0;
  overflow:auto;
  padding:16px 18px 18px;
}

.bangchien-grid{
  display:grid;
  grid-template-columns:350px minmax(0,1fr);
  gap:16px;
  align-items:start;
}

.bc-card{
  border:1px solid var(--line);
  border-radius:20px;
  background:linear-gradient(135deg,rgba(18,16,24,.74),rgba(28,19,18,.58));
  box-shadow:0 18px 55px rgba(0,0,0,.32);
  padding:16px;
  backdrop-filter:blur(12px);
}

.bc-left{
  display:grid;
  gap:14px;
}

.bc-main{
  display:grid;
  gap:14px;
  min-width:0;
}

.bc-card-head,
.bc-list-head{
  display:flex;
  justify-content:space-between;
  align-items:flex-start;
  gap:14px;
  margin-bottom:12px;
}

.bc-card h2,
.bc-list-head h2{
  margin:0;
  color:var(--gold);
  font-size:22px;
  line-height:1.1;
  text-transform:uppercase;
}

.bc-card-head span,
.bc-list-head span{
  color:var(--muted);
  font-size:12px;
  font-weight:800;
}

.bc-form{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:10px;
}

.bc-field{
  display:grid;
  gap:6px;
}

.bc-field span{
  color:var(--muted);
  text-transform:uppercase;
  font-size:10px;
  font-weight:950;
  letter-spacing:.10em;
}

.bc-field input,
.bc-field select,
.bc-field textarea,
.bc-toolbar input{
  min-height:42px;
  border-radius:14px;
  border:1px solid var(--line);
  background:rgba(7,8,12,.64);
  color:var(--text);
  padding:0 12px;
  outline:none;
}

.bc-field textarea{
  padding:10px 12px;
  resize:vertical;
}

.bc-full{
  grid-column:1/-1;
}

.bc-btn{
  min-height:42px;
  border-radius:14px;
  border:1px solid rgba(255,255,255,.18);
  background:linear-gradient(180deg,rgba(93,96,110,.88),rgba(45,47,58,.88));
  color:#fff7df;
  font-size:10px;
  font-weight:950;
  text-transform:uppercase;
  letter-spacing:.07em;
  padding:0 14px;
  box-shadow:inset 0 1px 0 rgba(255,255,255,.12),0 8px 20px rgba(0,0,0,.25);
}

.bc-btn:hover{filter:brightness(1.08);transform:translateY(-1px)}
.bc-primary{background:linear-gradient(180deg,#fff0aa,#d4a33c);color:#1c1004;border-color:#ffe69a}
.bc-success{background:linear-gradient(180deg,#25e29b,#0ea471);color:#031610;border-color:#8dffd0}
.bc-danger{background:linear-gradient(180deg,#ff5a7d,#b8193a);color:#fff;border-color:#ff9bad}

.bc-current,
.bc-register-box{
  border:1px solid rgba(255,255,255,.10);
  border-radius:16px;
  padding:14px;
  background:rgba(0,0,0,.22);
}

.bc-current-title{
  display:flex;
  justify-content:space-between;
  gap:10px;
  align-items:flex-start;
}

.bc-current h3,
.bc-register-box h3{
  margin:0 0 6px;
  color:var(--gold-2);
  text-transform:uppercase;
}

.bc-current-title span{
  color:#7fffc2;
  font-size:11px;
  font-weight:950;
  text-transform:uppercase;
  white-space:nowrap;
}

.bc-current-actions{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:10px;
  margin:12px 0;
}

.bc-current p,
.bc-help{
  margin:0;
  color:var(--muted);
  font-size:12px;
  line-height:1.45;
}

.bc-toolbar{
  display:grid;
  grid-template-columns:minmax(90px,120px) minmax(128px,1fr) minmax(118px,1fr) minmax(110px,1fr);
  gap:10px;
  align-items:stretch;
  min-width:min(620px,100%);
}

.bc-toolbar input,
.bc-toolbar .bc-btn{
  width:100%;
  height:42px;
  min-height:42px;
  text-align:center;
}

.bc-toolbar-small{
  grid-template-columns:repeat(4,minmax(88px,1fr));
  min-width:min(520px,100%);
}

.bc-sect-tools{
  display:grid;
  gap:8px;
  margin:8px 0 14px;
}

.bc-sect-counts,
.bc-filter-row{
  display:flex;
  flex-wrap:wrap;
  gap:8px;
}

.bc-sect-chip,
.bc-filter-btn{
  min-height:31px;
  border-radius:999px;
  border:1px solid rgba(245,213,137,.28);
  background:rgba(0,0,0,.28);
  color:#fff1ce;
  display:inline-flex;
  align-items:center;
  gap:6px;
  padding:0 10px;
  font-size:10px;
  font-weight:950;
}

.bc-filter-btn.active{
  background:linear-gradient(180deg,rgba(245,213,137,.28),rgba(0,0,0,.30));
  border-color:rgba(245,213,137,.62);
}

.bc-sect-chip img,
.bc-filter-btn img,
.bc-phai img{
  width:18px;
  height:18px;
  object-fit:contain;
}

.bc-count{
  min-width:22px;
  height:22px;
  border-radius:999px;
  display:grid;
  place-items:center;
  background:rgba(0,0,0,.34);
  color:var(--gold-2);
}

.bc-user-list{
  display:grid;
  gap:10px;
}

.bc-empty{
  border:1px dashed rgba(245,213,137,.22);
  border-radius:16px;
  background:rgba(0,0,0,.16);
  color:var(--muted);
  text-align:center;
  padding:18px;
  font-weight:800;
}

.bc-row,
.bc-x-row{
  display:grid;
  grid-template-columns:38px minmax(140px,1.1fr) minmax(110px,.70fr) minmax(120px,.85fr) minmax(112px,.72fr);
  gap:10px;
  align-items:center;
  border:1px solid rgba(245,213,137,.20);
  border-radius:16px;
  background:linear-gradient(90deg,rgba(77,39,24,.32),rgba(13,16,25,.52));
  padding:10px 12px;
}

.bc-x-row{
  grid-template-columns:38px minmax(140px,1.1fr) minmax(110px,.70fr) minmax(120px,.85fr) minmax(116px,.72fr) 74px;
}

.bc-check{
  width:30px;height:30px;
  display:grid;
  place-items:center;
  position:relative;
}

.bc-check input{
  position:absolute;
  opacity:0;
}

.bc-check span{
  width:27px;height:27px;
  border-radius:9px;
  border:2px solid rgba(245,213,137,.55);
  background:rgba(0,0,0,.25);
}

.bc-check input:checked + span{
  background:linear-gradient(180deg,#24e69f,#0da56f);
  border-color:#8dffd0;
}

.bc-check input:checked + span:after{
  content:"✓";
  display:grid;
  place-items:center;
  height:100%;
  color:#031610;
  font-weight:950;
}

.bc-name{
  color:var(--gold-2);
  font-weight:950;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}

.bc-phai,
.bc-team,
.bc-status,
.bc-x{
  height:32px;
  border-radius:999px;
  border:1px solid rgba(255,255,255,.10);
  background:rgba(0,0,0,.26);
  display:flex;
  justify-content:center;
  align-items:center;
  gap:7px;
  padding:0 10px;
  font-size:11px;
  font-weight:950;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}

.bc-status.pending{color:#ffe8ae}
.bc-status.absent,.bc-x{color:#ff7798}

@media(max-width:1100px){
  .bangchien-scroll{padding:12px}
  .bangchien-grid{grid-template-columns:1fr}
  .bc-form{grid-template-columns:1fr 1fr}
  .bc-list-head{display:grid;grid-template-columns:1fr;gap:10px}
  .bc-toolbar{grid-template-columns:repeat(2,minmax(0,1fr));min-width:0}
  .bc-toolbar-small{grid-template-columns:repeat(2,minmax(0,1fr))}
  .bc-row,.bc-x-row{
    grid-template-columns:34px minmax(130px,1fr);
    gap:8px;
  }
  .bc-phai,.bc-team,.bc-status,.bc-x{
    grid-column:2/-1;
    justify-content:flex-start;
  }
}

@media(max-width:560px){
  .scrim-frame{border-radius:16px}
  .bangchien-scroll{padding:8px}
  .bc-card{padding:12px;border-radius:16px}
  .bc-form{grid-template-columns:1fr}
  .bc-current-title{display:grid}
  .bc-current-actions{grid-template-columns:1fr}
  .bc-toolbar,.bc-toolbar-small{grid-template-columns:1fr}
  .bc-row,.bc-x-row{padding:10px}
}


/* =========================================================
   REBUILD V2.1 - BANG CHIẾN USER CARD GAP FIX
   Kéo tên/phái/team/trạng thái lại gần nhau, badge vừa nội dung.
   ========================================================= */

@media(min-width:1101px){
  .bc-row{
    grid-template-columns:34px minmax(150px,220px) max-content max-content max-content!important;
    justify-content:start!important;
    column-gap:12px!important;
    row-gap:8px!important;
  }

  .bc-x-row{
    grid-template-columns:34px minmax(150px,220px) max-content max-content max-content max-content!important;
    justify-content:start!important;
    column-gap:12px!important;
    row-gap:8px!important;
  }

  .bc-name{
    width:100%!important;
    max-width:220px!important;
  }

  .bc-phai,
  .bc-team,
  .bc-status,
  .bc-x{
    width:auto!important;
    min-width:104px!important;
    max-width:180px!important;
    padding:0 14px!important;
    justify-content:center!important;
  }

  .bc-phai{
    min-width:126px!important;
  }

  .bc-team{
    min-width:118px!important;
  }

  .bc-status{
    min-width:108px!important;
  }

  .bc-x{
    min-width:82px!important;
  }
}

@media(max-width:1100px){
  .bc-row,
  .bc-x-row{
    grid-template-columns:34px minmax(0,1fr)!important;
    gap:8px 10px!important;
  }

  .bc-name{
    grid-column:2/-1!important;
  }

  .bc-phai,
  .bc-team,
  .bc-status,
  .bc-x{
    grid-column:2/-1!important;
    width:max-content!important;
    max-width:100%!important;
    min-width:0!important;
    justify-content:flex-start!important;
    padding:0 12px!important;
  }
}

@media(max-width:560px){
  .bc-row,
  .bc-x-row{
    padding:10px!important;
  }

  .bc-name{
    font-size:14px!important;
  }

  .bc-phai,
  .bc-team,
  .bc-status,
  .bc-x{
    height:30px!important;
    font-size:10px!important;
  }
}