.bm-app-layout {
  min-height: 100vh;
}

.bm-app-shell {
  min-height: 100vh;
}

.bm-app-content {
  min-height: calc(100vh - 56px);
}

.bm-tailwind-page {
  min-height: calc(100vh - 104px);
  background: var(--bm-ui-bg);
  color: var(--bm-ui-text);
  font-size: 14px;
  line-height: 1.5;
}

.bm-tailwind-page h1 {
  font-size: 1.125rem;
  font-weight: 700;
  line-height: 1.3;
}

.bm-tailwind-page h2 {
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.35;
}

.bm-tailwind-page h3 {
  font-size: 0.9375rem;
  font-weight: 700;
  line-height: 1.35;
}

.bm-tailwind-page h4 {
  margin: 0 0 8px;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  line-height: 1.35;
  text-transform: uppercase;
  color: #475569;
}

.bm-tailwind-page p {
  margin: 0 0 8px;
  font-size: 13px;
  line-height: 1.45;
  color: #334155;
}

.bm-tailwind-page .form-group label,
.bm-tailwind-page .control-label {
  font-size: 12px;
  font-weight: 600;
  line-height: 1.35;
}

.bm-tailwind-page .content-header,
.bm-tailwind-page .content {
  padding: 0;
}

.bm-tailwind-container {
  box-sizing: border-box;
  max-width: 1600px;
  margin: 0 auto;
  padding: 16px;
}

.bm-filter-panel__body.collapse,
#collapseFilter.collapse {
  visibility: visible;
}

.bm-filter-panel__body.collapsing,
#collapseFilter.collapsing {
  display: block;
  overflow: hidden !important;
  visibility: visible;
}

.bm-filter-panel__body.collapse:not(.in):not(.collapsing),
#collapseFilter.collapse:not(.in):not(.collapsing) {
  display: none !important;
  height: 0 !important;
  overflow: hidden !important;
  visibility: hidden !important;
  padding: 0 !important;
}

.bm-filter-panel__body.collapse.in,
#collapseFilter.collapse.in {
  display: block !important;
  visibility: visible !important;
  height: auto !important;
  overflow: visible;
}

.bm-filter-panel .box-body > .row {
  display: flex;
  flex-wrap: wrap;
  margin-left: -8px;
  margin-right: -8px;
}

.bm-filter-panel .box-body > .row > [class*="col-"] {
  float: none;
  box-sizing: border-box;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  padding: 0 8px 12px;
}

.bm-filter-panel .box-body > .row > [class*="col-"] label {
  display: block;
}

.bm-filter-panel .box-body > .row > [class*="col-"] .bm-list-field,
.bm-filter-panel .box-body > .row > [class*="col-"] .form-control,
.bm-filter-panel .box-body > .row > [class*="col-"] .select2-container {
  width: 100% !important;
}

.bm-filter-panel .box-body input.bm-list-field,
.bm-filter-panel .box-body #sell_list_filter_date_range {
  height: 38px !important;
  min-height: 38px !important;
  box-sizing: border-box;
  border: 1px solid #d1d5db !important;
  border-radius: 8px !important;
  padding: 6px 12px !important;
  background: #fff !important;
  color: #0f172a;
  font-size: 13px;
  line-height: 1.4;
  width: 100% !important;
}

@media (min-width: 768px) {
  .bm-filter-panel .box-body > .row > [class*="col-"] {
    width: 25%;
    max-width: 25%;
  }
}

/* Stock history header has 4 KPI cards — fill the row evenly instead of 4-of-6. */
[data-page='stock-history'] .bm-page-header__kpis {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

@media (min-width: 1024px) {
  [data-page='stock-history'] .bm-page-header__kpis {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

/* Full-width pages: match list pages (product/purchase) — gutter from .bm-tw-content only */
.bm-list-page .bm-tailwind-container,
.bm-report-page .bm-tailwind-container,
.bm-sale-create .bm-tailwind-container,
.bm-purchase-create .bm-tailwind-container {
  max-width: 100%;
  width: 100%;
  margin-left: 0;
  margin-right: 0;
  padding: 0;
  box-sizing: border-box;
}

.bm-tailwind-page .box,
.bm-tailwind-page .card,
.bm-tailwind-page header.rounded-lg,
.bm-tailwind-page section.rounded-lg,
.bm-tailwind-page .content-header,
.bm-tailwind-page .modal-content,
.bm-tailwind-page .dataTables_wrapper {
  color: var(--bm-ui-text, #0f172a);
}

.bm-tailwind-page .box,
.bm-tailwind-page .card,
.bm-tailwind-page .box.box-primary,
.bm-tailwind-page .box.box-info,
.bm-tailwind-page header.rounded-lg,
.bm-tailwind-page header.bm-page-header,
.bm-tailwind-page section.rounded-lg {
  overflow: hidden;
  margin-bottom: 16px;
  border: 1px solid var(--bm-ui-border, #e2e8f0);
  border-radius: 8px;
  background: var(--bm-ui-surface, #ffffff);
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.06);
}

/* Full-bleed within the content column — no 1600px center cap; keep button inside the card. */
.bm-tailwind-page header.bm-page-header {
  box-sizing: border-box;
  width: 100%;
  max-width: 100%;
  overflow: hidden;
}

.bm-page-header__inner {
  box-sizing: border-box;
  width: 100%;
  max-width: 100%;
  padding: 4px 20px;
}

.bm-page-header__row {
  min-width: 0;
  max-width: 100%;
}

.bm-page-header__actions {
  min-width: 0;
}

.bm-tailwind-page .box-header,
.bm-tailwind-page .box-header.with-border,
.bm-tailwind-page .card > .row:first-child,
.bm-tailwind-page .card > .d-flex:first-child,
.bm-tailwind-page header.rounded-lg:not(.bm-page-header) > div > div:first-child {
  min-height: 48px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--bm-ui-border, #e2e8f0);
  background: var(--bm-ui-surface-soft, #f8fafc);
}

.bm-tailwind-page .box-title,
.bm-tailwind-page h1,
.bm-tailwind-page h2,
.bm-tailwind-page h3,
.bm-tailwind-page h4,
.bm-tailwind-page h5,
.bm-tailwind-page h6 {
  color: #0f172a;
}

.bm-tailwind-page .box-body,
.bm-tailwind-page .card .table-responsive,
.bm-tailwind-page .card_ul,
.bm-tailwind-page .box-header .card_ul {
  padding: 16px;
  background: #ffffff;
}

.bm-tailwind-page .kpi-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 12px;
}

.bm-tailwind-page .kpi-cards .card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 96px;
  align-items: center;
  min-height: 112px;
  padding: 14px;
}

.bm-tailwind-page .kpi-content span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 700;
}

.bm-tailwind-page .kpi-content h4 {
  margin: 8px 0 0;
  font-size: 20px;
  font-weight: 800;
  color: #0f172a;
}

.bm-tailwind-page .kpi-chart {
  min-width: 88px;
  min-height: 70px;
}

.bm-tailwind-page .dashboard-charts {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 16px;
}

.bm-tailwind-page .dashboard-charts > [class*="col-"],
.bm-tailwind-page .row > [class*="col-"] {
  width: auto;
  float: none;
  padding-left: 0;
  padding-right: 0;
}

.bm-tailwind-page .row {
  margin-left: 0;
  margin-right: 0;
}

.bm-tailwind-page .ml-5,
.bm-tailwind-page .mr-5,
.bm-tailwind-page .pl-5,
.bm-tailwind-page .pr-5 {
  margin-left: 0 !important;
  margin-right: 0 !important;
  padding-left: 0 !important;
  padding-right: 0 !important;
}

.bm-tailwind-page .form-group label,
.bm-tailwind-page .control-label,
.bm-tailwind-page .switch-btn-label,
.bm-tailwind-page .help-block,
.bm-tailwind-page .dataTables_info,
.bm-tailwind-page .dataTables_length label,
.bm-tailwind-page .dataTables_filter label {
  color: #475569;
}

.bm-tailwind-page .form-control,
.bm-tailwind-page .select2-container--default .select2-selection--single,
.bm-tailwind-page .select2-container--default .select2-selection--multiple,
.bm-tailwind-page input[type="text"],
.bm-tailwind-page input[type="password"],
.bm-tailwind-page input[type="email"],
.bm-tailwind-page textarea,
.bm-tailwind-page select {
  min-height: 36px;
  font-size: 13px;
  line-height: 1.4;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  background-color: #ffffff;
  color: #0f172a;
  box-shadow: none;
}

.bm-tailwind-page .form-control:focus,
.bm-tailwind-page input:focus,
.bm-tailwind-page textarea:focus,
.bm-tailwind-page select:focus {
  border-color: #334155;
  outline: 2px solid rgba(51, 65, 85, 0.18);
  outline-offset: 1px;
  box-shadow: none;
}

.bm-tailwind-page .table-responsive {
  overflow: auto;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  background: #ffffff;
}

.bm-tailwind-page table.table,
.bm-tailwind-page table.dataTable {
  width: 100% !important;
  margin: 0 !important;
  border-collapse: separate !important;
  border-spacing: 0;
  color: #0f172a;
}

.bm-tailwind-page table.table > thead > tr > th,
.bm-tailwind-page table.dataTable > thead > tr > th {
  border-bottom: 1px solid #e2e8f0 !important;
  background: #f8fafc;
  color: #334155;
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.bm-tailwind-page table.table > tbody > tr > td,
.bm-tailwind-page table.dataTable > tbody > tr > td {
  border-top: 1px solid #e2e8f0;
  color: #0f172a;
  vertical-align: middle;
}

.bm-tailwind-page table.table-striped > tbody > tr:nth-of-type(odd),
.bm-tailwind-page table.dataTable.stripe > tbody > tr.odd,
.bm-tailwind-page table.dataTable.display > tbody > tr.odd {
  background-color: #f8fafc;
}

.bm-tailwind-page table.table-hover > tbody > tr:hover,
.bm-tailwind-page table.dataTable.hover > tbody > tr:hover,
.bm-tailwind-page table.dataTable.display > tbody > tr:hover {
  background-color: #eef2ff;
}

.bm-tailwind-page .dataTables_wrapper .dataTables_filter input,
.bm-tailwind-page .dataTables_wrapper .dataTables_length select {
  margin-left: 8px;
}

.bm-tailwind-page .dataTables_wrapper .dataTables_paginate {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 6px;
  float: none !important;
  margin: 0 !important;
  padding: 0 !important;
}

.bm-tailwind-page .dataTables_wrapper .dataTables_paginate .paginate_button,
.bm-tailwind-page .dataTables_wrapper .dataTables_paginate span.paginate_button {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  min-width: 32px;
  min-height: 32px;
  margin: 0 !important;
  padding: 0 10px !important;
  border: 1px solid var(--bm-ui-border, #cbd5e1) !important;
  border-radius: 6px !important;
  color: var(--bm-ui-text, #334155) !important;
  background: var(--bm-ui-surface, #ffffff) !important;
  font-size: 12px !important;
  font-weight: 500;
  box-shadow: none !important;
}

.bm-tailwind-page .dataTables_wrapper .dataTables_paginate .paginate_button.current,
.bm-tailwind-page .dataTables_wrapper .dataTables_paginate .paginate_button.current:hover {
  border-color: var(--bm-ui-accent, #0f172a) !important;
  background: var(--bm-ui-accent, #0f172a) !important;
  color: var(--bm-ui-accent-text, #ffffff) !important;
}

.bm-tailwind-page .dataTables_wrapper .dataTables_paginate .paginate_button:hover:not(.disabled):not(.current) {
  background: var(--bm-ui-surface-soft, #f8fafc) !important;
}

.bm-tailwind-page .dataTables_wrapper .dataTables_paginate .paginate_button.disabled,
.bm-tailwind-page .dataTables_wrapper .dataTables_paginate .paginate_button.disabled:hover {
  opacity: 0.45;
  cursor: not-allowed;
}

.bm-tailwind-page .dataTables_wrapper .dataTables_info {
  padding: 0;
  font-size: 12px;
  color: var(--bm-ui-muted, #64748b);
}

.bm-tailwind-page .btn,
.bm-tailwind-page .btn-primary,
.bm-tailwind-page .btn-info,
.bm-tailwind-page .btn-success,
.bm-tailwind-page .btn-danger {
  border-radius: 6px;
  font-size: 13px;
  font-weight: 600;
  line-height: 1.35;
}

.bm-tailwind-page .btn-primary {
  border-color: #0f172a;
  background: #0f172a;
  color: #ffffff;
}

.bm-tailwind-page .btn-info {
  border-color: #2563eb;
  background: #2563eb;
  color: #ffffff;
}

.bm-tailwind-page .btn-success {
  border-color: #16a34a;
  background: #16a34a;
  color: #ffffff;
}

.bm-tailwind-page .btn-danger {
  border-color: #dc2626;
  background: #dc2626;
  color: #ffffff;
}

.bm-tailwind-page .label.bg-gray {
  display: inline-flex;
  margin-left: 6px;
  border-radius: 999px;
  background: #e2e8f0 !important;
  color: #334155 !important;
}

.bm-create-form {
  display: block;
}

.bm-create-shell {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 16px;
  align-items: start;
}

.bm-create-main {
  min-width: 0;
}

.bm-create-panel,
.bm-create-aside,
.bm-summary-card {
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  background: #ffffff;
  color: #0f172a;
}

.bm-create-panel {
  overflow: hidden;
}

.bm-create-tabs {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  padding: 0 12px;
  border-bottom: 1px solid #e2e8f0;
  background: #f8fafc;
}

.bm-create-tabs span {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 10px;
  border-bottom: 2px solid transparent;
  color: #64748b;
  font-size: 13px;
  font-weight: 800;
  white-space: nowrap;
}

.bm-create-tabs span.is-active {
  border-color: #0f172a;
  color: #0f172a;
}

.bm-create-section {
  padding: 16px;
  border-bottom: 1px solid #e2e8f0;
}

.bm-create-section:last-child {
  border-bottom: 0;
}

.bm-create-section-header {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

.bm-create-section-header h3 {
  margin: 0;
  color: #0f172a;
  font-size: 15px;
  font-weight: 900;
}

.bm-create-section-header p {
  margin: 3px 0 0;
  color: #64748b;
  font-size: 12px;
}

.bm-create-section-header > span {
  align-self: start;
  padding: 5px 8px;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  color: #475569;
  font-size: 11px;
  font-weight: 800;
  white-space: nowrap;
}

.bm-create-section .box {
  margin-bottom: 0 !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

.bm-create-section .box-header {
  display: none;
}

.bm-create-section .box-body {
  padding: 0 !important;
  background: transparent !important;
}

.bm-create-section .box-body,
.bm-create-section .box-body > .row,
.bm-create-section > .row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 12px;
}

.bm-create-section .box-body > .row,
.bm-create-section .table-responsive,
.bm-create-section #product_form_part,
.bm-create-section .section_row,
.bm-create-section .user_auth_fields {
  grid-column: 1 / -1;
}

.bm-create-section .box-body > [class*="col-"],
.bm-create-section .box-body > .row > [class*="col-"],
.bm-create-section .row > [class*="col-"],
.bm-create-section .form-group[class*="col-"],
.bm-create-section .user_auth_fields > [class*="col-"] {
  width: auto !important;
  min-width: 0;
  float: none !important;
  padding-left: 0 !important;
  padding-right: 0 !important;
}

.bm-create-section .box-body > .clearfix,
.bm-create-section .row > .clearfix,
.bm-create-section .clearfix {
  display: none !important;
}

.bm-create-section .col-sm-6,
.bm-create-section .col-md-6 {
  grid-column: span 2;
}

.bm-create-section .col-sm-12,
.bm-create-section .col-md-12,
.bm-create-section textarea.form-control {
  grid-column: 1 / -1;
}

.bm-create-section .form-group,
.bm-create-section .bm-product-field {
  margin-bottom: 0 !important;
}

.bm-create-section .form-group label,
.bm-create-section .bm-product-field label,
.bm-create-section .control-label,
.bm-create-section .switch-btn-label,
.bm-create-section .setting-switch-label-text {
  color: #334155;
  font-size: 12px;
  font-weight: 800;
}

.bm-create-section .help-block {
  margin: 5px 0 0;
  color: #64748b;
  font-size: 12px;
}

.bm-create-section .input-group,
.bm-create-section .select2-container,
.bm-create-section .form-control,
.bm-create-section .bm-product-input,
.bm-create-section select.bm-product-input,
.bm-create-section textarea.bm-product-input {
  width: 100% !important;
}

.bm-tailwind-page .switch-btn-group {
  display: flex;
  align-items: center;
  gap: 8px;
}

.bm-create-section .switch-btn-group,
.bm-create-section .setting-switch-button-form-group,
.bm-create-section .checkbox label {
  min-height: 42px;
  gap: 10px;
  padding: 9px 5px;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  background: #f8fafc;
}

.bm-create-section .checkbox {
  margin: 0;
}

.bm-create-aside {
  position: sticky;
  top: 72px;
  display: grid;
  gap: 12px;
  padding: 12px;
}

.bm-summary-card {
  padding: 14px;
}

.bm-summary-title {
  margin-bottom: 12px;
  color: #0f172a;
  font-size: 14px;
  font-weight: 900;
}

.bm-summary-card dl {
  display: grid;
  gap: 9px;
  margin: 0;
}

.bm-summary-card dl > div {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  border-bottom: 1px solid #f1f5f9;
  padding-bottom: 8px;
}

.bm-summary-card dl > div:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.bm-summary-card dt {
  color: #64748b;
  font-size: 12px;
  font-weight: 700;
}

.bm-summary-card dd {
  max-width: 180px;
  margin: 0;
  color: #0f172a;
  font-size: 12px;
  font-weight: 900;
  text-align: right;
  word-break: break-word;
}

.bm-summary-note,
.bm-validation-list {
  margin: 0;
  color: #475569;
  font-size: 12px;
}

.bm-validation-list {
  display: grid;
  gap: 8px;
  padding-left: 0;
  list-style: none;
}

.bm-validation-list li {
  display: flex;
  gap: 8px;
}

.bm-validation-list li::before {
  content: "";
  width: 7px;
  height: 7px;
  margin-top: 5px;
  border-radius: 999px;
  background: #f59e0b;
  flex: 0 0 auto;
}

.bm-validation-list li.is-complete::before {
  background: #16a34a;
}

.bm-create-form > .row:last-of-type {
  position: sticky;
  bottom: 0;
  z-index: 20;
  margin-top: 16px;
  padding: 12px;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(10px);
}

.bm-tailwind-page .list-group-item {
  padding: 8px 0;
  border-color: #e2e8f0;
  background: transparent;
  color: #0f172a;
  font-size: 13px;
  line-height: 1.4;
}

.bm-tailwind-page .list-group-item b {
  font-size: 12px;
  font-weight: 600;
  color: #475569;
}

.bm-tailwind-page .modal-content {
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  background: #ffffff;
}

.bm-tailwind-page header.rounded-lg [class*="rounded-md"][class*="border"],
.bm-tailwind-page section.rounded-lg [class*="rounded-md"][class*="border"] {
  border-color: var(--bm-ui-border, #e2e8f0);
  background: var(--bm-ui-surface, #ffffff);
  color: var(--bm-ui-text, #0f172a);
}

.bm-tailwind-page[data-page="create-user"] #user_add_form > .row,
.bm-tailwind-page[data-page="edit-user"] #user_edit_form > .row,
.bm-tailwind-page[data-page="profile"] #edit_user_profile_form > .row,
.bm-tailwind-page[data-page="profile"] #edit_password_form > .row,
.bm-tailwind-page[data-page="create-user"] .box-body,
.bm-tailwind-page[data-page="edit-user"] .box-body,
.bm-tailwind-page[data-page="profile"] .box-body {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 12px;
}

.bm-tailwind-page[data-page="create-user"] .box-body > .clearfix,
.bm-tailwind-page[data-page="edit-user"] .box-body > .clearfix,
.bm-tailwind-page[data-page="profile"] .box-body > .clearfix,
.bm-tailwind-page[data-page="create-user"] #user_add_form > .row > .clearfix,
.bm-tailwind-page[data-page="edit-user"] #user_edit_form > .row > .clearfix,
.bm-tailwind-page[data-page="profile"] #edit_user_profile_form > .row > .clearfix,
.bm-tailwind-page[data-page="profile"] #edit_password_form > .row > .clearfix {
  display: none;
}

.bm-tailwind-page[data-page="create-user"] .box-body > [class*="col-"],
.bm-tailwind-page[data-page="edit-user"] .box-body > [class*="col-"],
.bm-tailwind-page[data-page="profile"] .box-body > [class*="col-"],
.bm-tailwind-page[data-page="create-user"] #user_add_form > .row > [class*="col-"],
.bm-tailwind-page[data-page="edit-user"] #user_edit_form > .row > [class*="col-"],
.bm-tailwind-page[data-page="profile"] #edit_user_profile_form > .row > [class*="col-"],
.bm-tailwind-page[data-page="profile"] #edit_password_form > .row > [class*="col-"],
.bm-tailwind-page[data-page="create-user"] .user_auth_fields > [class*="col-"],
.bm-tailwind-page[data-page="edit-user"] .user_auth_fields > [class*="col-"],
.bm-tailwind-page[data-page="create-user"] .selected_contacts_div,
.bm-tailwind-page[data-page="edit-user"] .selected_contacts_div {
  width: auto;
  min-width: 0;
  float: none;
  padding-left: 0;
  padding-right: 0;
}

.bm-tailwind-page[data-page="create-user"] .user_auth_fields,
.bm-tailwind-page[data-page="edit-user"] .user_auth_fields {
  display: grid;
  grid-column: 1 / -1;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 12px;
}

.bm-tailwind-page[data-page="create-user"] .form-group,
.bm-tailwind-page[data-page="edit-user"] .form-group,
.bm-tailwind-page[data-page="profile"] .form-group {
  margin-bottom: 0;
}

.bm-tailwind-page[data-page="create-user"] h4,
.bm-tailwind-page[data-page="edit-user"] h4,
.bm-tailwind-page[data-page="profile"] h4 {
  margin: 4px 0;
  font-size: 14px;
  font-weight: 800;
}

.bm-tailwind-page[data-page="view-user"] .row {
  display: grid;
  grid-template-columns: minmax(240px, 320px) minmax(0, 1fr);
  gap: 16px;
}

.bm-tailwind-page[data-page="product-list"] .filters,
.bm-tailwind-page[data-page="product-list"] .box.box-solid {
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.06);
}

.bm-tailwind-page[data-page="product-list"] .filters .box-body,
.bm-tailwind-page[data-page="product-list"] .box-body {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 12px;
}

.bm-tailwind-page[data-page="product-list"] .filters .box-body > [class*="col-"],
.bm-tailwind-page[data-page="product-list"] .box-body > [class*="col-"] {
  width: auto;
  float: none;
  padding-left: 0;
  padding-right: 0;
}

.bm-tailwind-page[data-page="product-list"] .nav-tabs-custom {
  overflow: hidden;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.06);
}

.bm-tailwind-page[data-page="product-list"] .nav-tabs-custom > .nav-tabs {
  display: flex;
  border-bottom: 1px solid #e2e8f0;
  background: #f8fafc;
}

.bm-tailwind-page[data-page="product-list"] .nav-tabs-custom > .nav-tabs > li {
  float: none;
}

.bm-tailwind-page[data-page="product-list"] .nav-tabs-custom > .nav-tabs > li > a {
  margin: 0;
  border: 0;
  border-radius: 0;
  color: #475569;
  font-weight: 700;
}

.bm-tailwind-page[data-page="product-list"] .nav-tabs-custom > .nav-tabs > li.active > a,
.bm-tailwind-page[data-page="product-list"] .nav-tabs-custom > .nav-tabs > li > a:hover {
  background: #ffffff;
  color: #0f172a;
}

.bm-tailwind-page[data-page="product-list"] .tab-content {
  padding: 16px;
  background: #ffffff;
}

.bm-tailwind-page[data-page="product-list"] #product_table tfoot td > div {
  flex-wrap: wrap;
  gap: 6px;
}

body.bm-theme-dark .bm-tailwind-page[data-page="product-list"] .filters,
body.bm-theme-dark .bm-tailwind-page[data-page="product-list"] .box.box-solid,
body.bm-theme-dark .bm-tailwind-page[data-page="product-list"] .nav-tabs-custom,
body.bm-theme-dark .bm-tailwind-page[data-page="product-list"] .tab-content {
  border-color: #1e293b;
  background: #0f172a;
  color: #e2e8f0;
}

body.bm-theme-dark .bm-tailwind-page[data-page="product-list"] .nav-tabs-custom > .nav-tabs {
  border-color: #1e293b;
  background: #111827;
}

body.bm-theme-dark .bm-tailwind-page[data-page="product-list"] .nav-tabs-custom > .nav-tabs > li > a {
  color: #cbd5e1;
}

body.bm-theme-dark .bm-tailwind-page[data-page="product-list"] .nav-tabs-custom > .nav-tabs > li.active > a,
body.bm-theme-dark .bm-tailwind-page[data-page="product-list"] .nav-tabs-custom > .nav-tabs > li > a:hover {
  background: #0f172a;
  color: #f8fafc;
}

.bm-tailwind-page[data-page="add-product"] .box {
  overflow: hidden;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.06);
}

.bm-tailwind-page[data-page="add-product"] .box-header {
  border-color: #e2e8f0;
  background: #f8fafc;
}

/* Layout grids for add-product live in bizmodo-create-product.css */

.bm-tailwind-page[data-page="add-product"] .form-group {
  margin-bottom: 0;
}

.bm-tailwind-page[data-page="add-product"] .form-group label {
  color: #334155;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.01em;
}

.bm-tailwind-page[data-page="add-product"] .form-control,
.bm-tailwind-page[data-page="add-product"] .select2-container,
.bm-tailwind-page[data-page="add-product"] .input-group {
  width: 100% !important;
}

.bm-tailwind-page[data-page="add-product"] textarea.form-control {
  min-height: 92px;
}

.bm-tailwind-page[data-page="add-product"] .help-block {
  margin-bottom: 0;
  color: #64748b;
  font-size: 12px;
}

.bm-tailwind-page[data-page="add-product"] .setting-switch-button-form-group {
  min-height: 42px;
  gap: 10px;
  padding: 9px 10px;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  background: #f8fafc;
}

.bm-tailwind-page[data-page="add-product"] .setting-switch-label-text {
  color: #334155;
  font-weight: 700;
}

.bm-tailwind-page[data-page="add-product"] .add-product-price-table {
  margin-bottom: 0;
  border-color: #e2e8f0;
}

.bm-tailwind-page[data-page="add-product"] .add-product-price-table th {
  background: #f8fafc;
  color: #334155;
  font-size: 12px;
}

.bm-tailwind-page[data-page="add-product"] .add-product-price-table td {
  vertical-align: top;
}

.bm-tailwind-page[data-page="add-product"] .btn-group {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
}

.bm-tailwind-page[data-page="add-product"] .btn-group > .btn {
  float: none;
  border-radius: 6px !important;
}

body.bm-theme-dark .bm-tailwind-page[data-page="add-product"] .box,
body.bm-theme-dark .bm-tailwind-page[data-page="add-product"] .setting-switch-button-form-group {
  border-color: #1e293b;
  background: #0f172a;
  color: #e2e8f0;
}

body.bm-theme-dark .bm-tailwind-page[data-page="add-product"] .box-header,
body.bm-theme-dark .bm-tailwind-page[data-page="add-product"] .add-product-price-table th {
  border-color: #1e293b;
  background: #111827;
  color: #f8fafc;
}

body.bm-theme-dark .bm-tailwind-page[data-page="add-product"] .form-group label,
body.bm-theme-dark .bm-tailwind-page[data-page="add-product"] .setting-switch-label-text {
  color: #e2e8f0;
}

body.bm-theme-dark .bm-tailwind-page[data-page="add-product"] .help-block {
  color: #94a3b8;
}

.bm-tailwind-page[data-page="edit-product"] .box {
  overflow: hidden;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.06);
}

.bm-tailwind-page[data-page="edit-product"] .box-header {
  border-color: #e2e8f0;
  background: #f8fafc;
}

/* Layout grids for edit-product live in bizmodo-edit-product.css */

.bm-tailwind-page[data-page="edit-product"] .form-group {
  margin-bottom: 0;
}

.bm-tailwind-page[data-page="edit-product"] .form-group label {
  color: #334155;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.01em;
}

.bm-tailwind-page[data-page="edit-product"] .form-control,
.bm-tailwind-page[data-page="edit-product"] .select2-container,
.bm-tailwind-page[data-page="edit-product"] .input-group {
  width: 100% !important;
}

.bm-tailwind-page[data-page="edit-product"] textarea.form-control {
  min-height: 92px;
}

.bm-tailwind-page[data-page="edit-product"] .help-block {
  margin-bottom: 0;
  color: #64748b;
  font-size: 12px;
}

.bm-tailwind-page[data-page="edit-product"] .setting-switch-button-form-group {
  min-height: 42px;
  gap: 10px;
  padding: 9px 10px;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  background: #f8fafc;
}

.bm-tailwind-page[data-page="edit-product"] .setting-switch-label-text {
  color: #334155;
  font-weight: 700;
}

.bm-tailwind-page[data-page="edit-product"] .add-product-price-table {
  margin-bottom: 0;
  border-color: #e2e8f0;
}

.bm-tailwind-page[data-page="edit-product"] .add-product-price-table th {
  background: #f8fafc;
  color: #334155;
  font-size: 12px;
}

.bm-tailwind-page[data-page="edit-product"] .add-product-price-table td {
  vertical-align: top;
}

.bm-tailwind-page[data-page="edit-product"] .btn-group {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
}

.bm-tailwind-page[data-page="edit-product"] .btn-group > .btn {
  float: none;
  border-radius: 6px !important;
}

body.bm-theme-dark .bm-tailwind-page[data-page="edit-product"] .box,
body.bm-theme-dark .bm-tailwind-page[data-page="edit-product"] .setting-switch-button-form-group {
  border-color: #1e293b;
  background: #0f172a;
  color: #e2e8f0;
}

body.bm-theme-dark .bm-tailwind-page[data-page="edit-product"] .box-header,
body.bm-theme-dark .bm-tailwind-page[data-page="edit-product"] .add-product-price-table th {
  border-color: #1e293b;
  background: #111827;
  color: #f8fafc;
}

body.bm-theme-dark .bm-tailwind-page[data-page="edit-product"] .form-group label,
body.bm-theme-dark .bm-tailwind-page[data-page="edit-product"] .setting-switch-label-text {
  color: #e2e8f0;
}

body.bm-theme-dark .bm-tailwind-page[data-page="edit-product"] .help-block {
  color: #94a3b8;
}

body.bm-theme-dark .bm-tailwind-page[data-page="edit-product"] table,
body.bm-theme-dark .bm-tailwind-page[data-page="edit-product"] table td,
body.bm-theme-dark .bm-tailwind-page[data-page="edit-product"] table th {
  border-color: #1e293b;
  background: #0f172a;
  color: #e2e8f0;
}

.bm-tailwind-page[data-page="product-view"].modal-content {
  overflow: hidden;
  border: 0;
  border-radius: 8px;
  background: #ffffff;
}

.bm-tailwind-page[data-page="product-view"] .modal-header,
.bm-tailwind-page[data-page="product-view"] .modal-footer {
  border-color: #e2e8f0;
  background: #f8fafc;
}

.bm-tailwind-page[data-page="product-view"] .modal-title {
  color: #0f172a;
  font-size: 18px;
  font-weight: 800;
}

.bm-tailwind-page[data-page="product-view"] .modal-body {
  padding: 16px 20px;
}

.bm-product-view-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(220px, 280px);
  gap: 16px;
  margin-bottom: 16px;
}

.bm-product-view-cards {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.bm-product-view-card,
.bm-product-view-description {
  padding: 12px;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  background: #ffffff;
}

.bm-product-view-card-title,
.bm-product-view-section-title {
  margin: 0 0 10px;
  color: #0f172a;
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.bm-product-view-meta {
  margin: 0;
}

.bm-product-view-meta > div {
  display: grid;
  grid-template-columns: minmax(110px, 38%) minmax(0, 1fr);
  gap: 8px;
  padding: 6px 0;
  border-bottom: 1px solid #f1f5f9;
}

.bm-product-view-meta > div:last-child {
  border-bottom: 0;
}

.bm-product-view-meta dt {
  margin: 0;
  color: #64748b;
  font-size: 12px;
  font-weight: 600;
}

.bm-product-view-meta dd {
  margin: 0;
  color: #0f172a;
  font-size: 13px;
  font-weight: 500;
}

.bm-product-view-description {
  margin-top: 12px;
}

.bm-product-view-description-body {
  color: #334155;
  font-size: 13px;
  line-height: 1.55;
}

.bm-product-view-aside {
  min-width: 0;
}

.bm-product-view-image {
  overflow: hidden;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  background: #f8fafc;
}

.bm-product-view-image img {
  display: block;
  width: 100%;
  max-height: 280px;
  object-fit: contain;
}

.bm-product-view-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #0f766e;
  font-weight: 600;
}

.bm-product-view-section {
  margin-top: 16px;
}

.bm-product-view-table {
  margin-bottom: 0;
  border-color: #e2e8f0;
  background: #ffffff;
}

.bm-product-view-table th {
  background: #f8fafc;
  color: #334155;
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}

.bm-product-view-table td {
  vertical-align: top;
  font-size: 13px;
}

.bm-product-view-loading,
.bm-product-view-error {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 120px;
  color: #64748b;
  font-size: 14px;
  font-weight: 600;
}

.bm-product-view-error {
  flex-direction: column;
  color: #b91c1c;
}

.bm-tailwind-page[data-page="product-view"] .invoice-col {
  min-height: 100%;
  padding: 12px;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  background: #ffffff;
}

.bm-tailwind-page[data-page="product-view"] .invoice-col b,
.bm-tailwind-page[data-page="product-view"] .invoice-col strong {
  color: #334155;
}

.bm-tailwind-page[data-page="product-view"] .thumbnail {
  margin-bottom: 0;
  border-color: #e2e8f0;
  border-radius: 8px;
  background: #f8fafc;
}

.bm-tailwind-page[data-page="product-view"] .thumbnail img {
  width: 100%;
  max-height: 260px;
  object-fit: contain;
}

.bm-tailwind-page[data-page="product-view"] table {
  margin-bottom: 0;
  border-color: #e2e8f0;
  background: #ffffff;
}

.bm-tailwind-page[data-page="product-view"] table th {
  background: #f8fafc;
  color: #334155;
  font-size: 12px;
}

.bm-tailwind-page[data-page="product-view"] table td {
  vertical-align: top;
}

body.bm-theme-dark .bm-tailwind-page[data-page="product-view"].modal-content,
body.bm-theme-dark .bm-tailwind-page[data-page="product-view"] .invoice-col,
body.bm-theme-dark .bm-tailwind-page[data-page="product-view"] .bm-product-view-card,
body.bm-theme-dark .bm-tailwind-page[data-page="product-view"] .bm-product-view-description,
body.bm-theme-dark .bm-tailwind-page[data-page="product-view"] .bm-product-view-image,
body.bm-theme-dark .bm-tailwind-page[data-page="product-view"] .thumbnail,
body.bm-theme-dark .bm-tailwind-page[data-page="product-view"] table,
body.bm-theme-dark .bm-tailwind-page[data-page="product-view"] table td,
body.bm-theme-dark .bm-tailwind-page[data-page="product-view"] table th {
  border-color: #1e293b;
  background: #0f172a;
  color: #e2e8f0;
}

body.bm-theme-dark .bm-tailwind-page[data-page="product-view"] .modal-header,
body.bm-theme-dark .bm-tailwind-page[data-page="product-view"] .modal-footer,
body.bm-theme-dark .bm-tailwind-page[data-page="product-view"] table th {
  border-color: #1e293b;
  background: #111827;
  color: #f8fafc;
}

body.bm-theme-dark .bm-tailwind-page[data-page="product-view"] .modal-title,
body.bm-theme-dark .bm-tailwind-page[data-page="product-view"] .invoice-col b,
body.bm-theme-dark .bm-tailwind-page[data-page="product-view"] .invoice-col strong,
body.bm-theme-dark .bm-tailwind-page[data-page="product-view"] .bm-product-view-card-title,
body.bm-theme-dark .bm-tailwind-page[data-page="product-view"] .bm-product-view-section-title,
body.bm-theme-dark .bm-tailwind-page[data-page="product-view"] .bm-product-view-meta dd {
  color: #f8fafc;
}

.bm-tailwind-page[data-page="stock-history"] .box {
  overflow: hidden;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.06);
}

.bm-tailwind-page[data-page="stock-history"] .box-header {
  border-color: #e2e8f0;
  background: #f8fafc;
}

.bm-tailwind-page[data-page="stock-history"] .box-body {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 12px;
}

.bm-tailwind-page[data-page="stock-history"] .box-body > [class*="col-"],
.bm-tailwind-page[data-page="stock-history"] .box-body > .row {
  width: auto;
  float: none;
  padding-left: 0;
  padding-right: 0;
}

.bm-tailwind-page[data-page="stock-history"] #product_stock_history {
  grid-column: 1 / -1;
}

.bm-tailwind-page[data-page="stock-history"] #product_stock_history h4,
.bm-tailwind-page[data-page="stock-history"] #product_stock_history strong {
  color: var(--bm-ui-text, #0f172a);
}

.bm-tailwind-page[data-page="stock-history"] #product_stock_history .row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 12px;
}

.bm-tailwind-page[data-page="stock-history"] #product_stock_history .row > [class*="col-"] {
  width: auto;
  float: none;
}

.bm-tailwind-page[data-page="stock-history"] table {
  margin-bottom: 0;
  border-color: #e2e8f0;
  background: #ffffff;
}

.bm-tailwind-page[data-page="stock-history"] table th {
  background: #f8fafc;
  color: #334155;
  font-size: 12px;
}

.bm-tailwind-page[data-page="stock-history"] .nav-tabs {
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  border-bottom: 1px solid #e2e8f0;
}

.bm-tailwind-page[data-page="stock-history"] .nav-tabs > li {
  float: none;
}

.bm-tailwind-page[data-page="stock-history"] .nav-tabs > li > a {
  margin: 0;
  border-radius: 6px 6px 0 0;
  color: #475569;
  font-weight: 700;
}

body.bm-theme-dark .bm-tailwind-page[data-page="stock-history"] .box,
body.bm-theme-dark .bm-tailwind-page[data-page="stock-history"] table,
body.bm-theme-dark .bm-tailwind-page[data-page="stock-history"] table td,
body.bm-theme-dark .bm-tailwind-page[data-page="stock-history"] table th {
  border-color: #1e293b;
  background: #0f172a;
  color: #e2e8f0;
}

body.bm-theme-dark .bm-tailwind-page[data-page="stock-history"] .box-header,
body.bm-theme-dark .bm-tailwind-page[data-page="stock-history"] table th {
  border-color: #1e293b;
  background: #111827;
  color: #f8fafc;
}

body.bm-theme-dark .bm-tailwind-page[data-page="stock-history"] .nav-tabs {
  border-color: #1e293b;
}

body.bm-theme-dark .bm-tailwind-page[data-page="stock-history"] .nav-tabs > li > a {
  color: #cbd5e1;
}

body.bm-theme-dark .bm-tailwind-page[data-page="stock-history"] #product_stock_history h4,
body.bm-theme-dark .bm-tailwind-page[data-page="stock-history"] #product_stock_history strong {
  color: #f8fafc;
}

@media (max-width: 991px) {
  .bm-product-view-layout {
    grid-template-columns: 1fr;
  }

  .bm-product-view-cards {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 767px) {
  .bm-tailwind-page[data-page="product-view"] .modal-body > .row:first-child {
    grid-template-columns: 1fr;
  }
}

.bm-tailwind-page[data-page="view-user"] .row .row {
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}

.bm-tailwind-page[data-page="view-user"] .profile-user-img {
  width: 96px;
  height: 96px;
  margin: 0 auto 12px;
  border: 3px solid #e2e8f0;
  object-fit: cover;
}

.bm-tailwind-page[data-page="view-user"] .profile-username {
  margin: 8px 0 4px;
  font-size: 15px;
  font-weight: 700;
  line-height: 1.3;
  text-transform: none;
  color: #0f172a;
}

.bm-tailwind-page[data-page="view-user"] .nav-tabs-custom {
  overflow: hidden;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.06);
}

.bm-tailwind-page[data-page="view-user"] .nav-tabs-custom > .nav-tabs {
  display: flex;
  border-bottom: 1px solid #e2e8f0;
  background: #f8fafc;
}

.bm-tailwind-page[data-page="view-user"] .nav-tabs-custom > .nav-tabs > li {
  float: none;
  flex: 1 1 0;
}

.bm-tailwind-page[data-page="view-user"] .nav-tabs-custom > .nav-tabs > li > a {
  margin: 0;
  border: 0;
  border-radius: 0;
  color: #475569;
  font-weight: 700;
}

.bm-tailwind-page[data-page="view-user"] .nav-tabs-custom > .nav-tabs > li.active > a,
.bm-tailwind-page[data-page="view-user"] .nav-tabs-custom > .nav-tabs > li > a:hover {
  background: #ffffff;
  color: #0f172a;
}

.bm-tailwind-page[data-page="view-user"] .tab-content {
  padding: 16px;
  background: #ffffff;
  color: #0f172a;
}

.bm-tailwind-page[data-page="view-user"] .tab-content p {
  color: #334155;
}

body.bm-theme-dark .bm-tailwind-page[data-page="view-user"] .profile-user-img {
  border-color: #334155;
}

body.bm-theme-dark .bm-tailwind-page[data-page="view-user"] .nav-tabs-custom,
body.bm-theme-dark .bm-tailwind-page[data-page="view-user"] .tab-content {
  border-color: #1e293b;
  background: #0f172a;
  color: #e2e8f0;
}

body.bm-theme-dark .bm-tailwind-page[data-page="view-user"] .nav-tabs-custom > .nav-tabs {
  border-color: #1e293b;
  background: #111827;
}

body.bm-theme-dark .bm-tailwind-page[data-page="view-user"] .nav-tabs-custom > .nav-tabs > li > a {
  color: #cbd5e1;
}

body.bm-theme-dark .bm-tailwind-page[data-page="view-user"] .nav-tabs-custom > .nav-tabs > li.active > a,
body.bm-theme-dark .bm-tailwind-page[data-page="view-user"] .nav-tabs-custom > .nav-tabs > li > a:hover {
  background: #0f172a;
  color: #f8fafc;
}

body.bm-theme-dark .bm-tailwind-page[data-page="view-user"] .tab-content p {
  color: #cbd5e1;
}

@media (max-width: 991px) {
  .bm-tailwind-page[data-page="view-user"] .row {
    grid-template-columns: 1fr;
  }
}

html[data-bm-theme='dark'] .bm-tailwind-page .box,
html[data-bm-theme='dark'] .bm-tailwind-page .card,
html[data-bm-theme='dark'] .bm-tailwind-page .box.box-primary,
html[data-bm-theme='dark'] .bm-tailwind-page .box.box-info,
html[data-bm-theme='dark'] .bm-tailwind-page header.rounded-lg,
html[data-bm-theme='dark'] .bm-tailwind-page header.bm-page-header,
html[data-bm-theme='dark'] .bm-tailwind-page section.rounded-lg,
html[data-bm-theme='dark'] .bm-tailwind-page .content-header,
html[data-bm-theme='dark'] .bm-tailwind-page .modal-content,
html[data-bm-theme='dark'] .bm-tailwind-page .dataTables_wrapper,
html.dark .bm-tailwind-page .box,
html.dark .bm-tailwind-page .card,
html.dark .bm-tailwind-page .box.box-primary,
html.dark .bm-tailwind-page .box.box-info,
html.dark .bm-tailwind-page header.rounded-lg,
html.dark .bm-tailwind-page header.bm-page-header,
html.dark .bm-tailwind-page section.rounded-lg,
html.dark .bm-tailwind-page .content-header,
html.dark .bm-tailwind-page .modal-content,
html.dark .bm-tailwind-page .dataTables_wrapper,
body.bm-theme-dark .bm-tailwind-page .box,
body.bm-theme-dark .bm-tailwind-page .card,
body.bm-theme-dark .bm-tailwind-page .box.box-primary,
body.bm-theme-dark .bm-tailwind-page .box.box-info,
body.bm-theme-dark .bm-tailwind-page header.rounded-lg,
body.bm-theme-dark .bm-tailwind-page header.bm-page-header,
body.bm-theme-dark .bm-tailwind-page section.rounded-lg,
body.bm-theme-dark .bm-tailwind-page .content-header,
body.bm-theme-dark .bm-tailwind-page .modal-content,
body.bm-theme-dark .bm-tailwind-page .dataTables_wrapper {
  border-color: var(--bm-ui-border, #1e293b);
  background: var(--bm-ui-surface, #0f172a);
  color: var(--bm-ui-text, #e2e8f0);
}

html[data-bm-theme='dark'] .bm-tailwind-page .box-header,
html[data-bm-theme='dark'] .bm-tailwind-page .box-header.with-border,
html[data-bm-theme='dark'] .bm-tailwind-page .card > .row:first-child,
html[data-bm-theme='dark'] .bm-tailwind-page .card > .d-flex:first-child,
html[data-bm-theme='dark'] .bm-tailwind-page header.rounded-lg:not(.bm-page-header) > div > div:first-child,
html.dark .bm-tailwind-page .box-header,
html.dark .bm-tailwind-page .box-header.with-border,
html.dark .bm-tailwind-page .card > .row:first-child,
html.dark .bm-tailwind-page .card > .d-flex:first-child,
html.dark .bm-tailwind-page header.rounded-lg:not(.bm-page-header) > div > div:first-child,
body.bm-theme-dark .bm-tailwind-page .box-header,
body.bm-theme-dark .bm-tailwind-page .box-header.with-border,
body.bm-theme-dark .bm-tailwind-page .card > .row:first-child,
body.bm-theme-dark .bm-tailwind-page .card > .d-flex:first-child,
body.bm-theme-dark .bm-tailwind-page header.rounded-lg:not(.bm-page-header) > div > div:first-child,
body.bm-theme-dark .bm-tailwind-page .box-body,
body.bm-theme-dark .bm-tailwind-page .card .table-responsive,
body.bm-theme-dark .bm-tailwind-page .card_ul,
body.bm-theme-dark .bm-tailwind-page .box-header .card_ul {
  border-color: #1e293b;
  background: #0f172a;
}

body.bm-theme-dark .bm-tailwind-page .box-title,
body.bm-theme-dark .bm-tailwind-page h1,
body.bm-theme-dark .bm-tailwind-page h2,
body.bm-theme-dark .bm-tailwind-page h3,
body.bm-theme-dark .bm-tailwind-page h4,
body.bm-theme-dark .bm-tailwind-page h5,
body.bm-theme-dark .bm-tailwind-page h6,
body.bm-theme-dark .bm-tailwind-page .kpi-content h4,
body.bm-theme-dark .bm-tailwind-page table.table,
body.bm-theme-dark .bm-tailwind-page table.dataTable,
body.bm-theme-dark .bm-tailwind-page table.table > tbody > tr > td,
body.bm-theme-dark .bm-tailwind-page table.dataTable > tbody > tr > td,
body.bm-theme-dark .bm-tailwind-page .list-group-item {
  color: #e2e8f0;
}

body.bm-theme-dark .bm-tailwind-page .form-group label,
body.bm-theme-dark .bm-tailwind-page .control-label,
body.bm-theme-dark .bm-tailwind-page .switch-btn-label,
body.bm-theme-dark .bm-tailwind-page .help-block,
body.bm-theme-dark .bm-tailwind-page .dataTables_info,
body.bm-theme-dark .bm-tailwind-page .dataTables_length label,
body.bm-theme-dark .bm-tailwind-page .dataTables_filter label {
  color: #cbd5e1;
}

body.bm-theme-dark .bm-tailwind-page .form-control,
body.bm-theme-dark .bm-tailwind-page .select2-container--default .select2-selection--single,
body.bm-theme-dark .bm-tailwind-page .select2-container--default .select2-selection--multiple,
body.bm-theme-dark .bm-tailwind-page input[type="text"],
body.bm-theme-dark .bm-tailwind-page input[type="password"],
body.bm-theme-dark .bm-tailwind-page input[type="email"],
body.bm-theme-dark .bm-tailwind-page textarea,
body.bm-theme-dark .bm-tailwind-page select {
  border-color: #334155;
  background-color: #020617;
  color: #f8fafc;
}

body.bm-theme-dark .bm-tailwind-page .table-responsive {
  border-color: #1e293b;
  background: #0f172a;
}

body.bm-theme-dark .bm-tailwind-page table.table > thead > tr > th,
body.bm-theme-dark .bm-tailwind-page table.dataTable > thead > tr > th {
  border-color: #1e293b !important;
  background: #111827;
  color: #cbd5e1;
}

body.bm-theme-dark .bm-tailwind-page table.table > tbody > tr > td,
body.bm-theme-dark .bm-tailwind-page table.dataTable > tbody > tr > td {
  border-color: #1e293b;
}

body.bm-theme-dark .bm-tailwind-page table.table-striped > tbody > tr:nth-of-type(odd),
body.bm-theme-dark .bm-tailwind-page table.dataTable.stripe > tbody > tr.odd,
body.bm-theme-dark .bm-tailwind-page table.dataTable.display > tbody > tr.odd {
  background-color: #111827;
}

body.bm-theme-dark .bm-tailwind-page table.table-hover > tbody > tr:hover,
body.bm-theme-dark .bm-tailwind-page table.dataTable.hover > tbody > tr:hover,
body.bm-theme-dark .bm-tailwind-page table.dataTable.display > tbody > tr:hover {
  background-color: #1e293b;
}

body.bm-theme-dark .bm-tailwind-page .dataTables_wrapper .dataTables_paginate .paginate_button {
  border-color: #334155 !important;
  background: #020617 !important;
  color: #cbd5e1 !important;
}

body.bm-theme-dark .bm-tailwind-page .dataTables_wrapper .dataTables_paginate .paginate_button.current,
body.bm-theme-dark .bm-tailwind-page .dataTables_wrapper .dataTables_paginate .paginate_button.current:hover {
  border-color: #f8fafc !important;
  background: #f8fafc !important;
  color: #020617 !important;
}

body.bm-theme-dark .bm-tailwind-page .label.bg-gray {
  background: #334155 !important;
  color: #e2e8f0 !important;
}

body.bm-theme-dark .bm-tailwind-page header.rounded-lg [class*="rounded-md"][class*="border"],
body.bm-theme-dark .bm-tailwind-page section.rounded-lg [class*="rounded-md"][class*="border"] {
  border-color: #1e293b;
  background: #020617;
  color: #e2e8f0;
}

html[data-bm-theme='dark'] .bm-tailwind-page header.rounded-lg [class*="text-slate-900"],
html[data-bm-theme='dark'] .bm-tailwind-page header.rounded-lg [class*="text-slate-100"],
html[data-bm-theme='dark'] .bm-tailwind-page section.rounded-lg [class*="text-slate-900"],
html[data-bm-theme='dark'] .bm-tailwind-page section.rounded-lg [class*="text-slate-100"],
html.dark .bm-tailwind-page header.rounded-lg [class*="text-slate-900"],
html.dark .bm-tailwind-page header.rounded-lg [class*="text-slate-100"],
html.dark .bm-tailwind-page section.rounded-lg [class*="text-slate-900"],
html.dark .bm-tailwind-page section.rounded-lg [class*="text-slate-100"],
body.bm-theme-dark .bm-tailwind-page header.rounded-lg [class*="text-slate-900"],
body.bm-theme-dark .bm-tailwind-page header.rounded-lg [class*="text-slate-100"],
body.bm-theme-dark .bm-tailwind-page section.rounded-lg [class*="text-slate-900"],
body.bm-theme-dark .bm-tailwind-page section.rounded-lg [class*="text-slate-100"] {
  color: var(--bm-ui-text, #e2e8f0) !important;
}

html[data-bm-theme='dark'] .bm-tailwind-page header.rounded-lg [class*="text-slate-500"],
html[data-bm-theme='dark'] .bm-tailwind-page header.rounded-lg [class*="text-slate-400"],
html[data-bm-theme='dark'] .bm-tailwind-page section.rounded-lg [class*="text-slate-500"],
html[data-bm-theme='dark'] .bm-tailwind-page section.rounded-lg [class*="text-slate-400"],
html.dark .bm-tailwind-page header.rounded-lg [class*="text-slate-500"],
html.dark .bm-tailwind-page header.rounded-lg [class*="text-slate-400"],
html.dark .bm-tailwind-page section.rounded-lg [class*="text-slate-500"],
html.dark .bm-tailwind-page section.rounded-lg [class*="text-slate-400"],
body.bm-theme-dark .bm-tailwind-page header.rounded-lg [class*="text-slate-500"],
body.bm-theme-dark .bm-tailwind-page header.rounded-lg [class*="text-slate-400"],
body.bm-theme-dark .bm-tailwind-page section.rounded-lg [class*="text-slate-500"],
body.bm-theme-dark .bm-tailwind-page section.rounded-lg [class*="text-slate-400"] {
  color: var(--bm-ui-muted, #94a3b8) !important;
}

body.bm-theme-dark .bm-create-panel,
body.bm-theme-dark .bm-create-aside,
body.bm-theme-dark .bm-summary-card {
  border-color: #1e293b;
  background: #0f172a;
  color: #e2e8f0;
}

body.bm-theme-dark .bm-create-tabs,
body.bm-theme-dark .bm-create-section,
body.bm-theme-dark .bm-summary-card dl > div {
  border-color: #1e293b;
}

body.bm-theme-dark .bm-create-tabs {
  background: #111827;
}

body.bm-theme-dark .bm-create-tabs span,
body.bm-theme-dark .bm-create-section-header p,
body.bm-theme-dark .bm-summary-card dt,
body.bm-theme-dark .bm-summary-note,
body.bm-theme-dark .bm-validation-list {
  color: #94a3b8;
}

body.bm-theme-dark .bm-create-tabs span.is-active,
body.bm-theme-dark .bm-create-section-header h3,
body.bm-theme-dark .bm-summary-title,
body.bm-theme-dark .bm-summary-card dd {
  color: #f8fafc;
}

body.bm-theme-dark .bm-create-tabs span.is-active {
  border-color: #f8fafc;
}

body.bm-theme-dark .bm-create-section-header > span,
body.bm-theme-dark .bm-create-section .switch-btn-group,
body.bm-theme-dark .bm-create-section .setting-switch-button-form-group,
body.bm-theme-dark .bm-create-section .checkbox label,
body.bm-theme-dark .bm-create-form > .row:last-of-type {
  border-color: #1e293b;
  background: #111827;
  color: #e2e8f0;
}

body.bm-theme-dark .bm-create-section .form-group label,
body.bm-theme-dark .bm-create-section .control-label,
body.bm-theme-dark .bm-create-section .switch-btn-label,
body.bm-theme-dark .bm-create-section .setting-switch-label-text {
  color: #e2e8f0;
}

body.bm-theme-dark .bm-create-section .help-block {
  color: #94a3b8;
}

@media (max-width: 1199px) {
  .bm-create-shell {
    grid-template-columns: 1fr;
  }

  .bm-create-aside {
    position: static;
  }
}

@media (max-width: 767px) {
  .bm-create-section {
    padding: 12px;
  }

  .bm-create-section .box-body,
  .bm-create-section .box-body > .row,
  .bm-create-section > .row {
    grid-template-columns: 1fr;
  }

  .bm-create-section .col-sm-6,
  .bm-create-section .col-md-6 {
    grid-column: 1 / -1;
  }

  .bm-create-section-header {
    display: block;
  }

  .bm-create-section-header > span {
    display: inline-flex;
    margin-top: 8px;
  }
}

.bm-tailwind-sticky-top {
  position: sticky;
  top: 0;
  z-index: 30;
}

.bm-tailwind-layout-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 16px;
}

.bm-sidebar-shell {
  contain: layout style;
}

.bm-sidebar-region {
  min-height: 100%;
}

.bm-sidebar-logo {
  display: block;
}

.bm-sidebar-menu {
  display: block;
}

.bm-sidebar-tree {
  width: 100%;
}

.bm-header-shell {
  contain: layout style;
}

.bm-header-navbar {
  min-height: 50px;
}

.bm-header-actions {
  display: block;
}

.bm-header-logo {
  display: block;
}

.bm-header-sidebar-toggle {
  min-width: 44px;
  text-align: center;
}

@media (max-width: 767px) {
  .bm-header-actions .header_dates {
    display: none;
  }
}

.bm-footer-shell {
  min-height: 44px;
}

.bm-footer-version {
  display: inline-block;
  line-height: 24px;
}

.bm-footer-font-tools {
  white-space: nowrap;
}

.bm-footer-font-tools .toggle-font-size {
  min-width: 28px;
}

@media (min-width: 1200px) {
  .bm-tailwind-layout-grid.has-summary {
    grid-template-columns: minmax(0, 1fr) 360px;
  }
}

@media (max-width: 767px) {
  .bm-tailwind-container {
    padding: 12px;
  }

  .bm-list-page .bm-tailwind-container,
  .bm-report-page .bm-tailwind-container,
  .bm-sale-create .bm-tailwind-container,
  .bm-purchase-create .bm-tailwind-container {
    padding: 0;
  }

  .bm-tailwind-page {
    min-height: calc(100vh - 72px);
  }
}

/* Account book summary — theme-driven colors (follow app theme, not OS) */
.bm-account-book-summary__label {
  color: #64748b;
}

.bm-account-book-summary__value {
  color: #0f172a;
}

html[data-bm-theme='dark'] .bm-account-book-summary__label,
body.bm-theme-dark .bm-account-book-summary__label {
  color: #94a3b8;
}

html[data-bm-theme='dark'] .bm-account-book-summary__value,
body.bm-theme-dark .bm-account-book-summary__value {
  color: #f1f5f9;
}

/* AJAX CRUD modals (brand / category / etc.) — field chrome on AdminLTE + Tailwind */
.modal .modal-body.bm-modal-form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.modal .bm-modal-form__label {
  display: block;
  margin: 0 0 6px;
  font-size: 13px;
  font-weight: 600;
  color: var(--bm-ui-muted, #475569);
}
.modal .bm-modal-form__label.inline-flex {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 0;
}
.modal .bm-modal-form__input,
.modal .bm-modal-form input.bm-modal-form__input,
.modal .bm-modal-form select.bm-modal-form__input,
.modal .bm-modal-form textarea.bm-modal-form__input {
  display: block;
  width: 100%;
  max-width: 100%;
  height: 38px;
  min-height: 38px;
  padding: 8px 10px;
  border: 1px solid var(--bm-ui-border, #cbd5e1);
  border-radius: 8px;
  background: var(--bm-ui-surface, #ffffff);
  color: var(--bm-ui-text, #0f172a);
  font-size: 14px;
  box-sizing: border-box;
}
.modal .bm-modal-form textarea.bm-modal-form__input {
  height: auto;
  min-height: 76px;
}
.modal .bm-modal-form__input:focus {
  border-color: var(--bm-ui-accent, #591cd3);
  outline: none;
}
.modal .bm-modal-form .select2-container {
  width: 100% !important;
}
.modal .bm-modal-form .select2-container .select2-selection--single {
  height: 38px;
  min-height: 38px;
  border: 1px solid var(--bm-ui-border, #cbd5e1);
  border-radius: 8px;
}
.modal .bm-modal-form .select2-container .select2-selection--single .select2-selection__rendered {
  line-height: 36px;
  padding-left: 10px;
}
.modal .bm-modal-form .select2-container .select2-selection--single .select2-selection__arrow {
  height: 36px;
}
