/* ==========================================================================
   RACKS ERP / Sada Hisab - Modern Enterprise Design System Stylesheet
   ========================================================================== */

:root {
  --bpos-primary: #1B98D6;
  --bpos-primary-hover: #1583B9;
  --bpos-primary-subtle: #EBF7FC;
  --bpos-secondary: #FF4B6E;
  --bpos-secondary-subtle: #FFF0F3;
  --bpos-amber: #F59E0B;
  --bpos-amber-subtle: #FEF3C7;
  --bpos-emerald: #10B981;
  --bpos-emerald-subtle: #ECFDF5;
  --bpos-purple: #8B5CF6;
  --bpos-purple-subtle: #F5F3FF;
  --bpos-orange: #F97316;
  --bpos-orange-hover: #EA580C;
  --bpos-dark-navy: #0B1120;
  --bpos-dark-card: #131B2E;
  --bpos-ground: #F8FAFC;
  --bpos-card: #FFFFFF;
  --bpos-border: #E2E8F0;
  --bpos-border-subtle: #F1F5F9;
  --bpos-text-primary: #0F172A;
  --bpos-text-secondary: #475569;
  --bpos-text-muted: #94A3B8;
  --bpos-radius: 12px;
  --bpos-radius-lg: 16px;
  --bpos-radius-full: 9999px;
  --bpos-shadow-sm: 0 1px 3px rgba(15, 23, 42, 0.05);
  --bpos-shadow: 0 4px 14px rgba(15, 23, 42, 0.04), 0 1px 3px rgba(15, 23, 42, 0.03);
  --bpos-shadow-lg: 0 12px 32px rgba(15, 23, 42, 0.08);
}

/* Reset inside wrap */
.bpos-wrap {
  margin: 10px 20px 20px 0;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  color: var(--bpos-text-primary);
  box-sizing: border-box;
}

.bpos-wrap *, .bpos-wrap *::before, .bpos-wrap *::after {
  box-sizing: border-box;
}

.bpos-app.bpos-racks-layout {
  display: flex;
  flex-direction: column;
  background-color: var(--bpos-ground);
  border: 1px solid var(--bpos-border);
  border-radius: var(--bpos-radius-lg);
  overflow: hidden;
  min-height: calc(100vh - 80px);
  box-shadow: var(--bpos-shadow);
  width: 100%;
}

.bpos-sidebar {
  display: none !important;
}

/* ==========================================================================
   MASTER TOP HEADER & HORIZONTAL NAVIGATION (RACKS ERP)
   ========================================================================== */
.bpos-master-header {
  background: var(--bpos-dark-navy);
  border-bottom: 1px solid #1E293B;
  color: #FFFFFF;
  display: flex;
  flex-direction: column;
  width: 100%;
  position: sticky;
  top: 0;
  z-index: 99;
}

.bpos-header-top-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 20px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  flex-wrap: wrap;
}

.bpos-brand-section {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-shrink: 0;
}

.bpos-brand-icon {
  width: 38px;
  height: 38px;
  background: rgba(27, 152, 214, 0.15);
  border: 1px solid rgba(27, 152, 214, 0.35);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.bpos-brand-text {
  display: flex;
  flex-direction: column;
}

.bpos-brand-name {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 16px;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: #FFFFFF;
  line-height: 1.1;
}

.bpos-brand-accent {
  color: var(--bpos-primary);
}

.bpos-brand-tagline {
  font-size: 11px;
  color: #94A3B8;
  font-weight: 500;
}

.bpos-master-header .bpos-store-chip {
  display: flex;
  align-items: center;
  gap: 8px;
  background: #131B2E;
  border: 1px solid #1E293B;
  border-radius: var(--bpos-radius-full);
  padding: 5px 12px;
  font-size: 12.5px;
  font-weight: 600;
  color: #F8FAFC;
  white-space: nowrap;
}

.bpos-master-header .bpos-store-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--bpos-emerald);
  box-shadow: 0 0 6px var(--bpos-emerald);
}

.bpos-master-header .bpos-global-search {
  flex: 1;
  max-width: 460px;
  position: relative;
  display: flex;
  align-items: center;
}

.bpos-master-header .bpos-global-search input {
  width: 100%;
  height: 36px;
  padding: 0 75px 0 36px;
  background: #131B2E;
  border: 1px solid #232F48;
  border-radius: 8px;
  font-size: 13px;
  color: #FFFFFF;
  outline: none;
  transition: all 0.2s ease;
}

.bpos-master-header .bpos-global-search input::placeholder {
  color: #64748B;
}

.bpos-master-header .bpos-global-search input:focus {
  background: #18233C;
  border-color: var(--bpos-primary);
  box-shadow: 0 0 0 3px rgba(27, 152, 214, 0.2);
}

.bpos-master-header .bpos-search-icon {
  position: absolute;
  left: 10px;
  color: #64748B;
  font-size: 19px;
  pointer-events: none;
}

.bpos-master-header .bpos-kbd-shortcut {
  position: absolute;
  right: 8px;
  font-size: 10.5px;
  font-weight: 600;
  background: #1E293B;
  border: 1px solid #334155;
  border-radius: 5px;
  padding: 2px 6px;
  color: #94A3B8;
}

.bpos-header-right {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.bpos-master-header .bpos-date-picker-chip {
  display: flex;
  align-items: center;
  gap: 6px;
  background: #131B2E;
  border: 1px solid #1E293B;
  border-radius: 8px;
  padding: 6px 12px;
  font-size: 12px;
  font-weight: 500;
  color: #CBD5E1;
  cursor: pointer;
}

.bpos-master-header .bpos-live-badge {
  display: flex;
  align-items: center;
  gap: 6px;
  background: rgba(16, 185, 129, 0.15);
  border: 1px solid rgba(16, 185, 129, 0.35);
  color: #34D399;
  border-radius: var(--bpos-radius-full);
  padding: 5px 12px;
  font-size: 12px;
  font-weight: 600;
}

.bpos-master-header .bpos-notif-btn {
  background: #131B2E;
  border: 1px solid #1E293B;
  color: #CBD5E1;
}

.bpos-master-header .bpos-notif-btn:hover {
  background: #1E293B;
  color: #FFFFFF;
}

.bpos-master-header .bpos-user-profile {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 4px 10px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  cursor: pointer;
}

.bpos-master-header .bpos-user-avatar {
  width: 28px;
  height: 28px;
  background: var(--bpos-primary);
  color: #FFFFFF;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 11px;
}

.bpos-master-header .bpos-user-role {
  font-size: 10px;
  font-weight: 700;
  line-height: 1.1;
  color: #38BDF8;
  letter-spacing: 0.03em;
}

.bpos-master-header .bpos-user-name {
  font-size: 12px;
  font-weight: 600;
  color: #F8FAFC;
}

.bpos-master-header .bpos-btn-icon-sq {
  background: #131B2E;
  border: 1px solid #1E293B;
  color: #CBD5E1;
}

.bpos-master-header .bpos-btn-icon-sq:hover {
  background: #1E293B;
  color: #38BDF8;
  border-color: #38BDF8;
}

/* ==========================================================================
   TOP NAVIGATION BAR (Exact replica of user screenshot, horizontal)
   ========================================================================== */
.bpos-top-navbar {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 7px 16px;
  background: #070B14;
  overflow-x: auto;
  scrollbar-width: none;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.bpos-top-navbar::-webkit-scrollbar {
  display: none;
}

.bpos-nav-item,
.bpos-side-item {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 13px;
  background: transparent;
  color: #94A3B8;
  border: 1px solid transparent;
  border-radius: 8px;
  font-family: 'Inter', sans-serif;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.18s ease;
  user-select: none;
}

.bpos-nav-item:hover,
.bpos-side-item:hover {
  background: rgba(255, 255, 255, 0.07);
  color: #FFFFFF;
}

.bpos-nav-item.active,
.bpos-side-item.active {
  background: var(--bpos-primary);
  border-color: #38BDF8;
  color: #FFFFFF;
  font-weight: 600;
  box-shadow: 0 4px 14px rgba(27, 152, 214, 0.4);
}

.bpos-nav-icon,
.bpos-side-icon {
  font-size: 18px;
  color: #64748B;
  transition: color 0.18s ease;
}

.bpos-nav-item:hover .bpos-nav-icon,
.bpos-side-item:hover .bpos-side-icon {
  color: #38BDF8;
}

.bpos-nav-item.active .bpos-nav-icon,
.bpos-side-item.active .bpos-side-icon {
  color: #FFFFFF;
}

.bpos-nav-label,
.bpos-side-label {
  display: inline-block;
}

.bpos-nav-badge,
.bpos-side-badge {
  background: var(--bpos-emerald);
  color: #FFFFFF;
  font-size: 10px;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 9999px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  box-shadow: 0 0 8px rgba(16, 185, 129, 0.4);
  margin-left: 2px;
}

.bpos-nav-chevron,
.bpos-side-chevron {
  font-size: 14px;
  color: #475569;
  margin-left: 2px;
  opacity: 0.7;
}

.bpos-nav-item.active .bpos-nav-chevron,
.bpos-side-item.active .bpos-side-chevron {
  color: #FFFFFF;
  opacity: 1;
}

.bpos-status-dot-pulse {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--bpos-emerald);
  box-shadow: 0 0 8px var(--bpos-emerald);
}

/* ==========================================================================
   MAIN CANVAS & TOPBAR
   ========================================================================== */
.bpos-canvas {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-width: 0;
  background: var(--bpos-ground);
}

.bpos-topbar {
  background: #FFFFFF;
  border-bottom: 1px solid var(--bpos-border);
  padding: 12px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.bpos-topbar-left {
  display: flex;
  align-items: center;
  gap: 14px;
  flex: 1;
  max-width: 600px;
}

.bpos-store-chip {
  display: flex;
  align-items: center;
  gap: 8px;
  background: #F1F5F9;
  border: 1px solid var(--bpos-border);
  border-radius: var(--bpos-radius-full);
  padding: 6px 14px;
  font-size: 13px;
  font-weight: 600;
  color: var(--bpos-text-primary);
  white-space: nowrap;
}

.bpos-store-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--bpos-emerald);
}

.bpos-global-search {
  flex: 1;
  position: relative;
  display: flex;
  align-items: center;
}

.bpos-global-search input {
  width: 100%;
  height: 38px;
  padding: 0 80px 0 36px;
  background: #F8FAFC;
  border: 1px solid var(--bpos-border);
  border-radius: 10px;
  font-size: 13px;
  color: var(--bpos-text-primary);
  outline: none;
  transition: all 0.2s ease;
}

.bpos-global-search input:focus {
  background: #FFFFFF;
  border-color: var(--bpos-primary);
  box-shadow: 0 0 0 3px rgba(27, 152, 214, 0.12);
}

.bpos-search-icon {
  position: absolute;
  left: 10px;
  color: var(--bpos-text-muted);
  font-size: 19px;
  pointer-events: none;
}

.bpos-kbd-shortcut {
  position: absolute;
  right: 10px;
  font-size: 11px;
  font-weight: 600;
  background: #FFFFFF;
  border: 1px solid var(--bpos-border);
  border-radius: 6px;
  padding: 2px 6px;
  color: var(--bpos-text-muted);
}

.bpos-topbar-right {
  display: flex;
  align-items: center;
  gap: 12px;
}

.bpos-date-picker-chip {
  display: flex;
  align-items: center;
  gap: 8px;
  background: #FFFFFF;
  border: 1px solid var(--bpos-border);
  border-radius: 10px;
  padding: 6px 12px;
  font-size: 12px;
  font-weight: 500;
  color: var(--bpos-text-secondary);
  cursor: pointer;
}

.bpos-live-badge {
  display: flex;
  align-items: center;
  gap: 6px;
  background: var(--bpos-emerald-subtle);
  border: 1px solid rgba(16, 185, 129, 0.3);
  color: #065F46;
  border-radius: var(--bpos-radius-full);
  padding: 5px 12px;
  font-size: 12px;
  font-weight: 600;
}

.bpos-notif-btn {
  position: relative;
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: #F8FAFC;
  border: 1px solid var(--bpos-border);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--bpos-text-secondary);
  cursor: pointer;
  transition: all 0.2s ease;
}

.bpos-notif-btn:hover {
  background: #FFFFFF;
  color: var(--bpos-text-primary);
}

.bpos-notif-badge {
  position: absolute;
  top: -4px;
  right: -4px;
  background: var(--bpos-secondary);
  color: #FFFFFF;
  font-size: 10px;
  font-weight: 700;
  width: 17px;
  height: 17px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid #FFFFFF;
}

.bpos-user-profile {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 4px 8px;
  border-radius: 10px;
  cursor: pointer;
}

.bpos-user-avatar {
  width: 32px;
  height: 32px;
  background: var(--bpos-dark-navy);
  color: #FFFFFF;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 12px;
}

.bpos-user-meta {
  display: flex;
  flex-direction: column;
}

.bpos-user-role {
  font-size: 12px;
  font-weight: 700;
  line-height: 1.1;
  color: var(--bpos-text-primary);
}

.bpos-user-name {
  font-size: 11px;
  color: var(--bpos-text-muted);
}

.bpos-btn-icon-sq {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: #F8FAFC;
  border: 1px solid var(--bpos-border);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--bpos-text-secondary);
  cursor: pointer;
  transition: all 0.2s ease;
}

.bpos-btn-icon-sq:hover {
  background: #FFFFFF;
  color: var(--bpos-primary);
  border-color: var(--bpos-primary);
}

/* ==========================================================================
   TOP ACTION RIBBON STRIP (IMAGE 1)
   ========================================================================== */
.bpos-ribbon-strip {
  background: #FFFFFF;
  border-bottom: 1px solid var(--bpos-border);
  padding: 8px 24px;
  display: flex;
  align-items: center;
  gap: 8px;
  overflow-x: auto;
}

.bpos-ribbon-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
  white-space: nowrap;
  background: #FFFFFF;
}

.bpos-ribbon-pos {
  color: #EA580C;
  border: 1px solid #FED7AA;
  background: #FFF7ED;
}
.bpos-ribbon-pos:hover {
  background: #FFEDD5;
}

.bpos-ribbon-invoice {
  color: #0284C7;
  border: 1px solid #BAE6FD;
  background: #F0F9FF;
}
.bpos-ribbon-invoice:hover {
  background: #E0F2FE;
}

.bpos-ribbon-return {
  color: #BE123C;
  border: 1px solid #FECDD3;
  background: #FFF1F2;
}
.bpos-ribbon-return:hover {
  background: #FFE4E6;
}

.bpos-ribbon-purchase {
  color: #047857;
  border: 1px solid #A7F3D0;
  background: #ECFDF5;
}
.bpos-ribbon-purchase:hover {
  background: #D1FAE5;
}

.bpos-ribbon-damage {
  color: #B91C1C;
  border: 1px solid #FECACA;
  background: #FEF2F2;
}
.bpos-ribbon-damage:hover {
  background: #FEE2E2;
}

.bpos-ribbon-history {
  color: #6D28D9;
  border: 1px solid #DDD6FE;
  background: #F5F3FF;
}
.bpos-ribbon-history:hover {
  background: #EDE9FE;
}

.bpos-ribbon-khata {
  color: #0E7490;
  border: 1px solid #A5F3FC;
  background: #ECFEFF;
}
.bpos-ribbon-khata:hover {
  background: #CFFAFE;
}

.bpos-ribbon-shift {
  color: #4338CA;
  border: 1px solid #C7D2FE;
  background: #EEF2FF;
}
.bpos-ribbon-shift:hover {
  background: #E0E7FF;
}

/* ==========================================================================
   CONTENT AREA & VIEW PANELS
   ========================================================================== */
.bpos-content-area {
  padding: 24px;
  flex: 1;
  overflow-y: auto;
}

.bpos-view {
  display: none;
}

.bpos-view.active {
  display: block;
  animation: bposFadeIn 0.2s ease-out;
}

@keyframes bposFadeIn {
  from { opacity: 0; transform: translateY(4px); }
  to { opacity: 1; transform: translateY(0); }
}

.bpos-page-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}

.bpos-page-heading {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 24px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--bpos-text-primary);
  margin: 0;
}

.bpos-page-subtitle {
  font-size: 13px;
  color: var(--bpos-text-secondary);
  margin: 4px 0 0 0;
}

.bpos-panel {
  background: var(--bpos-card);
  border: 1px solid var(--bpos-border);
  border-radius: var(--bpos-radius-lg);
  padding: 20px;
  box-shadow: var(--bpos-shadow-sm);
  margin-bottom: 20px;
}

.bpos-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}

.bpos-panel-title {
  display: flex;
  align-items: center;
  gap: 10px;
}

.bpos-panel-title h3 {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 16px;
  font-weight: 700;
  margin: 0;
  color: var(--bpos-text-primary);
}

.bpos-link-arrow {
  font-size: 12px;
  font-weight: 600;
  color: var(--bpos-primary);
  text-decoration: none;
  transition: all 0.15s ease;
}

.bpos-link-arrow:hover {
  color: var(--bpos-primary-hover);
  text-decoration: underline;
}

/* ==========================================================================
   EXECUTIVE DASHBOARD (IMAGE 2)
   ========================================================================== */
.bpos-exec-kpi-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 16px;
  margin-bottom: 20px;
}

.bpos-exec-card {
  background: var(--bpos-card);
  border: 1px solid var(--bpos-border);
  border-radius: var(--bpos-radius-lg);
  padding: 18px 20px;
  box-shadow: var(--bpos-shadow-sm);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 14px;
}

.bpos-exec-card-head {
  display: flex;
  align-items: flex-start;
  gap: 14px;
}

.bpos-icon-box {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.bpos-icon-box span {
  font-size: 22px;
}

.bpos-icon-box-emerald {
  background: var(--bpos-emerald-subtle);
  color: var(--bpos-emerald);
}

.bpos-icon-box-cyan {
  background: var(--bpos-primary-subtle);
  color: var(--bpos-primary);
}

.bpos-icon-box-purple {
  background: var(--bpos-purple-subtle);
  color: var(--bpos-purple);
}

.bpos-icon-box-orange {
  background: #FFF7ED;
  color: var(--bpos-amber);
}

.bpos-exec-label {
  font-size: 12px;
  font-weight: 600;
  color: var(--bpos-text-secondary);
}

.bpos-exec-val {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 22px;
  font-weight: 800;
  color: var(--bpos-text-primary);
  margin-top: 2px;
}

.bpos-exec-card-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.bpos-trend-up {
  font-size: 11px;
  font-weight: 600;
  color: var(--bpos-emerald);
}

.bpos-trend-up small {
  color: var(--bpos-text-muted);
}

.bpos-sparkline {
  width: 90px;
  height: 26px;
}

/* Middle Grid */
.bpos-middle-grid {
  display: grid;
  grid-template-columns: 7fr 5fr;
  gap: 20px;
  margin-bottom: 20px;
}

@media (max-width: 1024px) {
  .bpos-middle-grid {
    grid-template-columns: 1fr;
  }
}

.bpos-chart-container {
  display: flex;
  gap: 12px;
  height: 190px;
  margin-top: 10px;
}

.bpos-chart-y-axis {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  font-size: 10px;
  color: var(--bpos-text-muted);
  padding-bottom: 20px;
}

.bpos-chart-canvas {
  flex: 1;
  display: flex;
  flex-direction: column;
}

.bpos-chart-svg {
  width: 100%;
  height: 155px;
}

.bpos-chart-x-axis {
  display: flex;
  justify-content: space-between;
  font-size: 10px;
  color: var(--bpos-text-muted);
  margin-top: 6px;
}

.bpos-mini-select {
  padding: 4px 10px;
  border-radius: 8px;
  border: 1px solid var(--bpos-border);
  font-size: 12px;
  color: var(--bpos-text-secondary);
  background: #FFFFFF;
}

/* Needs Attention Card */
.bpos-badge-coral {
  background: var(--bpos-secondary-subtle);
  color: var(--bpos-secondary);
  font-size: 11px;
  font-weight: 700;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.bpos-attention-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.bpos-attention-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 8px 10px;
  border-radius: 10px;
  background: var(--bpos-ground);
}

.bpos-dot-bullet {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  margin-top: 5px;
  flex-shrink: 0;
}

.bpos-dot-rose { background: #F43F5E; }
.bpos-dot-amber { background: #F59E0B; }
.bpos-dot-emerald { background: #10B981; }
.bpos-dot-blue { background: #3B82F6; }

.bpos-att-body {
  flex: 1;
}

.bpos-att-title-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12px;
}

.bpos-pill-ok {
  background: #ECFDF5;
  color: #059669;
  font-size: 10px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 6px;
}

.bpos-pill-online {
  background: #EFF6FF;
  color: #2563EB;
  font-size: 10px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 6px;
}

.bpos-panel-footer {
  margin-top: 14px;
  text-align: right;
}

/* Bottom Grid (3 Columns) */
.bpos-bottom-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 20px;
  margin-bottom: 20px;
}

.bpos-activity-feed {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.bpos-activity-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 6px;
  border-radius: 8px;
  transition: background 0.15s ease;
}

.bpos-activity-item:hover {
  background: var(--bpos-ground);
}

.bpos-act-icon {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.bpos-act-body {
  flex: 1;
  font-size: 12px;
}

.bpos-act-arrow {
  color: var(--bpos-text-muted);
  font-size: 16px;
}

/* Top Customers */
.bpos-top-cust-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.bpos-top-cust-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 10px;
  border-radius: 8px;
  transition: background 0.15s ease;
  cursor: pointer;
}

.bpos-top-cust-row:hover {
  background: var(--bpos-ground);
}

.bpos-rank-num {
  font-size: 12px;
  font-weight: 700;
  color: var(--bpos-text-muted);
  width: 14px;
}

.bpos-top-cust-name {
  flex: 1;
  font-size: 13px;
}

.bpos-top-cust-val {
  font-size: 13px;
  color: var(--bpos-text-primary);
}

/* Quick Actions Grid */
.bpos-quick-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
}

.bpos-quick-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid transparent;
  font-family: 'Inter', sans-serif;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  text-align: left;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.bpos-quick-btn:hover {
  transform: translateY(-2px);
  box-shadow: var(--bpos-shadow-sm);
}

.bpos-quick-btn span:first-child {
  font-size: 19px;
}

.bpos-q-green { background: #ECFDF5; color: #047857; border-color: #A7F3D0; }
.bpos-q-sky { background: #F0F9FF; color: #0284C7; border-color: #BAE6FD; }
.bpos-q-purple { background: #F5F3FF; color: #6D28D9; border-color: #DDD6FE; }
.bpos-q-peach { background: #FFF7ED; color: #C2410C; border-color: #FED7AA; }
.bpos-q-teal { background: #F0FDFA; color: #0F766E; border-color: #99F6E4; }
.bpos-q-blue { background: #EFF6FF; color: #1D4ED8; border-color: #BFDBFE; }
.bpos-q-coral { background: #FFF1F2; color: #BE123C; border-color: #FECDD3; }
.bpos-q-slate { background: #F8FAFC; color: #475569; border-color: #E2E8F0; }

/* Explore More Bar */
.bpos-explore-bar {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 14px 20px;
  background: #FFFFFF;
  border: 1px solid var(--bpos-border);
  border-radius: var(--bpos-radius-lg);
  font-size: 12px;
  flex-wrap: wrap;
}

.bpos-explore-bar a {
  color: var(--bpos-text-secondary);
  text-decoration: none;
  font-weight: 600;
  transition: color 0.15s ease;
}

.bpos-explore-bar a:hover {
  color: var(--bpos-primary);
}

/* ==========================================================================
   SALE INVOICES VIEW (IMAGE 1)
   ========================================================================== */
.bpos-invoices-card {
  background: #FFFFFF;
  border: 1px solid var(--bpos-border);
  border-radius: var(--bpos-radius-lg);
  box-shadow: var(--bpos-shadow-sm);
  overflow: hidden;
}

.bpos-invoices-header {
  padding: 18px 24px;
  border-bottom: 1px solid var(--bpos-border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.bpos-invoices-title-group {
  display: flex;
  align-items: center;
  gap: 10px;
}

.bpos-invoices-title-group h2 {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 20px;
  font-weight: 700;
  color: var(--bpos-text-primary);
  margin: 0;
}

.bpos-counter-pill {
  background: #F1F5F9;
  color: var(--bpos-text-secondary);
  font-size: 12px;
  font-weight: 700;
  padding: 2px 9px;
  border-radius: var(--bpos-radius-full);
}

.bpos-invoices-controls {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.bpos-invoice-search-box {
  position: relative;
  display: flex;
  align-items: center;
}

.bpos-invoice-search-box input {
  height: 38px;
  padding: 0 14px 0 34px;
  background: #FFFFFF;
  border: 1px solid var(--bpos-border);
  border-radius: 8px;
  font-size: 13px;
  color: var(--bpos-text-primary);
  outline: none;
}

.bpos-invoice-search-box span {
  position: absolute;
  left: 10px;
}

.bpos-select-pill {
  height: 38px;
  padding: 0 12px;
  border-radius: 8px;
  border: 1px solid var(--bpos-border);
  background: #FFFFFF;
  font-size: 13px;
  color: var(--bpos-text-secondary);
}

.bpos-btn-orange {
  background: var(--bpos-orange);
  color: #FFFFFF;
  border: none;
  border-radius: 8px;
  padding: 9px 18px;
  font-size: 13px;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(249, 115, 22, 0.3);
  transition: all 0.15s ease;
}

.bpos-btn-orange:hover {
  background: var(--bpos-orange-hover);
}

/* ==========================================================================
   RACKS TABLES (IMAGE 1 SPEC)
   ========================================================================== */
.bpos-table-responsive {
  overflow-x: auto;
}

.bpos-racks-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
  text-align: left;
}

.bpos-racks-table thead tr {
  background: #FAFAFA;
  border-bottom: 1px solid var(--bpos-border);
}

.bpos-racks-table th {
  padding: 14px 20px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.05em;
  color: var(--bpos-text-muted);
  text-transform: uppercase;
}

.bpos-racks-table tbody tr {
  border-bottom: 1px solid var(--bpos-border-subtle);
  transition: background 0.15s ease;
}

.bpos-racks-table tbody tr:hover {
  background: #F8FAFC;
}

.bpos-racks-table td {
  padding: 16px 20px;
  color: var(--bpos-text-primary);
  vertical-align: middle;
}

.bpos-pill-status-pending {
  background: var(--bpos-secondary-subtle);
  color: var(--bpos-secondary);
  border: 1px solid rgba(255, 75, 110, 0.2);
  padding: 4px 12px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 600;
  display: inline-block;
}

.bpos-pill-status-paid {
  background: var(--bpos-emerald-subtle);
  color: #065F46;
  border: 1px solid rgba(16, 185, 129, 0.2);
  padding: 4px 12px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 600;
  display: inline-block;
}

.bpos-btn-edit-pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 6px 12px;
  border-radius: 6px;
  background: #FFFFFF;
  border: 1px solid var(--bpos-border);
  color: var(--bpos-text-secondary);
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
}

.bpos-btn-edit-pill:hover {
  border-color: var(--bpos-primary);
  color: var(--bpos-primary);
  background: var(--bpos-primary-subtle);
}

/* ==========================================================================
   POS TERMINAL LAYOUT
   ========================================================================== */
.bpos-pos-layout {
  display: grid;
  grid-template-columns: 1fr 380px;
  gap: 20px;
}

@media (max-width: 1024px) {
  .bpos-pos-layout {
    grid-template-columns: 1fr;
  }
}

.bpos-catalog-col {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.bpos-search-bar-wrap {
  display: flex;
  align-items: center;
  gap: 14px;
  background: #FFFFFF;
  padding: 12px 16px;
  border-radius: var(--bpos-radius-lg);
  border: 1px solid var(--bpos-border);
  box-shadow: var(--bpos-shadow-sm);
}

.bpos-search-input-box {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 8px;
}

.bpos-search-input-box input {
  width: 100%;
  border: none;
  outline: none;
  font-size: 14px;
  color: var(--bpos-text-primary);
  background: transparent;
}

.bpos-pricing-switch {
  display: flex;
  align-items: center;
  gap: 10px;
  border-left: 1px solid var(--bpos-border);
  padding-left: 14px;
}

/* Toggle Switch */
.bpos-toggle-switch {
  position: relative;
  display: inline-block;
  width: 44px;
  height: 24px;
}
.bpos-toggle-switch input { opacity: 0; width: 0; height: 0; }
.bpos-slider {
  position: absolute;
  cursor: pointer;
  inset: 0;
  background-color: #CBD5E1;
  transition: 0.3s;
  border-radius: 24px;
}
.bpos-slider:before {
  position: absolute;
  content: "";
  height: 18px;
  width: 18px;
  left: 3px;
  bottom: 3px;
  background-color: white;
  transition: 0.3s;
  border-radius: 50%;
}
input:checked + .bpos-slider { background-color: var(--bpos-primary); }
input:checked + .bpos-slider:before { transform: translateX(20px); }

/* Category Pills */
.bpos-cat-pills {
  display: flex;
  align-items: center;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 4px;
}

.bpos-cat-pill {
  padding: 8px 16px;
  border-radius: var(--bpos-radius-full);
  background: #FFFFFF;
  border: 1px solid var(--bpos-border);
  font-size: 12px;
  font-weight: 600;
  color: var(--bpos-text-secondary);
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.15s ease;
}

.bpos-cat-pill:hover {
  background: #F1F5F9;
  color: var(--bpos-text-primary);
}

.bpos-cat-pill.active {
  background: var(--bpos-primary);
  color: #FFFFFF;
  border-color: var(--bpos-primary);
  box-shadow: 0 2px 8px rgba(27, 152, 214, 0.3);
}

/* Product Cards Grid */
.bpos-prod-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 14px;
}

.bpos-prod-card {
  background: #FFFFFF;
  border: 1px solid var(--bpos-border);
  border-radius: var(--bpos-radius-lg);
  padding: 14px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 12px;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease;
  box-shadow: var(--bpos-shadow-sm);
}

.bpos-prod-card:hover {
  transform: translateY(-2px);
  border-color: var(--bpos-primary);
  box-shadow: var(--bpos-shadow);
}

.bpos-prod-card.out-of-stock {
  opacity: 0.55;
  cursor: not-allowed;
}

.bpos-card-top-badges {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 6px;
}

.bpos-sku-badge {
  font-size: 10px;
  font-weight: 700;
  background: #F1F5F9;
  color: var(--bpos-text-secondary);
  padding: 2px 6px;
  border-radius: 4px;
}

.bpos-stock-badge {
  font-size: 10px;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 4px;
}

.bpos-stock-badge.in-stock {
  background: #ECFDF5;
  color: #059669;
}

.bpos-stock-badge.low-stock {
  background: #FEF3C7;
  color: #D97706;
}

.bpos-stock-badge.out-stock {
  background: #FEE2E2;
  color: #DC2626;
}

.bpos-prod-name {
  font-size: 13px;
  font-weight: 600;
  color: var(--bpos-text-primary);
  line-height: 1.3;
}

.bpos-prod-price-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  border-top: 1px dashed var(--bpos-border);
  padding-top: 8px;
}

.bpos-prod-price {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 16px;
  font-weight: 800;
  color: var(--bpos-primary);
}

/* Cart Column */
.bpos-cart-col {
  background: #FFFFFF;
  border: 1px solid var(--bpos-border);
  border-radius: var(--bpos-radius-lg);
  padding: 16px;
  display: flex;
  flex-direction: column;
  box-shadow: var(--bpos-shadow-sm);
  height: fit-content;
}

.bpos-cust-picker-box {
  margin-bottom: 14px;
}

.bpos-cust-label-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 6px;
}

.bpos-select {
  width: 100%;
  height: 40px;
  padding: 0 12px;
  border-radius: 8px;
  border: 1px solid var(--bpos-border);
  font-size: 13px;
  background: #FFFFFF;
  color: var(--bpos-text-primary);
  outline: none;
}

.bpos-select:focus {
  border-color: var(--bpos-primary);
  box-shadow: 0 0 0 3px rgba(27, 152, 214, 0.12);
}

.bpos-cust-credit-banner {
  background: #FFFBEB;
  border: 1px solid #FCD34D;
  border-radius: 8px;
  padding: 8px 10px;
  margin-top: 8px;
  font-size: 11px;
  display: flex;
  justify-content: space-between;
  color: #92400E;
}

.bpos-cart-items-wrap {
  min-height: 220px;
  max-height: 340px;
  overflow-y: auto;
  border-top: 1px solid var(--bpos-border);
  border-bottom: 1px solid var(--bpos-border);
  padding: 10px 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.bpos-empty-cart {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 40px 10px;
  color: var(--bpos-text-muted);
}

.bpos-empty-cart p {
  margin: 8px 0 2px 0;
  font-size: 13px;
  font-weight: 600;
  color: var(--bpos-text-secondary);
}

.bpos-cart-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 8px;
  border-radius: 8px;
  background: #F8FAFC;
  border: 1px solid var(--bpos-border);
}

.bpos-cart-item-info {
  flex: 1;
}

.bpos-cart-item-title {
  font-size: 12px;
  font-weight: 600;
  color: var(--bpos-text-primary);
}

.bpos-cart-item-sub {
  font-size: 11px;
  color: var(--bpos-text-muted);
}

.bpos-qty-controls {
  display: flex;
  align-items: center;
  gap: 6px;
}

.bpos-qty-btn {
  width: 24px;
  height: 24px;
  border-radius: 6px;
  background: #FFFFFF;
  border: 1px solid var(--bpos-border);
  font-weight: bold;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.bpos-qty-val {
  font-size: 12px;
  font-weight: bold;
  min-width: 20px;
  text-align: center;
}

.bpos-cart-item-total {
  font-size: 13px;
  font-weight: 700;
  min-width: 60px;
  text-align: right;
  color: var(--bpos-text-primary);
}

.bpos-item-remove {
  background: transparent;
  border: none;
  color: var(--bpos-text-muted);
  cursor: pointer;
  font-size: 13px;
}
.bpos-item-remove:hover { color: #DC2626; }

/* Cart Calculations */
.bpos-cart-footer {
  padding-top: 14px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.bpos-cart-calc-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12px;
  color: var(--bpos-text-secondary);
}

.bpos-mini-input {
  width: 50px;
  height: 26px;
  border-radius: 6px;
  border: 1px solid var(--bpos-border);
  text-align: center;
  font-size: 11px;
}

.bpos-cart-total-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-top: 1px solid var(--bpos-border);
  padding-top: 8px;
  font-size: 14px;
  font-weight: 600;
}

.bpos-cart-total-row span:last-child {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 20px;
  font-weight: 800;
  color: var(--bpos-primary);
}

.bpos-cart-actions {
  display: flex;
  gap: 8px;
  margin-top: 6px;
}

.bpos-btn-pay {
  flex: 1;
  background: var(--bpos-primary);
  color: #FFFFFF;
  border: none;
  border-radius: 10px;
  padding: 12px;
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(27, 152, 214, 0.35);
  transition: all 0.15s ease;
}

.bpos-btn-pay:hover {
  background: var(--bpos-primary-hover);
}

/* ==========================================================================
   BUTTONS & FORM ELEMENTS
   ========================================================================== */
.bpos-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 18px;
  border-radius: 8px;
  font-family: 'Inter', sans-serif;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
  border: 1px solid transparent;
}

.bpos-btn-primary {
  background: var(--bpos-primary);
  color: #FFFFFF;
  box-shadow: 0 4px 14px rgba(27, 152, 214, 0.25);
}
.bpos-btn-primary:hover {
  background: var(--bpos-primary-hover);
}

.bpos-btn-secondary {
  background: #FFFFFF;
  border-color: var(--bpos-border);
  color: var(--bpos-text-primary);
}
.bpos-btn-secondary:hover {
  background: #F8FAFC;
  border-color: #CBD5E1;
}

.bpos-btn-danger {
  background: var(--bpos-secondary);
  color: #FFFFFF;
  box-shadow: 0 4px 14px rgba(255, 75, 110, 0.3);
}

.bpos-input {
  width: 100%;
  height: 42px;
  padding: 0 14px;
  border-radius: 8px;
  border: 1px solid var(--bpos-border);
  background: #FFFFFF;
  font-size: 13px;
  color: var(--bpos-text-primary);
  outline: none;
  transition: all 0.15s ease;
}

.bpos-input:focus {
  border-color: var(--bpos-primary);
  box-shadow: 0 0 0 3px rgba(27, 152, 214, 0.12);
}

.bpos-large-input {
  height: 50px;
  font-size: 18px;
  font-weight: 700;
}

.bpos-form-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
}

.bpos-col-2 {
  grid-column: span 2;
}

.bpos-filter-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}

.bpos-checkbox-label {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  cursor: pointer;
}

/* ==========================================================================
   CUSTOMER CARDS GRID
   ========================================================================== */
.bpos-customers-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 16px;
}

.bpos-cust-card {
  background: #FFFFFF;
  border: 1px solid var(--bpos-border);
  border-radius: var(--bpos-radius-lg);
  padding: 16px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 14px;
  box-shadow: var(--bpos-shadow-sm);
}

/* ==========================================================================
   MODALS
   ========================================================================== */
.bpos-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(11, 17, 32, 0.6);
  backdrop-filter: blur(4px);
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.bpos-modal {
  background: #FFFFFF;
  border-radius: var(--bpos-radius-lg);
  width: 100%;
  max-width: 520px;
  max-height: 90vh;
  overflow-y: auto;
  padding: 24px;
  box-shadow: var(--bpos-shadow-lg);
  border: 1px solid var(--bpos-border);
}

.bpos-large-modal {
  max-width: 800px;
}

.bpos-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
  border-bottom: 1px solid var(--bpos-border);
  padding-bottom: 12px;
}

.bpos-modal-header h3 {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 18px;
  font-weight: 700;
  margin: 0;
  color: var(--bpos-text-primary);
}

.bpos-modal-close {
  background: transparent;
  border: none;
  font-size: 20px;
  color: var(--bpos-text-muted);
  cursor: pointer;
}
.bpos-modal-close:hover { color: var(--bpos-text-primary); }

.bpos-checkout-banner {
  background: var(--bpos-ground);
  border: 1px solid var(--bpos-border);
  border-radius: 12px;
  padding: 14px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}

.bpos-checkout-price {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 24px;
  font-weight: 800;
  color: var(--bpos-primary);
}

.bpos-tender-tabs {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  margin-bottom: 16px;
}

.bpos-tender-btn {
  padding: 10px;
  border-radius: 8px;
  border: 1px solid var(--bpos-border);
  background: #FFFFFF;
  font-size: 12px;
  font-weight: 600;
  color: var(--bpos-text-secondary);
  cursor: pointer;
  text-align: center;
  transition: all 0.15s ease;
}

.bpos-tender-btn.active {
  background: var(--bpos-primary);
  color: #FFFFFF;
  border-color: var(--bpos-primary);
}

.bpos-quick-cash-chips {
  display: flex;
  gap: 8px;
  margin: 10px 0;
  flex-wrap: wrap;
}

.bpos-chip {
  padding: 6px 12px;
  border-radius: 6px;
  border: 1px solid var(--bpos-border);
  background: #FFFFFF;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
}

.bpos-change-box {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: var(--bpos-emerald-subtle);
  border: 1px solid rgba(16, 185, 129, 0.3);
  border-radius: 8px;
  padding: 10px 14px;
  margin-top: 10px;
  font-size: 13px;
}

.bpos-modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 24px;
}

/* Receipt Modal Styles */
.bpos-receipt-modal {
  max-width: 680px;
}

.bpos-toggle-receipt-type {
  display: flex;
  gap: 6px;
  margin-top: 6px;
}

.bpos-pill-tab {
  padding: 4px 10px;
  border-radius: 6px;
  border: 1px solid var(--bpos-border);
  background: #FFFFFF;
  font-size: 11px;
  cursor: pointer;
}

.bpos-pill-tab.active {
  background: var(--bpos-primary);
  color: #FFFFFF;
  border-color: var(--bpos-primary);
}

.bpos-receipt-preview-wrap {
  background: #F1F5F9;
  padding: 20px;
  border-radius: 12px;
  border: 1px solid var(--bpos-border);
  max-height: 480px;
  overflow-y: auto;
}

.bpos-printable-area {
  background: #FFFFFF;
  padding: 24px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

/* Variance Banner */
.bpos-variance-banner {
  padding: 12px 16px;
  border-radius: 8px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 14px;
}

.bpos-variance-banner.balanced {
  background: var(--bpos-emerald-subtle);
  color: #065F46;
  border: 1px solid rgba(16, 185, 129, 0.3);
}

.bpos-variance-banner.surplus {
  background: #EFF6FF;
  color: #1D4ED8;
  border: 1px solid rgba(59, 130, 246, 0.3);
}

.bpos-variance-banner.shortage {
  background: var(--bpos-secondary-subtle);
  color: var(--bpos-secondary);
  border: 1px solid rgba(255, 75, 110, 0.3);
}

/* ==========================================================================
   FULLSCREEN MODE
   ========================================================================== */
body.bpos-fullscreen #adminmenumain,
body.bpos-fullscreen #wpadminbar,
body.bpos-fullscreen #wpfooter {
  display: none !important;
}

body.bpos-fullscreen #wpcontent,
body.bpos-fullscreen #wpbody-content {
  margin: 0 !important;
  padding: 0 !important;
}

body.bpos-fullscreen .bpos-wrap {
  margin: 0 !important;
}

body.bpos-fullscreen .bpos-app.bpos-racks-layout {
  border-radius: 0 !important;
  border: none !important;
  min-height: 100vh !important;
  height: 100vh !important;
}

/* ==========================================================================
   PRINT STYLES (80mm & A4)
   ========================================================================== */
@media print {
  body * {
    visibility: hidden;
  }

  #bpos-printable-container,
  #bpos-printable-container * {
    visibility: visible;
  }

  #bpos-printable-container {
    position: absolute;
    left: 0;
    top: 0;
    width: 100%;
    margin: 0;
    padding: 0;
    box-shadow: none;
  }

  .no-print {
    display: none !important;
  }

  body.bpos-printing-barcodes * {
    visibility: hidden;
  }

  body.bpos-printing-barcodes #bpos-barcode-printable-area,
  body.bpos-printing-barcodes #bpos-barcode-printable-area * {
    visibility: visible;
  }

  body.bpos-printing-barcodes #bpos-barcode-printable-area {
    position: absolute;
    left: 0;
    top: 0;
    width: 100%;
    margin: 0;
    padding: 0;
  }
}

/* ==========================================================================
   BARCODE STICKER STUDIO STYLES (50mm x 25mm)
   ========================================================================== */
.bpos-sticker-card {
  width: 200px;
  height: 105px;
  background: #FFFFFF;
  border: 1px solid #CBD5E1;
  border-radius: 6px;
  padding: 6px 8px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
  box-sizing: border-box;
  text-align: center;
  overflow: hidden;
  font-family: 'Inter', sans-serif;
}

.bpos-sticker-store {
  font-size: 9px;
  font-weight: 800;
  color: #0F172A;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.1;
}

.bpos-sticker-name {
  font-size: 10px;
  font-weight: 600;
  color: #334155;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.1;
  margin: 1px 0;
}

.bpos-sticker-barcode-wrap {
  display: flex;
  justify-content: center;
  align-items: center;
  height: 48px;
  margin: 1px 0;
  overflow: hidden;
}

.bpos-sticker-barcode-wrap svg {
  max-width: 100%;
  max-height: 46px;
}

.bpos-sticker-foot {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 10px;
  border-top: 0.5px dashed #CBD5E1;
  padding-top: 2px;
  line-height: 1;
}

.bpos-sticker-sku {
  font-size: 8px;
  font-weight: 600;
  color: #64748B;
}

.bpos-sticker-price {
  font-size: 11px;
  font-weight: 800;
  color: #0F172A;
}

/* Printable sheet layout */
.bpos-barcode-sheet-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 10px;
}

@page {
  margin: 0;
}

/* ==========================================================================
   FINANCIAL STATEMENTS STYLES
   ========================================================================== */
.bpos-fin-statement {
  background: #FFFFFF;
  border: 1px solid var(--bpos-border);
  border-radius: var(--bpos-radius);
  padding: 24px;
  box-shadow: var(--bpos-shadow-sm);
}

.bpos-fin-section-title {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 14px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--bpos-primary);
  margin: 16px 0 8px 0;
  padding-bottom: 4px;
  border-bottom: 2px solid var(--bpos-primary);
}

.bpos-fin-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 0;
  border-bottom: 1px solid #F1F5F9;
  font-size: 13px;
}

.bpos-fin-row.total-row {
  font-weight: 700;
  font-size: 14px;
  border-top: 1px solid var(--bpos-border);
  border-bottom: 2px solid var(--bpos-border);
  padding: 10px 0;
  margin-top: 6px;
  background: #F8FAFC;
}

.bpos-fin-row.net-profit-row {
  font-weight: 800;
  font-size: 16px;
  color: #059669;
  border-top: 2px solid #059669;
  border-bottom: 3px double #059669;
  padding: 12px 0;
  margin-top: 10px;
}

/* ==========================================================================
   PHASE 1: AUTHENTICATION & PIN NUMPAD STYLES
   ========================================================================== */
.bpos-quick-user-btn {
  transition: all 0.15s ease;
}
.bpos-quick-user-btn:hover {
  border-color: var(--bpos-primary) !important;
  background: #f0f9ff !important;
  box-shadow: 0 2px 8px rgba(27, 152, 214, 0.15);
}
.bpos-pin-key {
  height: 48px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  font-size: 18px;
  font-weight: 600;
  color: #0f172a;
  cursor: pointer;
  transition: all 0.12s ease;
  user-select: none;
  display: flex;
  align-items: center;
  justify-content: center;
}
.bpos-pin-key:hover {
  background: #e2e8f0;
  border-color: #cbd5e1;
}
.bpos-pin-key:active {
  transform: scale(0.96);
}
.bpos-pin-key.bpos-pin-submit:hover {
  background: var(--bpos-primary-hover) !important;
}

/* ==========================================================================
   PHASE 2: BUSINESS, BRANCH & WAREHOUSE STYLES
   ========================================================================== */
.bpos-org-tab-btn {
  padding: 8px 16px;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  color: #64748b;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: all 0.15s ease;
  white-space: nowrap;
}
.bpos-org-tab-btn:hover {
  color: #0f172a;
  background: #f1f5f9;
  border-color: #cbd5e1;
}
.bpos-org-tab-btn.active {
  background: var(--bpos-primary) !important;
  color: #ffffff !important;
  border-color: var(--bpos-primary) !important;
  box-shadow: 0 2px 6px rgba(27, 152, 214, 0.35);
}

.bpos-branch-popover-item {
  padding: 10px 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  transition: background 0.15s ease;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}
.bpos-branch-popover-item:last-child {
  border-bottom: none;
}
.bpos-branch-popover-item:hover {
  background: #1e293b;
}
.bpos-branch-popover-item.active {
  background: rgba(27, 152, 214, 0.18);
  border-left: 3px solid #38bdf8;
}
.bpos-badge-ho {
  background: rgba(16, 185, 129, 0.15);
  color: #10b981;
  border: 1px solid rgba(16, 185, 129, 0.3);
  font-size: 10px;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 4px;
  letter-spacing: 0.02em;
}
.bpos-badge-sub {
  background: rgba(148, 163, 184, 0.15);
  color: #94a3b8;
  border: 1px solid rgba(148, 163, 184, 0.3);
  font-size: 10px;
  font-weight: 600;
  padding: 2px 6px;
  border-radius: 4px;
}

/* ==========================================================================
   PHASE 3: PRODUCTS, VARIANTS & BARCODE STUDIO STYLES
   ========================================================================== */
.bpos-badge-type {
  font-size: 10px;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 4px;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}
.bpos-badge-type-simple {
  background: #f1f5f9;
  color: #475569;
}
.bpos-badge-type-variable {
  background: rgba(139, 92, 246, 0.15);
  color: #8b5cf6;
  border: 1px solid rgba(139, 92, 246, 0.3);
}
.bpos-badge-type-weighted {
  background: rgba(14, 165, 233, 0.15);
  color: #0284c7;
  border: 1px solid rgba(14, 165, 233, 0.3);
}
.bpos-badge-type-batch {
  background: rgba(245, 158, 11, 0.15);
  color: #d97706;
  border: 1px solid rgba(245, 158, 11, 0.3);
}

#bpos-variants-matrix-table th, #bpos-variants-matrix-table td {
  padding: 6px 8px;
}
#bpos-variants-matrix-table input {
  padding: 4px 6px;
  font-size: 12px;
  height: 28px;
}

/* Barcode Studio Printable Presets */
.bpos-barcode-sheet-grid.preset-50x25 .bpos-sticker-card {
  width: 50mm;
  height: 25mm;
  page-break-inside: avoid;
}
.bpos-barcode-sheet-grid.preset-38x25 .bpos-sticker-card {
  width: 38mm;
  height: 25mm;
  page-break-inside: avoid;
}
.bpos-barcode-sheet-grid.preset-70x35 .bpos-sticker-card {
  width: 70mm;
  height: 35mm;
  page-break-inside: avoid;
}
.bpos-barcode-sheet-grid.preset-a4-40 {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 2mm;
  width: 210mm;
}

/* ==========================================================================
   PHASE 4: PERPETUAL INVENTORY, BATCHES & LOGISTICS STYLES
   ========================================================================== */
.bpos-pill-mv {
  display: inline-block;
  font-size: 10px;
  font-weight: 700;
  padding: 3px 7px;
  border-radius: 4px;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}
.bpos-pill-mv-opening { background: rgba(99, 102, 241, 0.15); color: #6366f1; border: 1px solid rgba(99, 102, 241, 0.3); }
.bpos-pill-mv-purchase { background: rgba(16, 185, 129, 0.15); color: #10b981; border: 1px solid rgba(16, 185, 129, 0.3); }
.bpos-pill-mv-sale { background: rgba(245, 158, 11, 0.15); color: #d97706; border: 1px solid rgba(245, 158, 11, 0.3); }
.bpos-pill-mv-transfer_in { background: rgba(14, 165, 233, 0.15); color: #0284c7; border: 1px solid rgba(14, 165, 233, 0.3); }
.bpos-pill-mv-transfer_out { background: rgba(244, 63, 94, 0.15); color: #e11d48; border: 1px solid rgba(244, 63, 94, 0.3); }
.bpos-pill-mv-customer_return { background: rgba(16, 185, 129, 0.15); color: #059669; border: 1px solid rgba(16, 185, 129, 0.3); }
.bpos-pill-mv-adjustment_in { background: rgba(20, 184, 166, 0.15); color: #0d9488; border: 1px solid rgba(20, 184, 166, 0.3); }
.bpos-pill-mv-adjustment_out { background: rgba(239, 68, 68, 0.15); color: #dc2626; border: 1px solid rgba(239, 68, 68, 0.3); }

/* Batch Expiry Badges */
.bpos-batch-pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 11px;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 9999px;
}
.bpos-batch-active { background: #dcfce7; color: #15803d; border: 1px solid #bbf7d0; }
.bpos-batch-expiring { background: #fef3c7; color: #b45309; border: 1px solid #fde68a; }
.bpos-batch-expired { background: #fee2e2; color: #b91c1c; border: 1px solid #fecaca; }

/* Transfer Status Badges */
.bpos-trf-pill {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 9999px;
}
.bpos-trf-transit { background: #e0f2fe; color: #0369a1; border: 1px solid #bae6fd; }
.bpos-trf-received { background: #dcfce7; color: #15803d; border: 1px solid #bbf7d0; }

/* ==========================================================================
   PHASE 5: POS COUNTER STATION, HOTKEYS & MULTI-TENDER STYLES
   ========================================================================== */
.bpos-hotkey-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: #ffffff;
  border: 1px solid #cbd5e1;
  padding: 4px 8px;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 600;
  color: #334155;
  cursor: pointer;
  transition: all 0.15s ease;
}
.bpos-hotkey-pill:hover {
  background: #f1f5f9;
  border-color: #94a3b8;
  transform: translateY(-1px);
}
.bpos-hotkey-pill kbd, .bpos-kbd {
  display: inline-block;
  padding: 1px 5px;
  font-family: monospace;
  font-size: 10px;
  background: #0f172a;
  color: #f8fafc;
  border-radius: 4px;
  box-shadow: 0 1px 2px rgba(0,0,0,0.15);
}
.bpos-hotkey-primary {
  background: #059669 !important;
  color: #ffffff !important;
  border-color: #047857 !important;
}
.bpos-hotkey-primary kbd {
  background: #064e3b !important;
  color: #a7f3d0 !important;
}
.bpos-vp-variant-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 12px;
  cursor: pointer;
  transition: all 0.15s ease;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}
.bpos-vp-variant-card:hover {
  border-color: #6366f1;
  background: #f5f3ff;
  box-shadow: 0 4px 12px rgba(99, 102, 241, 0.1);
  transform: translateY(-2px);
}

/* ==========================================================================
   PHASE 6: SALES ORDER LIFECYCLE & CREDIT NOTES
   ========================================================================== */
.bpos-order-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 8px;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}
.bpos-order-badge-quotation {
  background: #fef3c7;
  color: #b45309;
  border: 1px solid #fde68a;
}
.bpos-order-badge-confirmed {
  background: #e0f2fe;
  color: #0369a1;
  border: 1px solid #bae6fd;
}
.bpos-order-badge-packed {
  background: #ede9fe;
  color: #6d28d9;
  border: 1px solid #ddd6fe;
}
.bpos-order-badge-shipped {
  background: #fae8ff;
  color: #86198f;
  border: 1px solid #f5d0fe;
}
.bpos-order-badge-delivered {
  background: #dcfce7;
  color: #15803d;
  border: 1px solid #bbf7d0;
}
.bpos-order-badge-cancelled {
  background: #ffe4e6;
  color: #be123c;
  border: 1px solid #fecdd3;
}

.bpos-badge-credit-note {
  background: #fdf2f8;
  color: #be185d;
  border: 1px solid #fbcfe8;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 11px;
}

.bpos-sales-subtabs {
  display: flex;
  gap: 8px;
  padding: 8px 16px;
  background: #f8fafc;
  border-bottom: 1px solid #e2e8f0;
}
.bpos-sales-subtab-btn {
  padding: 6px 14px;
  font-size: 12.5px;
  font-weight: 600;
  color: #64748b;
  background: transparent;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: all 0.15s ease;
}
.bpos-sales-subtab-btn.active {
  background: #ffffff;
  color: #0f172a;
  box-shadow: 0 1px 3px rgba(0,0,0,0.08);
  font-weight: 700;
}

.bpos-order-info-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 12px;
  margin-bottom: 16px;
}
.bpos-order-info-card {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 12px;
}
.bpos-order-info-card span.label {
  font-size: 11px;
  font-weight: 600;
  color: #64748b;
  text-transform: uppercase;
  display: block;
  margin-bottom: 4px;
}
.bpos-order-info-card div.val {
  font-size: 13.5px;
  font-weight: 700;
  color: #0f172a;
}

.bpos-ret-item-row {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 12px;
  margin-bottom: 10px;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr 1fr;
  gap: 10px;
  align-items: center;
}
