/**
 * KMS.CSS — Style riêng cho Cổng Quản Lý Công Việc KMS (kms.html)
 * Phần lớn giao diện tái dùng .login-gate-overlay/.login-card-gold-drive (Dark Gold Theme có
 * sẵn từ màn Đăng nhập DMS) và toàn bộ .kst-*/.dms-* trong dms.css — file này chỉ bổ sung phần
 * CHƯA có: nhãn phụ màn đăng nhập KMS, ô tìm kiếm Header, Modal cảnh báo chặn truy cập.
 */

/* ---------- Màn hình Đăng nhập KMS ---------- */
.kms-login-title {
  text-align: center !important;
}
.kms-login-subtitle {
  text-align: center !important;
  font-weight: 700 !important;
  letter-spacing: 0.04em !important;
}
.kms-login-hint {
  text-align: center !important;
  font-size: 0.78rem !important;
  color: rgba(254, 240, 138, 0.65) !important;
  margin: -6px 0 18px !important;
}
.btn-login-kms {
  letter-spacing: 0.02em !important;
}

/* ---------- Header Cổng KMS — 3 khối cân đối (Brand | Search | User Profile) ---------- */
.kms-header-bar {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  gap: 20px !important;
  width: 100% !important;
}
.kms-header-bar .brand-mark-hsh { flex: 0 0 auto !important; }
.kms-header-bar .brand-titles {
  flex: 0 1 auto !important;
  min-width: 0 !important; /* cho phép Title/Subtitle tự cắt "..." nếu màn hẹp, không đẩy vỡ layout */
}
.kms-header-bar .brand-title-hsh {
  white-space: nowrap !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
}
.kms-header-bar .kms-header-brand-group {
  flex: 0 1 auto !important;
  min-width: 0 !important; /* cho phép Title/Subtitle tự cắt "..." nếu màn hẹp */
}
.kms-header-bar .brand-titles {
  flex: 0 1 auto !important;
  min-width: 0 !important;
}
.kms-header-bar .brand-title-hsh {
  white-space: nowrap !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
}
.kms-header-bar .kms-header-tools-group {
  flex: 0 0 auto !important;
  padding: 6px 4px !important; /* padding đồng nhất quanh cụm công cụ + user, đồng bộ chiều cao 2 khối */
}

/* Ô tìm kiếm Header KMS — dùng chung khuôn bo tròn .search-box-exact/.search-btn-exact
   (định nghĩa gốc trong style.css, đồng bộ tuyệt đối với trang Kiểm Soát Tỉnh). Mở rộng
   chiều rộng để không che chữ placeholder dài, co giãn linh hoạt trong khoảng 260–420px. */
.kms-search-box {
  flex: 1 1 340px !important;
  max-width: 420px !important;
  min-width: 260px !important;
  margin: 0 24px !important;
}

/* ---------- Modal/Alert cảnh báo chặn truy cập KMS (đỏ sang trọng) ---------- */
.kms-denied-card-vip {
  border: 1.5px solid #FCA5A5 !important;
  box-shadow: 0 25px 60px rgba(220, 38, 38, 0.28) !important;
}

/* ---------- Lịch Popup luôn nổi lên trên mọi Modal ---------- */
/* z-index thật của Popup Lịch (.kms-calpop) nằm ở khối "LỊCH POPUP TÙY BIẾN" phía dưới file này
   (999999999 !important, position:fixed, append thẳng vào cuối <body>) — không còn phụ thuộc
   Flatpickr nữa (đã gỡ bỏ hoàn toàn), nên không còn bị Modal cha có overflow:hidden cắt mất. */
.kst-date-group {
  display: flex !important;
  gap: 14px !important;
}
.kst-date-group .date-field { flex: 1 1 0 !important; }
.kst-date-input {
  border: 1.5px solid rgba(220, 38, 38, 0.25) !important;
  border-radius: 10px !important;
  padding: 9px 12px !important;
  font-size: 0.85rem !important;
  color: #334155 !important;
  background: #FFFFFF !important;
  width: 100% !important;
  transition: all 0.2s ease !important;
}
.kst-date-input:hover {
  border-color: #DC2626 !important;
  box-shadow: 0 0 0 4px rgba(220, 38, 38, 0.08) !important;
}
.kst-date-input:focus {
  outline: none !important;
  border-color: #DC2626 !important;
  box-shadow: 0 0 0 4px rgba(220, 38, 38, 0.14) !important;
}


/* =========================================================
 *  WIZARD "LẬP BÁO CÁO TUẦN" — 5 bước
 * ========================================================= */
.wizard-modal-card {
  max-width: 780px !important;
  max-height: 88vh !important;
  overflow-y: auto !important;
}

/* Thanh tiến trình 5 bước — viền sáng Đỏ - Vàng Kim Hoa Sen */
.wizard-progress-bar {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 4px !important;
  padding: 14px 8px !important;
  margin-bottom: 6px !important;
  border-radius: 14px !important;
  background: linear-gradient(135deg, #FFF7ED 0%, #FEF2F2 100%) !important;
  border: 1.5px solid #F5C451 !important;
  box-shadow: 0 0 0 1px rgba(220, 38, 38, 0.08), 0 8px 18px rgba(245, 196, 81, 0.15) !important;
}
.wizard-step-dot {
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  gap: 4px !important;
  min-width: 64px !important;
}
.wizard-step-dot .dot-num {
  width: 28px !important; height: 28px !important;
  border-radius: 50% !important;
  background: #E2E8F0 !important;
  color: #64748B !important;
  font-weight: 800 !important;
  font-size: 0.82rem !important;
  display: flex !important; align-items: center !important; justify-content: center !important;
  transition: all 0.25s ease !important;
}
.wizard-step-dot .dot-label {
  font-size: 0.66rem !important;
  color: #94A3B8 !important;
  font-weight: 700 !important;
  text-align: center !important;
  white-space: nowrap !important;
}
.wizard-step-dot.active .dot-num {
  background: linear-gradient(135deg, #DC2626 0%, #991B1B 100%) !important;
  color: #FFFFFF !important;
  box-shadow: 0 0 0 4px rgba(220, 38, 38, 0.18), 0 0 12px rgba(245, 196, 81, 0.5) !important;
}
.wizard-step-dot.active .dot-label { color: #991B1B !important; }
.wizard-step-dot.done .dot-num {
  background: linear-gradient(135deg, #F5C451 0%, #D4AF37 100%) !important;
  color: #3A1200 !important;
}
.wizard-step-line {
  flex: 1 1 20px !important;
  height: 2px !important;
  background: #E2E8F0 !important;
  margin-top: -18px !important;
}

.wizard-step-panel { margin-top: 14px !important; }

/* Dòng động (BCC Tháng) */
.wizard-dyn-row {
  display: flex !important;
  gap: 10px !important;
  align-items: center !important;
  margin-bottom: 10px !important;
}
.wizard-dyn-row input {
  border: 1.5px solid #E2E8F0 !important;
  border-radius: 10px !important;
  padding: 9px 12px !important;
  font-size: 0.85rem !important;
}

/* Thẻ lỗi động (Lỗi nghiệp vụ) */
.wizard-error-card {
  background: #F8FAFC !important;
  border: 1px solid #E2E8F0 !important;
  border-radius: 12px !important;
  padding: 14px 16px !important;
  margin-bottom: 14px !important;
}
.wizard-error-card-head {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  margin-bottom: 10px !important;
  color: #991B1B !important;
}
.wizard-row-remove {
  background: #FEE2E2 !important;
  color: #DC2626 !important;
  border: none !important;
  border-radius: 8px !important;
  width: 28px !important; height: 28px !important;
  cursor: pointer !important;
  font-weight: 800 !important;
  flex-shrink: 0 !important;
  transition: all 0.2s ease !important;
}
.wizard-row-remove:hover { background: #DC2626 !important; color: #FFFFFF !important; }

/* Footer điều hướng Wizard — nút bo tròn 10px, nổi 3D khi hover */
.wizard-nav-footer { justify-content: space-between !important; }
.wizard-nav-footer .dms-btn {
  border-radius: 10px !important;
  transition: transform 0.2s ease, box-shadow 0.2s ease !important;
}
.wizard-nav-footer .dms-btn:hover { transform: translateY(-2px) !important; }

/* =========================================================
 *  BỘ LỌC & TRÌNH SẮP XẾP NÂNG CAO — Sub-tab "Danh sách tất cả các Cụm"
 * ========================================================= */
.btn-filter-pill {
  display: inline-flex !important;
  align-items: center !important;
  gap: 8px !important;
  background: #FFFFFF !important;
  border: 1.5px solid rgba(220, 38, 38, 0.35) !important;
  color: #DC2626 !important;
  font-weight: 700 !important;
  font-size: 0.85rem !important;
  padding: 8px 18px !important;
  border-radius: 20px !important;
  cursor: pointer !important;
  transition: all 0.2s ease !important;
}
.btn-filter-pill svg { stroke: #DC2626 !important; flex-shrink: 0 !important; }
.btn-filter-pill:hover {
  background: rgba(220, 38, 38, 0.06) !important;
  box-shadow: 0 4px 12px rgba(220, 38, 38, 0.2) !important;
}
.btn-filter-pill.active {
  background: #DC2626 !important;
  color: #FFFFFF !important;
}
.btn-filter-pill.active svg { stroke: #FFFFFF !important; }

/* Panel trượt mượt — dùng max-height thay vì display:none để có hiệu ứng animation */
.kst-filter-panel {
  max-height: 0 !important;
  overflow: hidden !important;
  opacity: 0 !important;
  transition: max-height 0.35s ease, opacity 0.3s ease, margin 0.35s ease !important;
  margin-bottom: 0 !important;
}
.kst-filter-panel.open {
  max-height: 200px !important;
  opacity: 1 !important;
  margin-bottom: 14px !important;
}
.kst-filter-panel .kst-filter-bar { margin-bottom: 0 !important; }
.kst-filter-panel select {
  border: 1.5px solid #E2E8F0 !important;
  border-radius: 12px !important;
  padding: 9px 14px !important;
  font-size: 0.85rem !important;
  color: #334155 !important;
  background: #FFFFFF !important;
  transition: border-color 0.2s ease, box-shadow 0.2s ease !important;
}
.kst-filter-panel select:hover {
  border-color: #F5C451 !important;
}
.kst-filter-panel select:focus {
  outline: none !important;
  border-color: #DC2626 !important;
  box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.12) !important;
}

.kst-filter-result-badge {
  font-size: 0.8rem !important;
  font-weight: 700 !important;
  color: #B45309 !important;
  background: #FFFBEB !important;
  border: 1px solid #FDE68A !important;
  display: inline-block !important;
  padding: 4px 14px !important;
  border-radius: 99px !important;
  margin-bottom: 14px !important;
}

.kst-filter-empty-state {
  grid-column: 1 / -1 !important;
  text-align: center !important;
  padding: 48px 16px !important;
}
.kst-filter-empty-icon { font-size: 2.2rem !important; margin-bottom: 10px !important; }
.kst-filter-empty-title { font-weight: 800 !important; color: #475569 !important; font-size: 0.95rem !important; }
.kst-filter-empty-sub { font-size: 0.82rem !important; color: #94A3B8 !important; margin-top: 4px !important; }

@keyframes kstCardFadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}
.kst-fade-in {
  animation: kstCardFadeIn 0.35s ease both !important;
}

/* Responsive — dóng hàng dọc gọn gàng trên Mobile */
@media (max-width: 640px) {
  .kst-filter-panel .kst-filter-bar {
    flex-direction: column !important;
    align-items: stretch !important;
  }
  .kst-filter-panel select { width: 100% !important; }
}

/* =========================================================
 *  SEGMENTED TAB CONTROL — Thanh Sub-Nav KMS (Modern Premium SaaS)
 * ========================================================= */
.kms-sub-nav {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  flex-wrap: wrap !important;
  background: #FFFFFF !important;
  border: 1px solid #E2E8F0 !important;
  border-radius: 16px !important;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05) !important;
  padding: 6px !important;
  gap: 8px !important;
  margin-bottom: 20px !important;
}
.kms-sub-nav-tabs {
  display: flex !important;
  align-items: center !important;
  flex-wrap: wrap !important;
  gap: 8px !important;
}
/* Badge trạng thái lấp khoảng trống bên phải thanh Tab — ẩn trên màn hẹp để nhường chỗ cho Tab cuộn ngang */
.kms-sub-nav-status {
  display: flex !important;
  align-items: center !important;
  gap: 8px !important;
  padding: 6px 14px 6px 16px !important;
  border-left: 1px solid #E2E8F0 !important;
  font-size: 0.78rem !important;
  font-weight: 600 !important;
  color: #64748B !important;
  white-space: nowrap !important;
  flex: 0 0 auto !important;
}
.kms-status-dot {
  width: 8px !important;
  height: 8px !important;
  border-radius: 50% !important;
  background: #10B981 !important;
  box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.6) !important;
  animation: kmsStatusPulse 1.8s ease-in-out infinite !important;
  flex: none !important;
}
@keyframes kmsStatusPulse {
  0% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.55); }
  70% { box-shadow: 0 0 0 6px rgba(16, 185, 129, 0); }
  100% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); }
}
.kms-status-sep { color: #CBD5E1 !important; }
@media (max-width: 900px) {
  .kms-sub-nav-status { display: none !important; }
}
.kms-sub-nav .nav-btn {
  background: transparent !important;
  border: none !important;
  padding: 10px 20px !important;
  border-radius: 12px !important;
  font-weight: 600 !important;
  font-size: 0.92rem !important;
  color: #475569 !important;
  transition: all 0.25s ease-in-out !important;
  cursor: pointer !important;
  display: flex !important;
  align-items: center !important;
  gap: 8px !important;
}
.kms-sub-nav .nav-btn.active {
  background: linear-gradient(135deg, #DC2626 0%, #991B1B 100%) !important;
  color: #FFFFFF !important;
  font-weight: 700 !important;
  box-shadow: 0 4px 14px rgba(220, 38, 38, 0.35) !important;
}
.kms-sub-nav .nav-btn:hover:not(.active) {
  background: #FEF2F2 !important;
  color: #DC2626 !important;
}

/* =========================================================
 *  CARD KPI + WIZARD MODAL — bố cục lại theo Modern Premium SaaS
 * ========================================================= */
.kst-kpi-card {
  border-radius: 18px !important;
  border-color: #FEE2E2 !important;
}
.kst-kpi-value {
  font-size: 2rem !important;
  font-weight: 900 !important;
  text-align: center !important;
}
.kst-kpi-label {
  text-align: center !important;
}

.wizard-modal-card {
  max-width: 780px !important;
  padding: 28px 32px !important;
}
.wizard-modal-card .dms-form-grid {
  gap: 18px 20px !important;
}
@media (max-width: 640px) {
  .wizard-modal-card { padding: 20px 16px !important; }
  .wizard-modal-card .dms-form-grid { grid-template-columns: 1fr !important; }
}

/* =========================================================
 *  NÚT BẤM KÍCH HOẠT LỊCH 📅 — cạnh mọi ô nhập Ngày
 * ========================================================= */
.kms-date-input-group {
  display: flex !important;
  align-items: stretch !important;
  gap: 0 !important;
}
.kms-date-input-group .kst-date-input,
.kms-date-input-group .kms-date-picker {
  flex: 1 1 auto !important;
  border-top-right-radius: 0 !important;
  border-bottom-right-radius: 0 !important;
  border-right: none !important;
}
.btn-calendar-trigger {
  flex: 0 0 auto !important;
  border: 1.5px solid rgba(220, 38, 38, 0.25) !important;
  border-left: none !important;
  border-top-right-radius: 10px !important;
  border-bottom-right-radius: 10px !important;
  background: #FEF2F2 !important;
  color: #DC2626 !important;
  padding: 0 12px !important;
  cursor: pointer !important;
  font-size: 0.95rem !important;
  transition: all 0.2s ease !important;
}
.btn-calendar-trigger:hover {
  background: #DC2626 !important;
  filter: brightness(1.05) !important;
}

/* =========================================================
 *  LỊCH POPUP TÙY BIẾN — thay thế HOÀN TOÀN thư viện Flatpickr (nhìn đơn điệu, không đồng bộ
 *  hình thức với trang Công việc). TÁI SỬ DỤNG đúng class .calendar-dow/.calendar-grid/
 *  .calendar-day/.other-month/.today đã có sẵn trong css/style.css (Calendar Widget bên trang
 *  Công việc) — KHÔNG đụng tới style.css, chỉ bổ sung phần khung Popup nổi + trạng thái "đã
 *  chọn" riêng cho KMS (đỏ Hoa Sen, khác màu xanh "selected" gốc của Widget lọc công việc) ở
 *  ĐÂY, để 2 nơi luôn nhìn giống hệt nhau về bố cục/tông màu mà không ảnh hưởng lẫn nhau.
 * ========================================================= */
.kms-calpop {
  position: fixed !important;
  z-index: 999999999 !important;
  width: 300px !important;
  background: var(--surface-solid, #FFFFFF) !important;
  border: 1px solid var(--surface-border, #E2E8F0) !important;
  border-radius: 18px !important;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.18) !important;
  padding: 12px !important;
  display: none !important;
  font-family: inherit !important;
}
.kms-calpop.open { display: block !important; }
.kms-calpop-head {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  gap: 6px !important;
  background: #DC2626 !important; /* Đỏ Hoa Sen */
  border-radius: 12px !important;
  padding: 6px 8px !important;
  margin-bottom: 8px !important;
}
.kms-calpop-nav {
  background: rgba(255, 255, 255, 0.18) !important;
  border: none !important;
  color: #FFFFFF !important;
  width: 26px !important;
  height: 26px !important;
  border-radius: 8px !important;
  font-size: 1rem !important;
  font-weight: 800 !important;
  line-height: 1 !important;
  cursor: pointer !important;
  flex-shrink: 0 !important;
  transition: background 0.15s ease !important;
}
.kms-calpop-nav:hover { background: rgba(255, 255, 255, 0.32) !important; }
.kms-calpop-head .calendar-selects { flex: 1 1 auto !important; justify-content: center !important; }
.kms-calpop-head .calendar-selects select {
  border: 1.5px solid #FFFFFF !important;
  border-radius: 6px !important;
  padding: 3px 6px !important;
  font-size: 0.78rem !important;
  font-weight: 700 !important;
  color: #1E293B !important;
  background: #FFFFFF !important;
}
.kms-calpop .calendar-dow span { color: #64748B !important; font-weight: 700 !important; text-align: center !important; }
.kms-calpop .calendar-day { cursor: pointer !important; transition: background 0.15s ease, color 0.15s ease !important; }
.kms-calpop .calendar-day:not(.other-month):hover { background: #FEF2F2 !important; color: #DC2626 !important; }
/* Trạng thái "Hôm nay" — viền vàng nhạt, khác với trạng thái "Đã chọn" bên dưới */
.kms-calpop .calendar-day.today:not(.kms-picked) {
  outline: 2px solid #F5C451 !important;
  outline-offset: -2px !important;
  font-weight: 800 !important;
}
/* Trạng thái "Đã chọn" — nền Đỏ Hoa Sen đầy, đổ bóng đỏ, giống hệt style Flatpickr VIP trước đó */
.kms-calpop .calendar-day.kms-picked {
  background: #DC2626 !important;
  color: #FFFFFF !important;
  font-weight: 800 !important;
  box-shadow: 0 4px 12px rgba(220, 38, 38, 0.4) !important;
}

/* =========================================================
 *  THANH BỘ LỌC & TÌM KIẾM THÔNG MINH — Tab Kế hoạch / Báo cáo tuần
 * ========================================================= */
.kms-filter-bar {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  flex-wrap: wrap !important;
  gap: 12px !important;
  background: #FFFFFF !important;
  border: 1px solid #E2E8F0 !important;
  border-radius: 16px !important;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.04) !important;
  padding: 12px 14px !important;
  margin-bottom: 16px !important;
}
.kms-filter-bar .filter-group {
  display: flex !important;
  align-items: center !important;
  flex-wrap: wrap !important;
  gap: 10px !important;
  flex: 1 1 auto !important;
}
.filter-input-search {
  flex: 1 1 220px !important;
  min-width: 180px !important;
  border: 1.5px solid #E2E8F0 !important;
  border-radius: 12px !important;
  padding: 9px 14px !important;
  font-size: 0.85rem !important;
  color: #334155 !important;
  background: #F8FAFC !important;
  transition: all 0.2s ease !important;
}
.filter-input-search:focus {
  outline: none !important;
  border-color: #DC2626 !important;
  background: #FFFFFF !important;
  box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.1) !important;
}
.filter-select {
  border: 1.5px solid #E2E8F0 !important;
  border-radius: 12px !important;
  padding: 9px 12px !important;
  font-size: 0.83rem !important;
  color: #334155 !important;
  background: #F8FAFC !important;
  font-weight: 600 !important;
  transition: all 0.2s ease !important;
}
.filter-select:hover { border-color: #F5C451 !important; }
.filter-select:focus {
  outline: none !important;
  border-color: #DC2626 !important;
  box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.1) !important;
}
.btn-create-kms {
  flex: 0 0 auto !important;
  background: linear-gradient(135deg, #F5C451 0%, #D4AF37 100%) !important;
  color: #3A1200 !important;
  font-weight: 800 !important;
  font-size: 0.85rem !important;
  border: none !important;
  border-radius: 12px !important;
  padding: 10px 20px !important;
  cursor: pointer !important;
  white-space: nowrap !important;
  box-shadow: 0 6px 16px rgba(212, 175, 55, 0.35) !important;
  transition: transform 0.2s ease, box-shadow 0.2s ease !important;
}
.btn-create-kms:hover {
  transform: translateY(-2px) !important;
  box-shadow: 0 10px 22px rgba(212, 175, 55, 0.45) !important;
}
@media (max-width: 768px) {
  .kms-filter-bar { flex-direction: column !important; align-items: stretch !important; }
  .kms-filter-bar .filter-group { flex-direction: column !important; align-items: stretch !important; }
  .filter-input-search, .filter-select { width: 100% !important; }
  .btn-create-kms { width: 100% !important; }
}

/* =========================================================
 *  DẢI MÀU TRẠNG THÁI BÊN TRÁI — Card Kế hoạch (.kst-timeline-item) &
 *  Card Báo cáo tuần / Cửa hàng (.kst-store-card)
 * ========================================================= */
.kst-timeline-item,
.kst-store-card {
  position: relative !important;
  background: #FFFDF7 !important;
  border: 1px solid #E2E8F0 !important;
  border-radius: 16px !important;
  border-left: 5px solid #94A3B8 !important;
  overflow: hidden !important;
}
.kst-timeline-item.status-done,
.kst-store-card.status-done { border-left-color: #16A34A !important; }
.kst-timeline-item.status-progress,
.kst-store-card.status-progress { border-left-color: #F59E0B !important; }
.kst-timeline-item.status-pending,
.kst-store-card.status-pending { border-left-color: #DC2626 !important; }

.kst-card-avatar-chip {
  display: inline-flex !important;
  align-items: center !important;
  gap: 6px !important;
  font-weight: 700 !important;
  font-size: 0.85rem !important;
  color: #991B1B !important;
}
.kst-card-avatar-chip .chip-circle {
  width: 24px !important; height: 24px !important;
  border-radius: 50% !important;
  background: linear-gradient(135deg, #DC2626 0%, #991B1B 100%) !important;
  color: #FFFFFF !important;
  font-size: 0.7rem !important;
  font-weight: 800 !important;
  display: flex !important; align-items: center !important; justify-content: center !important;
  flex-shrink: 0 !important;
}

/* =========================================================
 *  POPUP XÁC NHẬN VUI NHỘN + MÈO AI MASCOT — khi Lưu kế hoạch
 * ========================================================= */
.kms-confirm-modal-card {
  max-width: 420px !important;
  text-align: center !important;
  padding: 32px 28px 26px !important;
}
.kms-mascot-cat {
  font-size: 3.6rem !important;
  line-height: 1 !important;
  margin-bottom: 6px !important;
  animation: kmsMascotBounce 1.6s ease-in-out infinite !important;
}
@keyframes kmsMascotBounce {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  25% { transform: translateY(-6px) rotate(-4deg); }
  50% { transform: translateY(0) rotate(0deg); }
  75% { transform: translateY(-3px) rotate(4deg); }
}
.kms-confirm-title {
  font-size: 1.15rem !important;
  font-weight: 800 !important;
  color: #991B1B !important;
  margin: 6px 0 8px !important;
}
.kms-confirm-desc {
  font-size: 0.88rem !important;
  color: #64748B !important;
  line-height: 1.5 !important;
  margin-bottom: 22px !important;
}
.kms-confirm-actions {
  display: flex !important;
  gap: 10px !important;
  justify-content: center !important;
}
.btn-cancel-modal {
  background: #F1F5F9 !important;
  color: #475569 !important;
  border: none !important;
  border-radius: 12px !important;
  padding: 11px 18px !important;
  font-weight: 700 !important;
  font-size: 0.85rem !important;
  cursor: pointer !important;
  transition: all 0.2s ease !important;
}
.btn-cancel-modal:hover { background: #E2E8F0 !important; }
.btn-confirm-modal {
  background: linear-gradient(135deg, #DC2626 0%, #991B1B 100%) !important;
  color: #FFFFFF !important;
  border: none !important;
  border-radius: 12px !important;
  padding: 11px 22px !important;
  font-weight: 800 !important;
  font-size: 0.85rem !important;
  cursor: pointer !important;
  box-shadow: 0 6px 16px rgba(220, 38, 38, 0.35) !important;
  transition: transform 0.2s ease, box-shadow 0.2s ease !important;
}
.btn-confirm-modal:hover { transform: translateY(-2px) !important; }

/* =========================================================
 *  Ô CHỌN ĐỊA ĐIỂM CÔNG TÁC (dropdown 39 CH) — dòng BCC Tháng
 * ========================================================= */
.report-bcc-location-select.form-select-custom {
  flex: 1 1 auto !important;
  border: 1.5px solid #E2E8F0 !important;
  border-radius: 10px !important;
  padding: 9px 12px !important;
  font-size: 0.85rem !important;
  color: #334155 !important;
  background: #FFFFFF !important;
  transition: all 0.2s ease !important;
}
.report-bcc-location-select.form-select-custom:focus {
  outline: none !important;
  border-color: #DC2626 !important;
  box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.12) !important;
}
.wizard-bcc-manual-input {
  flex: 1 1 auto !important;
  border: 1.5px solid #F5C451 !important;
  border-radius: 10px !important;
  padding: 9px 12px !important;
  margin-top: 6px !important;
  width: 100% !important;
}

/* =========================================================
 *  THẺ KHUNG LỚN GOM NHÓM THEO NHÂN SỰ/CỬA HÀNG (style Sheet Tồn đọng)
 *  Dùng cho Tab Kế hoạch (nhóm theo Nhân sự) & Tab Checklist (1 nhóm = ngữ cảnh đang chọn)
 * ========================================================= */
.kst-group-card {
  background: #FFFFFF !important;
  border: 1px solid #E2E8F0 !important;
  border-radius: 16px !important;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.05) !important;
  margin-bottom: 18px !important;
  overflow: hidden !important;
  border-left: 6px solid #94A3B8 !important;
}
.kst-group-card.status-done { border-left-color: #16A34A !important; }
.kst-group-card.status-progress { border-left-color: #F59E0B !important; }
.kst-group-card.status-pending { border-left-color: #DC2626 !important; }

.kst-group-header {
  display: flex !important;
  align-items: center !important;
  flex-wrap: wrap !important;
  gap: 10px !important;
  padding: 14px 18px !important;
  background: linear-gradient(135deg, #FFF7ED 0%, #FEF2F2 100%) !important;
  border-bottom: 1px solid #FDE68A !important;
}
.kst-group-header .kst-card-avatar-chip { font-size: 0.95rem !important; }
.kst-group-badge-cum {
  background: #FFFFFF !important;
  border: 1.5px solid #F5C451 !important;
  color: #B45309 !important;
  font-weight: 700 !important;
  font-size: 0.75rem !important;
  padding: 4px 12px !important;
  border-radius: 99px !important;
}
.kst-group-badge-count {
  margin-left: auto !important;
  background: #DC2626 !important;
  color: #FFFFFF !important;
  font-weight: 700 !important;
  font-size: 0.75rem !important;
  padding: 4px 14px !important;
  border-radius: 99px !important;
  white-space: nowrap !important;
}
.kst-group-body {
  padding: 14px 18px !important;
  display: flex !important;
  flex-direction: column !important;
  gap: 12px !important;
}
/* Item nhỏ bên trong Thẻ khung lớn — tái sử dụng dải màu trạng thái như .kst-timeline-item,
   nhưng bo góc nhỏ hơn + nền hơi khác để phân biệt rõ với khung Card cha bên ngoài. */
.kst-group-item {
  background: #FAFAF9 !important;
  border: 1px solid #F1F5F9 !important;
  border-left: 4px solid #94A3B8 !important;
  border-radius: 12px !important;
  padding: 10px 14px !important;
}
.kst-group-item.status-done { border-left-color: #16A34A !important; }
.kst-group-item.status-progress { border-left-color: #F59E0B !important; }
.kst-group-item.status-pending { border-left-color: #DC2626 !important; }