/* DJOHNPAO: dark mode contrast repair. Light mode remains untouched.
   Rule: dark surfaces = light text; light controls = dark text.
   No global span/td/button text override. */
.djp-theme-toggle{display:inline-flex;align-items:center;justify-content:center;gap:7px;min-height:36px;padding:7px 13px;border:1px solid var(--card-border,#e8ded5);border-radius:999px;background:var(--card-bg,#fff);color:var(--text-main,#2b1810);font:600 12px/1.2 inherit;cursor:pointer;white-space:nowrap}
.djp-theme-toggle:focus-visible{outline:2px solid #aaa;outline-offset:3px}
.djp-theme-icon{font-size:17px;line-height:1}
@media(max-width:600px){.djp-theme-toggle{min-width:38px;padding:7px 9px}.djp-theme-label{display:none}}
html[data-djp-theme="dark"]{
 color-scheme:dark;
 --sidebar-bg:#101010;--sidebar-active:#333;--sidebar-active-hover:#444;
 --sidebar-text-muted:#c8c8c8;--sidebar-border:#383838;
 --canvas-bg:#141414;--canvas-subtle:#1a1a1a;
 --card-bg:#222;--card-border:#444;--card-shadow:0 3px 18px #0005;
 --card-shadow-hover:0 6px 24px #0007;
 --text-main:#f4f4f4;--text-muted:#c8c8c8;--text-light:#bdbdbd;
 --accent-primary:#e8e8e8;--accent-hover:#fff;--accent-gold:#e2e2e2;--accent-cream:#292929;
 --status-green-bg:#27352d;--status-green-text:#d9f2e1;
 --status-amber-bg:#383123;--status-amber-text:#f7e6c5;
 --status-red-bg:#3b2929;--status-red-text:#fbd8d8;
 --status-blue-bg:#28323d;--status-blue-text:#dbeafa;
}
html[data-djp-theme="dark"] :is(body,.app-container,.main-content,.view-panel,.page-content,.content-area){background-color:#141414!important;color:#f4f4f4!important}
html[data-djp-theme="dark"] .sidebar{background:#101010!important;color:#f4f4f4!important}
html[data-djp-theme="dark"] :is(.top-header,.panel-card,.table-card,.chart-card,.pos-catalog-section,.pos-cart-panel,.pos-category-chips,.package-card,.cart-item-row,.pos-cart-summary,.pos-cart-total,.pos-payment-section,.stat-card,.card,.modal-content,.modal-card,.settings-card,.form-card,.stock-form-card,.inventory-card,.table-responsive-wrapper,.order-toolbar,.orders-tracking-panel,.orders-tracking-table,.pov-kpi-card,.import-summary-card,.reorder-cat-item,.ui-select-option){background-color:#222!important;color:#f4f4f4!important;border-color:#444!important}
html[data-djp-theme="dark"] .main-content :is(div,section,article,aside,header,footer,form)[style*="background:"]:not(.sidebar):not(.package-img-holder),
html[data-djp-theme="dark"] .main-content :is(div,section,article,aside,header,footer,form)[style*="background-color:"]:not(.sidebar):not(.package-img-holder){background-color:#242424!important;background-image:none!important;color:#f4f4f4!important;border-color:#444!important}
html[data-djp-theme="dark"] :is(.package-img-holder,.package-img-holder:not(.has-img)){background:#303030!important;border-color:#484848!important}
html[data-djp-theme="dark"] :is(.package-card:hover,.cart-item-row:hover,.reorder-cat-item:hover){background:#303030!important}
html[data-djp-theme="dark"] .main-content :is(h1,h2,h3,h4,h5,h6,.panel-title,.section-title,.card-title,.package-card-title,.cart-item-name){color:#f4f4f4!important}
html[data-djp-theme="dark"] .main-content :is(.text-muted,.muted,.form-hint,.helper-text,.subtitle,.description,.package-card-meta-row){color:#c8c8c8!important}
html[data-djp-theme="dark"] :is(input,select,textarea,.ui-select-trigger,.pos-search-box){background:#292929!important;color:#f5f5f5!important;border-color:#555!important}
html[data-djp-theme="dark"] :is(input,textarea)::placeholder{color:#bdbdbd!important}
html[data-djp-theme="dark"] :is(table,thead,tbody,tfoot,tr,td,th,.custom-table,.table-responsive-wrapper){border-color:#444!important}
html[data-djp-theme="dark"] :is(thead,thead tr,th,.custom-table th){background:#303030!important;color:#f5f5f5!important}
html[data-djp-theme="dark"] :is(tbody tr,tbody td,.custom-table tbody tr,.custom-table tbody td){background:#222!important;color:#f4f4f4!important}
html[data-djp-theme="dark"] :is(tbody tr:hover,tbody tr:hover td,.custom-table tbody tr:hover td){background:#303030!important}
html[data-djp-theme="dark"] .main-content :is(button,.btn,.btn-primary,.btn-secondary,.btn-export,.btn-subaction,.btn-add-cart,.pos-cat-chip,.filter-chip,.orders-tracking-tab,.btn-status-toggle){background:#333!important;color:#f5f5f5!important;border-color:#666!important;box-shadow:none}
html[data-djp-theme="dark"] .main-content :is(button,.btn,.pos-cat-chip,.filter-chip,.orders-tracking-tab):hover{background:#474747!important;color:#fff!important}
html[data-djp-theme="dark"] .main-content :is(.pos-cat-chip.active,.filter-chip.active,.orders-tracking-tab.active,.btn-pos-checkout){background:#efefef!important;color:#151515!important;border-color:#efefef!important}
html[data-djp-theme="dark"] .main-content :is(.pos-cat-chip.active,.filter-chip.active,.orders-tracking-tab.active,.btn-pos-checkout) :is(span,strong,small,i){color:inherit!important}
html[data-djp-theme="dark"] .main-content :is(button,.btn,.pos-cat-chip,.filter-chip,.orders-tracking-tab) :is(span,strong,small,i){color:inherit!important}
html[data-djp-theme="dark"] .main-content :is(.btn-pos-checkout,.btn-pos-checkout:hover){background:#efefef!important;color:#151515!important}
html[data-djp-theme="dark"] .main-content :is(.pill-badge,.badge-min-stock,.stat-badge,.package-card-cat-badge){background:#353535!important;color:#f4f4f4!important;border-color:#666!important}
html[data-djp-theme="dark"] .main-content :is(.pill-badge,.badge-min-stock,.stat-badge,.package-card-cat-badge) :is(span,strong,small){color:inherit!important}
html[data-djp-theme="dark"] :is(img,video,canvas){filter:none!important}
html[data-djp-theme="dark"] .djp-theme-toggle{background:#303030!important;color:#fff!important;border-color:#606060!important}
html[data-djp-theme="dark"] :is(a,button,input,select,textarea):focus-visible{outline:2px solid #e2e2e2;outline-offset:2px}
@media(max-width:767px){html[data-djp-theme="dark"] :is(.pos-cart-panel,.package-card,.panel-card){border-color:#444!important}}
@media print{html[data-djp-theme="dark"]{color-scheme:light}html[data-djp-theme="dark"] body,html[data-djp-theme="dark"] .main-content{background:#fff!important;color:#111!important}}


/* DJOHNPAO DARK MODE - CONSISTENT CONTRAST LAYER (18 Nov 2026)
   Strictly dark-only; no changes to application state, business logic or Light Mode.
   Neutral borders, readable content, restrained controls. */
html[data-djp-theme="dark"] {
  --djp-d-bg:#151515;--djp-d-panel:#232323;--djp-d-raised:#292929;
  --djp-d-hover:#323232;--djp-d-line:#3b3b3b;
  --djp-d-text:#f1f1f1;--djp-d-muted:#c5c5c5;
  --djp-d-secondary:#b6b6b6;
  scrollbar-color:#5a5a5a #191919;
}
html[data-djp-theme="dark"] :is(.main-content,.view-panel,.page-content,.content-area){color:var(--djp-d-text)!important}
html[data-djp-theme="dark"] .main-content :is(p,label,dt,dd,li,small,caption,summary){color:var(--djp-d-muted)}
html[data-djp-theme="dark"] .main-content :is(.top-header,.panel-card,.table-card,.chart-card,.pos-catalog-section,.pos-cart-panel,.pos-category-chips,.package-card,.cart-item-row,.pos-cart-summary,.pos-cart-total,.pos-payment-section,.stat-card,.card,.modal-content,.modal-card,.modal-card-luxury,.modal-card-zoom,.settings-card,.form-card,.stock-form-card,.inventory-card,.table-responsive-wrapper,.order-toolbar,.orders-tracking-panel,.orders-tracking-table,.pov-kpi-card,.import-summary-card,.reorder-cat-item){border-color:var(--djp-d-line)!important;box-shadow:none!important}
/* Inline-colored text inside the application's dark surfaces was the primary legibility defect.
   Explicit status colors are restored below, rather than forcing text colors on every element. */
html[data-djp-theme="dark"] .main-content :is(td,th,p,small,label,span,div,a)[style*="color:#0f172a"],
html[data-djp-theme="dark"] .main-content :is(td,th,p,small,label,span,div,a)[style*="color: #0f172a"],
html[data-djp-theme="dark"] .main-content :is(td,th,p,small,label,span,div,a)[style*="color:#111827"],
html[data-djp-theme="dark"] .main-content :is(td,th,p,small,label,span,div,a)[style*="color: #111827"],
html[data-djp-theme="dark"] .main-content :is(td,th,p,small,label,span,div,a)[style*="color:#1e293b"],
html[data-djp-theme="dark"] .main-content :is(td,th,p,small,label,span,div,a)[style*="color: #1e293b"],
html[data-djp-theme="dark"] .main-content :is(td,th,p,small,label,span,div,a)[style*="color:#1f2937"],
html[data-djp-theme="dark"] .main-content :is(td,th,p,small,label,span,div,a)[style*="color: #1f2937"],
html[data-djp-theme="dark"] .main-content :is(td,th,p,small,label,span,div,a)[style*="color:#243b53"],
html[data-djp-theme="dark"] .main-content :is(td,th,p,small,label,span,div,a)[style*="color: #243b53"],
html[data-djp-theme="dark"] .main-content :is(td,th,p,small,label,span,div,a)[style*="color:#2b1810"],
html[data-djp-theme="dark"] .main-content :is(td,th,p,small,label,span,div,a)[style*="color: #2b1810"],
html[data-djp-theme="dark"] .main-content :is(td,th,p,small,label,span,div,a)[style*="color:#334155"],
html[data-djp-theme="dark"] .main-content :is(td,th,p,small,label,span,div,a)[style*="color: #334155"],
html[data-djp-theme="dark"] .main-content :is(td,th,p,small,label,span,div,a)[style*="color:#374151"],
html[data-djp-theme="dark"] .main-content :is(td,th,p,small,label,span,div,a)[style*="color: #374151"],
html[data-djp-theme="dark"] .main-content :is(td,th,p,small,label,span,div,a)[style*="color:#475569"],
html[data-djp-theme="dark"] .main-content :is(td,th,p,small,label,span,div,a)[style*="color: #475569"],
html[data-djp-theme="dark"] .main-content :is(td,th,p,small,label,span,div,a)[style*="color:#64748b"],
html[data-djp-theme="dark"] .main-content :is(td,th,p,small,label,span,div,a)[style*="color: #64748b"],
html[data-djp-theme="dark"] .main-content :is(td,th,p,small,label,span,div,a)[style*="color:#78655e"],
html[data-djp-theme="dark"] .main-content :is(td,th,p,small,label,span,div,a)[style*="color: #78655e"],
html[data-djp-theme="dark"] .main-content :is(td,th,p,small,label,span,div,a)[style*="color:#6b7280"],
html[data-djp-theme="dark"] .main-content :is(td,th,p,small,label,span,div,a)[style*="color: #6b7280"]{color:var(--djp-d-muted)!important}
/* Keep labels and values readable even when the original light CSS hard-codes dark ink. */
html[data-djp-theme="dark"] .main-content :is(.activity-toolbar,.orders-tracking-note,.orders-tracking-tools,.orders-tracking-table-wrap,.pos-cart-header,.pos-cart-title,.pos-cart-summary,.pos-cart-total,.pos-payment-section,.stat-card,.table-card,.panel-card,.settings-card,.form-card) :is(p,small,label,span,div,strong){border-color:var(--djp-d-line)}
html[data-djp-theme="dark"] .main-content :is(.text-muted,.muted,.form-hint,.helper-text,.subtitle,.description,.package-card-meta-row,.orders-tracking-note){color:var(--djp-d-muted)!important}
html[data-djp-theme="dark"] .main-content :is(.activity-toolbar,.orders-tracking-tools,.orders-tracking-table-wrap) :is(a,small,time){color:var(--djp-d-muted)}
/* Dark inputs and table headers; avoid bright borders around chips and controls. */
html[data-djp-theme="dark"] :is(input:not([type="checkbox"]):not([type="radio"]),select,textarea,.ui-select-trigger,.pos-search-box){background:#2b2b2b!important;color:#f1f1f1!important;border:1px solid #484848!important;box-shadow:none!important}
html[data-djp-theme="dark"] :is(input,textarea)::placeholder{color:#b9b9b9!important;opacity:1}
html[data-djp-theme="dark"] .main-content :is(button,.btn,.btn-primary,.btn-secondary,.btn-export,.btn-subaction,.btn-add-cart,.pos-cat-chip,.filter-chip,.orders-tracking-tab,.btn-status-toggle){background:#303030!important;color:#f2f2f2!important;border:1px solid #494949!important;box-shadow:none!important;text-shadow:none!important}
html[data-djp-theme="dark"] .main-content :is(button,.btn,.pos-cat-chip,.filter-chip,.orders-tracking-tab):hover{background:#3c3c3c!important;border-color:#606060!important}
html[data-djp-theme="dark"] .main-content :is(.pos-cat-chip.active,.filter-chip.active,.orders-tracking-tab.active,.btn-pos-checkout){background:#e5e5e5!important;color:#151515!important;border-color:#e5e5e5!important}
html[data-djp-theme="dark"] .main-content :is(.pos-cat-chip.active,.filter-chip.active,.orders-tracking-tab.active,.btn-pos-checkout) :is(span,strong,small,i){color:#151515!important}
html[data-djp-theme="dark"] .main-content :is(button,.btn,.pos-cat-chip,.filter-chip,.orders-tracking-tab) :is(span,strong,small,i){text-shadow:none!important}
html[data-djp-theme="dark"] .main-content :is(thead,thead tr,th,.custom-table th){background:#303030!important;color:#ededed!important}
html[data-djp-theme="dark"] .main-content :is(tbody tr,tbody td,.custom-table tbody tr,.custom-table tbody td){background:#232323!important;color:#ededed!important}
html[data-djp-theme="dark"] .main-content :is(tbody tr:nth-child(even),tbody tr:nth-child(even) td){background:#272727!important}
html[data-djp-theme="dark"] .main-content :is(tbody tr:hover,tbody tr:hover td){background:#323232!important}
html[data-djp-theme="dark"] .main-content :is(table,th,td,tr){border-color:#393939!important}
html[data-djp-theme="dark"] .main-content :is(.pill-badge,.badge-min-stock,.stat-badge,.package-card-cat-badge){border-color:#494949!important}
/* Specific semantic indicators remain recognizable, not monochrome-on-monochrome. */
html[data-djp-theme="dark"] .main-content :is(.stat-badge.green,.status-success,.badge-success){background:#23392e!important;color:#c5f0d3!important;border-color:#365b45!important}
html[data-djp-theme="dark"] .main-content :is(.stat-badge.amber,.status-warning,.badge-warning){background:#403321!important;color:#ffe1aa!important;border-color:#655034!important}
html[data-djp-theme="dark"] .main-content :is(.stat-badge.red,.status-danger,.badge-danger){background:#442828!important;color:#ffcccc!important;border-color:#684040!important}
html[data-djp-theme="dark"] .main-content :is(.stat-badge.green,.stat-badge.amber,.stat-badge.red,.status-success,.status-warning,.status-danger) :is(span,strong,small){color:inherit!important}
/* Preserve browser-native checkbox/radio and focus visibility. */
html[data-djp-theme="dark"] :is(input[type="checkbox"],input[type="radio"]){accent-color:#d9d9d9}
html[data-djp-theme="dark"] :is(a,button,input,select,textarea):focus-visible{outline:2px solid #d0d0d0!important;outline-offset:2px}
/* Narrow devices retain existing responsive layout; scrolling stays inside data tables. */
@media(max-width:767px){
 html[data-djp-theme="dark"] .main-content :is(.table-responsive-wrapper,.orders-tracking-table-wrap){max-width:100%;overflow-x:auto;-webkit-overflow-scrolling:touch}
 html[data-djp-theme="dark"] .main-content :is(.pos-cart-panel,.package-card,.panel-card){border-color:#3b3b3b!important}
}


/* DJOHNPAO DARK MODE V2 — targeted fixes for POS, order activity and PO view.
   Only enabled by the dark theme attribute. Light mode and operational JS unchanged. */
html[data-djp-theme="dark"] {
  --djp-control-border:#424242;
  --djp-control-bg:#303030;
  --djp-control-ink:#ededed;
}
/* POS: title, summary, order-type buttons and checkout controls. */
html[data-djp-theme="dark"] .pos-cart-top-sticky {
  background: #1c1c1c !important;
  border-bottom-color: #383838 !important;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.45) !important;
}
html[data-djp-theme="dark"] .pos-cart-panel :is(.pos-cart-title,.pos-cart-title span,.pos-cart-title svg,.pos-cart-header,.pos-cart-header span){color:#f1f1f1!important;stroke:currentColor}
html[data-djp-theme="dark"] .pos-cart-panel :is(.pos-cart-badge,.cart-order-type-tabs,.cart-type-btn,.pos-cart-summary,.pos-cart-total,.pos-payment-section){border-color:#3d3d3d!important;box-shadow:none!important}
html[data-djp-theme="dark"] .pos-cart-panel .cart-order-type-tabs{background:#252525!important;padding:3px!important;border:1px solid #393939!important;border-radius:11px!important}
html[data-djp-theme="dark"] .pos-cart-panel .cart-type-btn{background:#303030!important;color:#e5e5e5!important;border:0!important;box-shadow:none!important;outline:0!important}
html[data-djp-theme="dark"] .pos-cart-panel .cart-type-btn.active{background:#474747!important;color:#fff!important;border:0!important}
html[data-djp-theme="dark"] .pos-cart-panel .cart-type-btn :is(span,strong,small){color:inherit!important}
html[data-djp-theme="dark"] .pos-cart-panel :is(.pos-cart-summary,.pos-cart-total,.pos-payment-section){background:#252525!important;color:#ededed!important}
html[data-djp-theme="dark"] .pos-cart-panel :is(.pos-cart-summary,.pos-cart-total,.pos-payment-section) :is(label,p,small,span,strong,div){color:#e3e3e3}
html[data-djp-theme="dark"] .pos-cart-panel :is(.pos-cart-total,.pos-cart-total *){color:#f2f2f2!important}
html[data-djp-theme="dark"] .pos-cart-panel .btn-pos-checkout{background:#dedede!important;color:#161616!important;border:1px solid #dedede!important}
html[data-djp-theme="dark"] .pos-cart-panel .btn-pos-checkout :is(span,strong,small,i,svg){color:#161616!important;stroke:currentColor}
/* Make POS catalogue controls understated instead of thick white framed. */
html[data-djp-theme="dark"] .main-content :is(.pos-cat-chip,.filter-chip,.btn-add-cart,.btn-export,.btn-subaction){border:1px solid #424242!important;box-shadow:none!important;outline:0}
html[data-djp-theme="dark"] .main-content :is(.pos-cat-chip.active,.filter-chip.active){border-color:#a3a3a3!important}
html[data-djp-theme="dark"] .main-content :is(.pos-catalog-section,.pos-category-chips){border-color:#383838!important;box-shadow:none!important}
/* PO View: remove the white navigation band and heavy white button outlines. */
html[data-djp-theme="dark"] .main-content .pov-subtabs-nav{background:#222!important;background-image:none!important;border:1px solid #393939!important;border-radius:12px!important;box-shadow:none!important;padding:5px!important;display:flex;flex-wrap:wrap;gap:6px}
html[data-djp-theme="dark"] .main-content .pov-subtabs-nav .pov-subtab-btn{background:#303030!important;color:#e9e9e9!important;border:1px solid #424242!important;box-shadow:none!important;outline:0!important;border-radius:9px!important}
html[data-djp-theme="dark"] .main-content .pov-subtabs-nav .pov-subtab-btn.active{background:#494949!important;color:#fff!important;border-color:#666!important}
html[data-djp-theme="dark"] .main-content .pov-subtabs-nav .pov-subtab-btn:hover{background:#3b3b3b!important}
html[data-djp-theme="dark"] .main-content #lblPOViewActiveFilterTag{color:#bdbdbd!important}
/* Order activity: generated detail rows contain hard-coded navy ink; keep
   meaningful red/green status values while lifting ordinary labels to grey. */
html[data-djp-theme="dark"] #subpanel-order-activity-log .custom-table tbody td{color:#e2e2e2!important}
html[data-djp-theme="dark"] #subpanel-order-activity-log .custom-table tbody td :is(div,span,small,p,strong,a){color:#d4d4d4}
html[data-djp-theme="dark"] #subpanel-order-activity-log .custom-table tbody td :is(div,span,small,p,strong,a)[style*="color:"]{color:#d4d4d4!important}
html[data-djp-theme="dark"] #subpanel-order-activity-log .custom-table tbody td :is(div,span,small,p,strong,a)[style*="color: #"]{color:#d4d4d4!important}
html[data-djp-theme="dark"] #subpanel-order-activity-log .custom-table tbody td :is(div,span,small,p,strong,a)[style*="color:#dc2626"],
html[data-djp-theme="dark"] #subpanel-order-activity-log .custom-table tbody td :is(div,span,small,p,strong,a)[style*="color: #dc2626"],
html[data-djp-theme="dark"] #subpanel-order-activity-log .custom-table tbody td :is(div,span,small,p,strong,a)[style*="color:red"]{color:#ff7777!important}
html[data-djp-theme="dark"] #subpanel-order-activity-log .custom-table tbody td :is(div,span,small,p,strong,a)[style*="color:#059669"],
html[data-djp-theme="dark"] #subpanel-order-activity-log .custom-table tbody td :is(div,span,small,p,strong,a)[style*="color: #059669"]{color:#69d9a5!important}
html[data-djp-theme="dark"] #subpanel-order-activity-log :is(#lblCustomOrderActInfo,#boxManualDateOrderActivityLog){color:#d0d0d0!important}
html[data-djp-theme="dark"] #boxManualDateOrderActivityLog{background:#292929!important;border-color:#424242!important}
html[data-djp-theme="dark"] #boxManualDateOrderActivityLog label{color:#e2e2e2!important}
/* Restore clear text on existing pale status tags and white/light empty states. */
html[data-djp-theme="dark"] .pos-cart-panel :is(.pos-cart-empty,.cart-empty-state,.empty-cart-state){background:#292929!important;color:#d7d7d7!important;border-color:#444!important}
html[data-djp-theme="dark"] .pos-cart-panel :is(.pos-cart-empty,.cart-empty-state,.empty-cart-state) :is(p,span,small,strong){color:#d7d7d7!important}
@media(max-width:767px){
 html[data-djp-theme="dark"] .main-content .pov-subtabs-nav{padding:4px!important;gap:4px}
 html[data-djp-theme="dark"] .main-content .pov-subtabs-nav .pov-subtab-btn{flex:1 1 auto;min-width:0;white-space:normal}
 html[data-djp-theme="dark"] #subpanel-order-activity-log .table-responsive{max-width:100%;overflow-x:auto;-webkit-overflow-scrolling:touch}
}

/* DJOHNPAO Dark Mode V3 — Menu/POS only, plus header account pill.
   Scoped to dark mode. Light theme and all operational behavior are untouched. */
html[data-djp-theme="dark"] .header-actions .user-switch-pill {
  background:#303030!important;color:#f1f1f1!important;
  border:1px solid #454545!important;box-shadow:none!important;
}
html[data-djp-theme="dark"] .header-actions .user-switch-pill #lblActiveUser,
html[data-djp-theme="dark"] .header-actions .user-switch-pill svg {
  color:#f1f1f1!important;stroke:currentColor!important;
}
html[data-djp-theme="dark"] .header-actions .user-switch-pill .user-avatar-mini {
  background:#4a4a4a!important;color:#fff!important;
}
/* Remove the white frame around catalogue search/category controls. */
html[data-djp-theme="dark"] #subpanel-menu .pos-catalog-toolbar {
  background:#222!important;background-image:none!important;
  border:1px solid #3b3b3b!important;box-shadow:none!important;
  color:#eee!important;
}
html[data-djp-theme="dark"] #subpanel-menu .pos-catalog-toolbar .pos-search-box,
html[data-djp-theme="dark"] #subpanel-menu .pos-catalog-toolbar .pos-category-chips {
  background:#262626!important;background-image:none!important;
  border:0!important;outline:0!important;box-shadow:none!important;
}
html[data-djp-theme="dark"] #subpanel-menu .pos-catalog-toolbar #searchPOSMenuInput {
  background:#2d2d2d!important;color:#f1f1f1!important;
  border:1px solid #444!important;outline:0!important;box-shadow:none!important;
}
html[data-djp-theme="dark"] #subpanel-menu .pos-catalog-toolbar #searchPOSMenuInput:focus-visible {
  outline:2px solid #929292!important;outline-offset:1px!important;
}
html[data-djp-theme="dark"] #subpanel-menu .pos-catalog-toolbar .pos-cat-chip {
  background:#353535!important;color:#ededed!important;
  border:1px solid #484848!important;box-shadow:none!important;
}
html[data-djp-theme="dark"] #subpanel-menu .pos-catalog-toolbar .pos-cat-chip.active {
  background:#d9d9d9!important;color:#171717!important;
  border-color:#d9d9d9!important;
}
html[data-djp-theme="dark"] #subpanel-menu .pos-catalog-toolbar .pos-cat-chip :is(span,strong) {
  color:inherit!important;
}
/* Cart rows are generated in JS with inline brown text; override only these labels. */
html[data-djp-theme="dark"] #subpanel-menu .pos-cart-panel .cart-item-row {
  background:#292929!important;border:1px solid #414141!important;
  box-shadow:none!important;
}
html[data-djp-theme="dark"] #subpanel-menu .pos-cart-panel .cart-item-row:hover {
  background:#303030!important;
}
html[data-djp-theme="dark"] #subpanel-menu .pos-cart-panel .cart-item-row > div:first-child > div[style*="color:"] {
  color:#f1f1f1!important;
}
html[data-djp-theme="dark"] #subpanel-menu .pos-cart-panel .cart-item-row > div:first-child > div[style*="color:"] strong {
  color:#e9e9e9!important;
}
html[data-djp-theme="dark"] #subpanel-menu .pos-cart-panel .cart-item-row .btn-cart-discount {
  background:#363636!important;color:#f0f0f0!important;
  border:1px solid #555!important;
}
html[data-djp-theme="dark"] #subpanel-menu .pos-cart-panel .cart-section-title,
html[data-djp-theme="dark"] #subpanel-menu .pos-cart-panel .cart-field-label {
  color:#c5c5c5!important;
}
html[data-djp-theme="dark"] #subpanel-menu .pos-cart-panel #cartChargesSection {
  background:#292929!important;border:1px solid #414141!important;box-shadow:none!important;
}
html[data-djp-theme="dark"] #subpanel-menu .pos-cart-panel #cartChargesSection > div:first-child > span {
  color:#e7e7e7!important;
}
html[data-djp-theme="dark"] #subpanel-menu .pos-cart-panel .cart-receipt-summary {
  background:#292929!important;color:#ededed!important;
  border:1px solid #414141!important;box-shadow:none!important;
}
html[data-djp-theme="dark"] #subpanel-menu .pos-cart-panel .cart-receipt-summary :is(.cart-summary-row,.total-label,.total-value,#cartProductsSubtotalLabel,#cartTotalLabel) {
  color:#f1f1f1!important;
}
html[data-djp-theme="dark"] #subpanel-menu .pos-cart-panel .cart-receipt-summary .cart-summary-row[style*="color:"] {
  color:#dedede!important;
}
html[data-djp-theme="dark"] #subpanel-menu .pos-cart-panel .cart-receipt-summary .total-row {
  border-color:#4a4a4a!important;
}
html[data-djp-theme="dark"] #subpanel-menu .pos-cart-panel .cart-receipt-summary .cart-payment-select-wrap label {
  color:#c7c7c7!important;
}
html[data-djp-theme="dark"] #subpanel-menu .pos-cart-panel .cart-receipt-summary #cartPaymentMethod {
  background:#353535!important;color:#f1f1f1!important;border-color:#4b4b4b!important;
}
html[data-djp-theme="dark"] #subpanel-menu .pos-cart-panel .cart-receipt-summary #btnSubmitOrder {
  background:#e0e0e0!important;color:#171717!important;border-color:#e0e0e0!important;
}
html[data-djp-theme="dark"] #subpanel-menu .pos-cart-panel .cart-receipt-summary #btnSubmitOrder :is(span,svg) {
  color:#171717!important;stroke:currentColor!important;
}
@media(max-width:767px){
  html[data-djp-theme="dark"] #subpanel-menu .pos-catalog-toolbar {max-width:100%;min-width:0;}
  html[data-djp-theme="dark"] #subpanel-menu .pos-cart-panel {max-width:100%;min-width:0;}
}

/* DJOHNPAO Dark Mode V4 — screenshot-specific contrast corrections.
   Scoped to dark mode only; no changes to light theme or business logic. */
/* Menu: readable item count in the cashier header. */
html[data-djp-theme="dark"] #subpanel-menu #cartItemCountBadge {
  background:#343434!important;color:#f5f5f5!important;
  border:1px solid #505050!important;box-shadow:none!important;
}
/* PO Detail Order: fix hard-coded dark ink and preserve meaningful statuses. */
html[data-djp-theme="dark"] #povTabContentOrders #tbodyPOViewBreakdown td > div[style*="color: #2a170f"] {
  color:#f2f2f2!important;
}
html[data-djp-theme="dark"] #povTabContentOrders #tbodyPOViewBreakdown td strong[style*="color: #b45309"] {
  color:#e8b58b!important;
}
html[data-djp-theme="dark"] #povTabContentOrders #tbodyPOViewBreakdown td span[style*="color: #16a34a"] {
  color:#77db9e!important;
}
html[data-djp-theme="dark"] #povTabContentOrders #tbodyPOViewBreakdown td span[style*="background:#f7efe7"] {
  background:#353535!important;color:#f2f2f2!important;border-color:#4d4d4d!important;
}
html[data-djp-theme="dark"] #povTabContentOrders #tbodyPOViewBreakdown .order-table-note-pill {
  background:#423521!important;color:#ffe0a8!important;border-color:#665238!important;
}
html[data-djp-theme="dark"] #povTabContentOrders .table-responsive {
  max-width:100%;overflow-x:auto;-webkit-overflow-scrolling:touch;
}
/* PO Rekap Menu: remove white cards and pale-on-pale text. */
html[data-djp-theme="dark"] #povTabContentMenus .pov-batch-card {
  background:#242424!important;color:#f1f1f1!important;
  border:1px solid #414141!important;box-shadow:none!important;
}
html[data-djp-theme="dark"] #povTabContentMenus .pov-batch-header,
html[data-djp-theme="dark"] #povTabContentMenus .pov-card-footer {
  border-color:#444!important;
}
html[data-djp-theme="dark"] #povTabContentMenus .pov-date-badge,
html[data-djp-theme="dark"] #povTabContentMenus .pov-cat-tag,
html[data-djp-theme="dark"] #povTabContentMenus .pov-cust-pill {
  background:#303030!important;color:#ededed!important;border-color:#505050!important;
}
html[data-djp-theme="dark"] #povTabContentMenus .pov-item-icon-holder,
html[data-djp-theme="dark"] #povTabContentMenus .pov-qty-banner {
  background:#303030!important;background-image:none!important;
  border-color:#4a4a4a!important;
}
html[data-djp-theme="dark"] #povTabContentMenus .pov-item-title,
html[data-djp-theme="dark"] #povTabContentMenus .pov-qty-total,
html[data-djp-theme="dark"] #povTabContentMenus .pov-cust-pill strong {
  color:#f5f5f5!important;
}
html[data-djp-theme="dark"] #povTabContentMenus .pov-time-span,
html[data-djp-theme="dark"] #povTabContentMenus .pov-qty-label,
html[data-djp-theme="dark"] #povTabContentMenus .pov-customers-header {
  color:#c9c9c9!important;
}
html[data-djp-theme="dark"] #povTabContentMenus .pov-btn-filter-detail {
  background:#353535!important;color:#f1f1f1!important;
  border:1px solid #505050!important;box-shadow:none!important;
}
html[data-djp-theme="dark"] #povTabContentMenus .pov-btn-filter-detail:hover {
  background:#414141!important;color:#fff!important;
}
/* PO BOM: generated cells contain fixed dark green/brown text. */
html[data-djp-theme="dark"] #povTabContentBOM #tbodyPOViewBOMAggregate td strong[style*="color: #1f3d30"] {
  color:#f1f1f1!important;
}
html[data-djp-theme="dark"] #povTabContentBOM #tbodyPOViewBOMAggregate td[style*="color: #274c3b"] {
  color:#dceee3!important;
}
html[data-djp-theme="dark"] #povTabContentBOM #tbodyPOViewBOMAggregate td[style*="color: #b45309"] {
  color:#e9ba8b!important;
}
html[data-djp-theme="dark"] #povTabContentBOM #tbodyPOViewBOMAggregate td[style*="color: #16a34a"] {
  color:#83e3ac!important;
}
html[data-djp-theme="dark"] #povTabContentBOM #tbodyPOViewBOMAggregate td[style*="color: #dc2626"] {
  color:#ff9a9a!important;
}
html[data-djp-theme="dark"] #povTabContentBOM .table-responsive {
  max-width:100%;overflow-x:auto;-webkit-overflow-scrolling:touch;
}
@media(max-width:767px) {
  html[data-djp-theme="dark"] #povTabContentMenus .pov-batch-grid {
    grid-template-columns:repeat(auto-fill,minmax(min(100%,260px),1fr));
  }
}

/* DJOHNPAO V5 — semantic hierarchy, dark theme only.
   No changes to light theme, markup, permissions, or business logic. */
html[data-djp-theme="dark"] {
  --djp-ink-primary:#eeeeee;
  --djp-ink-secondary:#c3c3c3;
  --djp-ink-tertiary:#a8a8a8;
  --djp-accent-warm:#e5bd96;
}
/* Readable hierarchy on dark surfaces, without forcing all text to white. */
html[data-djp-theme="dark"] .main-content :is(.package-card-title,.cart-item-name,.pov-item-title){color:var(--djp-ink-primary)!important;font-weight:700}
html[data-djp-theme="dark"] .main-content :is(.package-card-meta-row,.pov-time-span,.pov-qty-label,.pov-customers-header){color:var(--djp-ink-secondary)!important}
html[data-djp-theme="dark"] #povTabContentMenus .pov-qty-total{color:var(--djp-accent-warm)!important;font-weight:800}
html[data-djp-theme="dark"] #subpanel-menu #cartItemCountBadge{background:#363636!important;color:#f5f5f5!important;font-weight:800!important;border-color:#4d4d4d!important}
/* Meaningful solid action colors. These overrides follow the existing button classes. */
html[data-djp-theme="dark"] .main-content :is(.btn-danger,.btn-delete,.btn-remove,.btn-del-adj-row,.btn-del-in-row,.btn-del-out-row){background:#b72d38!important;color:#fff!important;border-color:#b72d38!important;font-weight:700!important}
html[data-djp-theme="dark"] .main-content :is(.btn-danger,.btn-delete,.btn-remove,.btn-del-adj-row,.btn-del-in-row,.btn-del-out-row):hover{background:#d13b47!important;color:#fff!important;border-color:#d13b47!important}
html[data-djp-theme="dark"] .main-content :is(.btn-success,.btn-confirm,.btn-approve,.btn-shortage-proceed){background:#177448!important;color:#fff!important;border-color:#177448!important;font-weight:700!important}
html[data-djp-theme="dark"] .main-content :is(.btn-success,.btn-confirm,.btn-approve,.btn-shortage-proceed):hover{background:#1b8955!important;color:#fff!important;border-color:#1b8955!important}
html[data-djp-theme="dark"] .main-content :is(.btn-warning,.btn-caution){background:#e9b44f!important;color:#241900!important;border-color:#e9b44f!important;font-weight:800!important}
/* Preserve semantic status badges: soft background with legible foreground. */
html[data-djp-theme="dark"] .main-content :is(.status-success,.badge-success,.stat-badge.green){background:#203d2f!important;color:#a8edc3!important;border-color:#38644b!important;font-weight:700!important}
html[data-djp-theme="dark"] .main-content :is(.status-warning,.badge-warning,.stat-badge.amber){background:#45361e!important;color:#f7d58b!important;border-color:#6d542e!important;font-weight:700!important}
html[data-djp-theme="dark"] .main-content :is(.status-danger,.badge-danger,.stat-badge.red){background:#46272b!important;color:#ffb7bf!important;border-color:#704047!important;font-weight:700!important}
html[data-djp-theme="dark"] .main-content :is(.status-success,.badge-success,.stat-badge.green,.status-warning,.badge-warning,.stat-badge.amber,.status-danger,.badge-danger,.stat-badge.red) :is(span,strong,small,i){color:inherit!important}
/* On explicitly pale pills and controls, dark lettering is required. */
html[data-djp-theme="dark"] .main-content :is(.pos-cat-chip.active,.filter-chip.active,.orders-tracking-tab.active,.btn-pos-checkout){color:#171717!important;font-weight:700!important}
/* Keep semantic button labels readable even if the base stylesheet colors nested spans. */
html[data-djp-theme="dark"] .main-content :is(.btn-danger,.btn-delete,.btn-remove,.btn-del-adj-row,.btn-del-in-row,.btn-del-out-row,.btn-success,.btn-confirm,.btn-approve,.btn-shortage-proceed) :is(span,strong,small,i){color:#fff!important}
html[data-djp-theme="dark"] .main-content :is(.btn-warning,.btn-caution) :is(span,strong,small,i){color:#241900!important}
@media(max-width:767px){html[data-djp-theme="dark"] .main-content :is(.btn-danger,.btn-delete,.btn-remove,.btn-success,.btn-confirm,.btn-approve,.btn-warning){max-width:100%;white-space:normal}}

/* V6 — Existing DJOHNPAO action controls mapped by actual class names. Dark mode only. */
html[data-djp-theme="dark"] .main-content :is(.btn-tbl-del,.btn-del-ing,.btn-del-in-row,.btn-del-out-row,.btn-del-adj-row,.btn-po-red,.btn-reject-audit,.btn-logout-pill,.btn-shortage-cancel){background:#b73542!important;color:#fff!important;border:1px solid #b73542!important;box-shadow:none!important;text-shadow:none!important;font-weight:700!important;}
html[data-djp-theme="dark"] .main-content :is(.btn-tbl-del,.btn-del-ing,.btn-del-in-row,.btn-del-out-row,.btn-del-adj-row,.btn-po-red,.btn-reject-audit,.btn-logout-pill,.btn-shortage-cancel):hover{background:#d14956!important;color:#fff!important;border-color:#d14956!important;}
html[data-djp-theme="dark"] .main-content :is(.btn-tbl-del,.btn-del-ing,.btn-del-in-row,.btn-del-out-row,.btn-del-adj-row,.btn-po-red,.btn-reject-audit,.btn-logout-pill,.btn-shortage-cancel) :is(span,strong,small,i,svg){color:inherit!important;}
html[data-djp-theme="dark"] .main-content :is(.btn-po-green,.btn-approve-audit,.btn-shortage-proceed,.btn-dp-submit,.btn-gatekeeper-submit){background:#16784d!important;color:#fff!important;border:1px solid #16784d!important;box-shadow:none!important;text-shadow:none!important;font-weight:700!important;}
html[data-djp-theme="dark"] .main-content :is(.btn-po-green,.btn-approve-audit,.btn-shortage-proceed,.btn-dp-submit,.btn-gatekeeper-submit):hover{background:#21925f!important;color:#fff!important;border-color:#21925f!important;}
html[data-djp-theme="dark"] .main-content :is(.btn-po-green,.btn-approve-audit,.btn-shortage-proceed,.btn-dp-submit,.btn-gatekeeper-submit) :is(span,strong,small,i,svg){color:inherit!important;}
html[data-djp-theme="dark"] .main-content :is(.btn-wa-action,.btn-po-blue,.btn-tbl-detail,.btn-alert-link,.btn-alert-action){background:#275d91!important;color:#fff!important;border:1px solid #275d91!important;box-shadow:none!important;text-shadow:none!important;font-weight:700!important;}
html[data-djp-theme="dark"] .main-content :is(.btn-wa-action,.btn-po-blue,.btn-tbl-detail,.btn-alert-link,.btn-alert-action):hover{background:#3375b3!important;color:#fff!important;border-color:#3375b3!important;}
html[data-djp-theme="dark"] .main-content :is(.btn-wa-action,.btn-po-blue,.btn-tbl-detail,.btn-alert-link,.btn-alert-action) :is(span,strong,small,i,svg){color:inherit!important;}
html[data-djp-theme="dark"] .main-content :is(.btn-tbl-edit,.btn-cart-discount,.btn-status-toggle){background:#e2ac4c!important;color:#21180b!important;border:1px solid #e2ac4c!important;box-shadow:none!important;text-shadow:none!important;font-weight:700!important;}
html[data-djp-theme="dark"] .main-content :is(.btn-tbl-edit,.btn-cart-discount,.btn-status-toggle):hover{background:#f0be66!important;color:#21180b!important;border-color:#f0be66!important;}
html[data-djp-theme="dark"] .main-content :is(.btn-tbl-edit,.btn-cart-discount,.btn-status-toggle) :is(span,strong,small,i,svg){color:inherit!important;}
html[data-djp-theme="dark"] .main-content :is(.btn-primary-artisan,.btn-pos-checkout,.btn-add-cart){background:#d7b28a!important;color:#21170f!important;border:1px solid #d7b28a!important;box-shadow:none!important;text-shadow:none!important;font-weight:700!important;}
html[data-djp-theme="dark"] .main-content :is(.btn-primary-artisan,.btn-pos-checkout,.btn-add-cart):hover{background:#e9c5a0!important;color:#21170f!important;border-color:#e9c5a0!important;}
html[data-djp-theme="dark"] .main-content :is(.btn-primary-artisan,.btn-pos-checkout,.btn-add-cart) :is(span,strong,small,i,svg){color:inherit!important;}
html[data-djp-theme="dark"] .main-content :is(.btn-mini-action,.btn-subaction,.btn-artisan,.btn-secondary-artisan,.btn-export-pill,.btn-export-orders,.btn-export-inventory,.btn-export-excel,.btn-export-menu,.btn-export-csv,.btn-export-pdf,.btn-secondary,.btn-close-modal,.btn-modal-close,.btn-close-picker,.btn-close-shortage,.btn-dp-cancel,.btn-dp-nav,.btn-dp-today,.btn-dp-nextyear,.btn-zoom-ctrl,.pov-subtab-btn,.pov-btn-filter-detail,.btn-qty,.btn-row-action,.btn-expand-arrow,.wa-tab-btn,.wa-var-chip,.btn-wa-tpl-chip,.btn-add-menu-action){background:#343434!important;color:#ececec!important;border:1px solid #454545!important;box-shadow:none!important;text-shadow:none!important;font-weight:700!important;}
html[data-djp-theme="dark"] .main-content :is(.btn-mini-action,.btn-subaction,.btn-artisan,.btn-secondary-artisan,.btn-export-pill,.btn-export-orders,.btn-export-inventory,.btn-export-excel,.btn-export-menu,.btn-export-csv,.btn-export-pdf,.btn-secondary,.btn-close-modal,.btn-modal-close,.btn-close-picker,.btn-close-shortage,.btn-dp-cancel,.btn-dp-nav,.btn-dp-today,.btn-dp-nextyear,.btn-zoom-ctrl,.pov-subtab-btn,.pov-btn-filter-detail,.btn-qty,.btn-row-action,.btn-expand-arrow,.wa-tab-btn,.wa-var-chip,.btn-wa-tpl-chip,.btn-add-menu-action):hover{background:#414141!important;color:#ececec!important;border-color:#414141!important;}
html[data-djp-theme="dark"] .main-content :is(.btn-mini-action,.btn-subaction,.btn-artisan,.btn-secondary-artisan,.btn-export-pill,.btn-export-orders,.btn-export-inventory,.btn-export-excel,.btn-export-menu,.btn-export-csv,.btn-export-pdf,.btn-secondary,.btn-close-modal,.btn-modal-close,.btn-close-picker,.btn-close-shortage,.btn-dp-cancel,.btn-dp-nav,.btn-dp-today,.btn-dp-nextyear,.btn-zoom-ctrl,.pov-subtab-btn,.pov-btn-filter-detail,.btn-qty,.btn-row-action,.btn-expand-arrow,.wa-tab-btn,.wa-var-chip,.btn-wa-tpl-chip,.btn-add-menu-action) :is(span,strong,small,i,svg){color:inherit!important;}
html[data-djp-theme="dark"] .main-content :is(.pos-cat-chip,.filter-chip,.orders-tracking-tab,.btn-dp-nav,.wa-tab-btn,.wa-var-chip,.btn-wa-tpl-chip){box-shadow:none!important;border:1px solid #444!important;}
html[data-djp-theme="dark"] .main-content :is(.pos-cat-chip.active,.filter-chip.active,.orders-tracking-tab.active,.wa-tab-btn.active,.pov-subtab-btn.active){background:#d7b28a!important;color:#21170f!important;border-color:#d7b28a!important;font-weight:750!important;}
html[data-djp-theme="dark"] .main-content :is(.pos-cat-chip.active,.filter-chip.active,.orders-tracking-tab.active,.wa-tab-btn.active,.pov-subtab-btn.active) :is(span,strong,small,i){color:inherit!important;}
html[data-djp-theme="dark"] .main-content :is(button,.btn,a[role="button"]):disabled{opacity:.48!important;cursor:not-allowed!important;box-shadow:none!important;}
@media(max-width:700px){html[data-djp-theme="dark"] .main-content :is(button,.btn,a[role="button"]){max-width:100%;overflow-wrap:anywhere;}}


/* V7 — khusus Dark Mode: Orders Tracking, Activity Log, dan status.
   Scoped agar Light Mode dan modul lain tidak berubah. */
html[data-djp-theme="dark"] #subpanel-orders-tracking .tracking-wa-btn {
  background:#16784d!important;border:1px solid #21885e!important;color:#fff!important;font-weight:750!important;
}
html[data-djp-theme="dark"] #subpanel-orders-tracking .tracking-reminder-btn {
  background:#e7b957!important;border:1px solid #e7b957!important;color:#211909!important;font-weight:750!important;
}
html[data-djp-theme="dark"] #subpanel-orders-tracking .tracking-success-btn {
  background:#16784d!important;border:1px solid #21885e!important;color:#fff!important;font-weight:750!important;
}
html[data-djp-theme="dark"] #subpanel-orders-tracking .tracking-fail-btn {
  background:#b73542!important;border:1px solid #b73542!important;color:#fff!important;font-weight:750!important;
}
html[data-djp-theme="dark"] #subpanel-orders-tracking .tracking-nonwa-btn {
  background:#3a4652!important;border:1px solid #53606c!important;color:#f1f5f9!important;font-weight:750!important;
}
html[data-djp-theme="dark"] #subpanel-orders-tracking .tracking-actions button:not(:disabled):hover {
  filter:brightness(1.13);
}
html[data-djp-theme="dark"] #subpanel-orders-tracking .tracking-actions button:disabled {
  opacity:.48!important;
}
html[data-djp-theme="dark"] #subpanel-orders-tracking .tracking-status {
  background:#49391e!important;color:#ffe1a3!important;border:1px solid #755a2b!important;font-weight:700!important;
}
html[data-djp-theme="dark"] #subpanel-orders-tracking .tracking-status.contacted {
  background:#163f2c!important;color:#a9efc6!important;border-color:#296a4a!important;
}
html[data-djp-theme="dark"] #subpanel-orders-tracking .tracking-remaining {
  color:#ffb17d!important;font-weight:750!important;
}
html[data-djp-theme="dark"] #subpanel-orders-tracking .orders-tracking-tools span {
  color:#edbc91!important;font-weight:750!important;
}
html[data-djp-theme="dark"] #subpanel-orders-tracking .orders-tracking-table td small,
html[data-djp-theme="dark"] #subpanel-orders-tracking .orders-tracking-note {
  color:#b9b9b9!important;
}
/* Tiga tahap memiliki warna penanda sendiri; tahap aktif lebih tegas. */
html[data-djp-theme="dark"] #subpanel-orders-tracking .orders-tracking-tab[data-tracking-stage="confirm"].active {
  background:#9a632d!important;border-color:#c18a50!important;color:#fff!important;
}
html[data-djp-theme="dark"] #subpanel-orders-tracking .orders-tracking-tab[data-tracking-stage="verified"].active {
  background:#176b4a!important;border-color:#30956a!important;color:#fff!important;
}
html[data-djp-theme="dark"] #subpanel-orders-tracking .orders-tracking-tab[data-tracking-stage="ready"].active {
  background:#d7b28a!important;border-color:#d7b28a!important;color:#24180e!important;
}
html[data-djp-theme="dark"] #subpanel-orders-tracking .orders-tracking-tab.active span {
  color:inherit!important;
}

/* Activity Log memiliki banyak warna inline dari renderer; override hanya di panel ini. */
html[data-djp-theme="dark"] #subpanel-order-activity-log .panel-card,
html[data-djp-theme="dark"] #subpanel-order-activity-log .order-section {
  color:#e8e8e8;
}
html[data-djp-theme="dark"] #subpanel-order-activity-log #boxManualDateOrderActivityLog {
  background:#292929!important;border-color:#464646!important;color:#e8e8e8!important;
}
html[data-djp-theme="dark"] #subpanel-order-activity-log #lblCustomOrderActInfo {
  color:#b8b8b8!important;
}
html[data-djp-theme="dark"] #subpanel-order-activity-log #tbodyOrderActivityLog td div[style*="color:#0f172a"],
html[data-djp-theme="dark"] #subpanel-order-activity-log #tbodyOrderActivityLog td strong[style*="color:#0f172a"] {
  color:#f0f0f0!important;
}
html[data-djp-theme="dark"] #subpanel-order-activity-log #tbodyOrderActivityLog td div[style*="color:#334155"],
html[data-djp-theme="dark"] #subpanel-order-activity-log #tbodyOrderActivityLog td div[style*="color:#64748b"],
html[data-djp-theme="dark"] #subpanel-order-activity-log #tbodyOrderActivityLog td span[style*="color:#64748b"] {
  color:#bfc5cc!important;
}
html[data-djp-theme="dark"] #subpanel-order-activity-log #tbodyOrderActivityLog td div[style*="background:#f8fafc"] {
  background:#292d32!important;border-color:#454b53!important;color:#e8e8e8!important;
}
html[data-djp-theme="dark"] #subpanel-order-activity-log #tbodyOrderActivityLog td div[style*="background:#f0fdf4"] {
  background:#183c2a!important;border-color:#326749!important;color:#e8e8e8!important;
}
html[data-djp-theme="dark"] #subpanel-order-activity-log #tbodyOrderActivityLog td strong[style*="color:#166534"],
html[data-djp-theme="dark"] #subpanel-order-activity-log #tbodyOrderActivityLog td div[style*="color:#15803d"],
html[data-djp-theme="dark"] #subpanel-order-activity-log #tbodyOrderActivityLog td span[style*="color:#15803d"] {
  color:#9ce7b9!important;
}
html[data-djp-theme="dark"] #subpanel-order-activity-log #tbodyOrderActivityLog td span[style*="color:#dc2626"],
html[data-djp-theme="dark"] #subpanel-order-activity-log #tbodyOrderActivityLog td div[style*="color:#dc2626"] {
  color:#ff9ca5!important;
}
/* Badge aktivitas: warna ditentukan oleh arti status, bukan semua putih. */
html[data-djp-theme="dark"] #subpanel-order-activity-log #tbodyOrderActivityLog td span[style*="background:#ecfdf5"],
html[data-djp-theme="dark"] #subpanel-order-activity-log #tbodyOrderActivityLog td span[style*="background:#f0fdf4"] {
  background:#17472f!important;color:#b4f4ca!important;border-color:#357750!important;
}
html[data-djp-theme="dark"] #subpanel-order-activity-log #tbodyOrderActivityLog td span[style*="background:#fef2f2"] {
  background:#58272e!important;color:#ffc1c7!important;border-color:#91424c!important;
}
html[data-djp-theme="dark"] #subpanel-order-activity-log #tbodyOrderActivityLog td span[style*="background:#eff6ff"] {
  background:#223c5a!important;color:#b8d9ff!important;border-color:#3c628a!important;
}
html[data-djp-theme="dark"] #subpanel-order-activity-log #tbodyOrderActivityLog td span[style*="background:#fffbeb"] {
  background:#49391e!important;color:#ffe1a3!important;border-color:#755a2b!important;
}
html[data-djp-theme="dark"] #subpanel-order-activity-log #tbodyOrderActivityLog td span[style*="background:"] {
  font-weight:750!important;
}
html[data-djp-theme="dark"] #subpanel-order-activity-log #inputSearchOrderAct,
html[data-djp-theme="dark"] #subpanel-order-activity-log #selectActionTypeOrderAct,
html[data-djp-theme="dark"] #subpanel-order-activity-log input[type="date"] {
  background:#292929!important;color:#ededed!important;border-color:#555!important;color-scheme:dark;
}
@media(max-width:767px) {
  html[data-djp-theme="dark"] #subpanel-orders-tracking .tracking-actions {
    min-width:115px;
  }
  html[data-djp-theme="dark"] #subpanel-orders-tracking .tracking-actions button {
    white-space:normal;line-height:1.25;
  }
}


/* V8: hanya badge pembayaran & pengambilan di Pre-Order View dan History Orders.
   Tidak mengubah data, label, maupun aturan Light Mode. */
html[data-djp-theme="dark"] #tbodyPOViewBreakdown td:nth-child(9),
html[data-djp-theme="dark"] #tbodyOutgoingOrders td:nth-last-child(3) {
  vertical-align:middle;
}
/* Status pembayaran Lunas (hijau), berdasarkan warna asli renderer. */
html[data-djp-theme="dark"] #tbodyPOViewBreakdown .pill-badge[style*="background:#ecfdf5"],
html[data-djp-theme="dark"] #tbodyOutgoingOrders .pill-badge[style*="background:#ecfdf5"] {
  background:#194c34!important;color:#b6f3cd!important;border:1px solid #337e55!important;
  font-weight:800!important;
}
/* Belum Lunas (merah) dan DP (amber) dibedakan dari Lunas. */
html[data-djp-theme="dark"] #tbodyPOViewBreakdown .pill-badge[style*="background:#fef3c7"],
html[data-djp-theme="dark"] #tbodyOutgoingOrders .pill-badge[style*="background:#fef3c7"] {
  background:#593024!important;color:#ffd0a5!important;border:1px solid #a15a36!important;
  font-weight:800!important;
}
html[data-djp-theme="dark"] #tbodyPOViewBreakdown .pill-badge[style*="background:#fee2e2"],
html[data-djp-theme="dark"] #tbodyOutgoingOrders .pill-badge[style*="background:#fee2e2"] {
  background:#5b2730!important;color:#ffc2ca!important;border:1px solid #9a4754!important;font-weight:800!important;
}
/* Metode pembayaran tetap menjadi informasi sekunder, bukan status utama. */
html[data-djp-theme="dark"] #tbodyPOViewBreakdown td span[style*="background: #fef3c7"],
html[data-djp-theme="dark"] #tbodyOutgoingOrders td span[style*="background: #fef3c7"] {
  background:#493b24!important;color:#ffe2a5!important;border:1px solid #79613b!important;
  font-weight:750!important;
}
/* Nilai sisa tagihan perlu menonjol, tanpa mengubah perhitungan. */
html[data-djp-theme="dark"] #tbodyPOViewBreakdown td div[style*="color: #dc2626"],
html[data-djp-theme="dark"] #tbodyOutgoingOrders td div[style*="color: #dc2626"] {
  color:#ff9da8!important;font-weight:800!important;
}
/* History: status pengambilan ditentukan oleh warna inline aslinya. */
html[data-djp-theme="dark"] #tbodyOutgoingOrders .pill-badge[style*="background:#eff6ff"] {
  background:#4b3b22!important;color:#ffdf9e!important;border:1px solid #8d6b38!important;font-weight:800!important;
}
html[data-djp-theme="dark"] #tbodyOutgoingOrders .pill-badge[style*="background:#fffbeb"] {
  background:#4b3b22!important;color:#ffdf9e!important;border:1px solid #8d6b38!important;font-weight:800!important;
}
/* Batasi ke label history agar badge WALK IN tetap dengan warna berbeda. */
html[data-djp-theme="dark"] #tbodyOutgoingOrders .pill-badge[style*="background:#fef3c7"] {
  background:#493b24!important;color:#ffe2a5!important;border:1px solid #79613b!important;
}
/* Rapikan jarak dan alignment tanpa mengubah ukuran tabel atau alur scroll. */
html[data-djp-theme="dark"] #tbodyPOViewBreakdown .pill-badge,
html[data-djp-theme="dark"] #tbodyOutgoingOrders .pill-badge {
  display:inline-flex;align-items:center;justify-content:center;
  min-height:25px;max-width:100%;padding:4px 10px!important;
  border-radius:9px!important;line-height:1.25!important;
  white-space:normal;text-align:center;overflow-wrap:anywhere;
}
html[data-djp-theme="dark"] #tbodyPOViewBreakdown td:nth-child(9) > div,
html[data-djp-theme="dark"] #tbodyOutgoingOrders td > div {
  line-height:1.4;
}
@media(max-width:767px) {
  html[data-djp-theme="dark"] #tbodyPOViewBreakdown .pill-badge,
  html[data-djp-theme="dark"] #tbodyOutgoingOrders .pill-badge {
    font-size:.72rem!important;padding:4px 7px!important;
  }
}


/* V8 tambahan: badge status Confirmed pada kolom Status Pre-Order View.
   Tidak menyentuh badge Batal / Selesai dan tidak memengaruhi Light Mode. */
html[data-djp-theme="dark"] #tbodyPOViewBreakdown tr td:last-child .pill-badge:not([style*="background:#fee2e2"]):not([style*="background:#ecfdf5"]),
html[data-djp-theme="dark"] #tbodyPOViewBreakdown tr td:last-child .pill-badge[style*="background:#eff6ff"] {
  background:#214b78!important;
  color:#d8ebff!important;
  border:1px solid #3979b5!important;
  font-weight:800!important;
  text-align:center;
}
@media(max-width:767px) {
  html[data-djp-theme="dark"] #tbodyPOViewBreakdown tr td:last-child .pill-badge {
    padding:4px 8px!important;
    max-width:100%;
  }
}


/* V9: Staff Management > Privilege & Hak Akses Staf.
   Visual only, scoped to Dark Mode; preserve Light Mode and permission logic. */
html[data-djp-theme="dark"] #privilegeModuleCard .privilege-header-box {
  background:#292929!important;
  border:1px solid #484848!important;
  color:#e8e8e8!important;
  border-radius:12px;
}
html[data-djp-theme="dark"] #privilegeModuleCard .privilege-label-staff {
  color:#e7c6a4!important;
  font-weight:800;
}
html[data-djp-theme="dark"] #privilegeModuleCard .privilege-select-input {
  background:#1c1c1c!important;
  color:#f2f2f2!important;
  border:1px solid #555!important;
  color-scheme:dark;
}
html[data-djp-theme="dark"] #privilegeModuleCard .privilege-select-input:focus {
  border-color:#d7b28a!important;
  box-shadow:0 0 0 3px rgba(215,178,138,.18)!important;
}
html[data-djp-theme="dark"] #privilegeModuleCard .privilege-status-label {
  color:#bdbdbd!important;
}
html[data-djp-theme="dark"] #privilegeModuleCard .privilege-status-badge {
  background:#173d2b!important;color:#a9f0c5!important;
  border:1px solid #357a54!important;font-weight:800;
}
html[data-djp-theme="dark"] #privilegeModuleCard .privilege-status-badge.inactive {
  background:#51262b!important;color:#ffc4ca!important;
  border-color:#994852!important;
}
html[data-djp-theme="dark"] #privilegeModuleCard .priv-group-card {
  border-bottom-color:#3b3b3b!important;
}
html[data-djp-theme="dark"] #privilegeModuleCard .priv-group-title {
  color:#f1f1f1!important;font-weight:800;
}
html[data-djp-theme="dark"] #privilegeModuleCard .priv-item-label {
  color:#c9c9c9!important;
}
html[data-djp-theme="dark"] #privilegeModuleCard .priv-item-label:hover {
  color:#fff!important;
}
html[data-djp-theme="dark"] #privilegeModuleCard .priv-child-checkbox,
html[data-djp-theme="dark"] #privilegeModuleCard .priv-master-checkbox {
  accent-color:#d7b28a;
}
html[data-djp-theme="dark"] #privilegeModuleCard .privilege-footer-actions {
  border-top-color:#424242!important;
}
html[data-djp-theme="dark"] #privilegeModuleCard .btn-subaction {
  background:#343434!important;border-color:#545454!important;
  color:#f1f1f1!important;font-weight:750;
}
html[data-djp-theme="dark"] #privilegeModuleCard .btn-subaction:hover:not(:disabled) {
  background:#444!important;border-color:#777!important;
}
html[data-djp-theme="dark"] #privilegeModuleCard #btnPrivilegeViewOnly {
  background:#184631!important;color:#b7f5cf!important;border-color:#327a53!important;
}
html[data-djp-theme="dark"] #privilegeModuleCard #btnPrivilegeResetAll {
  background:#642b32!important;color:#ffd7da!important;border-color:#a84b55!important;
}
html[data-djp-theme="dark"] #privilegeModuleCard #btnSavePrivileges {
  background:#16784d!important;color:#fff!important;border-color:#278f61!important;font-weight:800;
}
html[data-djp-theme="dark"] #privilegeModuleCard .privilege-owner-banner {
  background:#3c301e!important;border-color:#79603a!important;color:#f4e2c8!important;
}
html[data-djp-theme="dark"] #privilegeModuleCard .privilege-owner-banner-text,
html[data-djp-theme="dark"] #privilegeModuleCard .privilege-owner-banner-text strong,
html[data-djp-theme="dark"] #privilegeModuleCard .privilege-owner-banner-text p {
  color:#f4e2c8!important;
}
@media(max-width:767px) {
  html[data-djp-theme="dark"] #privilegeModuleCard .privilege-header-box {
    padding:14px!important;gap:12px;
  }
  html[data-djp-theme="dark"] #privilegeModuleCard .privilege-header-left {
    min-width:0;width:100%;max-width:100%;
  }
  html[data-djp-theme="dark"] #privilegeModuleCard .privilege-header-right {
    flex-wrap:wrap;
  }
  html[data-djp-theme="dark"] #privilegeModuleCard .priv-grid-2col {
    grid-template-columns:minmax(0,1fr);
  }
  html[data-djp-theme="dark"] #privilegeModuleCard .priv-item-label {
    overflow-wrap:anywhere;
  }
}


/* V10 — Settings & WhatsApp Center: koreksi kontras hanya pada Dark Mode. */
html[data-djp-theme="dark"] #panelSettingTemplates #settingTemplatesListWrap > div {
  background:#252525!important;border-color:#454545!important;color:#e9e9e9!important;
}
html[data-djp-theme="dark"] #panelSettingTemplates #settingTemplatesListWrap strong[style*="color:#1e3a2b"] {
  color:#e6c39e!important;font-weight:800!important;
}
html[data-djp-theme="dark"] #panelSettingTemplates #settingTemplatesListWrap div[style*="background:#f9fafb"] {
  background:#1b1b1b!important;color:#e6e6e6!important;border-color:#454545!important;
}
html[data-djp-theme="dark"] #panelSettingTemplates #settingTemplatesListWrap div[style*="color:#9ca3af"] {
  color:#b6b6b6!important;
}
html[data-djp-theme="dark"] #panelSettingTemplates #settingTemplatesListWrap span[style*="background:#ecfdf5"] {
  background:#174a32!important;color:#b2f2cc!important;border-color:#327653!important;font-weight:800!important;
}
html[data-djp-theme="dark"] #panelSettingTemplates #settingTemplatesListWrap span[style*="background:#f3f4f6"] {
  background:#373737!important;color:#c9c9c9!important;border-color:#555!important;
}
html[data-djp-theme="dark"] #panelSettingTemplates #settingTemplatesListWrap button[onclick^="deleteSettingsTemplateAction"] {
  background:#9d303d!important;color:#fff!important;border-color:#b8424f!important;font-weight:750!important;
}
html[data-djp-theme="dark"] #panelSettingTemplates #settingTemplatesListWrap button[onclick^="openEditSettingsTemplateForm"] {
  background:#343434!important;color:#f2f2f2!important;border-color:#555!important;font-weight:750!important;
}
html[data-djp-theme="dark"] #panelSettingTemplates h3[style*="color: #1e3a2b"],
html[data-djp-theme="dark"] #boxSettingTemplateForm #titleSettingTemplateForm {
  color:#f0e0cc!important;
}
html[data-djp-theme="dark"] #boxSettingTemplateForm {
  background:#252525!important;border-color:#505050!important;color:#ededed!important;
}
html[data-djp-theme="dark"] #boxSettingTemplateForm label[style*="color:"],
html[data-djp-theme="dark"] #boxSettingTemplateForm span[style*="color:#6b7280"] {
  color:#d0d0d0!important;
}
html[data-djp-theme="dark"] #panelSettingTemplates .wa-var-chip {
  background:#343434!important;color:#eee!important;border-color:#555!important;
}
html[data-djp-theme="dark"] #panelSettingTemplates .wa-var-chip:hover {background:#444!important;}
/* Konfirmasi simpan hanya muncul saat ada respons dari API. */
.privilege-save-feedback {margin-top:12px;padding:11px 14px;border-radius:10px;font-size:.85rem;font-weight:700;line-height:1.5;overflow-wrap:anywhere;}
.privilege-save-feedback.is-success {background:#e8f7ed;border:1px solid #88c9a1;color:#14532d;}
.privilege-save-feedback.is-error {background:#fff1f2;border:1px solid #f5a3ac;color:#9f1239;}
html[data-djp-theme="dark"] .privilege-save-feedback.is-success {background:#183e2b;border-color:#347c55;color:#b4f3ca;}
html[data-djp-theme="dark"] .privilege-save-feedback.is-error {background:#4c252b;border-color:#a54b56;color:#ffd1d5;}
@media(max-width:767px) {
  html[data-djp-theme="dark"] #panelSettingTemplates #settingTemplatesListWrap > div {padding:13px!important;}
  html[data-djp-theme="dark"] #panelSettingTemplates #settingTemplatesListWrap > div > div:first-child {flex-wrap:wrap;gap:10px;}
  html[data-djp-theme="dark"] #panelSettingTemplates #settingTemplatesListWrap div[style*="background:#f9fafb"] {overflow-wrap:anywhere;}
}

/* ==============================================================================
 * V11 — DARK MODE: GATEKEEPER LOGIN SCREEN & PIN NUMPAD MODAL (ARTISAN ROAST)
 * Khusus mode gelap; mode terang (Light Mode) tetap 100% utuh tanpa perubahan.
 * ============================================================================== */

/* 1. Latar Belakang & Shell Login Screen */
html[data-djp-theme="dark"] .login-gatekeeper-backdrop {
  background: radial-gradient(circle at 50% 25%, #241610 0%, #0d0805 100%) !important;
}

html[data-djp-theme="dark"] .login-shell {
  background: #171310 !important;
  border: 1px solid #33271f !important;
  box-shadow: 0 28px 90px rgba(0, 0, 0, 0.85) !important;
}

html[data-djp-theme="dark"] .login-gatekeeper-card {
  background: #171310 !important;
  color: #f4f4f4 !important;
}

/* 2. Logo Asli DJOHNPAO di Layar Login (Signature Warm Cream Badge) */
html[data-djp-theme="dark"] .brand-mark-login {
  background: #fbefdc !important;
  border-radius: 14px !important;
  padding: 10px 14px !important;
  width: 175px !important;
  max-width: 100% !important;
  box-sizing: border-box !important;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.3) !important;
}

/* 3. Tipografi Header Login */
html[data-djp-theme="dark"] .gatekeeper-brand-header > .login-eyebrow {
  color: #dca877 !important;
}

html[data-djp-theme="dark"] .gatekeeper-title {
  color: #f5f5f5 !important;
}

html[data-djp-theme="dark"] .gatekeeper-subtitle {
  color: #a89c90 !important;
}

html[data-djp-theme="dark"] .gatekeeper-label {
  color: #cbbbae !important;
}

/* 4. Kolom Isian Input & Ikon */
html[data-djp-theme="dark"] .gatekeeper-input {
  background: #241e1a !important;
  border: 1.5px solid #45372d !important;
  color: #f5f5f5 !important;
}

html[data-djp-theme="dark"] .gatekeeper-input::placeholder {
  color: #8c7d70 !important;
}

html[data-djp-theme="dark"] .gatekeeper-input:focus {
  border-color: #dca877 !important;
  background-color: #2b231e !important;
  box-shadow: 0 0 0 3px rgba(220, 168, 119, 0.22) !important;
}

html[data-djp-theme="dark"] .gatekeeper-input-wrapper .input-icon-left {
  color: #dca877 !important;
}

html[data-djp-theme="dark"] .gatekeeper-pw-toggle {
  color: #a89a8c !important;
}

html[data-djp-theme="dark"] .gatekeeper-pw-toggle:hover {
  color: #dca877 !important;
}

/* 5. Kotak Notifikasi / Sesi Berakhir (Elegan Dark Crimson) */
html[data-djp-theme="dark"] .gatekeeper-error-box {
  background-color: #3b1d20 !important;
  border: 1px solid #8e2b32 !important;
  color: #fca5a5 !important;
}

html[data-djp-theme="dark"] .gatekeeper-error-box svg {
  stroke: #fca5a5 !important;
}

/* 6. Tombol Masuk & Keamanan */
html[data-djp-theme="dark"] .btn-gatekeeper-submit {
  background: linear-gradient(135deg, #a65b38 0%, #7d3f24 100%) !important;
  color: #ffffff !important;
  border: none !important;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.45) !important;
}

html[data-djp-theme="dark"] .btn-gatekeeper-submit:hover {
  background: linear-gradient(135deg, #b86740 0%, #8d472a 100%) !important;
  box-shadow: 0 6px 22px rgba(110, 53, 29, 0.55) !important;
}

html[data-djp-theme="dark"] .gatekeeper-security-badge {
  color: #8c7d70 !important;
}

html[data-djp-theme="dark"] .gatekeeper-security-badge svg {
  stroke: #8c7d70 !important;
}

/* 7. Modal PIN Numpad Kasir/Staf (#loginModal) */
html[data-djp-theme="dark"] #loginModal .numpad-btn {
  background-color: #241e1a !important;
  border-color: #45372d !important;
  color: #f5f5f5 !important;
}

html[data-djp-theme="dark"] #loginModal .numpad-btn:hover {
  background-color: #382e27 !important;
  border-color: #dca877 !important;
  color: #ffffff !important;
  transform: translateY(-2px);
}

html[data-djp-theme="dark"] #loginModal .numpad-btn:active {
  background-color: #a65b38 !important;
  color: #fff !important;
}

html[data-djp-theme="dark"] #loginModal .pin-dot {
  border-color: #dca877 !important;
}

html[data-djp-theme="dark"] #loginModal .pin-dot.filled {
  background-color: #dca877 !important;
}

html[data-djp-theme="dark"] #loginModal #selectStaffUser {
  background-color: #241e1a !important;
  border-color: #45372d !important;
  color: #f5f5f5 !important;
}

@media(max-width:768px) {
  html[data-djp-theme="dark"] .brand-mark-login {
    width: 160px !important;
  }
}

/* 8. Komponen Kartu Status Koneksi (Online / Offline) & Titik Berpendar */
html[data-djp-theme="dark"] .connection-banner-card.is-online {
  background: linear-gradient(135deg, #102619 0%, #132f1f 100%) !important;
  border-color: #1d5334 !important;
  color: #a7f3d0 !important;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.35) !important;
}

html[data-djp-theme="dark"] .connection-banner-card.is-online .connection-badge-pill {
  background: #064e3b !important;
  color: #6ee7b7 !important;
  border-color: #059669 !important;
}

html[data-djp-theme="dark"] .connection-banner-card.is-online .pulse-status-dot {
  background-color: #34d399 !important;
  box-shadow: 0 0 10px rgba(52, 211, 153, 0.9), 0 0 20px rgba(16, 185, 129, 0.5) !important;
}

html[data-djp-theme="dark"] .connection-banner-card.is-online .pulse-glow-ring {
  background-color: rgba(16, 185, 129, 0.4) !important;
}

html[data-djp-theme="dark"] .connection-banner-card.is-online .btn-network-sim {
  background: #1c261e !important;
  color: #e2e8f0 !important;
  border-color: #2e4a36 !important;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.25) !important;
}

html[data-djp-theme="dark"] .connection-banner-card.is-online .btn-network-sim:hover {
  background: #27382b !important;
  border-color: #3d6347 !important;
  color: #ffffff !important;
}

html[data-djp-theme="dark"] .connection-banner-card.is-offline {
  background: linear-gradient(135deg, #2d1215 0%, #36171a 100%) !important;
  border-color: #69222a !important;
  color: #fca5a5 !important;
  box-shadow: 0 4px 16px rgba(153, 27, 27, 0.25) !important;
}

html[data-djp-theme="dark"] .connection-banner-card.is-offline .connection-badge-pill {
  background: #451014 !important;
  color: #fca5a5 !important;
  border-color: #991b1b !important;
}

html[data-djp-theme="dark"] .connection-banner-card.is-offline .pulse-status-dot {
  background-color: #f87171 !important;
  box-shadow: 0 0 12px rgba(248, 113, 113, 0.95), 0 0 24px rgba(239, 68, 68, 0.6) !important;
}

html[data-djp-theme="dark"] .connection-banner-card.is-offline .pulse-glow-ring {
  background-color: rgba(239, 68, 68, 0.5) !important;
}

html[data-djp-theme="dark"] .connection-sim-badge {
  background: #452b0d !important;
  color: #fcd34d !important;
  border-color: #784a14 !important;
}

html[data-djp-theme="dark"] .connection-banner-card.is-offline .btn-network-sim,
html[data-djp-theme="dark"] .btn-network-sim.is-active-sim {
  background: #991b1b !important;
  color: #ffffff !important;
  border-color: #b91c1c !important;
}

html[data-djp-theme="dark"] .connection-banner-card.is-offline .btn-network-sim:hover,
html[data-djp-theme="dark"] .btn-network-sim.is-active-sim:hover {
  background: #b91c1c !important;
  border-color: #dc2626 !important;
}

/* 9. Komponen Widget Staf Online di Header */
html[data-djp-theme="dark"] .staff-online-pill {
  background: #1b1612 !important;
  border-color: #382d24 !important;
  color: #a7f3d0 !important;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.3) !important;
}

html[data-djp-theme="dark"] .staff-online-pill:hover,
html[data-djp-theme="dark"] .staff-online-pill[aria-expanded="true"] {
  background: #271f19 !important;
  border-color: #10b981 !important;
  color: #34d399 !important;
  box-shadow: 0 3px 8px rgba(16, 185, 129, 0.2) !important;
}

html[data-djp-theme="dark"] .staff-online-dot {
  background: #34d399 !important;
  box-shadow: 0 0 8px rgba(52, 211, 153, 0.9) !important;
}

html[data-djp-theme="dark"] .staff-online-pulse-ring {
  background: rgba(16, 185, 129, 0.4) !important;
}

html[data-djp-theme="dark"] .staff-online-chevron {
  color: #a7f3d0 !important;
}

html[data-djp-theme="dark"] .staff-online-dropdown {
  background: #181310 !important;
  border-color: #3d3027 !important;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.6) !important;
}

html[data-djp-theme="dark"] .staff-online-dropdown-header {
  background: #221b16 !important;
  border-bottom-color: #3d3027 !important;
}

html[data-djp-theme="dark"] .staff-online-header-title {
  color: #f5ede6 !important;
}

html[data-djp-theme="dark"] .staff-online-header-badge {
  background: #064e3b !important;
  color: #6ee7b7 !important;
  border-color: #059669 !important;
}

html[data-djp-theme="dark"] .staff-online-item:hover {
  background: #241d17 !important;
}

html[data-djp-theme="dark"] .staff-avatar-circle {
  background: #2a221b !important;
  color: #f5ede6 !important;
  border-color: #4a3b30 !important;
}

html[data-djp-theme="dark"] .staff-avatar-online-dot {
  border-color: #181310 !important;
}

html[data-djp-theme="dark"] .staff-item-name {
  color: #f5ede6 !important;
}

html[data-djp-theme="dark"] .staff-item-name .staff-you-tag {
  background: #064e3b !important;
  color: #6ee7b7 !important;
}

html[data-djp-theme="dark"] .staff-time-active {
  color: #9ca3af !important;
}

html[data-djp-theme="dark"] .staff-role-owner {
  background: #452b0d !important;
  color: #fcd34d !important;
  border-color: #784a14 !important;
}

html[data-djp-theme="dark"] .staff-role-admin {
  background: #1e1b4b !important;
  color: #c7d2fe !important;
  border-color: #3730a3 !important;
}

html[data-djp-theme="dark"] .staff-role-kasir {
  background: #064e3b !important;
  color: #a7f3d0 !important;
  border-color: #059669 !important;
}

html[data-djp-theme="dark"] .staff-role-gudang {
  background: #431407 !important;
  color: #fed7aa !important;
  border-color: #9a3412 !important;
}

html[data-djp-theme="dark"] .staff-online-dropdown-footer {
  background: #1e1814 !important;
  border-top-color: #3d3027 !important;
  color: #9ca3af !important;
}

html[data-djp-theme="dark"] .btn-refresh-staff-online {
  color: #d1d5db !important;
}

html[data-djp-theme="dark"] .btn-refresh-staff-online:hover {
  background: #2d231b !important;
  color: #ffffff !important;
}

/* ==============================================================================
 * V12 — DARK MODE & RESPONSIVE POLISH: EXPANDABLE DRAWER, MODALS & MULTI-DEVICE
 * Khusus mode gelap dan adaptasi lintas perangkat (PC, Mac, Tablet, iPhone, Android).
 * Mode terang (Light Mode) dan alur bisnis operasional tetap 100% utuh tanpa perubahan.
 * ============================================================================== */

/* 1. Expandable Detail Drawer (History Orders & PO - Unpaid) */
html[data-djp-theme="dark"] .expandable-detail-drawer,
html[data-djp-theme="dark"] .expand-drawer-td,
html[data-djp-theme="dark"] .expandable-detail-drawer > td {
  background: #181818 !important;
  border-color: #383838 !important;
}

html[data-djp-theme="dark"] .drawer-content-box {
  background: #181818 !important;
  background-image: none !important;
  border-top: 1px solid #383838 !important;
  border-bottom: 2px solid #2f2f2f !important;
  color: #ededed !important;
}

html[data-djp-theme="dark"] .drawer-card {
  background: #232323 !important;
  border: 1px solid #383838 !important;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.4) !important;
  color: #ededed !important;
}

html[data-djp-theme="dark"] .drawer-card-title {
  color: #f5f5f5 !important;
  border-bottom: 1px solid #333333 !important;
  padding-bottom: 6px !important;
}

html[data-djp-theme="dark"] .drawer-card-title[style*="color:#047857"],
html[data-djp-theme="dark"] .drawer-card-title[style*="color: #047857"] {
  color: #6ee7b7 !important;
}

html[data-djp-theme="dark"] .drawer-card-title[style*="color:#845322"],
html[data-djp-theme="dark"] .drawer-card-title[style*="color: #845322"] {
  color: #fcd34d !important;
}

/* Tabel Produk di dalam Drawer */
html[data-djp-theme="dark"] .drawer-card thead tr,
html[data-djp-theme="dark"] .drawer-card thead tr[style*="background"] {
  background: #2b2b2b !important;
}

html[data-djp-theme="dark"] .drawer-card thead th {
  background: #2b2b2b !important;
  color: #f0f0f0 !important;
  border-color: #3d3d3d !important;
  font-weight: 750 !important;
}

html[data-djp-theme="dark"] .drawer-card tbody td {
  background: #232323 !important;
  color: #e5e5e5 !important;
  border-color: #333333 !important;
}

html[data-djp-theme="dark"] .drawer-card tbody tr:hover td {
  background: #2c2c2c !important;
}

html[data-djp-theme="dark"] .drawer-prod-title,
html[data-djp-theme="dark"] .drawer-card td strong[style*="color:#1e293b"],
html[data-djp-theme="dark"] .drawer-card td strong[style*="color: #1e293b"],
html[data-djp-theme="dark"] .drawer-card td strong {
  color: #f5f5f5 !important;
  font-weight: 700 !important;
}

html[data-djp-theme="dark"] .custom-table th,
html[data-djp-theme="dark"] .custom-table th * {
  color: #f1f1f1 !important;
  font-weight: 700 !important;
}
html[data-djp-theme="dark"] .custom-table th[style*="color:#059669"],
html[data-djp-theme="dark"] .custom-table th[style*="color: #059669"] {
  color: #6ee7b7 !important;
}
html[data-djp-theme="dark"] .custom-table th[style*="color:#845322"],
html[data-djp-theme="dark"] .custom-table th[style*="color: #845322"] {
  color: #fcd34d !important;
}
html[data-djp-theme="dark"] .custom-table th[style*="color:#dc2626"],
html[data-djp-theme="dark"] .custom-table th[style*="color: #dc2626"] {
  color: #fca5a5 !important;
}

html[data-djp-theme="dark"] .drawer-card td[style*="color:#64748b"],
html[data-djp-theme="dark"] .drawer-card td[style*="color: #64748b"] {
  color: #a8a8a8 !important;
}

html[data-djp-theme="dark"] .drawer-card td[style*="color:#475569"],
html[data-djp-theme="dark"] .drawer-card td[style*="color: #475569"] {
  color: #d1d5db !important;
}

html[data-djp-theme="dark"] .drawer-card td[style*="color:#0f172a"],
html[data-djp-theme="dark"] .drawer-card td[style*="color: #0f172a"] {
  color: #f5f5f5 !important;
}

html[data-djp-theme="dark"] .drawer-card td[style*="color:#059669"],
html[data-djp-theme="dark"] .drawer-card td[style*="color: #059669"] {
  color: #6ee7b7 !important;
}

html[data-djp-theme="dark"] .drawer-card td[style*="color:#94a3b8"],
html[data-djp-theme="dark"] .drawer-card td[style*="color: #94a3b8"] {
  color: #888888 !important;
}

/* Rincian Diskon & Biaya Tambahan di Drawer */
html[data-djp-theme="dark"] .drawer-card span[style*="color:#475569"],
html[data-djp-theme="dark"] .drawer-card span[style*="color: #475569"] {
  color: #c9c9c9 !important;
}

html[data-djp-theme="dark"] .drawer-card strong[style*="color:#059669"],
html[data-djp-theme="dark"] .drawer-card strong[style*="color: #059669"] {
  color: #6ee7b7 !important;
}

html[data-djp-theme="dark"] .drawer-card div[style*="color:#047857"],
html[data-djp-theme="dark"] .drawer-card div[style*="color: #047857"] {
  color: #6ee7b7 !important;
  border-top: 1px dashed #23543d !important;
}

html[data-djp-theme="dark"] .drawer-card span[style*="color:#78350f"],
html[data-djp-theme="dark"] .drawer-card span[style*="color: #78350f"] {
  color: #fcd34d !important;
}

html[data-djp-theme="dark"] .drawer-card strong[style*="color:#845322"],
html[data-djp-theme="dark"] .drawer-card strong[style*="color: #845322"] {
  color: #fde68a !important;
}

html[data-djp-theme="dark"] .drawer-card div[style*="color:#78350f"],
html[data-djp-theme="dark"] .drawer-card div[style*="color: #78350f"] {
  color: #fde68a !important;
  border-top: 1px dashed #59421f !important;
}

html[data-djp-theme="dark"] .drawer-card div[style*="color:#94a3b8"],
html[data-djp-theme="dark"] .drawer-card div[style*="color: #94a3b8"] {
  color: #949494 !important;
}

/* 2. Modal-Modal & Dialog (Termasuk Elemen di Luar .main-content) */
html[data-djp-theme="dark"] :is(.modal-card-luxury, .modal-content, .modal-card) {
  background: #1e1e1e !important;
  color: #ededed !important;
  border: 1px solid #3d3d3d !important;
  box-shadow: 0 25px 75px rgba(0, 0, 0, 0.75) !important;
}

html[data-djp-theme="dark"] :is(.modal-card-luxury, .modal-content, .modal-card) :is(h1, h2, h3, h4, h5, h6) {
  color: #f5f5f5 !important;
}

html[data-djp-theme="dark"] :is(.modal-card-luxury, .modal-content, .modal-card) :is(div, section, article, aside)[style*="background: linear-gradient"],
html[data-djp-theme="dark"] :is(.modal-card-luxury, .modal-content, .modal-card) :is(div, section, article, aside)[style*="background: #f"],
html[data-djp-theme="dark"] :is(.modal-card-luxury, .modal-content, .modal-card) :is(div, section, article, aside)[style*="background:#f"],
html[data-djp-theme="dark"] :is(.modal-card-luxury, .modal-content, .modal-card) :is(div, section, article, aside)[style*="background: #fafaf9"],
html[data-djp-theme="dark"] :is(.modal-card-luxury, .modal-content, .modal-card) :is(div, section, article, aside)[style*="background:#fafaf9"] {
  background: #272727 !important;
  background-image: none !important;
  border: 1px solid #3d3d3d !important;
  color: #ededed !important;
}

html[data-djp-theme="dark"] :is(.modal-card-luxury, .modal-content, .modal-card) :is(div, section, article, aside)[style*="background: #fffbeb"],
html[data-djp-theme="dark"] :is(.modal-card-luxury, .modal-content, .modal-card) :is(div, section, article, aside)[style*="background:#fffbeb"] {
  background: #382d1c !important;
  border: 1px solid #6b522b !important;
  color: #fde68a !important;
}

html[data-djp-theme="dark"] :is(.modal-card-luxury, .modal-content, .modal-card) :is(p, span, label, small) {
  color: #c5c5c5;
}

html[data-djp-theme="dark"] :is(.modal-card-luxury, .modal-content, .modal-card) :is(span, strong, div, p, td, th, small, label)[style*="color:#1e3a2b"],
html[data-djp-theme="dark"] :is(.modal-card-luxury, .modal-content, .modal-card) :is(span, strong, div, p, td, th, small, label)[style*="color: #1e3a2b"],
html[data-djp-theme="dark"] :is(.modal-card-luxury, .modal-content, .modal-card) :is(span, strong, div, p, td, th, small, label)[style*="color:#1c100c"],
html[data-djp-theme="dark"] :is(.modal-card-luxury, .modal-content, .modal-card) :is(span, strong, div, p, td, th, small, label)[style*="color: #1c100c"],
html[data-djp-theme="dark"] :is(.modal-card-luxury, .modal-content, .modal-card) :is(span, strong, div, p, td, th, small, label)[style*="color:#1e3a2f"],
html[data-djp-theme="dark"] :is(.modal-card-luxury, .modal-content, .modal-card) :is(span, strong, div, p, td, th, small, label)[style*="color: #1e3a2f"],
html[data-djp-theme="dark"] :is(.modal-card-luxury, .modal-content, .modal-card) :is(span, strong, div, p, td, th, small, label)[style*="color:#1e293b"],
html[data-djp-theme="dark"] :is(.modal-card-luxury, .modal-content, .modal-card) :is(span, strong, div, p, td, th, small, label)[style*="color: #1e293b"] {
  color: #f1f1f1 !important;
}

html[data-djp-theme="dark"] :is(.modal-card-luxury, .modal-content, .modal-card) :is(span, strong, div, p, td, th, small, label)[style*="color:#6b7280"],
html[data-djp-theme="dark"] :is(.modal-card-luxury, .modal-content, .modal-card) :is(span, strong, div, p, td, th, small, label)[style*="color: #6b7280"],
html[data-djp-theme="dark"] :is(.modal-card-luxury, .modal-content, .modal-card) :is(span, strong, div, p, td, th, small, label)[style*="color:#9ca3af"],
html[data-djp-theme="dark"] :is(.modal-card-luxury, .modal-content, .modal-card) :is(span, strong, div, p, td, th, small, label)[style*="color: #9ca3af"] {
  color: #b0b0b0 !important;
}

html[data-djp-theme="dark"] :is(.modal-card-luxury, .modal-content, .modal-card) thead tr {
  background: #2b2b2b !important;
}

html[data-djp-theme="dark"] :is(.modal-card-luxury, .modal-content, .modal-card) thead th {
  background: #2b2b2b !important;
  color: #f0f0f0 !important;
  border-color: #3d3d3d !important;
}

html[data-djp-theme="dark"] :is(.modal-card-luxury, .modal-content, .modal-card) tbody td {
  background: #232323 !important;
  color: #e5e5e5 !important;
  border-color: #383838 !important;
}

/* 3. Penataan Adaptif Lintas Perangkat (PC, Mac, Tablet, iPhone, Android) */
.drawer-table-responsive {
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

@media (max-width: 960px) {
  .drawer-grid-3 {
    grid-template-columns: 1fr !important;
    gap: 12px !important;
  }
  .drawer-card[style*="grid-column: span 2"],
  .drawer-card {
    grid-column: span 1 !important;
  }
}

@media (max-width: 640px) {
  .drawer-content-box {
    padding: 10px 8px !important;
  }
  .drawer-card {
    padding: 10px !important;
    border-radius: 10px !important;
  }
  .drawer-card-title {
    font-size: 0.74rem !important;
  }
}

/* ================================================================
   TOP STICKY BAR DARK MODE CONTRAST & DEPTH
   ================================================================ */
html[data-djp-theme="dark"] .top-sticky-bar {
  background-color: #141414 !important;
  border-bottom-color: rgba(255, 255, 255, 0.08) !important;
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.45) !important;
}

/* ================================================================
   SUMMARY CARDS (KARTU RINGKASAN) DARK MODE CONTRAST & DEPTH
   ================================================================ */
html[data-djp-theme="dark"] .stat-card {
  background-color: #1e1e1e !important;
  border: 1px solid #383838 !important;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.4) !important;
}

html[data-djp-theme="dark"] .stat-card .stat-title {
  color: #c8c8c8 !important;
}

html[data-djp-theme="dark"] .stat-card .stat-value {
  color: #ffffff !important;
  font-weight: 750 !important;
}

html[data-djp-theme="dark"] .stat-card .stat-subtext {
  color: #9e9e9e !important;
}

html[data-djp-theme="dark"] .stat-icon-wrapper {
  background: #2c251e !important;
  color: #e5b378 !important;
  border: 1px solid #4a3b2b !important;
}

/* Kartu Pengaturan Tema di Mode Gelap */
html[data-djp-theme="dark"] .theme-control-card {
  background-color: #1c1c1c !important;
  border-color: #383838 !important;
}

html[data-djp-theme="dark"] .btn-card-theme-toggle {
  background: #2a2520 !important;
  color: #f5c88c !important;
  border-color: #5c442e !important;
}

html[data-djp-theme="dark"] .btn-card-theme-toggle:hover {
  background: #383028 !important;
  border-color: #8c6844 !important;
}

/* ================= PAGINATION (PRE-ORDER VIEW, HISTORY ORDERS, PO UNPAID) DARK CONTRAST ================= */
html[data-djp-theme="dark"] .pagination-container {
  background: #1c1c1c !important;
  border-color: #383838 !important;
  color: #a3a3a3 !important;
}
html[data-djp-theme="dark"] .pagination-container .pagination-info,
html[data-djp-theme="dark"] .pagination-container div {
  color: #a3a3a3 !important;
}
html[data-djp-theme="dark"] .pagination-container strong {
  color: #f4f4f4 !important;
}
html[data-djp-theme="dark"] .pagination-container select.form-select-artisan {
  background: #252525 !important;
  border-color: #404040 !important;
  color: #f4f4f4 !important;
}
html[data-djp-theme="dark"] :is(.btn-pagination-nav, .btn-pagination-num) {
  background: #252525 !important;
  border-color: #3d3d3d !important;
  color: #e5e5e5 !important;
}
html[data-djp-theme="dark"] :is(.btn-pagination-nav:hover:not([disabled]), .btn-pagination-num:hover:not(.active)) {
  background: #333333 !important;
  border-color: #555555 !important;
  color: #ffffff !important;
}
html[data-djp-theme="dark"] .btn-pagination-num.active {
  background: #9c5a3c !important;
  border-color: #9c5a3c !important;
  color: #ffffff !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.4) !important;
}
html[data-djp-theme="dark"] .btn-pagination-nav:disabled {
  background: #181818 !important;
  border-color: #282828 !important;
  color: #555555 !important;
  opacity: 0.35 !important;
}
html[data-djp-theme="dark"] .pagination-ellipsis {
  color: #666666 !important;
}

/* ================================================================
   SIDEBAR TOGGLE & COLLAPSE DARK MODE
   ================================================================ */
html[data-djp-theme="dark"] .mobile-nav-toggle {
  background: #222222 !important;
  color: #f4f4f4 !important;
  border-color: #383838 !important;
}
html[data-djp-theme="dark"] .mobile-nav-toggle:hover {
  background: #2c251e !important;
  color: #e5b378 !important;
  border-color: #7d5a3c !important;
}
html[data-djp-theme="dark"] .mobile-nav-toggle.is-collapsed {
  border-color: #7d5a3c !important;
  background: #2a2018 !important;
  color: #f5c88c !important;
}
html[data-djp-theme="dark"] .sidebar-collapse-btn {
  background: rgba(255, 255, 255, 0.08) !important;
  color: #dfcdbf !important;
  border-color: rgba(255, 255, 255, 0.16) !important;
}
html[data-djp-theme="dark"] .sidebar-collapse-btn:hover {
  background: rgba(255, 255, 255, 0.22) !important;
  color: #ffffff !important;
  border-color: rgba(255, 255, 255, 0.4) !important;
}

/* ================================================================
   TABLET POS 4-COLUMN CARDS & CATEGORY TABS DARK MODE
   ================================================================ */
html[data-djp-theme="dark"] .pos-view-container .package-card {
  background: #1c1c1c !important;
  border-color: #383838 !important;
}
html[data-djp-theme="dark"] .pos-view-container .package-card:hover {
  border-color: #9c5a3c !important;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.45) !important;
}
html[data-djp-theme="dark"] .pos-view-container .package-img-holder {
  background: #252525 !important;
  border-color: #333333 !important;
}
html[data-djp-theme="dark"] .pos-view-container .package-name {
  color: #f1f1f1 !important;
}
html[data-djp-theme="dark"] .pos-view-container .package-price {
  color: #60a5fa !important;
}
html[data-djp-theme="dark"] .pos-view-container .package-card-cat-badge {
  background: #252525 !important;
  color: #d1d5db !important;
  border-color: #383838 !important;
}
html[data-djp-theme="dark"] .pos-cat-chip {
  background: #252525 !important;
  border-color: #3d3d3d !important;
  color: #e5e5e5 !important;
}
html[data-djp-theme="dark"] .pos-cat-chip.active {
  background: #9c5a3c !important;
  border-color: #9c5a3c !important;
  color: #ffffff !important;
}

/* ================================================================================
 * REVISI V25: Dark Mode untuk Kartu Draggable Template WA
 * ================================================================================ */
html[data-djp-theme="dark"] .wa-template-draggable-card {
  background: #1e1e1e !important;
  border-color: #383838 !important;
}

html[data-djp-theme="dark"] .wa-template-draggable-card.is-dragging {
  background: #172554 !important;
  border-color: #60a5fa !important;
}

html[data-djp-theme="dark"] .wa-template-draggable-card.drag-over-top {
  border-top-color: #60a5fa !important;
}

html[data-djp-theme="dark"] .wa-template-draggable-card.drag-over-bottom {
  border-bottom-color: #60a5fa !important;
}

html[data-djp-theme="dark"] .wa-tpl-drag-handle {
  background: #282828 !important;
  border-color: #444444 !important;
  color: #cbd5e1 !important;
}

html[data-djp-theme="dark"] .wa-tpl-drag-handle:hover {
  background: #333333 !important;
  border-color: #555555 !important;
  color: #ffffff !important;
}

html[data-djp-theme="dark"] .wa-order-btn-group {
  border-color: #444444 !important;
}

html[data-djp-theme="dark"] .wa-order-btn-group .btn-wa-move {
  background: #282828 !important;
  color: #cbd5e1 !important;
  border-color: #444444 !important;
}

html[data-djp-theme="dark"] .wa-order-btn-group .btn-wa-move:hover:not(:disabled) {
  background: #383838 !important;
  color: #60a5fa !important;
}

html[data-djp-theme="dark"] .wa-order-btn-group .btn-wa-move:disabled {
  background: #1c1c1c !important;
  color: #555555 !important;
}

/* ==============================================================================
 * V26 — DARK MODE: WHATSAPP SIMULATOR LIVE PREVIEW & SETTINGS CONTROLS
 * Kontras tinggi, visual otentik WhatsApp Dark Mode, dan teks 100% terbaca jelas.
 * ============================================================================== */

/* 1. WhatsApp Simulator Outer Card Container */
html[data-djp-theme="dark"] .wa-simulator-card,
html[data-djp-theme="dark"] #boxSettingTemplateForm .wa-simulator-card {
  background-color: #111b21 !important;
  border-color: #2a3942 !important;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.45) !important;
}

/* 2. WhatsApp Simulator Top Header */
html[data-djp-theme="dark"] .wa-simulator-header,
html[data-djp-theme="dark"] #boxSettingTemplateForm .wa-simulator-header,
html[data-djp-theme="dark"] #boxSettingTemplateForm div[style*="background: #075e54"] {
  background-color: #1f2c34 !important;
  color: #e9edef !important;
  border-bottom: 1px solid #2a3942 !important;
}

html[data-djp-theme="dark"] .wa-simulator-avatar,
html[data-djp-theme="dark"] #boxSettingTemplateForm .wa-simulator-avatar {
  background-color: #2a3942 !important;
  border: 1px solid #3b4a54 !important;
}

html[data-djp-theme="dark"] .wa-simulator-title,
html[data-djp-theme="dark"] #boxSettingTemplateForm .wa-simulator-title {
  color: #e9edef !important;
}

html[data-djp-theme="dark"] .wa-simulator-status,
html[data-djp-theme="dark"] #boxSettingTemplateForm .wa-simulator-status {
  color: #00a884 !important; /* Authentic WhatsApp online green */
}

html[data-djp-theme="dark"] .wa-simulator-badge,
html[data-djp-theme="dark"] #boxSettingTemplateForm .wa-simulator-badge {
  background-color: rgba(255, 255, 255, 0.12) !important;
  color: #e9edef !important;
}

/* 3. WhatsApp Chat Area & Wallpaper */
html[data-djp-theme="dark"] .wa-simulator-body,
html[data-djp-theme="dark"] #boxSettingTemplateForm .wa-simulator-body,
html[data-djp-theme="dark"] #boxSettingTemplateForm div[style*="background-color: #efeae2"] {
  background-color: #0b141a !important; /* Authentic WA dark background */
  background-image: radial-gradient(#1f2c34 1.2px, transparent 1.2px) !important;
  background-size: 16px 16px !important;
}

/* 4. Date Pill ("HARI INI") */
html[data-djp-theme="dark"] .wa-simulator-date-pill,
html[data-djp-theme="dark"] #boxSettingTemplateForm .wa-simulator-date-pill,
html[data-djp-theme="dark"] #boxSettingTemplateForm div[style*="background: rgba(255,255,255,0.92)"] {
  background-color: #182229 !important;
  color: #8696a0 !important;
  border: 1px solid rgba(255, 255, 255, 0.08) !important;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.4) !important;
}

/* 5. Chat Bubble (Outgoing WhatsApp Green Bubble in Dark Mode) */
html[data-djp-theme="dark"] .wa-simulator-bubble,
html[data-djp-theme="dark"] #boxSettingTemplateForm .wa-simulator-bubble,
html[data-djp-theme="dark"] #boxSettingTemplateForm div[style*="background: #d9fdd3"] {
  background-color: #005c4b !important; /* Iconic WA outgoing dark bubble */
  border-color: #005c4b !important;
  color: #e9edef !important;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.4) !important;
}

/* 6. Text Content Inside Bubble (High Contrast) */
html[data-djp-theme="dark"] #waTplLivePreviewText,
html[data-djp-theme="dark"] #boxSettingTemplateForm #waTplLivePreviewText {
  color: #e9edef !important; /* Crisp readable light text */
}

html[data-djp-theme="dark"] #waTplLivePreviewText strong,
html[data-djp-theme="dark"] #waTplLivePreviewText .wa-preview-bold,
html[data-djp-theme="dark"] #boxSettingTemplateForm #waTplLivePreviewText strong {
  color: #ffffff !important;
  font-weight: 700 !important;
}

html[data-djp-theme="dark"] #waTplLivePreviewText a,
html[data-djp-theme="dark"] #waTplLivePreviewText .wa-preview-link,
html[data-djp-theme="dark"] #boxSettingTemplateForm #waTplLivePreviewText a {
  color: #53bdeb !important; /* WhatsApp cyan link */
  text-decoration: underline !important;
}

html[data-djp-theme="dark"] #waTplLivePreviewText .wa-preview-placeholder,
html[data-djp-theme="dark"] #waTplLivePreviewText span[style*="italic"] {
  color: #8696a0 !important;
}

/* 7. Timestamp & Read Receipts */
html[data-djp-theme="dark"] .wa-simulator-time-wrap,
html[data-djp-theme="dark"] #waTplLivePreviewTime,
html[data-djp-theme="dark"] #boxSettingTemplateForm #waTplLivePreviewTime {
  color: #8696a0 !important;
}

html[data-djp-theme="dark"] .wa-simulator-ticks {
  color: #53bdeb !important;
}

/* 8. Simulator Footer Hint Note */
html[data-djp-theme="dark"] .wa-simulator-footer-hint,
html[data-djp-theme="dark"] #boxSettingTemplateForm .wa-simulator-footer-hint,
html[data-djp-theme="dark"] #boxSettingTemplateForm div[style*="color: #6b7280"] {
  color: #9ca3af !important;
}

/* 9. Template Form Controls (Left Column) */
html[data-djp-theme="dark"] #settingTplFormName,
html[data-djp-theme="dark"] #settingTplFormBody {
  background-color: #1b1b1b !important;
  color: #f3f4f6 !important;
  border-color: #4b5563 !important;
}

html[data-djp-theme="dark"] #settingTplFormName:focus,
html[data-djp-theme="dark"] #settingTplFormBody:focus {
  border-color: #10b981 !important;
  outline: none !important;
}

html[data-djp-theme="dark"] #boxSettingTemplateForm label {
  color: #d1d5db !important;
}

html[data-djp-theme="dark"] #boxSettingTemplateForm .wa-var-chip {
  background-color: #262626 !important;
  color: #e5e7eb !important;
  border-color: #404040 !important;
}

html[data-djp-theme="dark"] #boxSettingTemplateForm .wa-var-chip:hover {
  background-color: #3b3b3b !important;
  color: #ffffff !important;
  border-color: #60a5fa !important;
}

html[data-djp-theme="dark"] #boxSettingTemplateForm .wa-var-chip[onclick*="link_nota"] {
  background-color: #064e3b !important;
  color: #6ee7b7 !important;
  border-color: #047857 !important;
}

/* ================================================================================
 * REVISI V27: POS LOAD MORE SENTINEL DARK MODE
 * ================================================================================ */
html[data-djp-theme="dark"] .btn-load-more-pos {
  background: #252525 !important;
  border-color: #404040 !important;
  color: #e5e5e5 !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3) !important;
}

html[data-djp-theme="dark"] .btn-load-more-pos:hover {
  background: #9c5a3c !important;
  border-color: #9c5a3c !important;
  color: #ffffff !important;
  box-shadow: 0 4px 14px rgba(156, 90, 60, 0.4) !important;
}

html[data-djp-theme="dark"] .pos-load-more-info {
  color: #9ca3af !important;
}

/* ================================================================================
 * REVISI V28: INVENTORY FILTER CHIPS DARK MODE (HIGH CONTRAST)
 * ================================================================================ */
html[data-djp-theme="dark"] .filter-chip-booked {
  background: #0f2338 !important;
  border-color: #1e4976 !important;
  color: #7dd3fc !important;
}

html[data-djp-theme="dark"] .filter-chip-booked:hover {
  background: #153654 !important;
  border-color: #38bdf8 !important;
  color: #ffffff !important;
}

html[data-djp-theme="dark"] .filter-chip-booked.active {
  background: #0284c7 !important;
  border-color: #38bdf8 !important;
  color: #ffffff !important;
  box-shadow: 0 2px 10px rgba(2, 132, 199, 0.45) !important;
}

html[data-djp-theme="dark"] .filter-chip-warning {
  background: #2e1d08 !important;
  border-color: #633c08 !important;
  color: #fde68a !important;
}

html[data-djp-theme="dark"] .filter-chip-warning:hover {
  background: #3d270b !important;
  border-color: #b45309 !important;
  color: #ffffff !important;
}

html[data-djp-theme="dark"] .filter-chip-warning.active {
  background: #d97706 !important;
  border-color: #f59e0b !important;
  color: #ffffff !important;
  box-shadow: 0 2px 10px rgba(217, 119, 6, 0.45) !important;
}

html[data-djp-theme="dark"] .filter-chip-danger {
  background: #2d0e0e !important;
  border-color: #6d1b1b !important;
  color: #fca5a5 !important;
}

html[data-djp-theme="dark"] .filter-chip-danger:hover {
  background: #3e1414 !important;
  border-color: #b91c1c !important;
  color: #ffffff !important;
}

html[data-djp-theme="dark"] .filter-chip-danger.active {
  background: #dc2626 !important;
  border-color: #ef4444 !important;
  color: #ffffff !important;
  box-shadow: 0 2px 10px rgba(220, 38, 38, 0.45) !important;
}

/* Dark Mode support for Zero-Privilege Gatekeeper */
html[data-djp-theme="dark"] .no-access-card {
  background: #18181b !important;
  border-color: #27272a !important;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4) !important;
}

html[data-djp-theme="dark"] .no-access-icon {
  background: #271414 !important;
  border-color: #451a1a !important;
}

html[data-djp-theme="dark"] .no-access-title {
  color: #f4f4f5 !important;
}

html[data-djp-theme="dark"] .no-access-desc {
  color: #d4d4d8 !important;
}

html[data-djp-theme="dark"] .no-access-badge {
  background: #2e1d05 !important;
  border-color: #78350f !important;
  color: #fde68a !important;
}

html[data-djp-theme="dark"] .no-access-subtext {
  color: #a1a1aa !important;
}

/* ==========================================================================
   DARK MODE SUPPORT FOR LIVECHAT INTERNAL TIM
   ========================================================================== */
html[data-djp-theme="dark"] .chat-floating-btn {
  background: linear-gradient(135deg, #18181b 0%, #27272a 100%) !important;
  border-color: rgba(255, 255, 255, 0.12) !important;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5) !important;
}

html[data-djp-theme="dark"] .chat-floating-btn.chat-btn-active {
  background: linear-gradient(135deg, #0284c7 0%, #0369a1 100%) !important;
  border-color: #38bdf8 !important;
}

html[data-djp-theme="dark"] .chat-window-box {
  background: #141416 !important;
  border-color: #27272a !important;
  box-shadow: 0 16px 45px rgba(0, 0, 0, 0.6) !important;
}

html[data-djp-theme="dark"] .chat-window-header {
  background: #09090b !important;
  border-bottom-color: #27272a !important;
}

html[data-djp-theme="dark"] .chat-tabs-bar {
  background: #18181b !important;
  border-bottom-color: #27272a !important;
}

html[data-djp-theme="dark"] .chat-tab-btn {
  color: #a1a1aa !important;
}

html[data-djp-theme="dark"] .chat-tab-btn.active {
  background: #27272a !important;
  color: #38bdf8 !important;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.4) !important;
}

html[data-djp-theme="dark"] .chat-tab-counter {
  background: #27272a !important;
  color: #a1a1aa !important;
}

html[data-djp-theme="dark"] .chat-tab-page {
  background: #141416 !important;
}

html[data-djp-theme="dark"] .chat-pane-header {
  background: #18181b !important;
  border-bottom-color: #27272a !important;
}

html[data-djp-theme="dark"] .chat-pane-title {
  color: #a1a1aa !important;
}

html[data-djp-theme="dark"] .chat-recent-card,
html[data-djp-theme="dark"] .chat-member-card,
html[data-djp-theme="dark"] .chat-group-card {
  background: #18181b !important;
  border-color: #27272a !important;
}

html[data-djp-theme="dark"] .chat-recent-card:hover,
html[data-djp-theme="dark"] .chat-member-card:hover,
html[data-djp-theme="dark"] .chat-group-card:hover {
  background: #202024 !important;
  border-color: #3f3f46 !important;
}

html[data-djp-theme="dark"] .chat-card-title {
  color: #f4f4f5 !important;
}

html[data-djp-theme="dark"] .chat-card-snippet {
  color: #a1a1aa !important;
}

html[data-djp-theme="dark"] .chat-card-time {
  color: #71717a !important;
}

html[data-djp-theme="dark"] .chat-search-input {
  background: #18181b !important;
  border-color: #27272a !important;
  color: #f4f4f5 !important;
}

html[data-djp-theme="dark"] .chat-search-input:focus {
  border-color: #38bdf8 !important;
}

html[data-djp-theme="dark"] .chat-member-meta-header {
  background: #18181b !important;
  border-bottom-color: #27272a !important;
  color: #71717a !important;
}

html[data-djp-theme="dark"] .chat-direct-bar {
  background: #18181b !important;
  border-bottom-color: #27272a !important;
  color: #f4f4f5 !important;
}

html[data-djp-theme="dark"] .chat-back-btn {
  background: #27272a !important;
  border-color: #3f3f46 !important;
  color: #e4e4e7 !important;
}

html[data-djp-theme="dark"] .chat-back-btn:hover {
  background: #3f3f46 !important;
}

html[data-djp-theme="dark"] .chat-target-meta strong {
  color: #f4f4f5 !important;
}

html[data-djp-theme="dark"] .chat-target-sub {
  color: #a1a1aa !important;
}

html[data-djp-theme="dark"] .chat-role-badge {
  background: #27272a !important;
  color: #cbd5e1 !important;
}

html[data-djp-theme="dark"] .badge-role-owner {
  background: rgba(245, 158, 11, 0.15) !important;
  color: #fbbf24 !important;
}

html[data-djp-theme="dark"] .badge-role-admin {
  background: rgba(14, 165, 233, 0.15) !important;
  color: #38bdf8 !important;
}

html[data-djp-theme="dark"] .badge-role-kasir {
  background: rgba(16, 185, 129, 0.15) !important;
  color: #34d399 !important;
}

html[data-djp-theme="dark"] .badge-role-gudang {
  background: rgba(168, 85, 247, 0.15) !important;
  color: #c084fc !important;
}

html[data-djp-theme="dark"] .chat-member-action-btn {
  background: #27272a !important;
  border-color: #3f3f46 !important;
  color: #38bdf8 !important;
}

html[data-djp-theme="dark"] .chat-group-pill {
  background: #27272a !important;
  color: #cbd5e1 !important;
}

html[data-djp-theme="dark"] .chat-create-group-form {
  background: #141416 !important;
}

html[data-djp-theme="dark"] .chat-form-label {
  color: #e4e4e7 !important;
}

html[data-djp-theme="dark"] .chat-form-input {
  background: #18181b !important;
  border-color: #27272a !important;
  color: #f4f4f5 !important;
}

html[data-djp-theme="dark"] .chat-form-input:focus {
  border-color: #38bdf8 !important;
}

html[data-djp-theme="dark"] .chat-members-checklist {
  background: #18181b !important;
  border-color: #27272a !important;
}

html[data-djp-theme="dark"] .chat-member-check-row {
  background: #141416 !important;
  border-color: #27272a !important;
}

html[data-djp-theme="dark"] .chat-member-check-row:hover {
  background: #202024 !important;
}

html[data-djp-theme="dark"] .chat-check-info strong {
  color: #f4f4f5 !important;
}

html[data-djp-theme="dark"] .chat-check-info small {
  color: #a1a1aa !important;
}

html[data-djp-theme="dark"] .chat-messages-container {
  background: #141416 !important;
}

html[data-djp-theme="dark"] .chat-welcome-notice {
  background: #18181b !important;
  border-color: #3f3f46 !important;
}

html[data-djp-theme="dark"] .chat-welcome-notice p {
  color: #a1a1aa !important;
}

html[data-djp-theme="dark"] .chat-system-message span {
  background: #27272a !important;
  color: #cbd5e1 !important;
}

html[data-djp-theme="dark"] .chat-bubble-peer {
  background: #1f1f23 !important;
  border-color: #2e2e33 !important;
  color: #f4f4f5 !important;
}

html[data-djp-theme="dark"] .chat-bubble-sender {
  color: #38bdf8 !important;
}

html[data-djp-theme="dark"] .chat-sender-role {
  background: #27272a !important;
  color: #a1a1aa !important;
}

html[data-djp-theme="dark"] .chat-bubble-self {
  background: linear-gradient(135deg, #0284c7 0%, #0369a1 100%) !important;
  color: #ffffff !important;
}

html[data-djp-theme="dark"] .chat-window-footer {
  background: #18181b !important;
  border-top-color: #27272a !important;
}

html[data-djp-theme="dark"] .chat-input-wrapper {
  background: #141416 !important;
  border-color: #27272a !important;
}

html[data-djp-theme="dark"] .chat-input-wrapper:focus-within {
  border-color: #38bdf8 !important;
  box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.15) !important;
}

html[data-djp-theme="dark"] .chat-textarea {
  color: #f4f4f5 !important;
}

/* ==============================================================================
   REVISI V35: DARK MODE STYLES UNTUK AKSI INVENTORY & DRAG AND DROP
   ============================================================================== */
html[data-djp-theme="dark"] .btn-row-edit {
  color: #60a5fa !important;
  border-color: #3b82f6 !important;
  background: rgba(59, 130, 246, 0.08) !important;
}

html[data-djp-theme="dark"] .btn-row-edit:hover {
  background: #2563eb !important;
  color: #ffffff !important;
}

html[data-djp-theme="dark"] .btn-row-delete {
  color: #f87171 !important;
  border-color: #ef4444 !important;
  background: rgba(239, 68, 68, 0.08) !important;
}

html[data-djp-theme="dark"] .btn-row-delete:hover {
  background: #dc2626 !important;
  color: #ffffff !important;
}

html[data-djp-theme="dark"] .drag-handle-inv {
  color: #71717a !important;
}

html[data-djp-theme="dark"] .drag-handle-inv:hover {
  background: #27272a !important;
  color: #f4f4f5 !important;
}

html[data-djp-theme="dark"] .btn-touch-move {
  background: #18181b !important;
  border-color: #3f3f46 !important;
  color: #a1a1aa !important;
}

html[data-djp-theme="dark"] .btn-touch-move:hover,
html[data-djp-theme="dark"] .btn-touch-move:active {
  background: var(--accent-primary, #b46b48) !important;
  color: #ffffff !important;
  border-color: var(--accent-primary, #b46b48) !important;
}

html[data-djp-theme="dark"] .inv-item-row.is-dragging-row {
  opacity: 0.45;
  background-color: #1e293b !important;
}

/* ==============================================================================
   REVISI V39: DARK MODE UNTUK PENGATURAN GRUP LIVECHAT
   ============================================================================== */
html[data-djp-theme="dark"] .chat-group-settings-btn {
  color: #38bdf8 !important;
  background: rgba(56, 189, 248, 0.12) !important;
  border-color: rgba(56, 189, 248, 0.25) !important;
}

html[data-djp-theme="dark"] .chat-group-settings-btn:hover {
  background: #0284c7 !important;
  color: #ffffff !important;
}

html[data-djp-theme="dark"] .chat-group-gear-btn:hover {
  background: #27272a !important;
}

html[data-djp-theme="dark"] .chat-group-current-members {
  background: #18181b !important;
  border-color: #27272a !important;
}

html[data-djp-theme="dark"] .chat-grp-member-item {
  background: #202023 !important;
  border-color: #2e2e32 !important;
}

html[data-djp-theme="dark"] .chat-btn-remove-member {
  background: rgba(239, 68, 68, 0.15) !important;
  border-color: rgba(239, 68, 68, 0.3) !important;
  color: #f87171 !important;
}

html[data-djp-theme="dark"] .chat-btn-remove-member:hover {
  background: #dc2626 !important;
  color: #ffffff !important;
}

html[data-djp-theme="dark"] .chat-submit-btn-secondary {
  background: #1e293b !important;
  color: #38bdf8 !important;
  border-color: #0284c7 !important;
}

html[data-djp-theme="dark"] .chat-submit-btn-secondary:hover {
  background: #0284c7 !important;
  color: #ffffff !important;
}

html[data-djp-theme="dark"] .chat-danger-zone {
  border-top-color: #7f1d1d !important;
}

html[data-djp-theme="dark"] .chat-danger-desc {
  color: #a1a1aa !important;
}

html[data-djp-theme="dark"] .chat-btn-danger {
  background: #dc2626 !important;
  color: #ffffff !important;
}

html[data-djp-theme="dark"] .chat-btn-danger:hover {
  background: #b91c1c !important;
}







