/* Light palette is isolated: the existing dark appearance stays in glass-theme.css. */
[data-bs-theme="light"] {
  color-scheme: light;
  --pos-panel-bg: #ffffff;
  --tblr-body-bg: #f4f5f7;
  --tblr-body-color: #171b21;
  --tblr-bg-surface: #ffffff;
  --tblr-card-bg: #ffffff;
  --tblr-border-color: #c4cbd4;
  --tblr-secondary: #505b69;
}
[data-bs-theme="light"] body { background: #f4f5f7; color: #171b21; }
[data-bs-theme="light"] :is(.page-wrapper,.page-body,.content-wrapper,.productos-page,.card-body,.dataTables_wrapper) { color: #171b21 !important; }
[data-bs-theme="light"] :is(.card,.modal-content,.dropdown-menu,.navbar.sticky-top,.navbar-collapse,.swal2-popup,.list-group-item) {
  background: #fff !important; color: #171b21 !important; border-color: #c4cbd4 !important;
}
[data-bs-theme="light"] :is(.card-header,.card-footer,.modal-header,.modal-footer) { background: #f8f9fb !important; border-color: #c4cbd4 !important; }
[data-bs-theme="light"] :is(.text-white,.text-light,.card-title,.modal-title,.form-label,.swal2-title,.nav-link,.nav-link-icon,.dropdown-item,.page-title) { color: #171b21 !important; }
[data-bs-theme="light"] :is(.text-white-50,.text-muted,.text-secondary,.form-hint,.swal2-content,.swal2-html-container,.breadcrumb-item,.dataTables_info) { color: #505b69 !important; }
[data-bs-theme="light"] :is(.nav-link-icon,.input-group-text) :is(i,svg) { color: #171b21 !important; }
[data-bs-theme="light"] .navbar-toggler { color: #171b21; border-color: #8b95a3; }
[data-bs-theme="light"] .navbar-toggler-icon { filter: brightness(0); }
[data-bs-theme="light"] .navbar-brand-image { filter: none !important; }
[data-bs-theme="light"] .btn-close { filter: none; opacity: .75; }
[data-bs-theme="light"] :is(.dropdown-item:hover,.dropdown-item:focus,.nav-link:hover) { background: #e9edf2 !important; color: #101418 !important; }
[data-bs-theme="light"] :is(.form-control,.form-select,textarea,select,.input-group-text,.dataTables_filter input,.dataTables_length select) {
  background: #fff !important; color: #171b21 !important; border-color: #8995a5 !important;
}
[data-bs-theme="light"] :is(.form-control,.form-select,textarea):focus { background: #fff !important; color: #171b21 !important; border-color: #1759a6 !important; box-shadow: 0 0 0 .2rem #1759a633; }
[data-bs-theme="light"] :is(input,textarea)::placeholder { color: #596575 !important; opacity: 1; }
[data-bs-theme="light"] :is(.form-control,.form-select):disabled { background: #e9edf2 !important; color: #505b69 !important; }
[data-bs-theme="light"] .form-control[readonly] { background: #f1f3f6 !important; }
[data-bs-theme="light"] select option { background: #fff; color: #171b21; }
[data-bs-theme="light"] .form-check-input { border-color: #687585; }
[data-bs-theme="light"] .table {
  --tblr-table-bg: #fff; --tblr-table-striped-bg: #f0f3f7; --tblr-table-hover-bg: #e7edf5;
  --tblr-table-border-color: #c4cbd4; color: #171b21 !important; background: #fff !important;
}
[data-bs-theme="light"] .table :is(td,th) { color: #171b21 !important; border-color: #c4cbd4 !important; }
[data-bs-theme="light"] .table thead th { background: #e8edf3 !important; color: #171b21 !important; }
[data-bs-theme="light"] .table-striped tbody tr:nth-of-type(odd) > td { background: #f0f3f7 !important; }
[data-bs-theme="light"] .table tbody tr:hover > td { background: #e7edf5 !important; }
[data-bs-theme="light"] :is(.page-link,.dataTables_wrapper .paginate_button) { background: #fff !important; color: #174f91 !important; border-color: #a3adba !important; }
[data-bs-theme="light"] .page-item.active .page-link { background: #1759a6 !important; color: #fff !important; }
[data-bs-theme="light"] .btn-outline-secondary { color: #263343; border-color: #687585; }
[data-bs-theme="light"] .btn-outline-secondary:hover { background: #e1e7ef; color: #171b21; }
[data-bs-theme="light"] .btn-outline-success { color: #176537; border-color: #176537; }
[data-bs-theme="light"] .btn-outline-success:hover { background: #176537; color: #fff; }
[data-bs-theme="light"] .btn-outline-warning { color: #7c4600; border-color: #975900; }
[data-bs-theme="light"] .text-success { color: #176537 !important; }
[data-bs-theme="light"] .text-danger { color: #a2212b !important; }
[data-bs-theme="light"] .text-warning { color: #7c4600 !important; }
/* White remains appropriate on saturated action buttons; icons inherit it. */
[data-bs-theme="light"] :is(.btn-primary,.bg-primary.badge,.bg-blue.badge) { background: #1759a6 !important; color: #fff !important; }
[data-bs-theme="light"] :is(.btn-success,.bg-success.badge,.btn-check:checked + .btn-outline-success) { background: #176537 !important; color: #fff !important; }
[data-bs-theme="light"] :is(.btn-danger,.bg-danger.badge,.btn-check:checked + .btn-outline-danger) { background: #a2212b !important; color: #fff !important; }
[data-bs-theme="light"] :is(.btn-warning,.bg-warning.badge,.btn-check:checked + .btn-outline-warning) { background: #f5cc70 !important; color: #302000 !important; }
[data-bs-theme="light"] .bg-secondary.badge { background: #505b69 !important; color: #fff !important; }
[data-bs-theme="light"] .bg-info.badge { background: #d6edf7 !important; color: #173c50 !important; }
[data-bs-theme="light"] .dashboard-indicator-icon { color: #4b596b; }
[data-bs-theme="light"] .dashboard-indicator-card { background: #fff !important; color: #171b21 !important; }
[data-bs-theme="light"] .modal { z-index: 2000 !important; }
[data-bs-theme="light"] .modal-backdrop { z-index: 1090 !important; }
[data-bs-theme="light"] #modalEditarVenta :is(.venta-detalle-dark,.venta-detalle-contenido,.venta-detalle-tabla) { background: #fff !important; color: #171b21 !important; border-color: #c4cbd4 !important; }
[data-bs-theme="light"] #modalEditarVenta :is(h6,strong,.venta-detalle-tabla > :not(caption) > * > *) { background: transparent !important; color: #171b21 !important; border-color: #c4cbd4 !important; }
[data-bs-theme="light"] #modalEditarVenta .text-muted { color: #505b69 !important; }
[data-bs-theme="light"] #modalEditarVenta .venta-detalle-dark .badge { background: #e8edf3 !important; color: #171b21 !important; border-color: #c4cbd4 !important; }
[data-bs-theme="light"] :is(.apexcharts-text,.chart text) { fill: #171b21 !important; }
[data-bs-theme="light"] :is(.apexcharts-legend-text,.apexcharts-tooltip,.apexcharts-tooltip-title,.apexcharts-menu) { background: #fff !important; color: #171b21 !important; }
.pos-theme-toggle { min-width: 44px; min-height: 44px; flex-shrink: 0; }
.pos-theme-toggle:focus-visible { outline: 3px solid #478bdd; outline-offset: 2px; }
